/* ============================================================
   AutomateWithClark — design system
   Dark-first theme: black base, green #37ca37 primary,
   blue #188bf6 secondary, green→teal→blue gradient accent,
   Inter typeface, 15px rounded cards, pill buttons.
   ============================================================ */

:root {
  --primary: #37ca37;
  --secondary: #188bf6;
  --cobalt: #155eef;
  --gradient: linear-gradient(45deg, #00dc82, #36e4da 50%, #0047e1);

  /* dark theme (default) */
  --bg: #0a0a0a;
  --bg-alt: #101010;
  --card: #161616;
  --card-hover: #1d1d1d;
  --border: rgba(255, 255, 255, 0.09);
  --text: #ffffff;
  --text-muted: #a3a3a3;
  --nav-bg: rgba(10, 10, 10, 0.85);
  --shadow: 0 10px 40px rgba(0, 0, 0, 0.45);
  --glow-opacity: 0.22;
  /* golden-yellow accent (bright gold on dark) */
  --gold: #ffc433;
  --gold-2: #ff9f1a;
  --gradient-gold: linear-gradient(45deg, #ffc433, #ff9f1a);
  --grid-line: rgba(255, 255, 255, 0.05);
}

[data-theme="light"] {
  --bg: #ffffff;
  --bg-alt: #f5f5f5;
  --card: #ffffff;
  --card-hover: #fafafa;
  --border: #e5e7eb;
  --text: #0a0a0a;
  --text-muted: #607179;
  --nav-bg: rgba(255, 255, 255, 0.88);
  --shadow: 0 10px 40px rgba(15, 40, 80, 0.08);
  --glow-opacity: 0.12;
  /* deeper amber in light mode so gold text stays readable on white */
  --gold: #b45309;
  --gold-2: #f59e0b;
  --gradient-gold: linear-gradient(45deg, #b45309, #f59e0b);
  --grid-line: rgba(10, 10, 10, 0.055);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 84px; }

html {
  background: var(--bg);
  transition: background 0.3s ease;
}

body {
  font-family: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  background: transparent;
  color: var(--text);
  line-height: 1.6;
  transition: color 0.3s ease;
  overflow-x: hidden;
}

/* fixed grid layer behind all content, fading out toward the bottom */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 44px 44px;
  -webkit-mask-image: radial-gradient(ellipse 100% 80% at 50% 0%, #000 35%, transparent 78%);
  mask-image: radial-gradient(ellipse 100% 80% at 50% 0%, #000 35%, transparent 78%);
}

.container { max-width: 1140px; margin: 0 auto; padding: 0 24px; }

h1, h2, h3 { font-weight: 800; line-height: 1.15; letter-spacing: -0.02em; }

.grad-text {
  background: var(--gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}
.grad-gold {
  background: var(--gradient-gold);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

/* ---------- badge ---------- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 16px;
  border-radius: 75px;
  border: 1px solid var(--border);
  background: var(--card);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 18px;
}
.badge-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 10px var(--gold);
  animation: pulse 2s infinite;
}
@keyframes pulse { 50% { opacity: 0.4; } }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 26px;
  border-radius: 75px;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}
.btn-primary {
  background: var(--gradient);
  color: #fff;
  box-shadow: 0 6px 24px rgba(0, 220, 130, 0.3);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 10px 32px rgba(0, 220, 130, 0.45); }
.btn-outline {
  background: transparent;
  color: var(--text);
  border: 2px solid var(--border);
}
.btn-outline:hover { border-color: var(--primary); color: var(--primary); transform: translateY(-2px); }
.btn-sm { padding: 9px 20px; font-size: 0.85rem; }
.btn-lg { padding: 15px 34px; font-size: 1rem; }

/* ---------- navbar ---------- */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: var(--nav-bg);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s ease, background 0.3s ease;
}
.navbar.scrolled { border-bottom-color: var(--border); }
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}
.logo {
  font-size: 1.25rem;
  font-weight: 900;
  color: var(--text);
  text-decoration: none;
  letter-spacing: -0.03em;
}
.nav-links { display: flex; align-items: center; gap: 30px; }
.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 600;
  transition: color 0.2s ease;
}
.nav-links a:hover { color: var(--primary); }
.nav-actions { display: flex; align-items: center; gap: 14px; }
.nav-mobile-actions { display: none; }

/* theme toggle */
.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 75px;
  padding: 8px 12px;
  cursor: pointer;
  font-size: 1rem;
  color: var(--text);
  transition: border-color 0.2s ease, transform 0.2s ease;
}
.theme-toggle:hover { border-color: var(--primary); transform: translateY(-1px); }
.theme-toggle .toggle-label { font-size: 0.85rem; font-weight: 600; font-family: inherit; }
[data-theme="dark"] .icon-sun { display: none; }
[data-theme="dark"] .icon-moon { display: inline; }
[data-theme="light"] .icon-sun { display: inline; }
[data-theme="light"] .icon-moon { display: none; }

/* hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.hamburger span {
  width: 24px; height: 2.5px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.3s ease, opacity 0.3s ease;
}
.hamburger.open span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

/* ---------- hero ---------- */
.hero {
  position: relative;
  padding: 160px 0 90px;
  overflow: hidden;
}
.hero-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  opacity: var(--glow-opacity);
  pointer-events: none;
}
.hero-glow-1 {
  width: 480px; height: 480px;
  background: #00dc82;
  top: -140px; right: -100px;
  animation: glow-float-a 9s ease-in-out infinite;
}
.hero-glow-2 {
  width: 420px; height: 420px;
  background: #0047e1;
  bottom: -180px; left: -120px;
  animation: glow-float-b 12s ease-in-out infinite;
}
.hero-glow-3 {
  width: 300px; height: 300px;
  background: var(--gold);
  top: 38%; left: 32%;
  opacity: calc(var(--glow-opacity) * 0.7);
  animation: glow-float-c 10s ease-in-out infinite;
}
@keyframes glow-float-a {
  50% { transform: translate(-36px, 32px) scale(1.08); }
}
@keyframes glow-float-b {
  50% { transform: translate(40px, -28px) scale(1.06); }
}
@keyframes glow-float-c {
  33% { transform: translate(28px, -36px); }
  66% { transform: translate(-24px, 20px); }
}

/* floating decorative shapes */
.deco {
  position: absolute;
  pointer-events: none;
  z-index: 0;
}
.deco-ring {
  width: 26px; height: 26px;
  border: 3px solid var(--gold);
  border-radius: 50%;
  top: 22%; right: 10%;
  opacity: 0.55;
  animation: deco-float 7s ease-in-out infinite;
}
.deco-dot {
  width: 14px; height: 14px;
  border-radius: 50%;
  background: var(--gradient);
  bottom: 20%; right: 20%;
  opacity: 0.65;
  animation: deco-float 9s ease-in-out infinite reverse;
}
.deco-plus {
  font-size: 1.5rem;
  font-weight: 900;
  color: var(--gold);
  top: 30%; left: 6%;
  opacity: 0.5;
  animation: deco-spin 14s linear infinite;
}
@keyframes deco-float {
  50% { transform: translateY(-22px); }
}
@keyframes deco-spin {
  50% { transform: translateY(-16px) rotate(180deg); }
  100% { transform: translateY(0) rotate(360deg); }
}
@media (prefers-reduced-motion: reduce) {
  .hero-glow, .deco { animation: none; }
}
.hero-inner {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 60px;
  align-items: center;
  position: relative;
}
.hero h1 { font-size: clamp(2.4rem, 5.5vw, 3.9rem); margin-bottom: 10px; }
.hero-role {
  font-size: clamp(1.1rem, 2.5vw, 1.5rem);
  font-weight: 700;
  color: var(--gold);
  margin-bottom: 20px;
}
.hero-desc {
  font-size: 1.08rem;
  color: var(--text-muted);
  max-width: 540px;
  margin-bottom: 32px;
}
.hero-cta { display: flex; gap: 16px; flex-wrap: wrap; }

.hero-visual { display: flex; justify-content: center; }
.hero-img-frame {
  width: min(340px, 80vw);
  aspect-ratio: 1;
  border-radius: 24px;
  padding: 4px;
  background: var(--gradient);
  box-shadow: var(--shadow);
}
.hero-img-frame img,
.hero-placeholder {
  width: 100%; height: 100%;
  border-radius: 21px;
  object-fit: cover;
  display: block;
}
.hero-placeholder {
  background: var(--card);
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero-initials { font-size: 6rem; font-weight: 900; }

/* ---------- tools strip ---------- */
.tools-strip {
  padding: 34px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: var(--bg-alt);
}
.tools-label {
  text-align: center;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-muted);
  margin-bottom: 18px;
}
/* marquee: track holds two copies of the list; shifting -50%
   moves exactly one full copy, so the loop is seamless */
.marquee {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
}
.marquee-track {
  display: flex;
  width: max-content;
  animation: marquee-scroll 40s linear infinite;
}
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes marquee-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  .marquee-track { animation: none; flex-wrap: wrap; justify-content: center; }
}
.marquee-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 26px;
  margin-right: 22px;
  border-radius: 75px;
  border: 1px solid var(--border);
  background: var(--card);
  font-weight: 700;
  font-size: 0.95rem;
  white-space: nowrap;
  flex-shrink: 0;
}
.marquee-item img {
  height: 28px;
  width: 28px;
  object-fit: contain;
}

