:root{
  --body-bg: radial-gradient(circle at top, #111827 0, #020617 55%, #000 100%);
  --bg:#050816;
  --bg-alt:#070b1f;
  --surface:#0b1024;
  --accent:#3b82f6;
  --accent-soft: rgba(59,130,246,.1);
  --accent-strong:#2563eb;
  --text:#f9fafb;
  --muted:#9ca3af;
  --border-subtle: rgba(148,163,184,.25);
  --radius-lg:1.25rem;
  --radius-xl:1.75rem;
  --shadow-soft: 0 24px 60px rgba(15,23,42,.7);
  --max-width:1120px;
  --transition-fast:180ms ease-out;
}

/* LIGHT THEME */
:root[data-theme="light"]{
  --body-bg: radial-gradient(circle at top, #e5e7eb 0, #f9fafb 55%, #ffffff 100%);
  --bg:#f9fafb;
  --bg-alt:#e5e7eb;
  --surface:#ffffff;
  --accent:#2563eb;
  --accent-soft: rgba(37,99,235,.06);
  --accent-strong:#1d4ed8;
  --text:#020617;
  --muted:#4b5563;
  --border-subtle: rgba(148,163,184,.5);
}

*{ box-sizing:border-box; }
html,body{
  margin:0; padding:0;
  font-family:"Inter",system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
  background:var(--body-bg);
  color:var(--text);
  scroll-behavior:smooth;
}
body{ min-height:100vh; }
a{ color:inherit; text-decoration:none; }
img{ max-width:100%; display:block; }

.page{ min-height:100vh; display:flex; flex-direction:column; }
.container{ width:100%; max-width:var(--max-width); margin:0 auto; padding:0 1.5rem; }

header{
  position:sticky; top:0; z-index:40;
  backdrop-filter: blur(16px);
  background: linear-gradient(to bottom, rgba(15,23,42,.9), rgba(15,23,42,.75), transparent);
  border-bottom:1px solid rgba(148,163,184,.18);
}
:root[data-theme="light"] header{
  background: linear-gradient(to bottom, rgba(248,250,252,.95), rgba(248,250,252,.85), transparent);
  border-bottom-color: rgba(148,163,184,.35);
}

.nav{
  display:flex; align-items:center; justify-content:space-between;
  padding:1rem .25rem; gap:1rem;
}
.nav-left{ display:flex; align-items:center; gap:.75rem; }

.logo-mark{
  width:40px; height:40px; border-radius:999px;
  background: radial-gradient(circle at 30% 30%, #93c5fd 0, #1d4ed8 38%, #020617 100%);
  display:flex; align-items:center; justify-content:center;
  box-shadow:0 12px 30px rgba(37,99,235,.7);
  font-size:.85rem; font-weight:700; letter-spacing:.08em; text-transform:uppercase;
  color:#f9fafb;
}
.logo-text{ display:flex; flex-direction:column; gap:.1rem; }
.logo-title{ font-weight:600; letter-spacing:.05em; text-transform:uppercase; font-size:.85rem; }
.logo-sub{ font-size:.75rem; color:var(--muted); }

.nav-links{ display:flex; align-items:center; gap:1.5rem; font-size:.9rem; }
.nav-links a{
  position:relative; color:var(--muted); padding-bottom:.1rem;
  transition: color var(--transition-fast);
}
.nav-links a::after{
  content:""; position:absolute; left:0; bottom:-.2rem;
  width:0; height:2px; border-radius:999px;
  background: linear-gradient(to right, #3b82f6, #22c55e);
  transition: width 200ms ease-out;
}
.nav-links a:hover{ color:var(--text); }
.nav-links a:hover::after{ width:100%; }

.nav-cta{ display:flex; align-items:center; gap:.75rem; }

.button{
  display:inline-flex; align-items:center; justify-content:center; gap:.4rem;
  padding:.55rem 1.1rem;
  border-radius:999px;
  border:1px solid transparent;
  font-size:.85rem; font-weight:500;
  cursor:pointer;
  background:transparent; color:var(--text);
  transition: background var(--transition-fast), border-color var(--transition-fast),
    transform var(--transition-fast), box-shadow var(--transition-fast),
    color var(--transition-fast);
}
.button-outline{ border-color: rgba(148,163,184,.4); background: rgba(15,23,42,.8); }
:root[data-theme="light"] .button-outline{ background: rgba(248,250,252,.9); border-color: rgba(148,163,184,.7); }
.button-outline:hover{ border-color: rgba(148,163,184,.9); background: rgba(15,23,42,1); transform: translateY(-1px); }
:root[data-theme="light"] .button-outline:hover{ background:#e5e7eb; }

.button-primary{
  background: radial-gradient(circle at 0 0, #22c55e, #2563eb);
  box-shadow:0 18px 45px rgba(34,197,94,.65);
  color:#f9fafb;
}
.button-primary:hover{ transform: translateY(-1px) scale(1.01); box-shadow:0 22px 60px rgba(34,197,94,.8); }
.button span.icon{ font-size:1.1rem; margin-left:.1rem; }

.theme-toggle{
  border-radius:999px;
  border:1px solid rgba(148,163,184,.6);
  background: rgba(15,23,42,.9);
  color:var(--text);
  padding:.35rem .55rem;
  display:inline-flex; align-items:center; justify-content:center;
  cursor:pointer; font-size:.9rem;
}
:root[data-theme="light"] .theme-toggle{ background: rgba(248,250,252,.95); }

.nav-toggle{
  display:none;
  background: rgba(15,23,42,.9);
  border-radius:999px;
  border:1px solid rgba(148,163,184,.4);
  padding:.35rem .75rem;
  cursor:pointer;
}
:root[data-theme="light"] .nav-toggle{ background: rgba(248,250,252,.95); }

.nav-toggle-line{
  width:16px; height:1.8px; border-radius:999px;
  background: var(--text);
  position:relative;
}
.nav-toggle-line::before,
.nav-toggle-line::after{
  content:"";
  position:absolute; left:0;
  width:16px; height:1.8px; border-radius:999px;
  background: var(--text);
  transform-origin:center;
  transition: transform 160ms ease, top 160ms ease, opacity 160ms ease;
}
.nav-toggle-line::before{ top:-4px; }
.nav-toggle-line::after{ top:4px; }
.nav-toggle.active .nav-toggle-line{ background:transparent; }
.nav-toggle.active .nav-toggle-line::before{ top:0; transform: rotate(40deg); }
.nav-toggle.active .nav-toggle-line::after{ top:0; transform: rotate(-40deg); }

.nav-menu-mobile{
  display:none;
  flex-direction:column;
  gap:.5rem;
  padding:.75rem 0;
}
.nav-menu-mobile a{ padding:.4rem 0; font-size:.95rem; color:var(--muted); }
.nav-menu-mobile a:hover{ color:var(--text); }
.nav-menu-mobile.open{ display:flex; }

main{ flex:1; }
section{ padding:4.5rem 0; }

/* HERO */
.hero{ padding-top:4.5rem; padding-bottom:4.5rem; }
.hero-grid{
  display:grid;
  grid-template-columns:minmax(0,1.15fr) minmax(0,1fr);
  gap:3rem;
  align-items:center;
}
.hero-copy-eyebrow{
  font-size:.85rem;
  letter-spacing:.21em;
  text-transform:uppercase;
  color:var(--muted);
  display:inline-flex;
  align-items:center;
  gap:.5rem;
  margin-bottom:1.25rem;
}
.pill{
  padding:.2rem .6rem;
  border-radius:999px;
  border:1px solid rgba(148,163,184,.35);
  background: linear-gradient(to right, rgba(34,197,94,.16), rgba(37,99,235,.03));
  font-size:.75rem;
  color:#bbf7d0;
}
.hero-title{
  font-size: clamp(2.5rem, 3.4vw, 3.25rem);
  line-height:1.1;
  letter-spacing:-.04em;
  margin:0 0 1.3rem;
}
.hero-title span.gradient{
  background: linear-gradient(to right, #4ade80, #22c55e, #60a5fa);
  -webkit-background-clip:text;
  color:transparent;
}
.hero-subtitle{
  max-width:34rem;
  font-size:.98rem;
  color:var(--muted);
  line-height:1.7;
  margin-bottom:1.9rem;
}
.hero-meta-row{
  display:flex; flex-wrap:wrap;
  gap:1rem; align-items:center;
  margin-bottom:2rem;
}
.hero-metric{ display:flex; flex-direction:column; gap:.1rem; }
.hero-metric-label{
  font-size:.75rem;
  color:var(--muted);
  text-transform:uppercase;
  letter-spacing:.12em;
}
.hero-metric-value{ font-size:.95rem; font-weight:500; }
.hero-cta-row{
  display:flex; flex-wrap:wrap;
  align-items:center;
  gap:.85rem;
}
.hero-note{
  font-size:.82rem;
  color:var(--muted);
  display:flex;
  align-items:center;
  gap:.4rem;
}
.hero-badge-dot{
  width:8px; height:8px; border-radius:999px;
  background: radial-gradient(circle at 30% 30%, #bbf7d0, #22c55e);
  box-shadow:0 0 16px rgba(34,197,94,.9);
}

.hero-visual{ position:relative; }
.hero-card{
  border-radius: var(--radius-xl);
  padding:1.2rem 1.4rem;
  background:
    radial-gradient(circle at 0 0, rgba(56,189,248,.12), transparent 45%),
    radial-gradient(circle at 100% 100%, rgba(74,222,128,.16), transparent 45%),
    rgba(15,23,42,.95);
  border:1px solid rgba(148,163,184,.45);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(18px);
}
:root[data-theme="light"] .hero-card{
  background:
    radial-gradient(circle at 0 0, rgba(56,189,248,.12), transparent 45%),
    radial-gradient(circle at 100% 100%, rgba(74,222,128,.16), transparent 45%),
    rgba(248,250,252,.98);
  border-color: rgba(148,163,184,.6);
}
.hero-card-header{ display:flex; align-items:center; justify-content:space-between; margin-bottom:1rem; }
.hero-card-title{ font-size:.9rem; font-weight:500; }
.hero-card-sub{ font-size:.78rem; color:var(--muted); }
.hero-card-tag{
  padding:.25rem .65rem;
  font-size:.75rem;
  border-radius:999px;
  border:1px solid rgba(148,163,184,.5);
  background: rgba(15,23,42,.9);
  color:#bbf7d0;
}
:root[data-theme="light"] .hero-card-tag{ background: rgba(248,250,252,.98); color:#16a34a; }

.hero-card-grid{
  display:grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap:.75rem;
}
.metric-card{
  border-radius:1rem;
  border:1px solid rgba(148,163,184,.35);
  padding:.75rem .8rem;
  background: radial-gradient(circle at 0 0, rgba(34,197,94,.14), transparent 60%), rgba(15,23,42,.9);
}
:root[data-theme="light"] .metric-card{
  background: radial-gradient(circle at 0 0, rgba(34,197,94,.08), transparent 60%), #fff;
  border-color: rgba(148,163,184,.6);
}
.metric-label{
  font-size:.7rem;
  text-transform:uppercase;
  letter-spacing:.12em;
  color:var(--muted);
  margin-bottom:.15rem;
}
.metric-value{ font-size:1.1rem; font-weight:600; margin-bottom:.1rem; }
.metric-caption{ font-size:.75rem; color:var(--muted); }

.hero-badge-floating{
  position:absolute;
  bottom:-1.2rem;
  right:-.1rem;
  animation: float 6s ease-in-out infinite;
  padding:.65rem .85rem;
  border-radius:1rem;
  background: rgba(15,23,42,.98);
  border:1px solid rgba(148,163,184,.5);
  font-size:.78rem;
  display:flex;
  flex-direction:column;
  gap:.18rem;
  max-width:230px;
  box-shadow:0 18px 40px rgba(15,23,42,.9);
}
:root[data-theme="light"] .hero-badge-floating{
  background: rgba(248,250,252,.98);
  border-color: rgba(148,163,184,.6);
  box-shadow: 0 18px 40px rgba(15,23,42,.15);
}
.hero-badge-label{
  text-transform:uppercase;
  letter-spacing:.16em;
  font-size:.68rem;
  color:var(--muted);
}
.hero-badge-main{ font-size:.86rem; }
.hero-badge-main span{ color:#bbf7d0; }
:root[data-theme="light"] .hero-badge-main span{ color:#16a34a; }

@keyframes float{
  0%,100%{ transform: translateY(0); }
  50%{ transform: translateY(-6px); }
}

.section-label{
  font-size:.78rem;
  letter-spacing:.21em;
  text-transform:uppercase;
  color:var(--muted);
  margin-bottom:.9rem;
}
.section-title-row{
  display:flex;
  flex-wrap:wrap;
  justify-content:space-between;
  gap:1.25rem;
  align-items:flex-end;
  margin-bottom:2rem;
}
.section-title{
  font-size:1.55rem;
  letter-spacing:-.03em;
  margin:0;
}
.section-subtitle{
  max-width:26rem;
  font-size:.92rem;
  color:var(--muted);
  line-height:1.6;
}

/* SERVICES */
#services{ border-top:1px solid rgba(148,163,184,.2); }
.services-grid{
  display:grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap:1.5rem;
}
.service-card{
  border-radius: var(--radius-lg);
  padding:1.25rem 1.2rem;
  background: radial-gradient(circle at 0 0, rgba(34,197,94,.14), transparent 55%), rgba(15,23,42,.93);
  border:1px solid rgba(148,163,184,.4);
  position:relative;
  overflow:hidden;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast),
    border-color var(--transition-fast), background 220ms ease-out;
  cursor: default;
}
:root[data-theme="light"] .service-card{
  background: radial-gradient(circle at 0 0, rgba(34,197,94,.1), transparent 55%), #fff;
  border-color: rgba(148,163,184,.6);
}
.service-card::before{
  content:"";
  position:absolute; inset:-1px;
  background: radial-gradient(circle at 0 0, rgba(34,197,94,.35), transparent 60%);
  opacity:0;
  transition: opacity 220ms ease-out;
  pointer-events:none;
}
.service-card:hover{
  transform: translateY(-4px);
  box-shadow: 0 20px 55px rgba(15,23,42,.9);
  border-color: rgba(74,222,128,.9);
}
:root[data-theme="light"] .service-card:hover{ box-shadow: 0 18px 45px rgba(15,23,42,.18); }
.service-card:hover::before{ opacity:1; }
.service-icon{
  width:30px; height:30px;
  border-radius:.9rem;
  background: rgba(15,23,42,.9);
  border:1px solid rgba(148,163,184,.6);
  display:flex; align-items:center; justify-content:center;
  font-size:1rem;
  margin-bottom:.9rem;
}
:root[data-theme="light"] .service-icon{ background: rgba(248,250,252,.98); }
.service-title{ font-size:1rem; font-weight:500; margin-bottom:.4rem; }
.service-text{ font-size:.88rem; color:var(--muted); margin-bottom:.85rem; line-height:1.6; }
.service-meta{ font-size:.78rem; color:#bbf7d0; }
:root[data-theme="light"] .service-meta{ color:#16a34a; }

/* ABOUT */
#about{ border-top:1px solid rgba(148,163,184,.2); }
.about-grid{
  display:grid;
  grid-template-columns: minmax(0,1.2fr) minmax(0,1fr);
  gap:2.5rem;
  align-items:center;
}
.about-text p{ font-size:.94rem; color:var(--muted); line-height:1.7; margin-bottom:1rem; }
.about-list{
  list-style:none;
  padding:0; margin:1rem 0 0;
  display:grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap:.75rem 1rem;
}
.about-list li{ font-size:.9rem; display:flex; align-items:center; gap:.4rem; }
.about-list-dot{
  width:7px; height:7px; border-radius:999px;
  background:#4ade80;
  box-shadow:0 0 10px rgba(74,222,128,.85);
}
.about-card{
  border-radius: var(--radius-lg);
  padding:1rem;
  background: radial-gradient(circle at 100% 0, rgba(56,189,248,.16), transparent 55%), rgba(15,23,42,.94);
  border:1px solid rgba(148,163,184,.4);
}
:root[data-theme="light"] .about-card{
  background: radial-gradient(circle at 100% 0, rgba(56,189,248,.14), transparent 55%), #fff;
  border-color: rgba(148,163,184,.6);
}
.about-metrics{
  display:grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap:1rem;
  margin-top:.5rem;
}
.about-metric-label{
  font-size:.75rem;
  text-transform:uppercase;
  letter-spacing:.12em;
  color:var(--muted);
  margin-bottom:.1rem;
}
.about-metric-value{ font-size:1.15rem; font-weight:600; margin-bottom:.15rem; }
.about-metric-caption{ font-size:.8rem; color:var(--muted); }

/* CASE STUDIES */
#case-studies{ border-top:1px solid rgba(148,163,184,.2); }
.case-card{
  border-radius: var(--radius-lg);
  padding:1.2rem 1.1rem;
  border:1px solid rgba(148,163,184,.38);
  background: radial-gradient(circle at 0 100%, rgba(34,197,94,.12), transparent 55%), rgba(15,23,42,.96);
  display:grid;
  grid-template-columns: minmax(0,1.3fr) minmax(0,1fr);
  gap:1.8rem;
}
:root[data-theme="light"] .case-card{
  background: radial-gradient(circle at 0 100%, rgba(34,197,94,.12), transparent 55%), #fff;
  border-color: rgba(148,163,184,.6);
}
.case-pill{
  display:inline-flex;
  align-items:center;
  gap:.4rem;
  padding:.25rem .65rem;
  border-radius:999px;
  background: rgba(15,23,42,.9);
  border:1px solid rgba(148,163,184,.6);
  font-size:.75rem;
  color:#bbf7d0;
  margin-bottom:.8rem;
}
:root[data-theme="light"] .case-pill{ background: rgba(248,250,252,.98); color:#16a34a; }
.case-title{ font-size:1.1rem; font-weight:500; margin-bottom:.55rem; }
.case-text{ font-size:.88rem; color:var(--muted); margin-bottom:.9rem; line-height:1.6; }
.case-tags{ display:flex; flex-wrap:wrap; gap:.4rem; font-size:.77rem; }
.case-tag{
  padding:.18rem .55rem;
  border-radius:999px;
  background: rgba(15,23,42,.9);
  border:1px solid rgba(148,163,184,.6);
  color:#bfdbfe;
}
:root[data-theme="light"] .case-tag{ background: rgba(248,250,252,.98); color:#1d4ed8; }
.case-metrics{
  display:grid;
  grid-template-columns: minmax(0,1fr) minmax(0,1fr);
  gap:.9rem;
  font-size:.86rem;
}
.case-metrics-label{
  font-size:.74rem;
  text-transform:uppercase;
  letter-spacing:.14em;
  color:var(--muted);
}
.case-metrics-value{ font-size:1.05rem; font-weight:600; margin-bottom:.1rem; }

/* CONTACT */
#contact{ border-top:1px solid rgba(148,163,184,.2); }
.contact-grid{
  display:grid;
  grid-template-columns: minmax(0,1.2fr) minmax(0,1fr);
  gap:2rem;
  align-items:flex-start;
}
.contact-blurb{ font-size:.94rem; color:var(--muted); line-height:1.7; margin-bottom:1.25rem; }
.contact-cards{
  display:grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap:.9rem;
}
.contact-card{
  border-radius:1rem;
  border:1px solid rgba(148,163,184,.42);
  padding:.9rem;
  background: rgba(15,23,42,.94);
  font-size:.86rem;
}
:root[data-theme="light"] .contact-card{ background:#fff; border-color: rgba(148,163,184,.6); }
.contact-label{
  font-size:.74rem;
  text-transform:uppercase;
  letter-spacing:.15em;
  color:var(--muted);
  margin-bottom:.25rem;
}
.contact-value{ font-size:.9rem; }

form{
  border-radius: var(--radius-lg);
  padding:1.2rem 1.1rem;
  background: radial-gradient(circle at 100% 0, rgba(56,189,248,.18), transparent 55%), rgba(15,23,42,.96);
  border:1px solid rgba(148,163,184,.6);
  box-shadow:0 14px 40px rgba(15,23,42,.85);
}
:root[data-theme="light"] form{
  background: radial-gradient(circle at 100% 0, rgba(56,189,248,.18), transparent 55%), #fff;
  box-shadow:0 12px 35px rgba(15,23,42,.16);
}
.hp-field{ display:none; }

.form-row{
  display:grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap:.8rem;
}
.field{ margin-bottom:.8rem; }
.field label{
  display:block;
  font-size:.78rem;
  margin-bottom:.25rem;
  color:var(--muted);
}
.field input,
.field textarea{
  width:100%;
  padding:.6rem .7rem;
  border-radius:.7rem;
  border:1px solid rgba(148,163,184,.6);
  background: rgba(15,23,42,.95);
  color:var(--text);
  font-size:.9rem;
  outline:none;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast), background 140ms ease-out;
}
:root[data-theme="light"] .field input,
:root[data-theme="light"] .field textarea{ background:#fff; }
.field input:focus,
.field textarea:focus{
  border-color:#4ade80;
  box-shadow: 0 0 0 1px rgba(74,222,128,.7);
  background: rgba(15,23,42,1);
}
:root[data-theme="light"] .field input:focus,
:root[data-theme="light"] .field textarea:focus{ background:#f9fafb; }

.field textarea{ resize:vertical; min-height:120px; }
.form-footnote{ margin-top:.5rem; font-size:.75rem; color:var(--muted); }

/* FOOTER */
footer{
  border-top:1px solid rgba(148,163,184,.18);
  padding:1.6rem 0 2rem;
  font-size:.8rem;
  color:var(--muted);
}
:root[data-theme="light"] footer{ border-top-color: rgba(148,163,184,.35); }
.footer-row{
  display:flex;
  flex-wrap:wrap;
  justify-content:space-between;
  gap:.8rem;
  align-items:center;
}
.footer-links{ display:flex; gap:1.25rem; }
.footer-links a{ color:var(--muted); }
.footer-links a:hover{ color:var(--text); }

/* RESPONSIVE */
@media (max-width: 960px){
  .hero-grid,.about-grid,.case-card,.contact-grid{ grid-template-columns: minmax(0,1fr); }
  .hero-card{ max-width:420px; margin:0 auto; }
}
@media (max-width: 768px){
  .nav-links,.nav-cta{ display:none; }
  .nav-toggle{ display:inline-flex; align-items:center; justify-content:center; }
  .hero{ padding-top:3.5rem; }
  section{ padding:3.5rem 0; }
  .services-grid{ grid-template-columns: minmax(0,1fr); }
  .about-list{ grid-template-columns: minmax(0,1fr); }
  .contact-cards{ grid-template-columns: minmax(0,1fr); }
  .form-row{ grid-template-columns: minmax(0,1fr); }
}
