/* ==========================================================================
   WT Studio — Demo Portfolio Landing Page
   ========================================================================== */

:root {
  --bg: #0a0a12;
  --bg-alt: #0f0f1a;
  --surface: #14141f;
  --surface-2: #1b1b29;
  --border: rgba(255,255,255,0.08);
  --text: #f5f5fa;
  --text-dim: #a6a6bd;
  --text-dimmer: #74748f;
  --primary: #8b5cf6;
  --primary-2: #06b6d4;
  --accent: #f472b6;
  --grad: linear-gradient(135deg, #8b5cf6 0%, #06b6d4 100%);
  --grad-2: linear-gradient(135deg, #f472b6 0%, #8b5cf6 100%);
  --shadow: 0 10px 40px rgba(0,0,0,0.35);
  --radius: 20px;
  --radius-sm: 12px;
  --ff-heading: 'Sora', sans-serif;
  --ff-body: 'Inter', sans-serif;
}

[data-theme="light"] {
  --bg: #f7f7fb;
  --bg-alt: #ffffff;
  --surface: #ffffff;
  --surface-2: #f1f1f8;
  --border: rgba(10,10,20,0.08);
  --text: #14141f;
  --text-dim: #4b4b63;
  --text-dimmer: #7a7a92;
  --shadow: 0 10px 40px rgba(20,20,40,0.08);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--ff-body);
  line-height: 1.6;
  overflow-x: hidden;
  cursor: none;
  transition: background 0.4s ease, color 0.4s ease;
}

@media (hover: none), (pointer: coarse) {
  body { cursor: auto; }
  .cursor-dot, .cursor-outline { display: none; }
}

h1, h2, h3, h4 { font-family: var(--ff-heading); font-weight: 700; margin: 0 0 0.6em; line-height: 1.2; }
p { color: var(--text-dim); margin: 0 0 1em; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul { list-style: none; margin: 0; padding: 0; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }

.container { width: min(1200px, 92%); margin: 0 auto; }
.gradient-text {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--primary-2);
  margin-bottom: 0.8rem;
}

/* ---------- Custom cursor ---------- */
.cursor-dot, .cursor-outline {
  position: fixed;
  top: 0; left: 0;
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
}
.cursor-dot { width: 6px; height: 6px; background: var(--primary-2); }
.cursor-outline {
  width: 34px; height: 34px;
  border: 1.5px solid var(--primary);
  transition: width 0.2s, height 0.2s, opacity 0.2s;
  opacity: 0.6;
}
.cursor-outline.hovered { width: 56px; height: 56px; opacity: 1; background: rgba(139,92,246,0.08); }

/* ---------- Preloader ---------- */
.preloader {
  position: fixed; inset: 0; z-index: 10000;
  background: var(--bg);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1.2rem;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}
.preloader.done { opacity: 0; visibility: hidden; }
.preloader-logo {
  font-family: var(--ff-heading); font-weight: 800; font-size: 1.6rem;
  width: 64px; height: 64px; border-radius: 18px;
  display: flex; align-items: center; justify-content: center;
  background: var(--grad); color: #fff;
  animation: pulse 1.4s ease-in-out infinite;
}
.preloader-bar { width: 160px; height: 3px; background: var(--surface-2); border-radius: 3px; overflow: hidden; }
.preloader-bar span { display: block; height: 100%; width: 40%; background: var(--grad); animation: loading 1.1s ease-in-out infinite; }
@keyframes loading { 0% { transform: translateX(-100%); } 100% { transform: translateX(350%); } }
@keyframes pulse { 0%,100% { transform: scale(1); } 50% { transform: scale(1.08); } }

/* ---------- Scroll progress ---------- */
.scroll-progress {
  position: fixed; top: 0; left: 0; height: 3px; width: 0%;
  background: var(--grad); z-index: 2000;
}

/* ---------- Ambient blobs ---------- */
.bg-blobs { position: fixed; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.blob { position: absolute; border-radius: 50%; filter: blur(90px); opacity: 0.35; }
.blob-1 { width: 480px; height: 480px; background: var(--primary); top: -120px; left: -100px; animation: drift 18s ease-in-out infinite; }
.blob-2 { width: 420px; height: 420px; background: var(--primary-2); top: 30%; right: -140px; animation: drift 22s ease-in-out infinite reverse; }
.blob-3 { width: 380px; height: 380px; background: var(--accent); bottom: -160px; left: 30%; animation: drift 20s ease-in-out infinite; }
@keyframes drift { 0%,100% { transform: translate(0,0) scale(1); } 50% { transform: translate(40px,60px) scale(1.1); } }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.55em;
  padding: 0.85em 1.6em; border-radius: 999px; font-weight: 600; font-size: 0.95rem;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease, color 0.25s ease;
  white-space: nowrap;
}
.btn-primary { background: var(--grad); color: #fff; box-shadow: 0 8px 24px rgba(139,92,246,0.35); }
.btn-primary:hover { transform: translateY(-3px); box-shadow: 0 14px 32px rgba(139,92,246,0.45); }
.btn-ghost { background: var(--surface); color: var(--text); border: 1px solid var(--border); }
.btn-ghost:hover { transform: translateY(-3px); border-color: var(--primary); }
.btn-light { background: #fff; color: #0a0a12; }
.btn-light:hover { transform: translateY(-3px); box-shadow: 0 14px 32px rgba(255,255,255,0.25); }
.btn-lg { padding: 1em 2em; font-size: 1rem; }
.btn-sm { padding: 0.6em 1.2em; font-size: 0.85rem; }
.btn-block { width: 100%; }

/* ---------- Navbar ---------- */
.navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  padding: 1.1rem 0;
  transition: background 0.3s ease, padding 0.3s ease, box-shadow 0.3s ease;
}
.navbar.scrolled {
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(16px);
  padding: 0.7rem 0;
  box-shadow: 0 6px 30px rgba(0,0,0,0.25);
  border-bottom: 1px solid var(--border);
}
.navbar-inner { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; }
.brand { display: flex; align-items: center; gap: 0.6rem; font-family: var(--ff-heading); font-weight: 700; font-size: 1.05rem; }
.brand-mark { width: 36px; height: 36px; border-radius: 10px; background: var(--grad); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 0.85rem; }
.brand-name em { font-style: normal; color: var(--primary-2); }
.nav-links { display: flex; gap: 2rem; }
.nav-link { position: relative; font-weight: 500; font-size: 0.92rem; color: var(--text-dim); }
.nav-link::after { content: ''; position: absolute; left: 0; bottom: -6px; width: 0; height: 2px; background: var(--grad); transition: width 0.25s ease; }
.nav-link:hover { color: var(--text); }
.nav-link:hover::after { width: 100%; }
.navbar-actions { display: flex; align-items: center; gap: 1rem; }
.theme-toggle { width: 38px; height: 38px; border-radius: 50%; background: var(--surface); border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; position: relative; }
.theme-toggle i { position: absolute; transition: opacity 0.3s, transform 0.3s; font-size: 0.9rem; }
.theme-toggle .fa-sun { opacity: 0; transform: rotate(90deg); color: #fbbf24; }
.theme-toggle .fa-moon { opacity: 1; transform: rotate(0); color: var(--primary-2); }
[data-theme="light"] .theme-toggle .fa-sun { opacity: 1; transform: rotate(0); }
[data-theme="light"] .theme-toggle .fa-moon { opacity: 0; transform: rotate(-90deg); }
.hamburger { display: none; flex-direction: column; gap: 5px; width: 24px; }
.hamburger span { display: block; height: 2px; width: 100%; background: var(--text); border-radius: 2px; transition: transform 0.3s, opacity 0.3s; }

/* ---------- Hero ---------- */
.hero { position: relative; z-index: 1; padding: 9.5rem 0 3rem; }
.hero-grid { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 3rem; align-items: center; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 0.6rem;
  padding: 0.5em 1em; border-radius: 999px; background: var(--surface); border: 1px solid var(--border);
  font-size: 0.82rem; font-weight: 600; color: var(--text-dim); margin-bottom: 1.4rem;
}
.dot-live { width: 8px; height: 8px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 0 rgba(34,197,94,0.6); animation: livepulse 1.8s infinite; }
@keyframes livepulse { 0% { box-shadow: 0 0 0 0 rgba(34,197,94,0.5); } 70% { box-shadow: 0 0 0 8px rgba(34,197,94,0); } 100% { box-shadow: 0 0 0 0 rgba(34,197,94,0); } }
.hero-title { font-size: clamp(2.2rem, 4.4vw, 3.6rem); letter-spacing: -0.02em; margin-bottom: 0.7em; }
.hero-subtitle { font-size: 1.08rem; max-width: 540px; margin-bottom: 2rem; }
.hero-cta { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.2rem; }
.hero-trust {
  display: flex; flex-wrap: wrap; gap: 1rem 1.3rem; align-items: center;
  color: var(--text-dim); font-size: 0.82rem; font-weight: 600;
}
.hero-trust span {
  display: inline-flex; align-items: center; gap: 0.45rem;
  padding: 0.45rem 0.7rem; border: 1px solid var(--border); border-radius: 999px; background: rgba(255,255,255,0.02);
}
.hero-trust i { color: var(--primary-2); }
.hero-stats { display: grid; grid-template-columns: repeat(4, auto); gap: 2rem; }
.stat { display: flex; flex-direction: column; }
.stat-number, .stat-suffix { font-family: var(--ff-heading); font-size: 1.7rem; font-weight: 800; color: var(--text); }
.stat-suffix { display: inline; }
.stat-label { font-size: 0.8rem; color: var(--text-dimmer); margin-top: 0.2rem; }

/* Hero visual mock browser */
.hero-visual { position: relative; }
.mock-browser {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow);
  transform: perspective(1200px) rotateY(-8deg) rotateX(4deg);
  transition: transform 0.5s ease;
}
.mock-browser:hover { transform: perspective(1200px) rotateY(-2deg) rotateX(1deg); }
.premium-browser { border: 1px solid rgba(139,92,246,0.25); box-shadow: 0 28px 60px rgba(76, 29, 149, 0.32); }
.mock-browser-bar { display: flex; align-items: center; gap: 6px; padding: 0.8rem 1rem; background: var(--surface-2); border-bottom: 1px solid var(--border); }
.mock-browser-bar span { width: 10px; height: 10px; border-radius: 50%; background: var(--text-dimmer); opacity: 0.5; }
.mock-url { margin-left: 1rem; font-size: 0.72rem; color: var(--text-dimmer); background: var(--bg); padding: 0.3em 0.8em; border-radius: 6px; display: flex; align-items: center; gap: 0.4em; }
.mock-browser-body { padding: 1.6rem; }
.mock-nav { height: 12px; width: 40%; background: var(--surface-2); border-radius: 6px; margin-bottom: 1.6rem; }
.premium-nav { width: 100%; height: auto; display: flex; gap: 0.6rem; margin-bottom: 1.4rem; }
.premium-pill {
  padding: 0.42rem 0.7rem; border-radius: 999px; background: rgba(255,255,255,0.08); color: var(--text); font-size: 0.7rem; font-weight: 700;
}
.premium-pill.muted { color: var(--text-dim); }
.mock-hero { display: flex; flex-direction: column; gap: 0.6rem; margin-bottom: 1.6rem; }
.mock-line { height: 14px; border-radius: 6px; background: var(--surface-2); }
.mock-line.lg { width: 85%; height: 22px; background: var(--grad); opacity: 0.85; }
.mock-line.md { width: 70%; }
.mock-line.sm { width: 50%; }
.mock-btn { margin-top: 0.6rem; width: 130px; height: 34px; border-radius: 999px; background: var(--grad); }
.mock-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.8rem; }
.mock-card { height: 70px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--border); }
.mock-card.highlight { background: linear-gradient(135deg, rgba(139,92,246,0.35), rgba(6,182,212,0.25)); border-color: rgba(255,255,255,0.15); }