/* ---------- sections ---------- */
.section { padding: 96px 0; }
.section-alt { background: var(--bg-alt); }
.section-head { text-align: center; max-width: 640px; margin: 0 auto 56px; }
.section-head h2 { font-size: clamp(1.9rem, 4vw, 2.7rem); margin-bottom: 14px; }
.section-head p { color: var(--text-muted); font-size: 1.05rem; }

/* ---------- cards ---------- */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 26px;
}
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 15px;
  padding: 30px;
  transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease, box-shadow 0.25s ease;
}
.card:hover {
  transform: translateY(-5px);
  border-color: rgba(55, 202, 55, 0.45);
  background: var(--card-hover);
  box-shadow: var(--shadow);
}
.service-card h3 { font-size: 1.25rem; margin-bottom: 12px; }
.service-card p { color: var(--text-muted); font-size: 0.95rem; margin-bottom: 18px; }
.service-icon {
  width: 54px; height: 54px;
  border-radius: 14px;
  background: linear-gradient(45deg, rgba(0, 220, 130, 0.15), rgba(0, 71, 225, 0.15));
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 20px;
}
.tag-row { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.tag {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: 75px;
  background: rgba(24, 139, 246, 0.12);
  color: var(--secondary);
  border: 1px solid rgba(24, 139, 246, 0.25);
}
.card-link {
  color: var(--primary);
  font-weight: 700;
  font-size: 0.9rem;
  text-decoration: none;
}
.card-link:hover { text-decoration: underline; }

/* ---------- portfolio ---------- */
.filter-row {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 44px;
}
.filter-btn {
  padding: 10px 24px;
  border-radius: 75px;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.88rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}
.filter-btn:hover { border-color: var(--primary); color: var(--text); }
.filter-btn.active {
  background: var(--gradient);
  color: #fff;
  border-color: transparent;
}
.portfolio-card { padding: 0; overflow: hidden; display: flex; flex-direction: column; }
.portfolio-card.hidden { display: none; }
.portfolio-thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: linear-gradient(45deg, rgba(0, 220, 130, 0.1), rgba(0, 71, 225, 0.14));
}
.portfolio-thumb.has-media { cursor: zoom-in; }
.thumb-slides { position: absolute; inset: 0; }
.thumb-slide { position: absolute; inset: 0; display: none; }
.thumb-slide.active { display: block; }
.thumb-slide img,
.thumb-slide video {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}
.portfolio-card:hover .thumb-slide.active img { transform: scale(1.05); }
.play-badge {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 52px; height: 52px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  padding-left: 4px;
  pointer-events: none;
  backdrop-filter: blur(4px);
}
.zoom-hint {
  position: absolute;
  top: 12px; right: 12px;
  width: 34px; height: 34px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  opacity: 0;
  transition: opacity 0.25s ease;
  pointer-events: none;
}
.portfolio-thumb.has-media:hover .zoom-hint,
.portfolio-thumb.has-media:focus .zoom-hint { opacity: 1; }
.thumb-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 34px; height: 34px;
  border-radius: 50%;
  border: none;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
}
.thumb-nav:hover { background: rgba(0, 0, 0, 0.8); }
.thumb-nav.prev { left: 10px; }
.thumb-nav.next { right: 10px; }
.thumb-dots {
  position: absolute;
  bottom: 10px; left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  z-index: 2;
}
.thumb-dots .dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.45);
  transition: background 0.2s ease;
}
.thumb-dots .dot.active { background: #fff; }
.thumb-placeholder {
  width: 100%; height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.6rem;
  opacity: 0.55;
}
a.thumb-link {
  text-decoration: none;
  cursor: pointer;
  opacity: 0.85;
  transition: opacity 0.2s ease;
}
a.thumb-link:hover { opacity: 1; }
.cat-chip {
  position: absolute;
  top: 12px; left: 12px;
  padding: 5px 14px;
  border-radius: 75px;
  background: rgba(0, 0, 0, 0.65);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  backdrop-filter: blur(6px);
}
.portfolio-body { padding: 22px 24px 26px; display: flex; flex-direction: column; flex: 1; }
.portfolio-body h3 { font-size: 1.05rem; margin-bottom: 8px; }
.portfolio-body p { color: var(--text-muted); font-size: 0.88rem; flex: 1; }
.portfolio-links { display: flex; gap: 16px; margin-top: 14px; flex-wrap: wrap; }

/* ---------- about ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: start;
}
.about-text h2 { font-size: clamp(1.9rem, 4vw, 2.5rem); margin-bottom: 16px; }
.about-role { font-weight: 700; color: var(--gold); margin-bottom: 16px; }
.about-bio { color: var(--text-muted); margin-bottom: 28px; }
.about-skills h3 { font-size: 1.2rem; margin-bottom: 20px; }
.skills-list { display: flex; flex-direction: column; gap: 10px; }
.skill-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 11px 16px;
  border-radius: 12px;
  background: var(--card);
  border: 1px solid var(--border);
  font-size: 0.9rem;
  font-weight: 500;
  transition: border-color 0.2s ease, transform 0.2s ease;
}
.skill-item:hover { border-color: rgba(55, 202, 55, 0.4); transform: translateX(4px); }
.check {
  color: var(--primary);
  font-weight: 900;
  flex-shrink: 0;
}

/* ---------- contact ---------- */
.contact-box {
  text-align: center;
  max-width: 720px;
  margin: 0 auto;
  padding: 60px 40px;
  border-radius: 24px;
  background: var(--card);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}
.contact-box::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: var(--gradient);
}
.contact-box h2 { font-size: clamp(1.7rem, 3.5vw, 2.4rem); margin-bottom: 16px; }
.contact-box p { color: var(--text-muted); max-width: 540px; margin: 0 auto 32px; }
.contact-actions { display: flex; justify-content: center; gap: 16px; flex-wrap: wrap; }

