@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=IBM+Plex+Mono:wght@400;500&display=swap');

/* ====================================================
   DESIGN TOKENS — matched to the main site (site.css):
   warm near-black bg, cream ink, orange accent — was
   previously matched to haoqi.design's navy/lime-green
   palette instead, which is why these pages read as a
   different site from the homepage.
   ==================================================== */
:root {
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'IBM Plex Mono', monospace;

  --label: 237, 232, 223;             /* matches site.css --ink */
  --label-d: 237, 232, 223;
  --background-deep: 12, 10, 9;       /* #0c0a09 — matches site.css --bg */
  --background-elevated: rgba(255,255,255,0.06);

  --l1: rgba(var(--label), 1);
  --l2: rgba(var(--label-d), 0.62);
  --l3: rgba(var(--label-d), 0.34);
  --l4: rgba(var(--label-d), 0.14);
  --line: rgba(var(--label-d), 0.12);

  --bg: rgb(var(--background-deep));
  --selection: #ff5a26; /* matches site.css --hot */
  --scene-accent: #ff5a26;

  --gutter: 56px;
  --transition: all 0.25s cubic-bezier(0.25, 1, 0.5, 1);

  /* Case study variables */
  --color-accent: var(--selection);
  --text-secondary: var(--l2);
  --text-muted: var(--l3);
  --border-grid: var(--line);
}

html.light {
  --label: 12, 10, 9;
  --label-d: 40, 36, 32;
  --background-deep: 245, 241, 234;   /* warm paper, not icy blue */
  --background-elevated: rgba(255,255,255,0.5);
  --l2: rgba(var(--label-d), 0.65);
  --l3: rgba(var(--label-d), 0.35);
  --l4: rgba(var(--label-d), 0.16);
  --line: rgba(var(--label-d), 0.14);

  /* Case study variables */
  --color-accent: var(--selection);
  --text-secondary: var(--l2);
  --text-muted: var(--l3);
  --border-grid: var(--line);
}

@media (max-width: 900px) {
  :root { --gutter: 20px; }
}

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

html {
  scroll-behavior: smooth;
  background: var(--bg);
  color: var(--l1);
  font-family: var(--font-sans);
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  max-width: 100%;
}

body {
  overflow-x: hidden;
  max-width: 100%;
  background: var(--bg);
  min-height: 100vh;
  transition: background-color 0.3s ease, color 0.3s ease;
}

/* overflow safety net: any stray fixed-width image/media or long
   unbroken string (URLs, long headings) can force horizontal scroll
   on narrow viewports otherwise */
img, video, canvas, svg { max-width: 100%; }
h1, h2, h3, p { overflow-wrap: break-word; word-break: break-word; }

::-webkit-scrollbar { width: 0; }
::selection { background: var(--selection); color: #000; }

a { color: inherit; text-decoration: none; }

.font-mono { font-family: var(--font-mono) !important; }

/* ====================================================
   LOADING BAR
   ==================================================== */
.loading-screen {
  position: fixed;
  inset: 0;
  background: var(--bg);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.5s ease, visibility 0.5s;
}

.loading-screen.hidden { opacity: 0; visibility: hidden; pointer-events: none; }

.loading-bar-container {
  width: 140px;
  height: 4px;
  background: var(--l4);
  border-radius: 99px;
  overflow: hidden;
}

.loading-bar {
  width: 0%;
  height: 100%;
  background: var(--l1);
  transition: width 0.35s ease;
  border-radius: 99px;
}

/* ====================================================
   DOTTED HOVER
   ==================================================== */
.dotted-hover {
  position: relative;
  display: inline-block;
  padding: 6px 10px;
  transition: var(--transition);
}

.dotted-hover::before {
  content: '';
  position: absolute;
  inset: 0;
  border: 1px dotted transparent;
  transition: border-color 0.2s ease;
}

.dotted-hover:hover::before { border-color: var(--l1); }

/* ====================================================
   BACKGROUND: blurred diagonal light streaks + sparse
   crosshair ticks — retargeted from haoqi.design's blue/
   purple palette to the site's own warm orange/amber tones
   so this matches the homepage's atmosphere instead of a
   different studio's.
   ==================================================== */
.bg-streaks {
  position: fixed;
  inset: -20%;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 60% 50% at 45% 55%, rgba(255, 90, 38, 0.35) 0%, transparent 70%),
    repeating-linear-gradient(
      115deg,
      rgba(255, 154, 96, 0.14) 0px,
      rgba(255, 154, 96, 0.14) 40px,
      transparent 40px,
      transparent 130px,
      rgba(120, 90, 60, 0.14) 130px,
      rgba(120, 90, 60, 0.14) 170px,
      transparent 170px,
      transparent 260px
    );
  filter: blur(28px);
  opacity: 0.9;
}

