:root {
  --bg: #f4f7fb;
  --bg-deep: #0b1220;
  --ink: #111c2e;
  --muted: #5a6a85;
  --line: #d5deec;
  --accent: #2c6be8;
  --accent-soft: #e8f0ff;
  --surface: #ffffff;
  --hero-glow: #3d7cff;
  --danger: #c0392f;
  --radius: 14px;
  --shell-pad: clamp(1rem, 4vw, 1.5rem);
  --shell: min(1120px, calc(100% - (var(--shell-pad) * 2)));
  --font-display: "Fraunces", "Times New Roman", serif;
  --font-body: "Sora", "Helvetica Neue", sans-serif;
  --shadow: 0 24px 60px rgba(11, 18, 32, 0.18);
  --header-h: 4.25rem;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(1200px 500px at 10% -10%, rgba(44, 107, 232, 0.12), transparent 55%),
    radial-gradient(900px 420px at 100% 0%, rgba(11, 18, 32, 0.06), transparent 50%),
    var(--bg);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--ink);
}

.shell {
  width: var(--shell);
  margin-inline: auto;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -3rem;
  z-index: 100;
  padding: 0.6rem 0.9rem;
  background: var(--surface);
  border-radius: 8px;
}

.skip-link:focus {
  top: 1rem;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(14px);
  background: rgba(244, 247, 251, 0.82);
  border-bottom: 1px solid transparent;
  transition: border-color 200ms ease, background 200ms ease;
}

.site-header.is-scrolled {
  border-bottom-color: var(--line);
  background: rgba(244, 247, 251, 0.94);
}

.header-inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: var(--header-h);
  gap: 1rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  color: var(--ink);
  text-decoration: none;
}

.brand-logo {
  display: block;
  height: auto;
  width: auto;
}

.brand-logo-header {
  height: 1.85rem;
  width: auto;
}

.brand-logo-footer {
  height: 1.75rem;
  width: auto;
}

.brand-logo-hero {
  height: clamp(2.4rem, 5vw, 3.35rem);
  width: auto;
}

.brand-mark {
  width: 1.55rem;
  height: 1.55rem;
  border-radius: 0.45rem;
  background:
    linear-gradient(145deg, #4c8dff 0%, #2c6be8 55%, #0b1220 100%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.25);
  animation: mark-pulse 4.5s ease-in-out infinite;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 1.35rem;
}

.site-nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--ink);
}

.nav-cta {
  padding: 0.55rem 0.95rem;
  border-radius: 999px;
  background: var(--ink);
  color: #fff !important;
}

.nav-cta:hover {
  background: var(--accent);
}

.nav-toggle {
  display: none;
  width: 2.5rem;
  height: 2.5rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
  cursor: pointer;
}

.nav-toggle span:not(.sr-only) {
  display: block;
  width: 1.1rem;
  height: 2px;
  margin: 0 auto;
  background: var(--ink);
  box-shadow: 0 -5px 0 var(--ink), 0 5px 0 var(--ink);
}