/* ---------- testimonials ---------- */
.testimonials-grid { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
.testimonial-card { display: flex; flex-direction: column; }
.stars { margin-bottom: 14px; letter-spacing: 2px; }
.star { color: var(--border); font-size: 1rem; }
.star.filled { color: var(--gold); }
.testimonial-text {
  color: var(--text-muted);
  font-size: 0.93rem;
  font-style: italic;
  flex: 1;
  margin-bottom: 22px;
}
.testimonial-author { display: flex; align-items: center; gap: 14px; }
.avatar {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}
.avatar-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--gradient);
  color: #fff;
  font-weight: 800;
  font-size: 0.9rem;
}
.testimonial-author strong { display: block; font-size: 0.95rem; }
.author-role { color: var(--text-muted); font-size: 0.8rem; }

/* ---------- footer ---------- */
.footer {
  border-top: 1px solid var(--border);
  padding: 28px 0;
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.footer p { color: var(--text-muted); font-size: 0.85rem; }
.footer-admin {
  color: var(--text-muted);
  font-size: 0.8rem;
  text-decoration: none;
  opacity: 0.6;
}
.footer-admin:hover { color: var(--primary); opacity: 1; }

/* ---------- lightbox ---------- */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 300;
  background: rgba(0, 0, 0, 0.93);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 56px 72px 64px;
}
.lightbox.open { display: flex; }
.lb-stage {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  touch-action: pan-y;
}
.lb-slide {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.38s cubic-bezier(0.25, 0.8, 0.3, 1);
  will-change: transform;
}
.lb-stage img,
.lb-stage video {
  max-width: min(1100px, 88vw);
  max-height: 80vh;
  border-radius: 12px;
  box-shadow: 0 20px 80px rgba(0, 0, 0, 0.6);
}
.lb-close {
  position: absolute;
  top: 18px; right: 22px;
  width: 42px; height: 42px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font-size: 1.1rem;
  cursor: pointer;
  z-index: 2;
  transition: background 0.2s ease;
}
.lb-close:hover { background: rgba(255, 255, 255, 0.2); }
.lb-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 48px; height: 48px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font-size: 1.7rem;
  line-height: 1;
  cursor: pointer;
  z-index: 2;
  transition: background 0.2s ease;
}
.lb-nav:hover { background: rgba(255, 255, 255, 0.2); }
.lb-prev { left: 18px; }
.lb-next { right: 18px; }
.lb-footer {
  position: absolute;
  bottom: 18px; left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 16px;
  color: #fff;
  font-size: 0.9rem;
  font-weight: 600;
  background: rgba(0, 0, 0, 0.5);
  padding: 8px 18px;
  border-radius: 75px;
  max-width: 90vw;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.lb-counter { color: rgba(255, 255, 255, 0.6); }
@media (max-width: 700px) {
  .lightbox { padding: 56px 12px 64px; }
  .lb-nav { width: 40px; height: 40px; }
  .lb-prev { left: 8px; }
  .lb-next { right: 8px; }
  .lb-stage img, .lb-stage video { max-width: 94vw; }
}

/* ---------- case study page ---------- */
.cs-hero { padding: 140px 0 70px; }
.cs-hero-head { max-width: 820px; }
.cs-title {
  font-size: clamp(1.9rem, 4.5vw, 3rem);
  margin-bottom: 18px;
}
.cs-summary {
  color: var(--text-muted);
  font-size: 1.08rem;
  max-width: 680px;
  margin-bottom: 40px;
}
.cs-client-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin-bottom: 28px;
}
.cs-client-cell {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 15px;
  padding: 18px 22px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.cs-client-label {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
}
.cs-metrics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}
.cs-metric {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 15px;
  padding: 26px 24px;
  position: relative;
  overflow: hidden;
}
.cs-metric::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--gradient-gold);
}
.cs-metric-value {
  display: block;
  font-size: 2.1rem;
  font-weight: 900;
  letter-spacing: -0.02em;
  margin-bottom: 6px;
}
.cs-metric-label { color: var(--text-muted); font-size: 0.88rem; }