html.light .bg-streaks {
  background: repeating-linear-gradient(
    115deg,
    rgba(255, 255, 255, 0.55) 0px,
    rgba(255, 255, 255, 0.55) 40px,
    transparent 40px,
    transparent 130px,
    rgba(255, 190, 140, 0.28) 130px,
    rgba(255, 190, 140, 0.28) 170px,
    transparent 170px,
    transparent 260px
  );
}

.bg-grid {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    linear-gradient(var(--l3) 1px, transparent 1px),
    linear-gradient(90deg, var(--l3) 1px, transparent 1px);
  background-size: 8px 8px;
  background-position: -3.5px -3.5px;
  /* renders as sparse "+" ticks: only visible at large-grid
     intersections via mask, tiny crosses elsewhere are hidden */
  -webkit-mask-image: radial-gradient(circle 4px at center, black 99%, transparent 100%);
  mask-image: radial-gradient(circle 4px at center, black 99%, transparent 100%);
  -webkit-mask-repeat: repeat;
  mask-repeat: repeat;
  -webkit-mask-size: 480px 320px;
  mask-size: 480px 320px;
  opacity: 0.5;
}

/* ====================================================
   NAV
   ==================================================== */
.navbar {
  position: fixed;
  top: 0; left: 0;
  width: 100%;
  z-index: 50;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px var(--gutter);
}

.logo-link { font-family: var(--font-mono); font-size: 14px; font-weight: 500; }
.logo-link span { color: var(--l3); }

.nav-controls { display: flex; align-items: center; gap: 4px; }

.nav-btn {
  font-family: var(--font-mono);
  font-size: 13px;
  text-transform: uppercase;
  background: transparent;
  border: none;
  color: var(--l1);
  cursor: pointer;
}

@media (max-width: 700px) {
  .nav-btn:not(.always-show) { display: none; }
}

/* ====================================================
   HERO
   ==================================================== */
.hero {
  position: relative;
  z-index: 2;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 110px var(--gutter) 60px;
  border-bottom: 1px solid var(--line);
}

.hero-info {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 24px;
  font-family: var(--font-mono);
  font-size: 14px;
  line-height: 1.6;
}

.hero-role {
  grid-column: span 3;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 28px;
  line-height: 1.15;
  color: var(--l1);
}

.hero-tagline { grid-column: 5 / span 3; color: var(--l2); }

.hero-bio { grid-column: 8 / span 5; color: var(--l2); }

@media (max-width: 900px) {
  .hero-info { grid-template-columns: 1fr; gap: 16px; }
  .hero-role, .hero-tagline, .hero-bio { grid-column: 1; }
}

.hero-statement {
  font-weight: 700;
  font-size: 6.4vw;
  line-height: 1.02;
  letter-spacing: -0.01em;
  color: var(--l1);
  margin-top: 60px;
}

@media (max-width: 900px) {
  .hero-statement { font-size: 9vw; }
}

/* passcode block, inline within the bio sentence */
.protected-trigger {
  display: inline-flex;
  align-items: baseline;
  gap: 3px;
  cursor: pointer;
  margin: 0 2px;
}

.protected-square {
  display: inline-block;
  width: 9px;
  height: 9px;
  background: var(--l1);
  transition: background-color 0.2s;
}

.protected-trigger:hover .protected-square { background: var(--selection); }

.passcode-input-wrapper {
  display: none;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
}

.passcode-input-wrapper.visible { display: flex; }

.passcode-field {
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--selection);
  color: var(--l1);
  font-family: var(--font-mono);
  font-size: 14px;
  width: 90px;
  outline: none;
  text-align: center;
  letter-spacing: 0.1em;
}

.passcode-error-msg {
  color: #EF4444;
  font-family: var(--font-mono);
  font-size: 12px;
  display: none;
}

.secret-revealed-text {
  display: none;
  margin-top: 10px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--selection);
  border-left: 1px solid var(--selection);
  padding-left: 10px;
}

/* ====================================================
   SIGNATURE
   ==================================================== */
.signature-section {
  position: relative;
  z-index: 2;
  padding: 80px var(--gutter);
  border-bottom: 1px solid var(--line);
}

.signature-box { width: 100%; max-width: 260px; height: 120px; }
.svg-sign { width: 100%; height: 100%; }