/* Hero — one composition with tilted phone screens */
.hero {
  position: relative;
  min-height: min(92vh, 820px);
  display: grid;
  align-items: center;
  overflow: clip;
  color: #e6edf7;
  background:
    radial-gradient(ellipse 80% 60% at 70% 20%, rgba(76, 141, 255, 0.35), transparent 55%),
    radial-gradient(ellipse 50% 40% at 15% 80%, rgba(44, 107, 232, 0.22), transparent 50%),
    linear-gradient(165deg, #0b1220 0%, #141e30 48%, #0b1220 100%);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(230, 237, 247, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(230, 237, 247, 0.04) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 70% 60% at 60% 40%, #000 20%, transparent 75%);
  animation: grid-drift 28s linear infinite;
  pointer-events: none;
}

.hero-inner {
  position: relative;
  z-index: 1;
  padding: clamp(2.5rem, 8vh, 6rem) 0 clamp(2.5rem, 7vh, 5rem);
}

.hero-split {
  display: grid;
  gap: clamp(1.75rem, 4vw, 3.5rem);
  align-items: center;
}

.hero-copy {
  min-width: 0;
}

.hero-brand {
  display: inline-flex;
  align-items: center;
  margin-bottom: 1.35rem;
  opacity: 0;
  animation: rise 700ms ease forwards;
}

.hero h1 {
  max-width: 14ch;
  margin: 0 0 1rem;
  font-family: var(--font-display);
  font-size: clamp(1.85rem, 6.5vw, 3.4rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.08;
  opacity: 0;
  animation: rise 700ms ease 120ms forwards;
}

.hero-lead {
  max-width: 36rem;
  margin: 0 0 1.75rem;
  color: #8fa0bc;
  font-size: clamp(1rem, 2.4vw, 1.2rem);
  opacity: 0;
  animation: rise 700ms ease 220ms forwards;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  opacity: 0;
  animation: rise 700ms ease 320ms forwards;
}

.hero-phones {
  position: relative;
  width: min(100%, 420px);
  min-width: 0;
  aspect-ratio: 420 / 560;
  max-height: min(560px, 70vh);
  margin-inline: auto;
  animation: rise 900ms ease 120ms both;
}

.phone {
  position: absolute;
  margin: 0;
  width: 58%;
  max-width: 230px;
  border-radius: clamp(18px, 4vw, 28px);
  overflow: hidden;
  background: #0b1220;
  border: 1px solid rgba(230, 237, 247, 0.14);
  box-shadow:
    0 28px 60px rgba(0, 0, 0, 0.45),
    0 0 0 1px rgba(76, 141, 255, 0.12);
}

.phone img {
  width: 100%;
  height: auto;
  display: block;
}

.phone-back {
  top: 6%;
  right: 2%;
  transform: rotate(14deg);
  z-index: 1;
  animation: phone-float-back 6.5s ease-in-out infinite;
}

.phone-front {
  top: 16%;
  left: 4%;
  width: 64%;
  max-width: 250px;
  transform: rotate(8deg);
  z-index: 2;
  animation: phone-float-front 5.8s ease-in-out infinite;
}

@keyframes phone-float-front {
  0%,
  100% {
    transform: rotate(8deg) translate3d(0, 0, 0);
  }
  50% {
    transform: rotate(9deg) translate3d(0, -8px, 0);
  }
}

@keyframes phone-float-back {
  0%,
  100% {
    transform: rotate(14deg) translate3d(0, 0, 0);
  }
  50% {
    transform: rotate(15deg) translate3d(0, -6px, 0);
  }
}

/* Desktop: copy + phones side by side */
@media (min-width: 960px) {
  .hero-split {
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  }

  .hero-phones {
    justify-self: end;
  }
}

/* Tablet: still stacked, slightly tighter phones */
@media (max-width: 959px) {
  .hero {
    min-height: 0;
  }

  .hero-split {
    justify-items: stretch;
  }

  .hero-phones {
    width: min(100%, 380px);
  }
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  min-height: 2.9rem;
  padding: 0.7rem 1.2rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: transform 180ms ease, background 180ms ease, border-color 180ms ease;
}

.button:hover {
  transform: translateY(-1px);
}

.button-primary {
  background: #4c8dff;
  color: #04122b;
}

.button-primary:hover {
  background: #7aafff;
  color: #04122b;
}

.button-ghost {
  border-color: rgba(230, 237, 247, 0.22);
  color: #e6edf7;
  background: rgba(255, 255, 255, 0.03);
}

.button-ghost:hover {
  border-color: rgba(230, 237, 247, 0.45);
  color: #fff;
}

.button-on-light {
  background: var(--ink);
  color: #fff;
}

.button-on-light:hover {
  background: var(--accent);
  color: #fff;
}

.button-outline {
  border-color: var(--line);
  color: var(--ink);
  background: var(--surface);
}

/* Sections */
.section {
  padding: clamp(3.5rem, 8vw, 5.5rem) 0;
}

.section-tight {
  padding-top: 2.5rem;
}

.section h2 {
  margin: 0 0 0.75rem;
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 3vw, 2.2rem);
  letter-spacing: -0.02em;
  line-height: 1.15;
}

.section-lead {
  max-width: 40rem;
  margin: 0 0 2rem;
  color: var(--muted);
  font-size: 1.05rem;
}

.split {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 820px) {
  .split-2 {
    grid-template-columns: 1fr 1fr;
  }

  .split-3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

.point {
  padding: 0;
}

.point h3 {
  margin: 0 0 0.45rem;
  font-size: 1.05rem;
  font-weight: 600;
}

.point p {
  margin: 0;
  color: var(--muted);
}

.band {
  background: var(--surface);
  border-block: 1px solid var(--line);
}

.cta-panel {
  display: grid;
  gap: 1.25rem;
  align-items: center;
  padding: 2rem 0;
}

@media (min-width: 760px) {
  .cta-panel {
    grid-template-columns: 1fr auto;
  }
}

.cta-panel p {
  margin: 0.4rem 0 0;
  color: var(--muted);
}

/* Prose pages */
.page-hero {
  padding: 3.25rem 0 1.5rem;
}

.page-hero h1 {
  margin: 0 0 0.65rem;
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 2.8rem);
  letter-spacing: -0.03em;
  line-height: 1.1;
}

.page-hero p {
  margin: 0;
  max-width: 40rem;
  color: var(--muted);
}

.prose {
  max-width: 42rem;
  padding-bottom: 4rem;
}

.prose h2 {
  margin: 2rem 0 0.6rem;
  font-size: 1.15rem;
  font-family: var(--font-body);
  font-weight: 700;
}

.prose p,
.prose li {
  color: var(--muted);
}

.prose ul {
  padding-left: 1.2rem;
}

.prose strong {
  color: var(--ink);
  font-weight: 600;
}

.note {
  margin: 1.5rem 0;
  padding: 1rem 1.1rem;
  border-left: 3px solid var(--accent);
  background: var(--accent-soft);
  color: var(--ink);
  border-radius: 0 10px 10px 0;
}

.note.danger {
  border-left-color: var(--danger);
  background: #fdeeee;
}

/* FAQ */
.faq {
  display: grid;
  gap: 0.65rem;
  max-width: 44rem;
}

.faq details {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  overflow: hidden;
}

.faq summary {
  cursor: pointer;
  list-style: none;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.75rem;
  align-items: start;
  padding: 1rem 1.1rem;
  font-weight: 600;
  line-height: 1.35;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: "+";
  color: var(--muted);
  font-weight: 500;
  line-height: 1;
}

.faq details[open] summary::after {
  content: "–";
}

.faq details p {
  margin: 0;
  padding: 0 1.1rem 1.1rem;
  color: var(--muted);
}

.contact-block {
  margin-top: 2.5rem;
  max-width: 32rem;
}

.contact-block a.big-mail {
  display: inline-block;
  margin-top: 0.5rem;
  font-family: var(--font-display);
  font-size: clamp(1.15rem, 4vw, 1.4rem);
  font-weight: 700;
  color: var(--ink);
  text-decoration: none;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.contact-block a.big-mail:hover {
  color: var(--accent);
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--line);
  background: #eef2f8;
  padding: 2.5rem 0 2rem;
}

.footer-inner {
  display: grid;
  gap: 1.5rem;
}

.footer-brand p {
  margin: 0.35rem 0 0;
  color: var(--muted);
  max-width: 22rem;
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem 1.25rem;
}

.footer-nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.92rem;
}

