:root {
  --surface: rgba(9, 14, 26, 0.78);
  --surface-2: rgba(15, 23, 42, 0.96);
  --border: rgba(255, 255, 255, 0.08);
  --text: #e5eefc;
  --muted: #94a3b8;
  --cyan: #06b6d4;
  --violet: #8b5cf6;
}

* {
  box-sizing: border-box;
}

html {
  overflow-x: hidden;
}

body {
  min-width: 320px;
  font-family: 'Inter', sans-serif;
  background:
    radial-gradient(circle at top, rgba(6, 182, 212, 0.06), transparent 12%),
    #0b0f19;
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%;
}

img {
  max-width: 100%;
  display: block;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

body[data-theme='light'] {
  background:
    radial-gradient(circle at top, rgba(6, 182, 212, 0.08), transparent 12%),
    #f8fafc;
  color: #0f172a;
}

body[data-theme='light'] .site-grid {
  opacity: 0.06;
}

body[data-theme='light'] .nav-link,
body[data-theme='light'] .footer-link,
body[data-theme='light'] .text-slate-400,
body[data-theme='light'] .text-slate-300,
body[data-theme='light'] .text-slate-200,
body[data-theme='light'] .service-meta,
body[data-theme='light'] .benefit-item p,
body[data-theme='light'] .field-label,
body[data-theme='light'] .field-error {
  color: #475569;
}

body[data-theme='light'] .text-white,
body[data-theme='light'] h1,
body[data-theme='light'] h2,
body[data-theme='light'] h3,
body[data-theme='light'] h4,
body[data-theme='light'] .service-card h3,
body[data-theme='light'] .benefit-item h4 {
  color: #0f172a;
}

body[data-theme='light'] .visual-shell,
body[data-theme='light'] .service-card,
body[data-theme='light'] .benefits-ribbon,
body[data-theme='light'] .cta-panel,
body[data-theme='light'] .modal-panel,
body[data-theme='light'] footer,
body[data-theme='light'] header {
  background: rgba(255, 255, 255, 0.74);
  backdrop-filter: blur(16px);
  border-color: rgba(15, 23, 42, 0.08);
}

body[data-theme='light'] .service-card:hover,
body[data-theme='light'] .visual-shell:hover {
  box-shadow: 0 18px 50px rgba(6, 182, 212, 0.08);
}

body[data-theme='light'] .badge-pill,
body[data-theme='light'] .tag-pill,
body[data-theme='light'] .social-icon,
body[data-theme='light'] .field-input {
  background: rgba(255, 255, 255, 0.8);
  border-color: rgba(15, 23, 42, 0.08);
}

.site-grid {
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: 40px 40px;
  opacity: 0.12;
}

.brand-link:hover .brand-mark {
  transform: translateY(-1px) scale(1.02);
}

.theme-toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3.8rem;
  height: 2.2rem;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.toggle-track {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 9999px;
  background: linear-gradient(90deg, rgba(6, 182, 212, 0.18), rgba(139, 92, 246, 0.18));
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: background 0.3s ease, border-color 0.3s ease;
}

.toggle-thumb {
  position: absolute;
  top: 0.18rem;
  left: 0.18rem;
  width: 1.76rem;
  height: 1.76rem;
  border-radius: 9999px;
  background: linear-gradient(90deg, var(--cyan), var(--violet));
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08), 0 4px 12px rgba(0, 0, 0, 0.22);
  transition: transform 0.3s ease;
}

.theme-toggle[aria-pressed='true'] .toggle-track {
  background: linear-gradient(90deg, rgba(6, 182, 212, 0.32), rgba(139, 92, 246, 0.32));
  border-color: rgba(6, 182, 212, 0.26);
}

.theme-toggle[aria-pressed='true'] .toggle-thumb {
  transform: translateX(1.56rem);
}

body[data-theme='light'] .toggle-track {
  background: linear-gradient(90deg, rgba(6, 182, 212, 0.2), rgba(139, 92, 246, 0.18));
}