.cs-section-head {
  display: flex;
  align-items: flex-start;
  gap: 22px;
  margin-bottom: 26px;
}
.cs-num {
  font-size: 2.6rem;
  font-weight: 900;
  line-height: 1;
  background: var(--gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  flex-shrink: 0;
}
.cs-label {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--gold);
  margin-bottom: 8px;
}
.cs-section-head h2 { font-size: clamp(1.5rem, 3.2vw, 2.1rem); }
.cs-text {
  color: var(--text-muted);
  max-width: 760px;
  margin-bottom: 36px;
  font-size: 1.02rem;
}
.cs-cards { margin-top: 8px; }
.cs-card h3 { font-size: 1.08rem; margin-bottom: 10px; }
.cs-card p { color: var(--text-muted); font-size: 0.92rem; }
.cs-card-tag {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 12px;
}
.cs-list { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.cs-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.92rem;
  color: var(--text-muted);
}
.cs-quote {
  margin-top: 36px;
  padding: 26px 30px;
  border-left: 4px solid var(--gold);
  background: var(--card);
  border-radius: 0 15px 15px 0;
  font-style: italic;
  color: var(--text-muted);
  max-width: 760px;
}
.cs-table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: 15px; }
.cs-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--card);
  font-size: 0.92rem;
}
.cs-table th, .cs-table td {
  padding: 15px 20px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}
