:root {
  --bg: #1c1c24;
  --panel: #2a2a47;
  --panel-focus: #30304f;
  --text: #ffffff;
  --muted: rgba(255, 255, 255, 0.66);
  --soft: rgba(255, 255, 255, 0.58);
  --footer: #575769;
  --accent: #8c70ff;
  --accent-hover: #967dff;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  margin: 0;
  overflow-x: hidden;
  color: var(--text);
  background:
    radial-gradient(70% 55% at 56% 16%, rgba(140, 112, 255, 0.09) 0%, rgba(140, 112, 255, 0.025) 45%, transparent 78%),
    radial-gradient(54% 42% at 74% 34%, rgba(160, 76, 126, 0.09) 0%, rgba(160, 76, 126, 0.022) 50%, transparent 80%),
    linear-gradient(180deg, #14141c 0%, #171720 100%);
  font-family: "Source Sans 3", "Source Sans Pro", Arial, Helvetica, sans-serif;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -2;
  content: "";
  background:
    linear-gradient(180deg, rgba(8, 8, 12, 0.45), rgba(12, 12, 18, 0.2) 44%, rgba(10, 10, 15, 0.62)),
    url("assets/brand/digital-spell-bg.jpg");
  background-size: cover;
  background-position: center top;
  opacity: 0.58;
}

body::after {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  content: "";
  background:
    radial-gradient(52rem 34rem at 50% 12%, rgba(140, 112, 255, 0.1), transparent 76%),
    linear-gradient(90deg, rgba(255, 255, 255, 0.012), transparent 32%, rgba(255, 255, 255, 0.01));
}

a {
  color: inherit;
}

.site-shell,
.site-header {
  width: min(100%, 76rem);
}

.site-shell {
  margin: 0 auto;
  padding: 0 2rem 1.5rem;
}

.site-header {
  position: fixed;
  top: 0;
  left: 50%;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.1rem 2rem;
  transform: translateX(-50%);
}

.brand-mark {
  display: inline-flex;
  width: 8.6rem;
  align-items: center;
  opacity: 0.94;
}

.brand-mark img {
  width: 100%;
  height: auto;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.language-switcher {
  display: inline-flex;
  gap: 0.35rem;
  padding: 0.25rem;
  border: 1px solid rgba(140, 112, 255, 0.32);
  border-radius: 999px;
  background: rgba(28, 28, 36, 0.62);
  backdrop-filter: blur(12px);
}

.primary-button,
.submit-button {
  min-height: 2.75rem;
  border-radius: 1.25rem;
  font: inherit;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1;
}

.language-switcher button {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  min-height: 2rem;
  padding: 0.22rem 0.55rem 0.22rem 0.28rem;
  border: 0;
  border-radius: 999px;
  color: var(--muted);
  background: transparent;
  font: inherit;
  font-size: 0.72rem;
  font-weight: 800;
  line-height: 1;
  cursor: pointer;
}

.language-switcher img {
  width: 1.35rem;
  height: 1.35rem;
  border-radius: 0.38rem;
  object-fit: cover;
}

.language-switcher button.is-active {
  color: var(--text);
  background: var(--accent);
}

.primary-button,
.submit-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 3px solid var(--accent);
  color: var(--accent);
  background: transparent;
  text-decoration: none;
  cursor: pointer;
  transition:
    color 180ms ease,
    border-color 180ms ease,
    transform 180ms ease;
}

.primary-button,
.submit-button {
  min-width: 9.5rem;
  padding: 0 1.7rem;
}

.primary-button:hover,
.submit-button:hover {
  border-color: var(--accent-hover);
  color: var(--accent-hover);
  transform: scale(1.025);
}

.hero-section {
  position: relative;
  display: grid;
  min-height: 72vh;
  place-items: center;
  padding: 6.2rem 0 1.6rem;
  text-align: center;
}

.hero-lockup {
  position: relative;
  z-index: 1;
  display: grid;
  width: min(100%, 48rem);
  justify-items: center;
  gap: 1.15rem;
}

.hero-lockup h1,
.content-section h2 {
  margin: 0;
  color: var(--text);
  font-weight: 600;
  letter-spacing: 0;
}

.hero-lockup h1 {
  display: grid;
  gap: 0.42rem;
  margin-top: 0;
  font-size: clamp(2rem, 4.55vw, 3.25rem);
  line-height: 1.2;
}

.hero-lockup p {
  max-width: 48rem;
  margin: 0;
  color: var(--soft);
  font-size: clamp(1rem, 2.1vw, 1.15rem);
  font-weight: 300;
  line-height: 1.75;
}

.content-section {
  display: grid;
  justify-items: center;
  padding: clamp(1.9rem, 4.8vw, 3.6rem) 0;
  text-align: center;
}

.kicker {
  margin: 0 0 1.2rem;
  color: var(--accent);
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.6;
  text-transform: uppercase;
  letter-spacing: 0.2rem;
}

.content-section h2 {
  max-width: 54rem;
  font-size: clamp(1.85rem, 3.65vw, 2.75rem);
  line-height: 1.25;
}

.lead-copy,
.services-intro,
.service-item p {
  color: var(--muted);
  font-weight: 300;
  line-height: 1.875;
}

.lead-copy {
  max-width: 49rem;
  margin: 1.25rem 0 0;
  font-size: clamp(1rem, 1.8vw, 1.15rem);
}

.services-intro {
  margin: 0.75rem 0 0;
  font-size: 1.05rem;
}

.services-grid {
  display: grid;
  width: min(100%, 55rem);
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2.25rem 2.4rem;
  margin-top: 2.45rem;
}

.service-item {
  display: grid;
  justify-items: center;
  gap: 1.25rem;
  min-width: 0;
}

.service-item img {
  width: 7.6rem;
  height: 7.6rem;
  object-fit: contain;
}

.service-item h3 {
  margin: 0;
  color: var(--text);
  font-size: clamp(1.3rem, 2.3vw, 1.78rem);
  font-weight: 600;
  line-height: 1.25;
}

.service-item p {
  max-width: 22rem;
  margin: 0.8rem auto 0;
  font-size: 1rem;
}

.service-item a {
  color: rgba(255, 255, 255, 0.82);
  text-decoration-color: rgba(140, 112, 255, 0.68);
  text-underline-offset: 0.18em;
}

.contact-title {
  display: grid;
  gap: 0.15rem;
}

.contact-title span {
  display: block;
}

.contact-section {
  padding-bottom: 2.2rem;
}

.form-panel {
  position: relative;
  overflow: hidden;
  width: min(100%, 32rem);
  margin-top: 1.4rem;
  padding: clamp(1rem, 3vw, 1.45rem);
  border: 1px solid rgba(140, 112, 255, 0.22);
  border-radius: 1.15rem;
  background:
    linear-gradient(180deg, rgba(18, 18, 28, 0.68), rgba(18, 18, 28, 0.5)),
    url("assets/brand/digital-spell-bg.jpg");
  background-size: cover;
  background-position: center;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(12px);
}

.contact-form {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 0.85rem;
}

.form-trap {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.field-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid rgba(140, 112, 255, 0.58);
  border-radius: 0.82rem;
  color: rgba(255, 255, 255, 0.9);
  background: rgba(42, 42, 71, 0.76);
  font: inherit;
  font-size: 1rem;
  font-weight: 300;
  outline: none;
  transition:
    border-color 180ms ease,
    background 180ms ease;
}

.contact-form input {
  height: 3.1rem;
  padding: 0 1rem;
}

.contact-form textarea {
  min-height: 9.4rem;
  resize: vertical;
  padding: 0.9rem 1rem;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: rgba(255, 255, 255, 0.42);
}

.contact-form input:focus,
.contact-form textarea:focus {
  border-color: var(--accent-hover);
  background: var(--panel-focus);
  box-shadow: 0 0 0 3px rgba(140, 112, 255, 0.14);
}

.submit-button {
  justify-self: center;
  margin-top: 0.45rem;
}

.contact-form output {
  min-height: 1.5rem;
  color: var(--muted);
  font-size: 0.9rem;
}

.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  width: min(100%, 76rem);
  margin: 0 auto;
  padding: 1.5rem 2rem 3rem;
  color: var(--footer);
  font-size: 0.95rem;
  font-weight: 300;
  line-height: 1.8;
  text-align: right;
}