body[data-theme='light'] .toggle-thumb {
  background: linear-gradient(90deg, #0f172a, #334155);
}

.brand-mark,
.service-icon,
.benefit-icon,
.social-icon,
.modal-close,
.cta-pill,
.pulse-btn,
.secondary-btn,
.service-card,
.visual-shell,
.cta-panel {
  transition: all 0.3s ease;
}

.gradient-text {
  background: linear-gradient(90deg, #ffffff, #67e8f9 45%, #c4b5fd 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

body[data-theme='light'] .gradient-text {
  background: linear-gradient(90deg, #0f172a, #0ea5e9 45%, #8b5cf6 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.eyebrow {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 0.5rem;
  border-radius: 9999px;
  border: 1px solid rgba(6, 182, 212, 0.18);
  background: rgba(6, 182, 212, 0.08);
  padding: 0.65rem 0.95rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--cyan);
}

.hero-copy {
  transform-style: preserve-3d;
}

.cta-pill,
.pulse-btn,
.secondary-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  border-radius: 9999px;
  letter-spacing: 0.06em;
}

.cta-pill {
  background: linear-gradient(90deg, var(--cyan), var(--violet));
  color: #fff;
  padding: 0.78rem 1rem;
  font-size: 0.86rem;
}

.cta-pill:hover,
.pulse-btn:hover,
.secondary-btn:hover {
  transform: translateY(-2px);
}

.pulse-btn {
  background: linear-gradient(90deg, var(--cyan), var(--violet));
  color: #fff;
  padding: 1rem 1.8rem;
  box-shadow: 0 0 24px rgba(6, 182, 212, 0.2);
  animation: pulseGlow 2.8s infinite;
}

.secondary-btn {
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: inherit;
  padding: 1rem 1.8rem;
  background: rgba(255, 255, 255, 0.04);
}

.visual-shell {
  background: linear-gradient(180deg, rgba(9, 14, 26, 0.92), rgba(3, 6, 16, 0.88));
  border: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04), 0 24px 60px rgba(0, 0, 0, 0.38);
}

.orb {
  position: absolute;
  border-radius: 9999px;
  filter: blur(12px);
  opacity: 0.4;
}

.orb-one {
  width: 180px;
  height: 180px;
  background: radial-gradient(circle, rgba(6, 182, 212, 0.45), transparent 70%);
  top: 0;
  right: 0;
}

.orb-two {
  width: 140px;
  height: 140px;
  background: radial-gradient(circle, rgba(139, 92, 246, 0.32), transparent 70%);
  bottom: 0;
  left: 0;
}

.tag-pill,
.badge-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.06);
  padding: 0.45rem 0.7rem;
  font-size: 0.76rem;
  color: var(--muted);
}

.service-card,
.benefits-ribbon,
.cta-panel,
footer,
.modal-panel {
  background: linear-gradient(180deg, rgba(9, 14, 26, 0.86), rgba(2, 6, 23, 0.94));
  border: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04), 0 18px 45px rgba(0, 0, 0, 0.26);
  backdrop-filter: blur(18px);
}

.service-card {
  position: relative;
  overflow: hidden;
  border-radius: 1.6rem;
  padding: 1.6rem;
  transform-style: preserve-3d;
}

.service-card::before {
  content: '';
  position: absolute;
  inset: auto -50% -50% 50%;
  width: 180px;
  height: 180px;
  background: radial-gradient(circle, rgba(6, 182, 212, 0.12), transparent 70%);
  transform: translate(-50%, 0);
  transition: opacity 0.3s ease;
}

.service-card:hover {
  border-color: rgba(6, 182, 212, 0.28);
  transform: translateY(-6px);
}

.service-card h3 {
  font-size: 1.2rem;
  font-weight: 700;
  color: #fff;
}

.service-card ul {
  margin-top: 1rem;
  display: grid;
  gap: 0.4rem;
  font-size: 0.9rem;
  color: var(--muted);
}

.service-icon,
.benefit-icon {
  display: inline-flex;
  width: 3rem;
  height: 3rem;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
  background: linear-gradient(90deg, var(--cyan), var(--violet));
  color: white;
}

.service-icon svg,
.benefit-icon svg,
.social-icon svg,
.modal-close svg {
  width: 18px;
  height: 18px;
}

.benefits-ribbon {
  border-radius: 1.8rem;
}

.benefit-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem;
}

.benefit-item h4 {
  font-size: 0.95rem;
  font-weight: 700;
  color: #f8fafc;
}

.benefit-item p {
  font-size: 0.9rem;
  color: var(--muted);
}

.cta-panel {
  position: relative;
  overflow: hidden;
  border-radius: 2rem;
  background:
    linear-gradient(90deg, rgba(6, 182, 212, 0.1), rgba(139, 92, 246, 0.08)),
    linear-gradient(180deg, rgba(7, 11, 23, 0.96), rgba(2, 6, 20, 0.96));
}

.cta-panel::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(6, 182, 212, 0.06), transparent 40%);
}

