/* ============================================
   ToxDev Agency — Dark glass + neon accents
   Beginner note: CSS variables keep theme consistent.
   ============================================ */

:root {
  --bg-deep: #080716;
  --bg-elevated: #12102a;
  --surface: rgba(22, 24, 48, 0.58);
  --border: rgba(120, 140, 255, 0.22);
  --text: #e8e9f2;
  --text-muted: #a4a6c4;
  --accent: #7c5cff;
  --accent-2: #00e5c8;
  --glow: rgba(124, 92, 255, 0.45);
  --input-bg: rgba(8, 6, 22, 0.45);
  --header-bg-scrolled: rgba(14, 12, 32, 0.88);
  --radius: 18px;
  --font: "Outfit", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  --header-h: 72px;
}

[data-theme="light"] {
  --bg-deep: #f2f0fa;
  --bg-elevated: #ffffff;
  --surface: rgba(255, 255, 255, 0.78);
  --border: rgba(100, 80, 200, 0.2);
  --text: #1a1535;
  --text-muted: #5c5678;
  --accent: #6b4fe8;
  --accent-2: #009e8a;
  --glow: rgba(107, 79, 232, 0.35);
  --input-bg: rgba(255, 255, 255, 0.9);
  --header-bg-scrolled: rgba(255, 255, 255, 0.92);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .project-card:hover,
  .project-card:focus-within {
    transform: none;
  }
}

body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg-deep);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
  transition: background-color 0.35s ease, color 0.35s ease;
}

body.nav-open,
body.fab-open {
  overflow: hidden;
}

/* Subtle grid background — tinted, not flat black */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(124, 92, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124, 92, 255, 0.045) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 20%, black 20%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

[data-theme="light"] body::before {
  background-image:
    linear-gradient(rgba(107, 79, 232, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(107, 79, 232, 0.06) 1px, transparent 1px);
  mask-image: radial-gradient(ellipse 85% 65% at 50% 15%, black 25%, transparent 72%);
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  display: block;
}

.container {
  width: min(1120px, 92vw);
  margin-inline: auto;
  position: relative;
  z-index: 1;
}

/* ----- Loader ----- */
.loader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: grid;
  place-items: center;
  background: var(--bg-deep);
  transition: opacity 0.6s ease, visibility 0.6s ease, background 0.35s ease;
}

.loader.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.loader__inner {
  text-align: center;
}

.loader__ring {
  width: 52px;
  height: 52px;
  border: 3px solid rgba(124, 92, 255, 0.2);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.9s linear infinite;
}