.linkedin-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.35rem;
  height: 2.35rem;
  flex: 0 0 auto;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 1.2rem;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
}

.footer-meta {
  display: grid;
  justify-items: end;
  gap: 0.15rem;
}

.site-footer p {
  margin: 0;
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.45rem 0.65rem;
}

.site-footer nav a {
  text-decoration-thickness: 1px;
  text-underline-offset: 0.15em;
}

.site-footer nav a:not(:last-child) {
  padding-right: 0.65rem;
  border-right: 1px solid currentColor;
}

.legal-page .site-header {
  position: sticky;
  left: auto;
  right: auto;
  margin: 0 auto;
  transform: none;
}

.legal-shell {
  width: min(100%, 76rem);
  margin: 0 auto;
  padding: 3.2rem 2rem 1.5rem;
}

.back-link {
  display: inline-flex;
  margin-bottom: 1.4rem;
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
}

.back-link::before {
  content: "<";
  margin-right: 0.45rem;
  color: var(--accent);
}

.legal-content {
  width: min(100%, 58rem);
  padding: clamp(1.35rem, 4vw, 2.35rem);
  border: 1px solid rgba(140, 112, 255, 0.22);
  border-radius: 1.15rem;
  background: rgba(28, 28, 36, 0.5);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.16);
  backdrop-filter: blur(12px);
}

