@import "tailwindcss";

@theme {
  --font-display: "Space Grotesk", ui-sans-serif, system-ui, sans-serif;
  --font-sans: "Inter", ui-sans-serif, system-ui, sans-serif;

  --color-ink: #06060a;
  --color-ink-soft: #0c0c14;
  --color-mist: #ececf2;
  --color-aura-violet: #8b5cf6;
  --color-aura-cyan: #22d3ee;
  --color-aura-rose: #f472b6;

  --shadow-aura: 0 30px 60px -20px rgba(139, 92, 246, 0.35);
}

/* ---------- Base ---------- */
html, body { background: var(--color-ink); }
body { font-family: var(--font-sans); }

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: #06060a; }
::-webkit-scrollbar-thumb { background: linear-gradient(180deg, #2a2a3a, #1a1a26); border-radius: 999px; }
::-webkit-scrollbar-thumb:hover { background: linear-gradient(180deg, #3a3a52, #20202e); }

.font-display { font-family: var(--font-display); letter-spacing: -0.02em; }

/* ---------- Skip link ---------- */
.skip-link {
  position: absolute; top: -100px; left: 1rem; z-index: 100;
  background: var(--color-ink-soft); color: var(--color-mist);
  padding: .65rem 1rem; border-radius: .75rem; border: 1px solid rgba(255,255,255,.1);
  transition: top .25s ease;
}
.skip-link:focus { top: 1rem; }

/* ---------- Cursor halo + grain ---------- */
#cursor-halo {
  position: fixed; inset: 0; pointer-events: none; z-index: 1;
  background: radial-gradient(280px circle at var(--mx, 50%) var(--my, 50%),
              rgba(139,92,246,0.18), rgba(34,211,238,0.06) 40%, transparent 70%);
  mix-blend-mode: screen; transition: opacity .3s ease;
}
@media (hover: none) { #cursor-halo { display: none; } }

#grain {
  position: fixed; inset: 0; z-index: 2; pointer-events: none; opacity: .035;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/><feColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0 0 0 0.6 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

/* ---------- Logo mark ---------- */
.logo-mark {
  display: inline-block; width: 22px; height: 22px; border-radius: 8px;
  background:
    radial-gradient(circle at 30% 30%, #ffffff, transparent 40%),
    conic-gradient(from 200deg, #8b5cf6, #22d3ee, #f472b6, #8b5cf6);
  box-shadow: 0 0 24px rgba(139,92,246,.55);
  animation: spin-slow 14s linear infinite;
}
@keyframes spin-slow { to { transform: rotate(360deg); } }

/* ---------- Nav ---------- */
header#site-nav.is-scrolled > div:first-child {
  background: rgba(6,6,10,.65);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(255,255,255,.06);
}
header#site-nav > div:first-child { transition: background .3s ease, border-color .3s ease; border-bottom: 1px solid transparent; }

.nav-pill {
  display: inline-flex; align-items: center; padding: .55rem 1rem;
  font-size: .85rem; color: rgba(236,236,242,.7); border-radius: 999px;
  transition: color .2s ease, background .2s ease;
}
.nav-pill:hover { color: #fff; background: rgba(255,255,255,.06); }

.mobile-menu {
  margin: 0 1rem; padding: 1rem; border-radius: 1.25rem;
  background: rgba(6,6,10,.85); backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,.08);
}
.mobile-link {
  display: block; padding: .8rem 1rem; border-radius: .75rem;
  color: rgba(236,236,242,.85); font-size: 1rem;
}
.mobile-link:hover { background: rgba(255,255,255,.05); color: #fff; }

/* ---------- Buttons ---------- */
.btn-primary {
  display: inline-flex; align-items: center; gap: .55rem;
  padding: .75rem 1.25rem; border-radius: 999px;
  background: linear-gradient(135deg, #8b5cf6, #22d3ee);
  color: white; font-weight: 600; font-size: .9rem;
  box-shadow: 0 10px 30px -10px rgba(139,92,246,.55);
  transition: transform .25s ease, box-shadow .25s ease, filter .25s ease;
  position: relative; overflow: hidden;
}
.btn-primary::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(135deg, #f472b6, #8b5cf6);
  opacity: 0; transition: opacity .3s ease;
}
.btn-primary > * { position: relative; z-index: 1; }
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 18px 40px -12px rgba(244,114,182,.55); }
.btn-primary:hover::after { opacity: 1; }

.btn-ghost {
  display: inline-flex; align-items: center; gap: .55rem;
  padding: .75rem 1.25rem; border-radius: 999px;
  border: 1px solid rgba(255,255,255,.12); color: rgba(236,236,242,.9);
  font-weight: 500; font-size: .9rem;
  transition: background .25s ease, border-color .25s ease, color .25s ease;
}
.btn-ghost:hover { background: rgba(255,255,255,.05); border-color: rgba(255,255,255,.25); color: #fff; }

/* ---------- Eyebrow + section ---------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: .55rem;
  padding: .35rem .8rem; border-radius: 999px;
  border: 1px solid rgba(255,255,255,.1); background: rgba(255,255,255,.03);
  font-size: .72rem; letter-spacing: .14em; text-transform: uppercase;
  color: rgba(236,236,242,.7);
}
.eyebrow .dot {
  display: inline-block; width: 6px; height: 6px; border-radius: 999px;
  background: #22d3ee; box-shadow: 0 0 14px #22d3ee;
  animation: pulse 1.6s ease-in-out infinite;
}
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: .35; } }

.section { padding: 7rem 0; }
.section-header { max-width: 64rem; margin: 0 auto; padding: 0 1.25rem; text-align: center; }
.section-title { font-size: clamp(2rem, 4.5vw, 3.75rem); font-weight: 600; line-height: 1.05; margin-top: 1rem; }
.section-lead { margin: 1.25rem auto 0; max-width: 38rem; color: rgba(236,236,242,.65); font-size: 1.05rem; line-height: 1.6; }

/* ---------- Gradient text ---------- */
.gradient-text {
  background: linear-gradient(120deg, #f472b6 0%, #8b5cf6 40%, #22d3ee 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  background-size: 200% 200%;
  animation: shift 8s ease infinite;
}
@keyframes shift { 0%,100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }

/* ---------- HERO ---------- */
.hero-gradient {
  background:
    radial-gradient(60% 60% at 50% 10%, rgba(139,92,246,.2), transparent 70%),
    radial-gradient(80% 60% at 80% 80%, rgba(34,211,238,.18), transparent 60%),
    linear-gradient(180deg, rgba(6,6,10,.4) 0%, rgba(6,6,10,.85) 60%, #06060a 100%);
}
.hero-title {
  font-size: clamp(2.75rem, 8vw, 6.5rem);
  line-height: .98; font-weight: 600; letter-spacing: -0.035em;
  margin-top: 1.5rem;
}
.hero-title .block { display: block; }

.stat-card {
  padding: 1.25rem 1rem; border-radius: 1rem;
  border: 1px solid rgba(255,255,255,.08); background: rgba(255,255,255,.02);
  backdrop-filter: blur(8px);
}
.stat-label { display: block; font-size: .7rem; text-transform: uppercase; letter-spacing: .14em; color: rgba(236,236,242,.55); }
.stat-value { display: block; margin-top: .35rem; font-family: var(--font-display); font-size: 1.75rem; font-weight: 600; color: #fff; }

.hero-scroll { position: absolute; bottom: 2rem; left: 50%; transform: translateX(-50%); width: 22px; height: 38px; border: 1px solid rgba(255,255,255,.25); border-radius: 999px; display: grid; place-items: start center; padding-top: 6px; }
.hero-scroll-bar { width: 2px; height: 8px; background: #fff; border-radius: 999px; animation: scrollBar 1.6s ease-in-out infinite; }
@keyframes scrollBar { 0% { transform: translateY(0); opacity: 1; } 70% { transform: translateY(14px); opacity: 0; } 100% { opacity: 0; } }

/* ---------- Marquee ---------- */
.marquee-wrap { overflow: hidden; }
.marquee { display: flex; }
.marquee-track {
  display: flex; gap: 2.5rem; align-items: center; white-space: nowrap;
  font-family: var(--font-display); font-size: 1.5rem; color: rgba(236,236,242,.55);
  animation: marquee 32s linear infinite; padding-left: 2.5rem;
}
.marquee-track .dot-sep { width: 6px; height: 6px; border-radius: 999px; background: #8b5cf6; box-shadow: 0 0 12px #8b5cf6; }
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ---------- Filter chips ---------- */
.filter-chip {
  padding: .55rem 1rem; border-radius: 999px;
  border: 1px solid rgba(255,255,255,.1); background: rgba(255,255,255,.03);
  font-size: .82rem; color: rgba(236,236,242,.75);
  transition: background .25s ease, color .25s ease, border-color .25s ease, transform .15s ease;
}
.filter-chip:hover { color: #fff; border-color: rgba(255,255,255,.25); }
.filter-chip.is-active {
  background: linear-gradient(120deg, rgba(139,92,246,.25), rgba(34,211,238,.18));
  color: #fff; border-color: rgba(139,92,246,.5);
  box-shadow: 0 8px 30px -10px rgba(139,92,246,.4);
}

/* ---------- App card ---------- */
.app-card {
  position: relative; padding: 1.5rem; border-radius: 1.25rem;
  border: 1px solid rgba(255,255,255,.08);
  background: linear-gradient(180deg, rgba(255,255,255,.04), rgba(255,255,255,.01));
  overflow: hidden; isolation: isolate;
  transition: transform .4s cubic-bezier(.2,.8,.2,1), border-color .3s ease;
  display: flex; flex-direction: column; gap: 1rem; min-height: 220px;
}
.app-card::before {
  content: ""; position: absolute; inset: -1px; border-radius: inherit; padding: 1px;
  background: linear-gradient(135deg, rgba(139,92,246,.5), rgba(34,211,238,.3) 50%, transparent 70%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: 0; transition: opacity .35s ease; z-index: -1;
}
.app-card:hover { transform: translateY(-4px); border-color: transparent; }
.app-card:hover::before { opacity: 1; }
.app-card .glow {
  position: absolute; inset: auto -40% -60% -40%; height: 60%; opacity: .15;
  background: radial-gradient(ellipse at center, currentColor, transparent 70%);
  filter: blur(40px); transition: opacity .35s ease;
}
.app-card:hover .glow { opacity: .35; }

.app-icon-wrap {
  width: 56px; height: 56px; border-radius: 16px; display: grid; place-items: center;
  background: linear-gradient(135deg, var(--c1), var(--c2));
  box-shadow: 0 12px 30px -10px rgba(0,0,0,.6), inset 0 1px 0 rgba(255,255,255,.25);
  color: #06060a;
}
.app-icon-wrap svg { width: 28px; height: 28px; stroke-width: 2.25; }

.app-card h3 { font-family: var(--font-display); font-size: 1.25rem; font-weight: 600; color: #fff; }
.app-card p { font-size: .9rem; color: rgba(236,236,242,.7); line-height: 1.55; flex: 1; }
.app-card .meta { display: flex; align-items: center; justify-content: space-between; }
.app-card .pill {
  font-size: .68rem; letter-spacing: .14em; text-transform: uppercase;
  color: rgba(236,236,242,.6); padding: .25rem .6rem;
  border: 1px solid rgba(255,255,255,.1); border-radius: 999px;
}
.app-card a.store {
  display: inline-flex; align-items: center; gap: .35rem; font-size: .82rem; color: #fff;
  border-bottom: 1px solid transparent; padding-bottom: 1px;
  transition: border-color .25s ease, gap .25s ease;
}
.app-card a.store:hover { border-color: rgba(255,255,255,.4); gap: .55rem; }

/* ---------- Project card ---------- */
.project-card {
  position: relative; border-radius: 1.5rem; overflow: hidden; isolation: isolate;
  border: 1px solid rgba(255,255,255,.08); aspect-ratio: 4/5;
  transition: transform .5s cubic-bezier(.2,.8,.2,1);
}
.project-card img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .8s ease, filter .8s ease; }
.project-card::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 35%, rgba(6,6,10,.85) 100%);
}
.project-card:hover { transform: translateY(-6px); }
.project-card:hover img { transform: scale(1.06); filter: saturate(1.15); }
.project-card .body { position: absolute; inset: auto 0 0 0; padding: 1.5rem; z-index: 1; }
.project-card .pill { font-size: .68rem; letter-spacing: .14em; text-transform: uppercase; color: #fff; padding: .25rem .6rem; background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.15); border-radius: 999px; backdrop-filter: blur(8px); }
.project-card h3 { font-family: var(--font-display); font-size: 1.6rem; font-weight: 600; color: #fff; margin-top: .75rem; }
.project-card p { color: rgba(236,236,242,.7); margin-top: .5rem; font-size: .9rem; line-height: 1.55; }
.project-card .tags { display: flex; gap: .35rem; flex-wrap: wrap; margin-top: .75rem; }
.project-card .tag { font-size: .7rem; padding: .2rem .55rem; border: 1px solid rgba(255,255,255,.15); border-radius: 999px; color: rgba(236,236,242,.75); }

/* ---------- Service card ---------- */
.service-card {
  padding: 1.75rem; border-radius: 1.25rem;
  border: 1px solid rgba(255,255,255,.08);
  background: linear-gradient(180deg, rgba(255,255,255,.03), rgba(255,255,255,.005));
  transition: transform .35s ease, border-color .25s ease;
}
.service-card:hover { transform: translateY(-4px); border-color: rgba(139,92,246,.35); }
.service-card h3 { font-family: var(--font-display); font-size: 1.2rem; font-weight: 600; color: #fff; margin-top: 1rem; }
.service-card p { color: rgba(236,236,242,.65); font-size: .9rem; line-height: 1.55; margin-top: .5rem; }
.service-icon {
  width: 44px; height: 44px; padding: 10px; border-radius: 12px;
  background: linear-gradient(135deg, rgba(139,92,246,.2), rgba(34,211,238,.15));
  border: 1px solid rgba(139,92,246,.3); color: #fff;
}

/* ---------- KPI card ---------- */
.kpi-card {
  padding: 1.5rem; border-radius: 1rem;
  border: 1px solid rgba(255,255,255,.08); background: rgba(255,255,255,.02);
  display: flex; flex-direction: column; gap: .65rem;
  transition: transform .35s ease, border-color .25s ease;
}
.kpi-card:hover { transform: translateY(-3px); border-color: rgba(34,211,238,.3); }
.kpi-icon { width: 32px; height: 32px; color: #22d3ee; }
.kpi-value { font-family: var(--font-display); font-size: 2.25rem; font-weight: 600; color: #fff; }
.kpi-label { font-size: .8rem; color: rgba(236,236,242,.6); }

/* ---------- Aura blobs ---------- */
.aura-blob { position: absolute; border-radius: 50%; filter: blur(110px); opacity: .35; pointer-events: none; z-index: -1; }
.aura-blob-1 { width: 540px; height: 540px; background: radial-gradient(circle, #8b5cf6, transparent 60%); top: 20%; right: -10%; }
.aura-blob-2 { width: 480px; height: 480px; background: radial-gradient(circle, #22d3ee, transparent 60%); bottom: -10%; left: -10%; }

/* ---------- Contact ---------- */
.contact-card {
  padding: 2.5rem; border-radius: 1.5rem;
  background: linear-gradient(135deg, rgba(139,92,246,.08), rgba(34,211,238,.06));
  border: 1px solid rgba(255,255,255,.08);
  position: relative; overflow: hidden;
}
.contact-card::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(60% 60% at 80% 30%, rgba(139,92,246,.18), transparent 70%);
  pointer-events: none;
}
.contact-grid { display: grid; gap: 2.5rem; grid-template-columns: 1fr; position: relative; }
@media (min-width: 768px) { .contact-grid { grid-template-columns: 1fr 1fr; } }

.contact-form { display: flex; flex-direction: column; gap: 1rem; }
.field { display: flex; flex-direction: column; gap: .35rem; }
.field span { font-size: .75rem; letter-spacing: .14em; text-transform: uppercase; color: rgba(236,236,242,.55); }
.field input, .field textarea {
  width: 100%; padding: .85rem 1rem; border-radius: .8rem;
  background: rgba(6,6,10,.55); border: 1px solid rgba(255,255,255,.08);
  color: #fff; font-size: .95rem; font-family: inherit;
  transition: border-color .25s ease, background .25s ease, box-shadow .25s ease;
}
.field input:focus, .field textarea:focus {
  outline: none; border-color: rgba(139,92,246,.6);
  background: rgba(6,6,10,.75); box-shadow: 0 0 0 4px rgba(139,92,246,.12);
}

/* ---------- Social ---------- */
.social {
  display: grid; place-items: center; width: 38px; height: 38px; border-radius: 999px;
  background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.08);
  color: rgba(236,236,242,.7); transition: color .25s ease, background .25s ease, border-color .25s ease;
}
.social:hover { color: #fff; background: rgba(139,92,246,.18); border-color: rgba(139,92,246,.4); }
.social svg { width: 16px; height: 16px; }

/* ---------- Anim helpers ---------- */
[data-anim] { opacity: 0; transform: translateY(24px); }
[data-anim="reveal"] .word, [data-anim="reveal"] .line { display: inline-block; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
  [data-anim] { opacity: 1; transform: none; }
}