.cta-panel h2 {
  position: relative;
  z-index: 1;
  font-size: clamp(2.6rem, 4vw, 4rem);
  line-height: 1;
  color: #fff;
}

.social-icon {
  display: inline-flex;
  width: 3.2rem;
  height: 3.2rem;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.05);
  color: #e2e8f0;
}

.social-icon:hover,
.modal-close:hover {
  background: linear-gradient(90deg, var(--cyan), var(--violet));
  transform: translateY(-2px);
}

.footer-link:hover {
  color: #fff;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(3, 7, 18, 0.72);
  backdrop-filter: blur(12px);
  padding: 1rem;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.modal-backdrop.open {
  display: flex;
  opacity: 1;
  visibility: visible;
}

.modal-panel {
  position: relative;
  width: min(100%, 42rem);
  border-radius: 1.8rem;
  padding: 2rem;
}

.modal-close {
  position: absolute;
  right: 1rem;
  top: 1rem;
  display: inline-flex;
  width: 2.8rem;
  height: 2.8rem;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  color: #fff;
}

.field-label {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
  color: #cbd5e1;
}

.field-input {
  width: 100%;
  border-radius: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(15, 23, 42, 0.86);
  padding: 0.9rem 1rem;
  color: #e2e8f0;
  outline: none;
}

.field-input:focus {
  border-color: rgba(6, 182, 212, 0.72);
  box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.08);
}

.field-input.error {
  border-color: #f87171;
  box-shadow: 0 0 0 3px rgba(248, 113, 113, 0.08);
}

.field-input.success {
  border-color: #22c55e;
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.08);
}

.field-error {
  min-height: 1rem;
  margin-top: 0.35rem;
  font-size: 0.8rem;
  color: #fca5a5;
}

@keyframes pulseGlow {
  0%,
  100% {
    box-shadow: 0 0 18px rgba(6, 182, 212, 0.2), 0 0 32px rgba(139, 92, 246, 0.16);
  }
  50% {
    box-shadow: 0 0 28px rgba(6, 182, 212, 0.34), 0 0 44px rgba(139, 92, 246, 0.22);
  }
}

@media (max-width: 1024px) {
  #home {
    padding-top: 4.5rem;
  }

  .hero-copy {
    max-width: 42rem;
    margin: 0 auto;
    text-align: center;
    align-items: center;
  }

  .hero-visual {
    max-width: 46rem;
    margin: 0 auto;
  }
}

@media (max-width: 768px) {
  header nav {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .hero-copy h1 {
    font-size: clamp(3rem, 7vw, 4rem);
  }

  .hero-copy p {
    max-width: 100%;
  }

  .hero-copy .mt-10 {
    width: 100%;
    max-width: 24rem;
  }

  .pulse-btn,
  .secondary-btn,
  .cta-pill {
    width: 100%;
  }

  #threeCanvasWrap {
    height: 420px;
  }

  .services-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .benefits-ribbon .grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .cta-panel {
    padding: 3rem 1.5rem;
  }

  .cta-panel h2 {
    font-size: clamp(2rem, 4.8vw, 3rem);
  }

  .modal-panel {
    padding: 1.5rem;
  }

  footer {
    padding-top: 4rem;
    padding-bottom: 4rem;
  }

  .social-icon {
    width: 3rem;
    height: 3rem;
  }
}

@media (max-width: 640px) {
  #home {
    padding-top: 3.5rem;
    padding-bottom: 5rem;
  }

  .services-grid,
  .benefits-ribbon .grid,
  #consultationForm .grid {
    grid-template-columns: 1fr;
  }

  .benefit-item {
    align-items: flex-start;
  }

  .footer-link {
    word-break: break-word;
  }

  .modal-panel {
    width: 100%;
    border-radius: 1.25rem;
  }
}

@media (max-width: 480px) {
  .brand-link {
    gap: 0.65rem;
  }

  .brand-link .brand-mark {
    width: 3rem;
    height: 3rem;
  }

  .brand-link p:last-child {
    font-size: 0.82rem;
  }

  .eyebrow {
    font-size: 0.58rem;
    letter-spacing: 0.28em;
    padding: 0.55rem 0.75rem;
  }

  .hero-copy h1 {
    font-size: clamp(2.7rem, 9.5vw, 3.4rem);
  }

  .hero-copy p {
    font-size: 0.98rem;
  }

  #threeCanvasWrap {
    height: 360px;
  }

  .cta-panel h2 {
    font-size: clamp(2rem, 7vw, 2.5rem);
  }

  .social-icon {
    width: 2.9rem;
    height: 2.9rem;
  }
}