.svg-sign__path {
  fill: none;
  stroke: var(--l1);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-dasharray: 1000;
  stroke-dashoffset: 1000;
}

.svg-sign.is-drawing .svg-sign__path {
  animation: draw-sig 2s ease forwards;
}

.svg-sign.is-drawing .svg-sign__path:nth-child(2) { animation-delay: 1.6s; }

@keyframes draw-sig { to { stroke-dashoffset: 0; } }

/* ====================================================
   WORK GRID
   ==================================================== */
.work-section {
  position: relative;
  z-index: 2;
  padding: 80px var(--gutter);
  border-bottom: 1px solid var(--line);
}

.work-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 24px;
}

.work-item { grid-column: span 12; padding-bottom: 8px; }

.work-item.col-left { grid-column: 1 / span 6; }
.work-item.col-right { grid-column: 7 / span 6; }
.work-item.col-mid { grid-column: 3 / span 8; }
.work-item.col-full { grid-column: span 12; }

@media (max-width: 800px) {
  .work-item.col-left, .work-item.col-right,
  .work-item.col-mid, .work-item.col-full { grid-column: span 12; }
}

.work-link { display: block; }

.work-thumb-box {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  background: var(--background-elevated);
  border: 1px solid var(--line);
  overflow: hidden;
  transition: var(--transition);
}

.work-item:hover .work-thumb-box { border-color: var(--selection); }

.work-thumb-label {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0 16px;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--l3);
}

.work-thumb-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.35s ease;
}

.work-item:hover .work-thumb-img { opacity: 1; }

.work-chip {
  position: absolute;
  top: 0; right: 0;
  z-index: 2;
  background: var(--selection);
  color: #000;
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
  padding: 2px 6px;
}

.work-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
  font-family: var(--font-mono);
  font-size: 12px;
  text-transform: uppercase;
  color: var(--l2);
}

.work-name {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 18px;
  text-transform: none;
  color: var(--l1);
  transition: var(--transition);
}

.work-item:hover .work-name { color: var(--selection); }

/* ====================================================
   FOOTER
   ==================================================== */
.footer-section {
  position: relative;
  z-index: 2;
  padding: 80px var(--gutter) 60px;
  min-height: 70vh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.footer-statement {
  font-weight: 700;
  font-size: 5vw;
  text-transform: uppercase;
  line-height: 0.95;
  letter-spacing: -0.01em;
  text-align: center;
}

@media (max-width: 900px) { .footer-statement { font-size: 9vw; } }

.footer-links {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  border-top: 1px solid var(--line);
  padding-top: 32px;
  margin-top: 40px;
  font-family: var(--font-mono);
  font-size: 13px;
}

.footer-links .socials { display: flex; gap: 12px; }

/* ====================================================
   FOOTER BAR (clock + coords)
   ==================================================== */
.footer-bar {
  position: fixed;
  bottom: 0; left: 0;
  width: 100%;
  z-index: 50;
  display: flex;
  justify-content: space-between;
  padding: 20px var(--gutter);
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--l2);
  text-transform: uppercase;
  pointer-events: none;
}

@media (max-width: 700px) { .footer-bar { display: none; } }

/* ====================================================
   CASE STUDY DETAIL LAYOUT
   ==================================================== */
.case-hero {
  padding: 160px var(--gutter) 80px;
  border-bottom: 1px dashed var(--line);
  position: relative;
  z-index: 2;
  background: linear-gradient(180deg, rgba(255, 90, 38, 0.015) 0%, transparent 100%);
  overflow: hidden;
}

.case-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 24px 24px;
  opacity: 0.8;
  pointer-events: none;
}

.case-hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: var(--gutter);
  width: 80px;
  height: 1px;
  background: var(--color-accent);
}

.case-hero-container {
  max-width: 1200px;
  margin: 0 auto;
}

.case-hero-container h1 {
  font-family: var(--font-sans);
  font-size: clamp(32px, 4vw, 56px);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
  color: var(--text-main);
  margin-top: 12px;
}

.case-hero-container p {
  font-size: clamp(15px, 1.2vw, 18px);
  line-height: 1.6;
  color: var(--text-secondary);
  max-width: 720px;
  margin-top: 14px;
}

.case-body {
  padding: 80px var(--gutter);
  position: relative;
  z-index: 2;
}

.case-grid {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 80px;
  max-width: 1200px;
  margin: 0 auto;
  align-items: start;
}

@media (max-width: 950px) {
  .case-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
}