.floating-card {
  position: absolute; display: flex; align-items: center; gap: 0.7rem;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 0.8rem 1.1rem; box-shadow: var(--shadow); font-size: 0.8rem;
  animation: floaty 4.5s ease-in-out infinite;
}
.floating-card i { font-size: 1.1rem; }
.floating-card strong { display: block; font-family: var(--ff-heading); font-size: 1rem; }
.floating-card span { color: var(--text-dimmer); font-size: 0.72rem; }
.card-conversion { top: -8%; left: -8%; }
.card-conversion i { color: #22c55e; }
.card-load { bottom: 12%; left: -10%; animation-delay: 1s; }
.card-load i { color: #fbbf24; }
.card-rating { top: 40%; right: -10%; animation-delay: 2s; }
.card-rating i { color: #f472b6; }
@keyframes floaty { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-12px); } }

/* Marquee */
.marquee { margin-top: 5rem; overflow: hidden; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); padding: 1.4rem 0; }
.marquee-track { display: flex; gap: 3.5rem; width: max-content; animation: scroll-left 26s linear infinite; }
.marquee-track span { font-family: var(--ff-heading); font-weight: 700; letter-spacing: 0.06em; color: var(--text-dimmer); font-size: 0.95rem; white-space: nowrap; }
@keyframes scroll-left { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ---------- Sections ---------- */
.section { position: relative; z-index: 1; padding: 6.5rem 0; }
.section-alt { background: var(--bg-alt); }
.section-head { max-width: 640px; margin: 0 auto 3.5rem; text-align: center; }
.section-head h2 { font-size: clamp(1.7rem, 3vw, 2.4rem); }
.grid { display: grid; gap: 1.6rem; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }

/* Service cards */
.service-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 2rem; transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}
.service-card:hover { transform: translateY(-8px); box-shadow: var(--shadow); border-color: var(--primary); }
.service-icon { width: 52px; height: 52px; border-radius: 14px; display: flex; align-items: center; justify-content: center; font-size: 1.3rem; color: #fff; margin-bottom: 1.2rem; }
.icon-a { background: linear-gradient(135deg,#8b5cf6,#6366f1); }
.icon-b { background: linear-gradient(135deg,#06b6d4,#3b82f6); }
.icon-c { background: linear-gradient(135deg,#f472b6,#ef4444); }
.icon-d { background: linear-gradient(135deg,#22c55e,#06b6d4); }
.icon-e { background: linear-gradient(135deg,#f59e0b,#f472b6); }
.icon-f { background: linear-gradient(135deg,#6366f1,#8b5cf6); }
.card-link { display: inline-flex; align-items: center; gap: 0.5em; font-weight: 600; font-size: 0.88rem; color: var(--primary-2); margin-top: 0.4rem; }
.card-link i { transition: transform 0.25s ease; font-size: 0.8em; }
.service-card:hover .card-link i { transform: translateX(4px); }

/* Filter bar */
.filter-bar { display: flex; gap: 0.7rem; flex-wrap: wrap; justify-content: center; margin-bottom: 3rem; }
.filter-btn { padding: 0.55em 1.3em; border-radius: 999px; background: var(--surface); border: 1px solid var(--border); font-weight: 600; font-size: 0.86rem; color: var(--text-dim); transition: all 0.25s ease; }
.filter-btn:hover { border-color: var(--primary); color: var(--text); }
.filter-btn.active { background: var(--grad); color: #fff; border-color: transparent; }

/* Portfolio grid */
.portfolio-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.8rem; }
.portfolio-card {
  border-radius: var(--radius); overflow: hidden; background: var(--surface); border: 1px solid var(--border);
  cursor: pointer; transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}
.portfolio-card:hover { transform: translateY(-10px); box-shadow: 0 24px 50px rgba(0,0,0,0.4); border-color: var(--primary); }
.portfolio-card.hide { display: none; }
.portfolio-thumb {
  height: 260px; padding: 1.6rem; display: flex; align-items: center; justify-content: center;
  position: relative; overflow: hidden;
}
.portfolio-thumb::after { content: ''; position: absolute; inset: 0; background: radial-gradient(circle at 30% 20%, rgba(255,255,255,0.22), transparent 60%); pointer-events: none; }
.grad-1 { background: linear-gradient(135deg,#8b5cf6,#ec4899); }
.grad-2 { background: linear-gradient(135deg,#22c55e,#0ea5e9); }
.grad-3 { background: linear-gradient(135deg,#6366f1,#06b6d4); }
.grad-4 { background: linear-gradient(135deg,#f59e0b,#ef4444); }
.grad-5 { background: linear-gradient(135deg,#ec4899,#8b5cf6); }
.grad-6 { background: linear-gradient(135deg,#0ea5e9,#22c55e); }

.preview-badge {
  position: absolute; top: 1rem; right: 1rem; z-index: 2;
  background: rgba(10,10,20,0.55); backdrop-filter: blur(6px); color: #fff;
  font-size: 0.68rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase;
  padding: 0.4em 0.8em; border-radius: 999px; display: flex; align-items: center; gap: 0.4em;
}
.preview-badge::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 0 rgba(34,197,94,0.6); animation: livepulse 1.8s infinite; }

/* Mini browser preview mockups */
.mini-browser {
  width: 100%; height: 100%; background: rgba(10,10,20,0.35); border: 1px solid rgba(255,255,255,0.18);
  border-radius: 12px; overflow: hidden; backdrop-filter: blur(2px);
  transition: transform 0.4s ease; box-shadow: 0 14px 34px rgba(0,0,0,0.25);
}
.mini-browser iframe {
  width: 100%; height: 100%; border: none; display: block; background: #fff;
  transform: scale(1.02);
  transform-origin: top left;
}
.mini-browser .project-screenshot {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center top;
  display: block;
  background: rgba(255,255,255,0.94);
}
.mini-browser iframe.local-preview { display: none; }
.mini-browser .sticky-screenshot { object-position: center top; }
.mini-browser iframe.sticky-preview {
  width: 128%;
  height: 128%;
  transform: scale(0.78);
  transform-origin: top left;
}
.portfolio-card:hover .mini-browser { transform: scale(1.03) translateY(-2px); }
.mini-bar { display: flex; gap: 4px; padding: 0.55rem 0.7rem; background: rgba(255,255,255,0.08); }
.mini-bar span { width: 7px; height: 7px; border-radius: 50%; background: rgba(255,255,255,0.55); }
.mini-body { padding: 0.9rem; display: flex; flex-direction: column; gap: 0.6rem; }
.mini-nav { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 0.2rem; }
.mini-logo { width: 22px; height: 22px; border-radius: 6px; background: rgba(255,255,255,0.85); }

/* Newsroom preview */
.mini-role { font-size: 0.62rem; font-weight: 700; padding: 0.25em 0.6em; border-radius: 999px; color: #fff; }
.role-reader { background: rgba(255,255,255,0.25); }
.role-journalist { background: rgba(255,255,255,0.4); }
.role-editor { background: rgba(255,255,255,0.6); color: #1a1a2e; }
.mini-article { display: flex; align-items: center; gap: 0.6rem; background: rgba(255,255,255,0.14); border-radius: 8px; padding: 0.5rem 0.7rem; }
.mini-article > div { flex: 1; display: flex; flex-direction: column; gap: 0.3rem; }
.mini-avatar { width: 24px; height: 24px; border-radius: 50%; background: rgba(255,255,255,0.7); flex-shrink: 0; }
.mini-line { display: block; height: 8px; border-radius: 4px; background: rgba(255,255,255,0.55); }
.mini-line.lg { width: 100%; }
.mini-line.sm { width: 55%; opacity: 0.7; }
.mini-status { font-size: 0.6rem; font-weight: 700; padding: 0.25em 0.55em; border-radius: 6px; white-space: nowrap; }
.mini-status.approved { background: rgba(34,197,94,0.35); color: #dcfce7; }
.mini-status.pending { background: rgba(251,191,36,0.35); color: #fef3c7; }

/* E-commerce preview */
.mini-cart { margin-left: auto; position: relative; color: #fff; font-size: 0.9rem; }
.mini-cart em { position: absolute; top: -8px; right: -10px; background: #fff; color: #16a34a; font-size: 0.55rem; font-style: normal; font-weight: 800; width: 15px; height: 15px; border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.mini-products { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.5rem; }
.mini-product { height: 44px; border-radius: 8px; background: rgba(255,255,255,0.2); display: flex; align-items: flex-end; justify-content: flex-end; padding: 0.35rem; }
.mini-price { font-size: 0.62rem; font-weight: 800; background: rgba(255,255,255,0.9); color: #15803d; padding: 0.15em 0.4em; border-radius: 5px; }
.mini-checkout-btn { text-align: center; background: rgba(255,255,255,0.92); color: #16a34a; font-size: 0.7rem; font-weight: 700; padding: 0.5em; border-radius: 8px; display: flex; align-items: center; justify-content: center; gap: 0.4em; }

/* Notes preview */
.mini-add { margin-left: auto; font-size: 0.62rem; font-weight: 700; background: rgba(255,255,255,0.9); color: #4338ca; padding: 0.3em 0.6em; border-radius: 999px; }
.mini-notes-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.5rem; }
.mini-note { display: block; height: 46px; border-radius: 8px; transform: rotate(-2deg); box-shadow: 0 6px 14px rgba(0,0,0,0.2); }
.mini-note:nth-child(even) { transform: rotate(2deg); }
.note-yellow { background: #fde68a; }
.note-pink { background: #fbcfe8; }
.note-blue { background: #bfdbfe; }
.note-green { background: #bbf7d0; }
.note-purple { background: #ddd6fe; }

/* Rugby preview */
.mini-navlink { width: 26px; height: 6px; border-radius: 3px; background: rgba(255,255,255,0.5); }
.mini-hero-banner { height: 70px; border-radius: 8px; background: rgba(255,255,255,0.15); display: flex; align-items: center; justify-content: center; font-size: 1.6rem; color: rgba(255,255,255,0.9); }
.mini-fixture { display: flex; align-items: center; justify-content: space-between; background: rgba(255,255,255,0.14); border-radius: 8px; padding: 0.45rem 0.7rem; font-size: 0.68rem; font-weight: 700; color: #fff; }

.portfolio-info { padding: 1.4rem 1.5rem 1.6rem; }
.tag { display: inline-block; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: var(--primary-2); margin-bottom: 0.5rem; }
.portfolio-info h3 { font-size: 1.15rem; margin-bottom: 0.3rem; }
.view-project { display: inline-flex; align-items: center; gap: 0.5em; font-size: 0.85rem; font-weight: 600; color: var(--text); margin-top: 0.4rem; }

/* Shared tech-stack chips */
.tech-stack { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: 0.9rem; }
.tech-chip { font-size: 0.7rem; font-weight: 600; padding: 0.3em 0.7em; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--border); color: var(--text-dim); }

/* Modal extras */
.modal-stack { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-bottom: 1.2rem; }
.modal-subhead { font-size: 0.9rem; margin-bottom: 0.7rem; }
.modal-features { display: flex; flex-direction: column; gap: 0.55rem; margin-bottom: 1.4rem; padding: 0; list-style: none; }
.modal-features li { display: flex; align-items: flex-start; gap: 0.6rem; font-size: 0.86rem; color: var(--text-dim); }
.modal-features li i { color: #22c55e; margin-top: 0.25em; flex-shrink: 0; }
.modal-thumb .mini-browser { height: 100%; }


/* Timeline */
.timeline { position: relative; max-width: 760px; margin: 0 auto; }
.timeline::before { content: ''; position: absolute; left: 27px; top: 0; bottom: 0; width: 2px; background: linear-gradient(var(--border), var(--border)); }
.timeline-item { display: flex; gap: 1.6rem; position: relative; padding-bottom: 2.6rem; }
.timeline-item:last-child { padding-bottom: 0; }
.timeline-index {
  flex-shrink: 0; width: 56px; height: 56px; border-radius: 50%; background: var(--surface); border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center; font-family: var(--ff-heading); font-weight: 800; font-size: 0.95rem;
  color: var(--primary-2); z-index: 1;
}
.timeline-body h3 { font-size: 1.15rem; display: flex; align-items: center; gap: 0.6rem; }
.timeline-body h3 i { color: var(--primary); font-size: 1rem; }

/* Why us */
.why-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center; }
.why-list { display: flex; flex-direction: column; gap: 1rem; margin-top: 1.6rem; }
.why-list li { display: flex; gap: 0.8rem; align-items: flex-start; color: var(--text-dim); }
.why-list li i { color: #22c55e; margin-top: 0.25em; }
.why-visual { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; }
.feature-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.6rem; transition: transform 0.3s ease; }
.feature-card:hover { transform: translateY(-6px); }
.feature-card i { font-size: 1.5rem; margin-bottom: 0.8rem; color: var(--primary-2); }
.feature-card h4 { font-size: 1rem; margin-bottom: 0.3rem; }
.feature-card p { font-size: 0.85rem; margin: 0; }
.fc-2 { margin-top: 1.6rem; }
.fc-4 { margin-top: -1.6rem; }

/* Pricing */
.pricing-toggle { display: flex; align-items: center; justify-content: center; gap: 1rem; margin-bottom: 3rem; }
.toggle-label { font-weight: 600; color: var(--text-dimmer); transition: color 0.25s; }
.toggle-label.active { color: var(--text); }
.switch { width: 52px; height: 28px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--border); position: relative; }
.switch-knob { position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: var(--grad); transition: transform 0.3s ease; }
.switch.on .switch-knob { transform: translateX(24px); }

.pricing-grid { align-items: stretch; }
.price-card { position: relative; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 2.2rem; display: flex; flex-direction: column; transition: transform 0.3s ease, box-shadow 0.3s ease; }
.price-card:hover { transform: translateY(-8px); box-shadow: var(--shadow); }
.price-card.featured { border-color: var(--primary); background: linear-gradient(180deg, rgba(139,92,246,0.08), var(--surface) 40%); }
.price-badge { position: absolute; top: -14px; left: 50%; transform: translateX(-50%); background: var(--grad); color: #fff; font-size: 0.72rem; font-weight: 700; padding: 0.4em 1em; border-radius: 999px; }
.price-desc { font-size: 0.88rem; min-height: 2.6em; }
.price-amount { font-family: var(--ff-heading); font-size: 2.4rem; font-weight: 800; margin-bottom: 1.4rem; }
.price-period { font-size: 1rem; font-weight: 600; color: var(--text-dimmer); }
.hidden { display: none; }
.price-features { display: flex; flex-direction: column; gap: 0.7rem; margin-bottom: 1.8rem; flex-grow: 1; }
.price-features li { display: flex; gap: 0.6rem; font-size: 0.88rem; color: var(--text-dim); align-items: center; }
.price-features li i { color: var(--primary-2); }

/* Testimonials */
.testimonial-slider { position: relative; max-width: 720px; margin: 0 auto; overflow: hidden; }
.testimonial-track { display: flex; transition: transform 0.5s ease; }
.testimonial-card { flex: 0 0 100%; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 2.4rem; text-align: center; }
.stars { color: #fbbf24; margin-bottom: 1rem; font-size: 0.9rem; }
.testimonial-card p { font-size: 1.05rem; color: var(--text); font-style: italic; margin-bottom: 1.6rem; }
.testimonial-author { display: flex; align-items: center; justify-content: center; gap: 0.8rem; }
.avatar { width: 42px; height: 42px; border-radius: 50%; background: var(--grad); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 0.85rem; }
.testimonial-author div:last-child { text-align: left; }
.testimonial-author strong { display: block; font-size: 0.9rem; }
.testimonial-author span { font-size: 0.78rem; color: var(--text-dimmer); }
.testimonial-dots { display: flex; justify-content: center; gap: 0.5rem; margin-top: 1.6rem; }
.testimonial-dots button { width: 8px; height: 8px; border-radius: 50%; background: var(--surface-2); transition: all 0.25s ease; }
.testimonial-dots button.active { background: var(--grad); width: 22px; border-radius: 4px; }

/* FAQ */
.faq-grid { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 3rem; align-items: start; }
.accordion-item { border-bottom: 1px solid var(--border); }
.accordion-head { width: 100%; display: flex; justify-content: space-between; align-items: center; padding: 1.3rem 0; font-weight: 600; font-size: 1rem; text-align: left; }
.accordion-head i { transition: transform 0.3s ease; color: var(--primary-2); }
.accordion-item.active .accordion-head i { transform: rotate(180deg); }
.accordion-body { max-height: 0; overflow: hidden; transition: max-height 0.35s ease, padding 0.35s ease; }
.accordion-item.active .accordion-body { max-height: 220px; padding-bottom: 1.3rem; }
.accordion-body p { font-size: 0.92rem; margin: 0; }

/* CTA banner */
.cta-banner { position: relative; z-index: 1; background: var(--grad); padding: 5rem 0; text-align: center; }
.cta-inner h2 { color: #fff; font-size: clamp(1.6rem, 3vw, 2.3rem); }
.cta-inner p { color: rgba(255,255,255,0.85); margin-bottom: 2rem; }

/* Contact */
.contact-grid { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 3.5rem; align-items: start; }
.contact-item { display: flex; align-items: center; gap: 0.8rem; margin-bottom: 1rem; font-size: 0.92rem; color: var(--text-dim); }
.contact-item i { width: 34px; height: 34px; border-radius: 10px; background: var(--surface); border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; color: var(--primary-2); }
.social-row { display: flex; gap: 0.8rem; margin-top: 1.6rem; }
.social-row a { width: 40px; height: 40px; border-radius: 50%; background: var(--surface); border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; transition: all 0.25s ease; }
.social-row a:hover { background: var(--grad); color: #fff; transform: translateY(-3px); }

.contact-form { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 2.2rem; }
.form-trap { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; }
.form-group { margin-bottom: 1.2rem; position: relative; }
.form-group label { display: block; font-size: 0.85rem; font-weight: 600; margin-bottom: 0.5rem; }
.form-group input, .form-group select, .form-group textarea {
  width: 100%; padding: 0.85em 1em; border-radius: var(--radius-sm); border: 1px solid var(--border);
  background: var(--bg); color: var(--text); font-family: inherit; font-size: 0.92rem; resize: vertical;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(139,92,246,0.15); }
.error-msg { display: none; color: #f87171; font-size: 0.76rem; margin-top: 0.35rem; }
.form-group.invalid input, .form-group.invalid textarea { border-color: #f87171; }
.form-group.invalid select { border-color: #f87171; }
.form-group.invalid input:focus, .form-group.invalid textarea:focus, .form-group.invalid select:focus { box-shadow: 0 0 0 3px rgba(248,113,113,0.15); }
.form-group.invalid .error-msg { display: block; }
.newsletter-error { display: block; min-height: 1.1em; color: #f87171; font-size: 0.76rem; margin-top: 0.4rem; }
.form-success { display: none; align-items: center; gap: 0.6rem; margin-top: 1rem; padding: 0.9em 1.1em; border-radius: var(--radius-sm); background: rgba(34,197,94,0.12); color: #22c55e; font-size: 0.88rem; font-weight: 600; }
.form-success.show { display: flex; }
.form-success.form-error { background: rgba(248,113,113,0.12); color: #f87171; }

/* Footer */
.footer { position: relative; z-index: 1; background: var(--bg-alt); border-top: 1px solid var(--border); padding: 4.5rem 0 0; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 0.8fr 0.8fr 1.2fr; gap: 2.5rem; padding-bottom: 3rem; }
.footer-brand p { font-size: 0.88rem; margin-top: 1rem; max-width: 260px; }
.footer-col h4 { font-size: 0.9rem; margin-bottom: 1.2rem; }
.footer-col a { display: block; font-size: 0.88rem; color: var(--text-dim); margin-bottom: 0.8rem; transition: color 0.2s; }
.footer-col a:hover { color: var(--primary-2); }
.newsletter-form { display: flex; gap: 0.5rem; margin-top: 1rem; }
.newsletter-form input { flex: 1; padding: 0.7em 1em; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); color: var(--text); font-size: 0.85rem; }
.newsletter-form button { width: 40px; height: 40px; border-radius: 50%; background: var(--grad); color: #fff; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.footer-bottom { border-top: 1px solid var(--border); padding: 1.4rem 0; text-align: center; }
.footer-bottom p { font-size: 0.8rem; margin: 0; color: var(--text-dimmer); }

/* Back to top */
.back-to-top {
  position: fixed; bottom: 2rem; right: 2rem; width: 46px; height: 46px; border-radius: 50%;
  background: var(--grad); color: #fff; display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow); opacity: 0; visibility: hidden; transform: translateY(10px);
  transition: all 0.3s ease; z-index: 900;
}
.back-to-top.show { opacity: 1; visibility: visible; transform: translateY(0); }

/* Modal */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(6,6,12,0.7); backdrop-filter: blur(6px);
  display: flex; align-items: center; justify-content: center; z-index: 3000;
  opacity: 0; visibility: hidden; transition: opacity 0.3s ease, visibility 0.3s ease; padding: 1.5rem;
}
.modal-overlay.open { opacity: 1; visibility: visible; }
.modal-box {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  max-width: 980px; width: 100%; padding: 2rem; position: relative; max-height: 90vh; overflow-y: auto;
  transform: translateY(20px) scale(0.97); transition: transform 0.3s ease;
}
.modal-overlay.open .modal-box { transform: translateY(0) scale(1); }
.modal-close { position: absolute; top: 1.2rem; right: 1.2rem; width: 36px; height: 36px; border-radius: 50%; background: var(--surface-2); display: flex; align-items: center; justify-content: center; }
.modal-thumb { height: 420px; border-radius: var(--radius-sm); display: flex; align-items: center; justify-content: center; font-size: 2.4rem; color: #fff; margin-bottom: 1.4rem; padding: 1.1rem; position: relative; overflow: hidden; background: #080812; }
.modal-thumb iframe { width: 100%; height: 100%; border: none; display: block; background: #fff; }
.modal-thumb img { width: 100%; height: 100%; display: block; object-fit: contain; object-position: center; background: #fff; border-radius: 8px; }
.modal-thumb::after { content: ''; position: absolute; inset: 0; background: radial-gradient(circle at 30% 20%, rgba(255,255,255,0.22), transparent 60%); pointer-events: none; }
.modal-results { background: var(--surface-2); border-radius: var(--radius-sm); padding: 0.9em 1.1em; font-size: 0.85rem; font-weight: 600; color: var(--primary-2); margin-bottom: 1.4rem; }

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.in-view { opacity: 1; transform: translateY(0); }

/* ---------- Interactive polish ---------- */
.hero-content.reveal.in-view { animation: hero-arrive 0.9s cubic-bezier(.2,.8,.2,1) both; }
.hero-visual.reveal.in-view { animation: hero-visual-arrive 1s cubic-bezier(.2,.8,.2,1) 0.12s both; }
@keyframes hero-arrive { from { opacity: 0; transform: translateX(-24px); } to { opacity: 1; transform: translateX(0); } }
@keyframes hero-visual-arrive { from { opacity: 0; transform: translateX(24px) rotate(2deg); } to { opacity: 1; transform: translateX(0) rotate(0); } }

.mock-browser { animation: browser-float 7s ease-in-out infinite; }
.mock-browser:hover { animation-play-state: paused; }
@keyframes browser-float { 0%, 100% { translate: 0 0; } 50% { translate: 0 -8px; } }

.service-card, .portfolio-card, .price-card, .feature-card, .testimonial-card {
  position: relative;
  overflow: hidden;
}
.service-card::before, .portfolio-card::before, .price-card::before, .feature-card::before {
  content: '';
  position: absolute;
  inset: -1px;
  background: linear-gradient(115deg, transparent 25%, rgba(255,255,255,0.14) 46%, transparent 62%);
  transform: translateX(-120%);
  transition: transform 0.8s ease;
  pointer-events: none;
}
.service-card:hover::before, .portfolio-card:hover::before, .price-card:hover::before, .feature-card:hover::before { transform: translateX(120%); }
.service-card:hover .service-icon { transform: translateY(-4px) rotate(-5deg) scale(1.06); box-shadow: 0 10px 24px rgba(139,92,246,0.28); }
.service-icon { transition: transform 0.35s cubic-bezier(.2,.8,.2,1), box-shadow 0.35s ease; }
.price-card.featured { animation: featured-breathe 4s ease-in-out infinite; }
@keyframes featured-breathe { 0%, 100% { box-shadow: 0 0 0 rgba(139,92,246,0); } 50% { box-shadow: 0 18px 50px rgba(139,92,246,0.12); } }
.pricing-toggle .switch { transition: transform 0.25s ease, box-shadow 0.25s ease; }
.pricing-toggle .switch:hover { transform: scale(1.08); box-shadow: 0 0 0 5px rgba(139,92,246,0.1); }
.price-amount { transition: opacity 0.25s ease, transform 0.25s ease; }
.price-card:hover .price-amount { transform: translateX(4px); }
.btn { position: relative; overflow: hidden; }
.btn::after {
  content: '';
  position: absolute;
  inset: 0 auto 0 -80%;
  width: 45%;
  transform: skewX(-18deg);
  background: rgba(255,255,255,0.22);
  transition: left 0.55s ease;
}
.btn:hover::after { left: 135%; }
.section-head h2 { text-wrap: balance; }
.section-head::after {
  content: '';
  display: block;
  width: 46px;
  height: 3px;
  margin: 1.2rem auto 0;
  border-radius: 99px;
  background: var(--grad);
  animation: accent-line 3s ease-in-out infinite;
}
@keyframes accent-line { 0%, 100% { width: 46px; opacity: .65; } 50% { width: 82px; opacity: 1; } }
.marquee:hover .marquee-track { animation-play-state: paused; }
.testimonial-card { box-shadow: inset 0 1px 0 rgba(255,255,255,0.06); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; transition-duration: 0.01ms !important; }
  .reveal { opacity: 1; transform: none; }
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1024px) {
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .portfolio-grid { grid-template-columns: repeat(2, 1fr); }
  .hero-grid, .why-grid, .contact-grid, .faq-grid { grid-template-columns: 1fr; }
  .why-visual { order: -1; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 780px) {
  .nav-links { position: fixed; top: 0; right: 0; height: 100vh; width: 78%; max-width: 320px;
    background: var(--surface); border-left: 1px solid var(--border); flex-direction: column;
    padding: 6.5rem 2rem; gap: 1.6rem; transform: translateX(100%); transition: transform 0.35s ease; z-index: 999; }
  .nav-links.open { transform: translateX(0); }
  .hamburger { display: flex; }
  .hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .hamburger.open span:nth-child(2) { opacity: 0; }
  .hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .hero { padding-top: 7.5rem; }
  .hero-stats { grid-template-columns: repeat(2, 1fr); row-gap: 1.4rem; }
  .grid-3, .portfolio-grid { grid-template-columns: 1fr; }
  .floating-card { display: none; }
  .why-visual { grid-template-columns: 1fr 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
  .container { width: min(94%, 720px); }
  .navbar-inner { gap: 0.75rem; }
  .navbar-actions .btn { display: none; }
  .hero-grid { gap: 2rem; }
  .portfolio-thumb { height: 230px; padding: 1rem; }
  .portfolio-info { padding: 1.2rem; }
  .pricing-grid { gap: 1rem; }
  .price-card { padding: 1.6rem; }
}

@media (max-width: 600px) {
  .container { width: min(92%, 480px); }
  .section { padding: 4.5rem 0; }
  .hero { padding: 7rem 0 2rem; }
  .hero-title { font-size: clamp(2rem, 11vw, 3rem); }
  .hero-subtitle { font-size: 0.98rem; }
  .hero-cta, .hero-trust { gap: 0.7rem; }
  .hero-cta .btn { flex: 1 1 100%; }
  .hero-trust span { font-size: 0.74rem; }
  .mock-browser { transform: none; }
  .mock-browser:hover { transform: none; }
  .mock-browser-body { padding: 1rem; }
  .marquee { margin-top: 3rem; }
  .marquee-track { gap: 2rem; }
  .section-head { margin-bottom: 2.4rem; }
  .section-head h2 { font-size: 1.65rem; }
  .service-card { padding: 1.4rem; }
  .portfolio-thumb { height: 210px; padding: 0.8rem; }
  .preview-badge { top: 0.65rem; right: 0.65rem; }
  .mini-browser iframe.sticky-preview { width: 128%; height: 128%; }
  .pricing-toggle { gap: 0.6rem; margin-bottom: 2.5rem; }
  .toggle-label { font-size: 0.82rem; }
  .price-card { padding: 1.5rem; }
  .price-amount { font-size: 2rem; }
  .testimonial-card { padding: 1.5rem; }
  .testimonial-card p { font-size: 0.95rem; }
  .contact-form { padding: 1.4rem; }
  .form-row { gap: 0; }
  .btn-lg { width: 100%; }
  .modal-overlay { padding: 0.75rem; }
  .modal-box { padding: 1.3rem; max-height: 92vh; }
  .modal-thumb { height: 260px; padding: 0.6rem; }
  .footer { padding-top: 3.5rem; }
}

@media (max-width: 380px) {
  .brand-name { font-size: 0.92rem; }
  .brand-mark { width: 32px; height: 32px; }
  .theme-toggle { width: 34px; height: 34px; }
  .hero-trust { display: grid; grid-template-columns: 1fr; }
  .hero-trust span { width: fit-content; }
  .pricing-toggle { align-items: stretch; flex-direction: column; text-align: center; }
  .pricing-toggle .switch { align-self: center; }
}

@media (orientation: landscape) and (max-height: 560px) {
  .hero { padding-top: 6rem; }
  .hero-grid { grid-template-columns: 1fr 1fr; }
  .hero-visual { max-height: 360px; }
  .mock-browser { max-height: 340px; }
  .mock-browser-body { overflow: hidden; }
}
