/* =====================================================================
   ETHER THEME — dark spatial layer loaded after style.css on every page.
   Dot grid + jade glow + depth rings, mono eyebrows, gradient display type.
   ===================================================================== */

:root {
  --bg: #030D0F;
  --surface: #07171A;
  --surface-alt: #0B1F23;
  --text: #F2F4F4;
  --text2: #8E9C9E;
  --border: rgba(255, 255, 255, 0.1);
  --ring: rgba(255, 255, 255, 0.08);
  --ring-strong: rgba(255, 255, 255, 0.16);
  --glass: rgba(255, 255, 255, 0.03);
  --mono: ui-monospace, 'SFMono-Regular', 'JetBrains Mono', Menlo, Consolas, monospace;
  color-scheme: dark;
}

body {
  background: var(--bg);
  color: var(--text);
}

/* Site-wide faint dot field, fades toward the edges */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image: radial-gradient(rgba(0, 200, 150, 0.16) 1px, transparent 1px);
  background-size: 28px 28px;
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 40%, #000 30%, transparent 100%);
  mask-image: radial-gradient(ellipse 80% 70% at 50% 40%, #000 30%, transparent 100%);
  opacity: 0.55;
}

::selection {
  background: var(--accent);
  color: #030D0F;
}

/* ---------- Shared decorative primitives ---------- */
.ether-grid,
.ether-glow,
.ether-ring {
  position: absolute;
  pointer-events: none;
}

.ether-grid {
  inset: 0;
  background-image: radial-gradient(rgba(0, 200, 150, 0.28) 1px, transparent 1px);
  background-size: 28px 28px;
  -webkit-mask-image: radial-gradient(ellipse 70% 70% at 50% 50%, #000 55%, transparent 100%);
  mask-image: radial-gradient(ellipse 70% 70% at 50% 50%, #000 55%, transparent 100%);
  opacity: 0.6;
}

.ether-glow {
  inset: 0;
  background: radial-gradient(circle at var(--mx, 50%) var(--my, 50%), rgba(0, 200, 150, 0.16) 0%, transparent 62%);
}

.ether-ring {
  left: 50%;
  top: 50%;
  border-radius: 50%;
  transform: translate(-50%, -50%);
}

.ether-ring--inner {
  width: 48vmin;
  height: 48vmin;
  border: 1px solid rgba(0, 200, 150, 0.16);
}

.ether-ring--outer {
  width: 76vmin;
  height: 76vmin;
  border: 1px dashed rgba(255, 255, 255, 0.09);
  animation: etherSpin 120s linear infinite;
}

@keyframes etherSpin {
  to { transform: translate(-50%, -50%) rotate(360deg); }
}

.ether-eyebrow,
.section-eyebrow,
.fw-eyebrow,
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--accent);
  background: none;
  border: 0;
  padding: 0;
  box-shadow: none;
}

.ether-eyebrow .dot-loop {
  position: relative;
  inset: auto;
  flex: none;
}

/* Gradient display type */
.ether-display,
.section-heading,
.page-title,
.serif-heading,
.arch-page-title,
.fw-title,
.stats-text h2,
.testimonials-heading {
  background: linear-gradient(180deg, #FFFFFF 0%, #FFFFFF 45%, rgba(255, 255, 255, 0.42) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: #fff;
}

/* Inner-page titles move to the same tight sans display voice as the tunnel */
.serif-heading,
.arch-page-title {
  font-family: var(--font);
  font-weight: 700;
  letter-spacing: -0.05em;
  line-height: 0.92;
  text-transform: uppercase;
}

.page-title {
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1;
}

.ether-display {
  font-size: clamp(3.1rem, 10vw, 7.4rem);
  font-weight: 700;
  line-height: 0.9;
  letter-spacing: -0.055em;
  text-transform: uppercase;
}

.testimonials-highlight {
  -webkit-text-fill-color: var(--accent);
  color: var(--accent);
}

/* ---------- Buttons ---------- */
.btn-primary {
  background: var(--accent);
  color: #030D0F;
  font-weight: 600;
}

.btn-primary:hover {
  background: #1DE0AC;
  color: #030D0F;
  box-shadow: 0 10px 30px -8px var(--accent-glow), 0 0 0 1px rgba(0, 200, 150, 0.5);
}

.btn-primary:active {
  background: var(--accent);
}

.btn-secondary {
  color: var(--text);
  border-color: var(--ring-strong);
  background: rgba(255, 255, 255, 0.02);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(0, 200, 150, 0.6);
}

.btn-primary.dark-btn {
  background: var(--accent);
  color: #030D0F;
}

/* ---------- Loader ---------- */
.loader {
  background: var(--bg);
}

.loader-marketing {
  background: rgba(255, 255, 255, 0.02);
}

/* =====================================================================
   PERSPECTIVE TUNNEL (home hero)
   ===================================================================== */
.tunnel {
  position: relative;
  height: 320vh;
}

.tunnel.is-static {
  height: auto;
}

.tunnel-stage {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  width: 100%;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  perspective: 1200px;
  transform-style: preserve-3d;
  isolation: isolate;
}

.tunnel-title {
  position: relative;
  z-index: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 0 24px;
  max-width: 920px;
  pointer-events: none;
  will-change: transform, opacity;
}

.tunnel-title .ether-eyebrow {
  margin-bottom: 22px;
}

.tunnel-sub {
  margin-top: 22px;
  max-width: 44ch;
  font-size: clamp(0.98rem, 1.4vw, 1.1rem);
  font-weight: 400;
  color: var(--text2);
}

.tunnel-title .hero-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 32px;
  pointer-events: auto;
}