.footer-nav a:hover {
  color: var(--ink);
}

.footer-meta {
  margin: 0;
  color: var(--muted);
  font-size: 0.85rem;
}

/* Motion */
@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes mark-pulse {
  0%,
  100% {
    filter: brightness(1);
  }
  50% {
    filter: brightness(1.15);
  }
}

@keyframes grid-drift {
  from {
    transform: translate3d(0, 0, 0);
  }
  to {
    transform: translate3d(-48px, -24px, 0);
  }
}

.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 600ms ease, transform 600ms ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }

  .hero-brand,
  .hero h1,
  .hero-lead,
  .hero-actions,
  .hero-phones,
  .reveal {
    opacity: 1;
    transform: none;
  }

  .phone-back {
    transform: rotate(14deg);
  }

  .phone-front {
    transform: rotate(8deg);
  }
}

@media (max-width: 760px) and (prefers-reduced-motion: reduce) {
  .phone-front {
    transform: rotate(6deg) !important;
  }

  .phone-back {
    transform: rotate(11deg) !important;
  }
}

/* Phone / small tablet */
@media (max-width: 760px) {
  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
  }

  .site-nav {
    position: absolute;
    left: calc(-1 * var(--shell-pad));
    right: calc(-1 * var(--shell-pad));
    top: 100%;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 0.35rem var(--shell-pad) 1rem;
    background: rgba(244, 247, 251, 0.98);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 12px 28px rgba(11, 18, 32, 0.08);
  }

  .site-nav.is-open {
    display: flex;
  }

  .site-nav a {
    padding: 0.9rem 0;
    border-bottom: 1px solid var(--line);
  }

  .site-nav .nav-cta {
    margin-top: 0.65rem;
    text-align: center;
    border: 0;
  }

  .brand-logo-header {
    height: 1.55rem;
  }

  .header-inner {
    min-height: 3.75rem;
  }

  .hero-inner {
    padding: 2rem 0 2.25rem;
  }

  .hero-brand {
    margin-bottom: 1rem;
  }

  .brand-logo-hero {
    height: 2.15rem;
  }

  .hero h1 {
    max-width: none;
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-actions .button {
    width: 100%;
  }

  .hero-phones {
    width: min(100%, 300px);
    max-height: none;
  }

  .phone {
    max-width: none;
  }

  .phone-front {
    top: 12%;
    left: 2%;
    width: 66%;
    transform: rotate(6deg);
  }

  .phone-back {
    top: 4%;
    right: 0;
    width: 58%;
    transform: rotate(11deg);
  }

  @keyframes phone-float-front {
    0%,
    100% {
      transform: rotate(6deg) translate3d(0, 0, 0);
    }
    50% {
      transform: rotate(7deg) translate3d(0, -6px, 0);
    }
  }

  @keyframes phone-float-back {
    0%,
    100% {
      transform: rotate(11deg) translate3d(0, 0, 0);
    }
    50% {
      transform: rotate(12deg) translate3d(0, -5px, 0);
    }
  }

  .section {
    padding: 2.75rem 0;
  }

  .section-lead {
    font-size: 1rem;
    margin-bottom: 1.5rem;
  }

  .page-hero {
    padding: 2.25rem 0 1.15rem;
  }

  .prose {
    padding-bottom: 3rem;
  }

  .cta-panel {
    padding: 1.5rem 0;
  }

  .cta-panel .button {
    width: 100%;
  }

  .footer-nav {
    gap: 0.7rem 1rem;
  }

  .contact-block {
    margin-top: 2rem;
  }
}

/* Narrow phones */
@media (max-width: 420px) {
  .hero-phones {
    width: 100%;
  }

  .phone-front {
    width: 70%;
    left: 0;
  }

  .phone-back {
    width: 60%;
    right: -2%;
  }

  .note {
    padding: 0.9rem 0.95rem;
  }
}