.case-sidebar {
  position: sticky;
  top: 100px;
}

@media (max-width: 950px) {
  .case-sidebar {
    position: static;
  }
}

.case-sidebar-content {
  background: rgba(255, 255, 255, 0.015) !important;
  border: 1px solid var(--line) !important;
  border-radius: 16px !important;
  padding: 32px !important;
  position: relative;
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
}


/* Sidebar Meta Box Layout */
.case-meta-box {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.meta-item h4 {
  font-family: var(--font-mono) !important;
  font-size: 10px !important;
  color: var(--text-muted) !important;
  text-transform: uppercase !important;
  letter-spacing: 0.12em !important;
  margin-bottom: 6px !important;
}

.meta-item p {
  font-family: var(--font-sans) !important;
  font-size: 16px !important;
  font-weight: 500 !important;
  color: var(--text-main) !important;
  margin: 0 !important;
}

/* Sidebar Tech Pills */
.case-sidebar-content .tag {
  background: rgba(255, 90, 38, 0.06) !important;
  border: 1px solid rgba(255, 90, 38, 0.2) !important;
  color: var(--color-accent) !important;
  padding: 6px 12px !important;
  border-radius: 6px !important;
  font-size: 11px !important;
  font-family: var(--font-mono) !important;
  transition: all 0.25s ease !important;
}

.case-sidebar-content .tag:hover {
  background: rgba(255, 90, 38, 0.12) !important;
  border-color: var(--color-accent) !important;
}

/* Return Home Button Override */
.case-sidebar-content .btn-secondary {
  background: rgba(255, 255, 255, 0.02) !important;
  border: 1px dashed var(--line) !important;
  color: var(--text-main) !important;
  transition: all 0.3s ease !important;
  border-radius: 8px !important;
  font-family: var(--font-mono) !important;
  font-size: 11px !important;
  text-transform: uppercase !important;
  letter-spacing: 0.08em !important;
  padding: 12px !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
}

.case-sidebar-content .btn-secondary:hover {
  background: rgba(255, 90, 38, 0.05) !important;
  border: 1px solid var(--color-accent) !important;
  color: var(--color-accent) !important;
  box-shadow: 0 0 12px rgba(255, 90, 38, 0.05) !important;
}

.case-content-flow {
  display: flex;
  flex-direction: column;
  gap: 50px;
}

.case-content-flow section {
  display: flex;
  flex-direction: column;
  gap: 20px;
  position: relative;
}

.case-content-flow h3 {
  font-family: var(--font-sans);
  font-size: 28px;
  font-weight: 700;
  color: var(--l1);
  border-bottom: 1px dashed var(--line);
  padding-bottom: 14px;
  margin-bottom: 8px;
}

.case-content-flow h4 {
  font-family: var(--font-sans);
  font-size: 20px;
  font-weight: 600;
  color: var(--color-accent);
  margin-top: 16px;
}

.case-content-flow p {
  font-size: 16px;
  line-height: 1.7;
  color: var(--l2);
}

.case-content-flow ul, .case-content-flow ol {
  padding-left: 24px;
  color: var(--l2);
  line-height: 1.7;
}

.case-content-flow li {
  margin-bottom: 10px;
}

.glass-card {
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.tag {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--line);
  color: var(--l2);
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 11px;
  font-family: var(--font-mono);
  letter-spacing: 0.02em;
}

/* Metric Card Layouts */
.metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin: 32px 0;
}

.metric-card {
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 30px 24px;
  text-align: left;
  position: relative;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.metric-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 2px;
  background: var(--color-accent);
  opacity: 0.8;
}

.metric-card:hover {
  transform: translateY(-2px);
  border-color: var(--color-accent);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.3);
}

.metric-value {
  font-family: var(--font-sans);
  font-size: 42px;
  font-weight: 700;
  color: var(--color-accent);
  letter-spacing: -0.02em;
  text-shadow: 0 0 15px rgba(255, 90, 38, 0.25);
}

.metric-label {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 10px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  line-height: 1.4;
}

/* Image & Media Styling */
.case-media-container {
  margin: 36px 0;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.15);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
  transition: border-color 0.3s ease;
}

.case-media-container:hover {
  border-color: rgba(255, 255, 255, 0.12);
}

.case-img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.case-media-container:hover .case-img {
  transform: scale(1.01);
}

.case-media-caption {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  padding: 14px 20px;
  border-top: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.25);
  display: flex;
  align-items: center;
  gap: 10px;
}