.cs-table th {
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  background: var(--bg-alt);
}
.cs-table tr:last-child td { border-bottom: none; }
.cs-table td:first-child { font-weight: 700; }
.cs-before { color: #e93d3d; }
.cs-after { color: var(--primary); font-weight: 700; }

@media (max-width: 700px) {
  .cs-section-head { gap: 14px; }
  .cs-num { font-size: 1.9rem; }
}

/* ---------- reveal animation ---------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.visible { opacity: 1; transform: none; }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr; text-align: center; gap: 44px; }
  .hero-desc { margin-left: auto; margin-right: auto; }
  .hero-cta { justify-content: center; }
  .hero-text { order: 2; }
  .hero-visual { order: 1; }
  .hero-img-frame { width: min(260px, 70vw); }
  .about-grid { grid-template-columns: 1fr; gap: 44px; }
}

@media (max-width: 820px) {
  .nav-cta { display: none; }
  .nav-actions .theme-toggle { display: none; }
  .hamburger { display: flex; }
  .nav-links {
    position: fixed;
    top: 72px;
    left: 0; right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    padding: 12px 24px 24px;
    transform: translateY(-130%);
    transition: transform 0.3s ease;
    z-index: 99;
  }
  .nav-links.open { transform: translateY(0); }
  .nav-links a {
    padding: 14px 4px;
    border-bottom: 1px solid var(--border);
    font-size: 1rem;
  }
  .nav-mobile-actions {
    display: flex;
    align-items: center;
    gap: 14px;
    padding-top: 18px;
  }
  .hero { padding: 130px 0 70px; }
  .section { padding: 70px 0; }
  .contact-box { padding: 44px 24px; }
}