.legal-content h1,
.legal-content h2 {
  margin: 0;
  color: var(--text);
  font-weight: 600;
  letter-spacing: 0;
}

.legal-content h1 {
  font-size: clamp(2rem, 4.8vw, 3.2rem);
  line-height: 1.15;
}

.legal-content h2 {
  margin-top: 2rem;
  color: var(--accent);
  font-size: clamp(1.3rem, 2.6vw, 1.75rem);
  line-height: 1.25;
}

.legal-content p,
.legal-content li {
  color: var(--muted);
  font-size: 1rem;
  font-weight: 300;
  line-height: 1.85;
}

.legal-content p {
  margin: 1rem 0 0;
}

.legal-content ul {
  display: grid;
  gap: 0.65rem;
  margin: 1rem 0 0;
  padding-left: 1.2rem;
}

.legal-content strong {
  color: rgba(255, 255, 255, 0.86);
  font-weight: 600;
}

[dir="rtl"] .site-header,
[dir="rtl"] .header-actions,
[dir="rtl"] .site-footer nav {
  direction: rtl;
}

[dir="rtl"] .contact-form input,
[dir="rtl"] .contact-form textarea {
  text-align: right;
}

[dir="rtl"] .site-footer nav a:not(:last-child) {
  padding-right: 0;
  padding-left: 0.65rem;
  border-right: 0;
  border-left: 1px solid currentColor;
}

@media (max-width: 720px) {
  .site-shell,
  .site-header,
  .site-footer {
    padding-inline: 1.15rem;
  }

  .brand-mark {
    width: 7.35rem;
  }

  .language-switcher button {
    padding-right: 0.5rem;
  }

  .hero-lockup h1 {
    margin-top: 2.4rem;
  }

  .hero-section {
    min-height: 66vh;
    padding-bottom: 1rem;
  }

  .content-section {
    padding-block: 1.85rem;
  }

  .language-switcher {
    gap: 0.1rem;
    padding: 0.16rem;
  }

  .language-switcher button {
    min-height: 1.45rem;
    padding: 0 0.42rem;
    font-size: 0.66rem;
  }

  .language-switcher img {
    display: none;
  }

  .services-grid,
  .field-row {
    grid-template-columns: 1fr;
  }

  .services-grid {
    gap: 3rem;
  }

  .site-footer {
    align-items: flex-start;
    text-align: left;
  }

  .footer-meta {
    justify-items: start;
  }

  .site-footer nav {
    justify-content: flex-start;
  }

  .legal-shell {
    padding: 2.1rem 1.15rem 0.8rem;
  }

  .legal-content {
    padding: 1.2rem;
  }
}