.case-media-caption::before {
  content: 'EXHIBIT';
  font-size: 9px;
  font-weight: 700;
  color: var(--color-accent);
  border: 1px solid rgba(255, 90, 38, 0.3);
  padding: 2px 6px;
  border-radius: 4px;
  letter-spacing: 0.1em;
}

.case-img-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  margin: 32px 0;
}

@media (max-width: 900px) {
  .case-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  .case-sidebar {
    position: static;
  }
}

/* Portfolio Storytelling Extensions */
.next-project-banner {
  margin-top: 80px;
  border-top: 1px dashed var(--border-grid);
  padding-top: 50px;
}

.next-project-link {
  text-decoration: none;
  display: block;
}

.next-project-link .glass-card {
  padding: 40px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 40px;
  align-items: center;
  border: 1px solid var(--border-grid);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.01) 0%, rgba(255, 255, 255, 0.005) 100%);
  border-radius: 12px;
  position: relative;
  overflow: hidden;
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.next-project-link .glass-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: radial-gradient(circle at 100% 50%, rgba(255, 90, 38, 0.08) 0%, transparent 60%);
  opacity: 0;
  transition: opacity 0.5s ease;
  pointer-events: none;
}

.next-project-link:hover .glass-card::before {
  opacity: 1;
}

.next-project-link:hover .glass-card {
  border-color: var(--color-accent) !important;
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.3), inset 0 0 12px rgba(255, 255, 255, 0.02);
}

.next-project-kicker {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
  border-right: 1px solid var(--border-grid);
  padding-right: 40px;
  height: 100%;
  display: flex;
  align-items: center;
}

.next-project-link:hover .next-project-kicker {
  color: var(--color-accent);
}

.next-arrow {
  font-size: 24px;
  color: var(--text-muted);
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.next-project-link:hover .next-arrow {
  transform: translateX(8px);
  color: var(--color-accent);
}

@media (max-width: 768px) {
  .next-project-link .glass-card {
    grid-template-columns: 1fr auto;
    padding: 24px;
    gap: 20px;
  }
  .next-project-kicker {
    display: none; /* Hide vertical column on mobile for layout comfort */
  }
}

/* Interactive Tabs (Lomotif / Popsical) */
.interactive-tabs-widget {
  margin: 40px 0;
  border: 1px solid var(--border-grid);
  border-radius: 16px;
  background: rgba(0, 0, 0, 0.15);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
  overflow: hidden;
}

.tab-nav {
  display: flex;
  background: rgba(255, 255, 255, 0.01);
  border-bottom: 1px solid var(--border-grid);
  padding: 8px 12px;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
}

.tab-nav::-webkit-scrollbar {
  display: none;
}

.tab-btn {
  -webkit-appearance: none !important;
  appearance: none !important;
  background: transparent !important;
  border: 1px solid transparent !important;
  outline: none !important;
  box-shadow: none !important;
  
  padding: 12px 20px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  white-space: nowrap;
}

.tab-btn:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.02) !important;
}

.tab-btn.active {
  color: var(--color-accent) !important;
  background: rgba(255, 90, 38, 0.05) !important;
  border: 1px solid rgba(255, 90, 38, 0.15) !important;
  box-shadow: 0 0 12px rgba(255, 90, 38, 0.05) !important;
}

.tab-pane {
  display: none;
  padding: 30px;
  animation: slideUpFade 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.tab-pane.active {
  display: block;
}

/* Linear Timeline (Grab) */
.linear-timeline {
  margin: 40px 0;
  display: flex;
  flex-direction: column;
  gap: 40px;
}

.timeline-step {
  border: 1px solid var(--border-grid);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.015);
  padding: 40px;
  position: relative;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}


.timeline-step:hover {
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.02);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.25);
  transform: translateY(-2px);
}

.timeline-step-badge {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-accent);
  background: rgba(255, 90, 38, 0.08);
  border: 1px solid rgba(255, 90, 38, 0.2);
  padding: 4px 10px;
  border-radius: 6px;
  margin-bottom: 20px;
  display: inline-block;
}

.timeline-step h4 {
  font-size: 24px;
  margin: 0 0 20px 0;
  color: var(--text-main);
  font-family: var(--font-sans);
  font-weight: 700;
  border-bottom: 1px dashed var(--border-grid);
  padding-bottom: 12px;
}

@media (max-width: 600px) {
  .timeline-step {
    padding: 24px;
  }
}

@keyframes slideUpFade {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes slideRightFade {
  from { opacity: 0; transform: translateX(-12px); }
  to { opacity: 1; transform: translateX(0); }
}