.loader__text {
  margin-top: 1rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ----- Glass panels ----- */
.glass {
  background: var(--surface);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow:
    0 4px 24px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

[data-theme="light"] .glass {
  box-shadow:
    0 4px 28px rgba(80, 60, 160, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.85);
}

/* ----- Header ----- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0 clamp(1rem, 4vw, 2rem);
  z-index: 100;
  background: linear-gradient(to bottom, rgba(8, 7, 22, 0.94), transparent);
  transition: background 0.3s ease, box-shadow 0.3s ease;
}

[data-theme="light"] .header {
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0.96), rgba(255, 255, 255, 0));
}

.header.is-scrolled {
  background: var(--header-bg-scrolled);
  backdrop-filter: blur(12px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
}

[data-theme="light"] .header.is-scrolled {
  box-shadow: 0 8px 32px rgba(80, 60, 160, 0.12);
}

.header__end {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.theme-toggle {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: rgba(124, 92, 255, 0.1);
  color: var(--text-muted);
  cursor: pointer;
  transition: color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.theme-toggle:hover,
.theme-toggle:focus-visible {
  color: var(--accent-2);
  background: rgba(124, 92, 255, 0.18);
  box-shadow: 0 0 20px rgba(124, 92, 255, 0.2);
  outline: none;
}

.theme-toggle__icon {
  grid-area: 1 / 1;
  display: grid;
  place-items: center;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.theme-toggle__icon--sun {
  opacity: 0;
  transform: rotate(-45deg) scale(0.85);
}

[data-theme="light"] .theme-toggle__icon--moon {
  opacity: 0;
  transform: rotate(45deg) scale(0.85);
}

[data-theme="light"] .theme-toggle__icon--sun {
  opacity: 1;
  transform: rotate(0) scale(1);
  color: var(--accent);
}

.logo {
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
}

.logo__glow {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 40px var(--glow);
}

.nav__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 1.75rem;
}

.nav a {
  font-size: 0.95rem;
  color: var(--text-muted);
  transition: color 0.2s ease;
}

.nav a:hover,
.nav a:focus-visible {
  color: var(--text);
}

.nav__cta {
  padding: 0.45rem 1rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(124, 92, 255, 0.12);
  color: var(--text) !important;
}

.nav__cta:hover {
  box-shadow: 0 0 24px var(--glow);
}

.nav {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.nav__backdrop {
  display: none;
}

.nav__toggle {
  display: none;
  width: 44px;
  height: 44px;
  padding: 0;
  background: rgba(124, 92, 255, 0.08);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 12px;
  font-family: inherit;
  cursor: pointer;
  place-items: center;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.nav__toggle:hover,
.nav__toggle:focus-visible {
  background: rgba(124, 92, 255, 0.15);
  outline: none;
}

.nav__toggle-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: 22px;
  margin: 0 auto;
}

.nav__toggle-bar {
  display: block;
  width: 100%;
  height: 2px;
  border-radius: 1px;
  background: currentColor;
  transition: transform 0.25s ease, opacity 0.2s ease;
  transform-origin: center;
}

.nav__toggle[aria-expanded="true"] .nav__toggle-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav__toggle[aria-expanded="true"] .nav__toggle-bar:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.nav__toggle[aria-expanded="true"] .nav__toggle-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

@media (max-width: 768px) {
  .nav__toggle {
    display: grid;
  }

  .nav__backdrop {
    display: block;
    position: fixed;
    inset: 0;
    top: 0;
    z-index: 98;
    background: rgba(8, 6, 22, 0.55);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
  }

  .nav__backdrop.is-visible {
    opacity: 1;
    pointer-events: auto;
  }

  [data-theme="light"] .nav__backdrop {
    background: rgba(26, 21, 53, 0.35);
  }

  .nav__list {
    position: fixed;
    top: calc(var(--header-h) + 0.75rem);
    right: 1rem;
    left: 1rem;
    max-height: min(70vh, 420px);
    overflow-y: auto;
    flex-direction: column;
    align-items: stretch;
    padding: 0.75rem;
    z-index: 101;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow:
      0 24px 60px rgba(0, 0, 0, 0.45),
      0 0 0 1px rgba(124, 92, 255, 0.12) inset;
    transform-origin: top center;
    transform: translateY(-8px) scale(0.98);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.28s ease, transform 0.28s ease;
  }

  [data-theme="light"] .nav__list {
    box-shadow:
      0 24px 60px rgba(80, 60, 160, 0.15),
      0 0 0 1px rgba(124, 92, 255, 0.1) inset;
  }

  .nav__list.is-open {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0) scale(1);
  }

  .nav__list a {
    padding: 0.65rem 0.85rem;
    border-radius: 10px;
  }

  .nav__list .nav__cta {
    text-align: center;
    margin-top: 0.25rem;
  }
}

/* ----- Hero ----- */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  padding: calc(var(--header-h) + 2rem) 0 4rem;
  z-index: 1;
}

.hero__canvas-wrap {
  position: absolute;
  inset: 0;
  z-index: 0;
  /* Base + glows aligned with Three.js shapes (violet left, teal right, deep floor) */
  background-color: var(--bg-deep);
  background-image:
    radial-gradient(ellipse 130% 85% at 18% 28%, rgba(124, 92, 255, 0.42) 0%, transparent 52%),
    radial-gradient(ellipse 95% 75% at 82% 68%, rgba(0, 229, 200, 0.14) 0%, transparent 48%),
    radial-gradient(ellipse 110% 90% at 50% 105%, rgba(42, 31, 102, 0.55) 0%, transparent 55%),
    radial-gradient(ellipse 90% 70% at 50% -5%, rgba(18, 16, 40, 0.9) 0%, transparent 60%);
  pointer-events: none;
  transition: background-color 0.35s ease;
}

[data-theme="light"] .hero__canvas-wrap {
  background-image:
    radial-gradient(ellipse 125% 80% at 20% 25%, rgba(107, 79, 232, 0.2) 0%, transparent 52%),
    radial-gradient(ellipse 90% 70% at 85% 65%, rgba(0, 158, 138, 0.12) 0%, transparent 48%),
    radial-gradient(ellipse 100% 85% at 50% 100%, rgba(200, 190, 255, 0.35) 0%, transparent 55%),
    linear-gradient(180deg, #f5f3fc 0%, #ebe7f8 100%);
}

#heroCanvas {
  display: block;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.hero__content {
  position: relative;
  z-index: 2;
  width: min(720px, 92vw);
  margin-left: clamp(1rem, 5vw, 4rem);
  will-change: transform;
}

.hero__eyebrow {
  font-family: var(--mono);
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-2);
  margin-bottom: 1rem;
}

.hero__title {
  font-size: clamp(2.25rem, 5vw, 3.75rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin: 0 0 1.25rem;
}

.text-gradient {
  background: linear-gradient(120deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero__lead {
  font-size: 1.1rem;
  color: var(--text-muted);
  max-width: 34ch;
  margin-bottom: 2rem;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.5rem;
  border-radius: 999px;
  font-family: inherit;
  font-weight: 600;
  font-size: 0.95rem;
  border: none;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn:active {
  transform: scale(0.98);
}

.btn--primary {
  background: linear-gradient(135deg, var(--accent), #5a3fd4);
  color: #fff;
  box-shadow: 0 8px 32px rgba(124, 92, 255, 0.35);
}

.btn--primary:hover {
  box-shadow: 0 12px 40px rgba(124, 92, 255, 0.5);
}

.btn--ghost {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  border: 1px solid var(--border);
}

.btn--full {
  width: 100%;
}

.btn__spinner {
  display: none;
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

.btn.is-loading .btn__label {
  opacity: 0.6;
}

.btn.is-loading .btn__spinner {
  display: block;
}

.hero__scroll {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-muted);
  z-index: 2;
}

.hero__scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, var(--accent), transparent);
  animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
  0%,
  100% {
    opacity: 0.3;
    transform: scaleY(0.8);
  }
  50% {
    opacity: 1;
    transform: scaleY(1);
  }
}

/* ----- Sections ----- */
.section {
  position: relative;
  padding: clamp(4rem, 10vw, 7rem) 0;
  z-index: 1;
  overflow: hidden;
}

/* Themed bands (violet / teal washes — no pure black) */
.section.about {
  background:
    radial-gradient(ellipse 120% 90% at 10% 20%, rgba(124, 92, 255, 0.14) 0%, transparent 55%),
    radial-gradient(ellipse 90% 70% at 90% 80%, rgba(0, 229, 200, 0.07) 0%, transparent 50%),
    linear-gradient(180deg, #0a0818 0%, #0c0a1c 45%, #0a0f20 100%);
}

.section.services {
  background:
    radial-gradient(ellipse 100% 80% at 85% 15%, rgba(0, 229, 200, 0.1) 0%, transparent 50%),
    radial-gradient(ellipse 80% 60% at 15% 85%, rgba(124, 92, 255, 0.1) 0%, transparent 48%),
    linear-gradient(180deg, #0a0f20 0%, #0b0d22 50%, #090818 100%);
}

.section.portfolio {
  background:
    radial-gradient(ellipse 110% 85% at 50% 0%, rgba(124, 92, 255, 0.1) 0%, transparent 45%),
    radial-gradient(ellipse 70% 50% at 70% 100%, rgba(42, 31, 102, 0.35) 0%, transparent 55%),
    linear-gradient(180deg, #090818 0%, #0c0a1a 50%, #0a0c1e 100%);
}

.section.testimonials {
  background:
    radial-gradient(ellipse 100% 90% at 30% 60%, rgba(124, 92, 255, 0.12) 0%, transparent 52%),
    radial-gradient(ellipse 80% 70% at 75% 30%, rgba(0, 229, 200, 0.08) 0%, transparent 48%),
    linear-gradient(180deg, #0a0c1e 0%, #080716 100%);
}

[data-theme="light"] .section.about {
  background:
    radial-gradient(ellipse 120% 90% at 10% 20%, rgba(107, 79, 232, 0.12) 0%, transparent 55%),
    radial-gradient(ellipse 90% 70% at 90% 80%, rgba(0, 158, 138, 0.08) 0%, transparent 50%),
    linear-gradient(180deg, #faf8ff 0%, #f0ecfb 100%);
}

[data-theme="light"] .section.services {
  background:
    radial-gradient(ellipse 100% 80% at 85% 15%, rgba(0, 158, 138, 0.1) 0%, transparent 50%),
    radial-gradient(ellipse 80% 60% at 15% 85%, rgba(107, 79, 232, 0.1) 0%, transparent 48%),
    linear-gradient(180deg, #f0ecfb 0%, #e8e4f8 100%);
}

[data-theme="light"] .section.portfolio {
  background:
    radial-gradient(ellipse 110% 85% at 50% 0%, rgba(107, 79, 232, 0.1) 0%, transparent 45%),
    radial-gradient(ellipse 70% 50% at 70% 100%, rgba(200, 190, 255, 0.4) 0%, transparent 55%),
    linear-gradient(180deg, #e8e4f8 0%, #f2f0fa 100%);
}

[data-theme="light"] .section.testimonials {
  background:
    radial-gradient(ellipse 100% 90% at 30% 60%, rgba(107, 79, 232, 0.1) 0%, transparent 52%),
    radial-gradient(ellipse 80% 70% at 75% 30%, rgba(0, 158, 138, 0.07) 0%, transparent 48%),
    linear-gradient(180deg, #f2f0fa 0%, #faf8ff 100%);
}

.section__head {
  margin-bottom: 3rem;
  text-align: center;
  max-width: 560px;
  margin-inline: auto;
}

.section__title {
  font-size: clamp(1.75rem, 3.5vw, 2.25rem);
  margin: 0 0 0.75rem;
  letter-spacing: -0.02em;
}

.section__subtitle {
  margin: 0;
  color: var(--text-muted);
}

/* ----- Team tilt cards ----- */
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
}

.tilt-card {
  perspective: 1000px;
  padding: 0;
  border: none;
  background: transparent;
  cursor: default;
}

.tilt-card.glass {
  padding: 0;
}

.tilt-card__inner {
  padding: 0;
  border-radius: var(--radius);
  overflow: hidden;
  transform-style: preserve-3d;
  transition: transform 0.15s ease-out;
  will-change: transform;
}

/* Team: photo + skills + social */
.team-card .tilt-card__inner {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.team-card__photo {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
  background: var(--bg-elevated);
}

.team-card__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.team-card:hover .team-card__photo img {
  transform: scale(1.06);
}

.team-card__body {
  padding: 1.25rem 1.35rem 1.5rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.tilt-card__name {
  margin: 0 0 0.25rem;
  font-size: 1.15rem;
}

.tilt-card__role {
  margin: 0 0 0.85rem;
  font-size: 0.85rem;
  color: var(--accent-2);
  font-family: var(--mono);
}

.team-card__skills {
  list-style: none;
  margin: 0 0 1rem;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.team-card__skills li {
  font-size: 0.72rem;
  font-family: var(--mono);
  padding: 0.3rem 0.55rem;
  border-radius: 6px;
  background: rgba(124, 92, 255, 0.12);
  border: 1px solid rgba(124, 92, 255, 0.22);
  color: var(--text-muted);
}

.team-card__social {
  margin-top: auto;
  display: flex;
  gap: 0.65rem;
}

.social-link {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  transition: color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.social-link:hover,
.social-link:focus-visible {
  color: var(--accent-2);
  background: rgba(124, 92, 255, 0.15);
  box-shadow: 0 0 20px rgba(0, 229, 200, 0.15);
  transform: translateY(-2px);
  outline: none;
}

/* ----- Services (image + details) ----- */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
}

.service-card {
  text-align: left;
  padding: 0;
  overflow: hidden;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.service-card:hover,
.service-card:focus-visible {
  transform: translateY(-8px);
  border-color: rgba(124, 92, 255, 0.45);
  box-shadow:
    0 20px 56px rgba(124, 92, 255, 0.18),
    0 0 0 1px rgba(124, 92, 255, 0.12) inset;
  outline: none;
}

.service-card__media {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(145deg, #1a1538 0%, #0d1228 50%, #0a1620 100%);
}

[data-theme="light"] .service-card__media {
  background: linear-gradient(145deg, #e4dff8 0%, #dce8f4 50%, #d4f0ec 100%);
}

.service-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.55s cubic-bezier(0.33, 1, 0.68, 1);
}

.service-card:hover .service-card__media img {
  transform: scale(1.07);
}

.service-card__media-shine {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    125deg,
    transparent 40%,
    rgba(255, 255, 255, 0.07) 50%,
    transparent 60%
  );
  transform: translateX(-100%);
  transition: transform 0.7s ease;
}

.service-card:hover .service-card__media-shine {
  transform: translateX(100%);
}

.service-card__body {
  padding: 1.35rem 1.5rem 1.6rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.service-card__title {
  margin: 0 0 0.45rem;
  font-size: 1.2rem;
}

.service-card__desc {
  margin: 0 0 0.85rem;
  font-size: 0.92rem;
  color: var(--text-muted);
}

.service-card__details {
  margin: 0 0 1rem;
  padding-left: 1.1rem;
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.service-card__details li {
  margin-bottom: 0.35rem;
}

.service-card__hint {
  margin-top: auto;
  font-size: 0.78rem;
  font-family: var(--mono);
  color: var(--accent-2);
}

/* ----- Portfolio: image + title + CTA ----- */
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1.35rem;
  perspective: 1400px;
}

.project-card {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--bg-elevated);
  transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}

.project-card:hover,
.project-card:focus-within {
  transform: translateY(-6px) rotateX(2deg);
  border-color: rgba(124, 92, 255, 0.35);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45), 0 0 40px rgba(124, 92, 255, 0.12);
}

.project-card__link {
  display: block;
  color: inherit;
  text-decoration: none;
}

.project-card__image-wrap {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
}

.project-card__image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.55s ease;
}

.project-card:hover .project-card__image-wrap img {
  transform: scale(1.08);
}

.project-card__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(14, 12, 35, 0.94) 0%, rgba(20, 18, 45, 0.35) 45%, transparent 58%);
  pointer-events: none;
}

.project-card__content {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 1.1rem 1.15rem 1.15rem;
  z-index: 1;
}

.project-card__tag {
  display: inline-block;
  font-size: 0.65rem;
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent-2);
  margin-bottom: 0.35rem;
}

.project-card__title {
  margin: 0 0 0.75rem;
  font-size: 1.05rem;
  line-height: 1.25;
  letter-spacing: -0.02em;
}

.project-card__cta {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.82rem;
  font-weight: 600;
  font-family: var(--mono);
  color: var(--text);
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  background: rgba(124, 92, 255, 0.25);
  border: 1px solid rgba(124, 92, 255, 0.4);
  transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.project-card__cta svg {
  width: 14px;
  height: 14px;
  transition: transform 0.25s ease;
}

.project-card:hover .project-card__cta,
.project-card:focus-within .project-card__cta {
  background: rgba(124, 92, 255, 0.4);
  box-shadow: 0 0 24px rgba(124, 92, 255, 0.25);
}

.project-card:hover .project-card__cta svg {
  transform: translateX(4px);
}

[data-theme="light"] .project-card__overlay {
  background: linear-gradient(to top, rgba(26, 21, 48, 0.88) 0%, rgba(40, 35, 70, 0.2) 48%, transparent 60%);
}

/* ----- Testimonials ----- */
.testimonial-slider {
  padding: 2rem;
  max-width: 720px;
  margin-inline: auto;
}

.testimonial-slider__track {
  position: relative;
  min-height: 180px;
  overflow: hidden;
}

.testimonial-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: translateX(24px);
  transition: opacity 0.5s ease, transform 0.5s ease;
  pointer-events: none;
}

.testimonial-slide.is-active {
  opacity: 1;
  transform: translateX(0);
  pointer-events: auto;
}

.testimonial-slide blockquote {
  margin: 0;
  font-size: 1.15rem;
  line-height: 1.55;
}

.testimonial-slide cite {
  display: block;
  margin-top: 1.25rem;
  font-style: normal;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.testimonial-slide cite strong {
  display: block;
  color: var(--text);
}

.testimonial-slider__controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-top: 1.5rem;
}

.slider-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s ease, box-shadow 0.2s ease;
}

.slider-btn:hover {
  background: rgba(124, 92, 255, 0.2);
  box-shadow: 0 0 20px var(--glow);
}

.slider-dots {
  display: flex;
  gap: 0.5rem;
}

.slider-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--text-muted);
  border: none;
  padding: 0;
  cursor: pointer;
  opacity: 0.4;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.slider-dot.is-active {
  opacity: 1;
  transform: scale(1.25);
  background: var(--accent);
}

/* ----- Contact: full-bleed immersive bg ----- */
.contact--full {
  position: relative;
  overflow: hidden;
  padding: clamp(5rem, 12vw, 9rem) 0;
  isolation: isolate;
}

.contact__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.contact__aurora {
  position: absolute;
  inset: -20% -10%;
  background:
    radial-gradient(ellipse 80% 60% at 20% 40%, rgba(124, 92, 255, 0.35), transparent 50%),
    radial-gradient(ellipse 70% 50% at 80% 60%, rgba(0, 229, 200, 0.18), transparent 55%),
    radial-gradient(ellipse 50% 40% at 50% 100%, rgba(90, 60, 200, 0.25), transparent 45%);
  filter: blur(2px);
  animation: auroraShift 18s ease-in-out infinite alternate;
}

@keyframes auroraShift {
  0% {
    transform: translate(0, 0) scale(1);
    opacity: 1;
  }
  100% {
    transform: translate(3%, -2%) scale(1.05);
    opacity: 0.92;
  }
}

.contact__orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.55;
  animation: orbFloat 12s ease-in-out infinite;
}

.contact__orb--1 {
  width: min(420px, 60vw);
  height: min(420px, 60vw);
  background: radial-gradient(circle, rgba(124, 92, 255, 0.5), transparent 70%);
  top: -10%;
  left: -5%;
  animation-delay: 0s;
}

.contact__orb--2 {
  width: min(360px, 50vw);
  height: min(360px, 50vw);
  background: radial-gradient(circle, rgba(0, 229, 200, 0.35), transparent 70%);
  bottom: -15%;
  right: -8%;
  animation-delay: -4s;
}

.contact__orb--3 {
  width: min(280px, 40vw);
  height: min(280px, 40vw);
  background: radial-gradient(circle, rgba(255, 100, 180, 0.2), transparent 70%);
  top: 40%;
  right: 25%;
  animation-delay: -7s;
}

@keyframes orbFloat {
  0%,
  100% {
    transform: translate(0, 0);
  }
  50% {
    transform: translate(12px, -18px);
  }
}

.contact__noise {
  position: absolute;
  inset: 0;
  opacity: 0.04;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  mix-blend-mode: overlay;
}

.contact__layout {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 3.5rem);
  align-items: start;
}

@media (max-width: 900px) {
  .contact__layout {
    grid-template-columns: 1fr;
  }
}

.contact__eyebrow {
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent-2);
  margin: 0 0 0.75rem;
}

.contact__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 1.75rem;
}

.contact__chip {
  font-size: 0.78rem;
  font-family: var(--mono);
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-muted);
}

.contact__bullets {
  margin: 1.5rem 0 0;
  padding-left: 1.25rem;
  color: var(--text-muted);
}

.contact__bullets li {
  margin-bottom: 0.5rem;
}

.contact-form {
  padding: 2rem;
}

.contact-form--elevated {
  background: rgba(16, 14, 36, 0.68);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(124, 92, 255, 0.25);
  box-shadow:
    0 24px 80px rgba(0, 0, 0, 0.55),
    0 0 0 1px rgba(255, 255, 255, 0.05) inset,
    0 0 60px rgba(124, 92, 255, 0.08);
}

[data-theme="light"] .contact-form--elevated {
  background: rgba(255, 255, 255, 0.82);
  border-color: rgba(107, 79, 232, 0.22);
  box-shadow:
    0 24px 80px rgba(80, 60, 160, 0.12),
    0 0 0 1px rgba(255, 255, 255, 0.9) inset,
    0 0 48px rgba(107, 79, 232, 0.08);
}

.form-row {
  margin-bottom: 1.25rem;
}

.form-row label {
  display: block;
  font-size: 0.85rem;
  margin-bottom: 0.4rem;
  color: var(--text-muted);
}

.form-row input,
.form-row textarea {
  width: 100%;
  padding: 0.85rem 1rem;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--input-bg);
  color: var(--text);
  font-family: inherit;
  font-size: 1rem;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-row input:focus,
.form-row textarea:focus {
  outline: none;
  border-color: rgba(124, 92, 255, 0.5);
  box-shadow: 0 0 0 3px rgba(124, 92, 255, 0.15);
}

.form-row input.is-invalid,
.form-row textarea.is-invalid {
  border-color: #ff5c7a;
}

.field-error {
  display: block;
  min-height: 1.25rem;
  margin-top: 0.35rem;
  font-size: 0.8rem;
  color: #ff8fa3;
}

.form-hint {
  margin-top: 1rem;
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: center;
}

/* ----- Toast ----- */
.toast {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 10000;
  transform: translateY(120%);
  opacity: 0;
  transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.4s ease;
  max-width: min(380px, 92vw);
}

.toast.is-visible {
  transform: translateY(0);
  opacity: 1;
}

.toast__inner {
  display: flex;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  align-items: flex-start;
}

.toast__icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-2), #00b89a);
  display: grid;
  place-items: center;
  font-weight: 700;
  color: #061210;
}

.toast__title {
  display: block;
  margin-bottom: 0.25rem;
}

.toast__msg {
  margin: 0;
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* ----- Floating WhatsApp + social (single toggle opens panel) ----- */
.fab-float {
  position: fixed;
  z-index: 9998;
  right: max(1rem, env(safe-area-inset-right));
  bottom: max(1.25rem, env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.75rem;
  pointer-events: none;
}

.fab-float__backdrop {
  position: fixed;
  inset: 0;
  z-index: 9997;
  background: rgba(6, 4, 18, 0.45);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.28s ease, visibility 0.28s ease;
}

[data-theme="light"] .fab-float__backdrop {
  background: rgba(26, 21, 48, 0.25);
}

.fab-float.is-open .fab-float__backdrop {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.fab-float__panel {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.6rem;
  z-index: 9998;
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px) scale(0.96);
  transform-origin: bottom right;
  pointer-events: none;
  transition:
    opacity 0.28s ease,
    visibility 0.28s ease,
    transform 0.28s cubic-bezier(0.34, 1.2, 0.64, 1);
}

.fab-float.is-open .fab-float__panel {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

.fab-float__toggle {
  position: relative;
  z-index: 9999;
  width: 58px;
  height: 58px;
  padding: 0;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  color: #fff;
  background: linear-gradient(145deg, var(--accent) 0%, #5a3fd4 45%, #3d2a9e 100%);
  box-shadow:
    0 10px 36px rgba(124, 92, 255, 0.45),
    0 0 28px rgba(124, 92, 255, 0.4),
    0 0 0 1px rgba(255, 255, 255, 0.12) inset;
  pointer-events: auto;
  transition: transform 0.2s ease;
  animation: fabToggleGlow 2.6s ease-in-out infinite;
}

.fab-float__toggle::before {
  content: "";
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 2px solid rgba(124, 92, 255, 0.55);
  pointer-events: none;
  animation: fabToggleRing 2.4s ease-out infinite;
  z-index: -1;
}

.fab-float__toggle::after {
  content: "";
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 2px solid rgba(0, 229, 200, 0.35);
  pointer-events: none;
  animation: fabToggleRing 2.4s ease-out infinite 1.2s;
  z-index: -1;
}

@keyframes fabToggleGlow {
  0%,
  100% {
    box-shadow:
      0 10px 36px rgba(124, 92, 255, 0.45),
      0 0 28px rgba(124, 92, 255, 0.35),
      0 0 0 1px rgba(255, 255, 255, 0.12) inset;
  }
  50% {
    box-shadow:
      0 12px 48px rgba(124, 92, 255, 0.65),
      0 0 42px rgba(0, 229, 200, 0.45),
      0 0 56px rgba(124, 92, 255, 0.35),
      0 0 0 1px rgba(255, 255, 255, 0.2) inset;
  }
}

@keyframes fabToggleRing {
  0% {
    transform: scale(1);
    opacity: 0.75;
  }
  100% {
    transform: scale(1.45);
    opacity: 0;
  }
}

.fab-float.is-open .fab-float__toggle {
  animation: none;
  box-shadow:
    0 10px 36px rgba(124, 92, 255, 0.4),
    0 0 20px rgba(124, 92, 255, 0.25),
    0 0 0 1px rgba(255, 255, 255, 0.12) inset;
}

.fab-float.is-open .fab-float__toggle::before,
.fab-float.is-open .fab-float__toggle::after {
  animation: none;
  opacity: 0;
}

.fab-float__toggle:hover,
.fab-float__toggle:focus-visible {
  transform: scale(1.05);
  outline: none;
}

[data-theme="light"] .fab-float__toggle::before {
  border-color: rgba(107, 79, 232, 0.45);
}

[data-theme="light"] .fab-float__toggle::after {
  border-color: rgba(0, 158, 138, 0.3);
}

.fab-float__toggle-icon {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  transition: opacity 0.22s ease, transform 0.22s ease;
}

.fab-float__toggle-icon--close {
  opacity: 0;
  transform: rotate(-90deg) scale(0.85);
}

.fab-float.is-open .fab-float__toggle-icon--open {
  opacity: 0;
  transform: rotate(90deg) scale(0.85);
}

.fab-float.is-open .fab-float__toggle-icon--close {
  opacity: 1;
  transform: rotate(0) scale(1);
}

.fab-float__social {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.45rem;
  width: 100%;
}

.fab-float__btn {
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid var(--border);
  color: var(--text-muted);
  background: var(--surface);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow:
    0 8px 28px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  transition: transform 0.2s ease, color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.fab-float__btn:hover,
.fab-float__btn:focus-visible {
  color: var(--accent-2);
  border-color: rgba(124, 92, 255, 0.45);
  box-shadow: 0 10px 32px rgba(124, 92, 255, 0.2);
  transform: translateY(-2px);
  outline: none;
}

.fab-float__btn--social {
  width: 46px;
  height: 46px;
}

[data-theme="light"] .fab-float__btn--social {
  box-shadow:
    0 8px 24px rgba(80, 60, 160, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.85);
}

.fab-float__btn--wa {
  width: 58px;
  height: 58px;
  border: none;
  color: #fff;
  background: linear-gradient(155deg, #2fe27a 0%, #25d366 40%, #128c7e 100%);
  box-shadow:
    0 10px 36px rgba(37, 211, 102, 0.42),
    0 0 0 1px rgba(255, 255, 255, 0.12) inset;
}

.fab-float__btn--wa:hover,
.fab-float__btn--wa:focus-visible {
  color: #fff;
  border: none;
  box-shadow:
    0 14px 44px rgba(37, 211, 102, 0.55),
    0 0 0 1px rgba(255, 255, 255, 0.18) inset;
}

@media (prefers-reduced-motion: reduce) {
  .fab-float__btn,
  .fab-float__panel,
  .fab-float__backdrop,
  .fab-float__toggle-icon {
    transition: none;
  }
  .fab-float__btn:hover {
    transform: none;
  }
  .fab-float__panel {
    transform: none;
  }
  .fab-float__toggle,
  .fab-float__toggle::before,
  .fab-float__toggle::after {
    animation: none !important;
  }
}

@media print {
  .fab-float {
    display: none;
  }
}

/* ----- Footer ----- */
.footer {
  padding: 2rem 0 3rem;
  border-top: 1px solid var(--border);
  position: relative;
  z-index: 1;
}

.footer__inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.footer__top {
  font-size: 0.85rem;
  color: var(--accent-2);
}

/* GSAP reveal initial state (JS also sets) */
[data-reveal],
.reveal {
  opacity: 0;
  transform: translateY(28px);
}