.tunnel-prompt {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 20;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--text2);
  pointer-events: none;
}

.tunnel-prompt-line {
  width: 1px;
  height: 28px;
  background: linear-gradient(180deg, var(--accent), transparent);
  animation: tunnelPrompt 1.8s var(--ease) infinite;
  transform-origin: top;
}

@keyframes tunnelPrompt {
  0% { transform: scaleY(0); opacity: 1; }
  70% { transform: scaleY(1); opacity: 1; }
  100% { transform: scaleY(1); opacity: 0; }
}

.tunnel-space {
  position: absolute;
  inset: 0;
  pointer-events: none;
  transform-style: preserve-3d;
}

.tunnel-card {
  position: absolute;
  left: 50%;
  top: 50%;
  width: var(--tunnel-card-w, 240px);
  aspect-ratio: 4 / 5;
  border-radius: 18px;
  overflow: hidden;
  background: var(--surface);
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.9);
  outline: 1px solid rgba(255, 255, 255, 0.14);
  outline-offset: -1px;
  pointer-events: auto;
  will-change: transform, opacity;
  user-select: none;
  opacity: 0;
  transition: outline-color 0.4s ease, box-shadow 0.4s ease;
}

.tunnel-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
  transition: transform 0.7s var(--ease);
}

.tunnel-card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(3, 13, 15, 0.88) 0%, rgba(3, 13, 15, 0.1) 45%, transparent 70%);
  pointer-events: none;
}

.tunnel-card span {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 14px;
  z-index: 1;
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.95);
}

.tunnel-card:hover,
.tunnel-card:focus-visible {
  outline-color: rgba(0, 200, 150, 0.75);
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.9), 0 0 40px -6px var(--accent-glow);
}

.tunnel-card:hover img {
  transform: scale(1.08);
}

@media (max-width: 767px) {
  .tunnel {
    height: 260vh;
  }
  .ether-eyebrow,
  .section-eyebrow,
  .fw-eyebrow {
    font-size: 0.64rem;
    letter-spacing: 0.2em;
  }
  .tunnel-title .hero-buttons .btn-primary.lg,
  .tunnel-title .hero-buttons .btn-secondary.lg {
    padding: 14px 24px;
    font-size: 0.95rem;
  }
  .tunnel-card {
    border-radius: 14px;
  }
}

/* =====================================================================
   DEPTH HERO (inner page headers)
   ===================================================================== */
.ether-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
}

.ether-hero > .ether-grid,
.ether-hero > .ether-glow,
.ether-hero > .ether-ring {
  z-index: -1;
}

/* Fade the decor out at the bottom so short heroes don't end in a hard edge */
.ether-hero::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 45%;
  z-index: -1;
  pointer-events: none;
  background: linear-gradient(180deg, transparent, var(--bg));
}

.ether-hero .ether-ring--inner {
  width: min(560px, 70vw);
  height: min(560px, 70vw);
}

.ether-hero .ether-ring--outer {
  width: min(900px, 110vw);
  height: min(900px, 110vw);
}

/* =====================================================================
   SECTION + CARD RESKIN
   ===================================================================== */
.tech-strip,
.services-section,
.benefits-section,
.stats-section,
.testimonials-section,
.fw-section,
.skills-section,
.certs-section,
.opportunities-section,
.audit-includes-section,
.audit-form-section,
.offers-section,
.work-stats-section,
.arch-grid-section,
.portfolio-detail-section,
.next-project-section,
.how-section,
.includes-section,
.order-form-section,
.order-proof-section {
  background: transparent;
}

.service-card,
.benefit-card,
.stat-box,
.testi-card,
.testimo-card,
.cert-edu-card,
.skill-card,
.offer-card,
.audit-include-card,
.include-card {
  background: var(--glass);
  border: 1px solid var(--ring);
  box-shadow: none;
  transition: border-color 0.4s ease, background 0.4s ease, transform 0.4s var(--ease), box-shadow 0.4s ease;
}

.service-card:hover,
.benefit-card:hover,
.stat-box:hover,
.testi-card:hover,
.testimo-card:hover,
.cert-edu-card:hover,
.skill-card:hover,
.offer-card:hover,
.audit-include-card:hover,
.include-card:hover {
  background: rgba(0, 200, 150, 0.04);
  border-color: rgba(0, 200, 150, 0.45);
  box-shadow: 0 20px 50px -24px var(--accent-glow);
}

.service-number {
  font-family: var(--mono);
  color: var(--accent);
  letter-spacing: 0.2em;
}

.service-card h3,
.benefit-card h3,
.stat-box h3,
.testi-author strong {
  color: var(--text);
}

.testi-stars {
  color: var(--accent);
}

.tech-icon {
  filter: grayscale(1) brightness(1.6) contrast(0.9);
  opacity: 0.6;
  transition: filter 0.3s ease, opacity 0.3s ease;
}

.tech-icon:hover {
  filter: none;
  opacity: 1;
}

.tech-label {
  font-family: var(--mono);
  letter-spacing: 0.24em;
  text-transform: uppercase;
  font-size: 0.7rem;
}

.marquee-section {
  background: transparent;
  border-top: 1px solid var(--ring);
  border-bottom: 1px solid var(--ring);
}

.skill-tag:hover,
.filter-btn.active,
.filter-btn:hover,
.proj-live-link:hover,
.proj-tags span:hover {
  background: var(--accent);
  color: #030D0F;
  border-color: var(--accent);
}

.icn,
.cert-edu-icon,
.toolbar-icon {
  background: var(--surface-alt);
  color: var(--text);
}

/* Inverted pills (were ink-on-light) become jade chips */
.service-number,
.offer-label,
.how-step-number {
  background: var(--accent-soft);
  color: var(--accent);
  border: 1px solid rgba(0, 200, 150, 0.35);
}

/* About page */
.about-watermark {
  color: rgba(255, 255, 255, 0.025);
}

.cert-edu-title,
.cert-edu-info h4 {
  color: var(--text);
}

.cert-edu-info p,
.cert-edu-info strong {
  color: var(--text2);
}

.cert-edu-date {
  color: rgba(142, 156, 158, 0.8) !important;
}

.cert-edu-item {
  border-bottom-color: var(--ring);
}

/* Form fields */
input,
select,
textarea {
  color: var(--text);
  background-color: rgba(255, 255, 255, 0.03);
  border-color: var(--ring-strong);
}

input::placeholder,
textarea::placeholder {
  color: rgba(255, 255, 255, 0.32);
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
  outline: none;
}

select option {
  background: var(--surface);
  color: var(--text);
}

/* Footer blends into the page instead of a hard dark band */
.footer-dark {
  background: radial-gradient(42rem 34rem at var(--pointer-x, 50%) var(--pointer-y, 38%), rgba(0, 200, 150, 0.1), transparent 68%), linear-gradient(180deg, transparent 0%, #06171A 100%);
  border-top: 1px solid var(--ring);
}

.footer-col-title {
  font-family: var(--mono);
  letter-spacing: 0.3em;
  color: rgba(255, 255, 255, 0.55);
}

.fw-tab-btn {
  color: rgba(255, 255, 255, 0.55);
}

/* Custom cursor reads on dark */
.custom-cursor-dot {
  background: var(--accent);
  color: #030D0F;
}

@media (prefers-reduced-motion: reduce) {
  .ether-ring--outer,
  .tunnel-prompt-line {
    animation: none;
  }
}
