/* ==========================================================================
   TWLab — Split Personality Stylesheet
   Top: Maximal 1980s Pixel Wave Poster
   Below: Calm, Apple-Style Minimal iTunes Cover Flow Portfolio
   lab.threewaves.co.uk // by Threewaves
   ========================================================================== */

/* -------------------------------------------------------------------------
   1. Theme Variables & Tokens (Blue-Only Atmosphere System)
   ------------------------------------------------------------------------- */
:root {
  --font-sans: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, "SF Mono", Menlo, Monaco, Consolas, "Courier New", monospace;

  /* Universal Brand Blues */
  --blue-primary: #0055ff;
  --blue-electric: #00d4ff;
  --blue-glow: #00f0ff;
  --navy-deep: #0a1936;
  --navy-silhouette: #050d1e;
  --black-pixel: #000000;

  /* Common Light Portfolio Tokens (Calm, Apple-Clean) */
  --bg-page: #f8fafc;
  --bg-surface: #ffffff;
  --bg-surface-subtle: #f1f5f9;
  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #64748b;
  --border-light: #e2e8f0;
  --border-subtle: #cbd5e1;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 12px 28px rgba(0, 0, 0, 0.08);

  /* Container */
  --container-max: 1140px;

  /* Ocean Theme Tokens (Default) */
  --poster-sky-top: #061329;
  --poster-sky-bottom: #0e2a5c;
  --poster-header-bg: rgba(6, 19, 41, 0.88);
  --poster-header-border: rgba(0, 212, 255, 0.25);
  --poster-wave-mid: #0055ff;
  --poster-wave-crest: #00d4ff;
  --poster-accent: #00d4ff;
}

/* Electric Theme Tokens */
html[data-theme="electric"] {
  --poster-sky-top: #020b24;
  --poster-sky-bottom: #003da5;
  --poster-header-bg: rgba(2, 11, 36, 0.90);
  --poster-header-border: rgba(0, 240, 255, 0.35);
  --poster-wave-mid: #0066ff;
  --poster-wave-crest: #00f0ff;
  --poster-accent: #00f0ff;
}

/* Midnight Theme Tokens */
html[data-theme="midnight"] {
  --poster-sky-top: #020612;
  --poster-sky-bottom: #081635;
  --poster-header-bg: rgba(2, 6, 18, 0.92);
  --poster-header-border: rgba(0, 153, 255, 0.25);
  --poster-wave-mid: #003faa;
  --poster-wave-crest: #0099ff;
  --poster-accent: #38bdf8;
}

/* -------------------------------------------------------------------------
   2. Reset & Base Typography
   ------------------------------------------------------------------------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-family: var(--font-sans);
  background-color: var(--bg-page);
  color: var(--text-primary);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
  background-color: var(--bg-page);
}

:focus-visible {
  outline: 2px solid var(--blue-primary);
  outline-offset: 3px;
}

.container {
  width: 100%;
  max-width: var(--container-max);
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
  position: relative;
}

/* -------------------------------------------------------------------------
   3. Site Header (Full Bleed Translucent Blue Header)
   ------------------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  width: 100%;
  background: var(--poster-header-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--poster-header-border);
  transition: background-color 0.25s ease, border-color 0.25s ease;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 70px;
}

.brand-link {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

.brand-logo {
  display: block;
  height: 32px;
  width: auto;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.header-portfolio-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0.4rem 0.9rem;
  border: 1px solid rgba(255, 255, 255, 0.38);
  border-radius: 9999px;
  color: #ffffff;
  font-size: 0.85rem;
  font-weight: 650;
  text-decoration: none;
  white-space: nowrap;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.header-portfolio-link:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: #ffffff;
}

/* Blue-Only Theme Selector */
.theme-selector {
  display: inline-flex;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 9999px;
  padding: 3px;
  gap: 2px;
}

.theme-btn {
  background: transparent;
  border: none;
  border-radius: 9999px;
  padding: 0.35rem 0.85rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #94a3b8;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.theme-btn:hover {
  color: #ffffff;
}

.theme-btn.is-active,
.theme-btn[aria-pressed="true"] {
  background: var(--blue-primary);
  color: #ffffff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}

.btn-header-cta {
  background: #ffffff;
  color: var(--navy-deep);
  border: 1px solid #ffffff;
  border-radius: 9999px;
  padding: 0.45rem 1.15rem;
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.btn-header-cta:hover {
  background: var(--blue-electric);
  border-color: var(--blue-electric);
  color: #000000;
  transform: translateY(-1px);
}

/* -------------------------------------------------------------------------
   4. Top Viewport: Full Bleed 1980s Maximal Pixel Wave Poster
   ------------------------------------------------------------------------- */
.poster-hero-section {
  position: relative;
  min-height: calc(100vh - 70px);
  min-height: 88vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  background: var(--poster-sky-top);
  color: #ffffff;
}

.poster-canvas-stage {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  overflow: hidden;
}

.poster-canvas {
  display: block;
  width: 100%;
  height: 100%;
  image-rendering: pixelated;
  image-rendering: -moz-crisp-edges;
  image-rendering: crisp-edges;
  object-fit: cover;
}

.poster-canvas-overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 75% 35%, transparent 30%, rgba(2, 6, 18, 0.65) 90%),
              linear-gradient(to top, rgba(2, 6, 18, 0.85) 0%, transparent 40%);
  pointer-events: none;
}

.poster-content-container {
  position: relative;
  z-index: 2;
  padding-top: 4rem;
  padding-bottom: 5rem;
}

.poster-body {
  max-width: 820px;
}

/* TWLab is the largest identity element */
.poster-identity {
  display: flex;
  align-items: baseline;
  gap: 1.25rem;
  flex-wrap: wrap;
  margin-bottom: 1.5rem;
}

.poster-name {
  font-size: clamp(4.5rem, 14vw, 9.5rem);
  font-weight: 900;
  line-height: 0.88;
  letter-spacing: -0.04em;
  color: #ffffff;
  text-shadow: 0 4px 0 #000000,
               0 8px 30px rgba(0, 85, 255, 0.45);
  display: inline-block;
  user-select: none;
}

.poster-badge {
  font-family: var(--font-mono);
  font-size: clamp(0.85rem, 1.8vw, 1.15rem);
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--poster-accent);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.7);
}

.poster-headline {
  font-size: clamp(2rem, 4.5vw, 3.25rem);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.025em;
  color: #f8fafc;
  margin-bottom: 1.25rem;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.6);
}

.poster-intro {
  font-size: clamp(1.1rem, 2.2vw, 1.3rem);
  line-height: 1.6;
  color: #cbd5e1;
  max-width: 640px;
  margin-bottom: 2.5rem;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
}

.poster-cta-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.25rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  font-family: var(--font-sans);
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}

.btn-poster-primary {
  background: var(--blue-primary);
  color: #ffffff;
  border: 2px solid var(--black-pixel);
  box-shadow: 4px 4px 0 var(--black-pixel);
  padding: 0.95rem 1.85rem;
  font-size: 1.05rem;
}

.btn-poster-primary:hover {
  background: #0066ff;
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0 var(--black-pixel);
}

.btn-poster-primary:active {
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0 var(--black-pixel);
}

.btn-poster-secondary {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  border: 2px solid rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(8px);
  padding: 0.95rem 1.85rem;
  font-size: 1.05rem;
}

.btn-poster-secondary:hover {
  background: rgba(255, 255, 255, 0.22);
  border-color: #ffffff;
  transform: translateY(-2px);
}

.btn-arrow {
  font-family: var(--font-mono);
  font-weight: 900;
}

/* -------------------------------------------------------------------------
   5. Offer Section (specific services, no feature-card clutter)
   ------------------------------------------------------------------------- */
.offer-bridge-section {
  background: var(--bg-page);
  padding: 3rem 0 2.5rem;
  position: relative;
  z-index: 10;
}

.offer-inner {
  display: grid;
  grid-template-columns: minmax(190px, 0.72fr) minmax(0, 2fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: start;
}

.offer-heading {
  padding-top: 0.25rem;
}

.offer-heading h2 {
  max-width: 13ch;
  font-size: clamp(1.5rem, 2.5vw, 2rem);
  line-height: 1.15;
  letter-spacing: -0.025em;
  color: var(--text-primary);
}

.offer-heading p,
.offer-item p {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--text-secondary);
}

.offer-heading p {
  margin-top: 0.8rem;
  max-width: 30ch;
}

.offer-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--border-subtle);
}

.offer-item {
  padding: 1.15rem 1.2rem 0;
}

.offer-item:not(:first-child) {
  border-left: 1px solid var(--border-light);
}

.offer-item-primary {
  background: color-mix(in srgb, var(--blue-primary) 5%, transparent);
  box-shadow: inset 0 2px 0 var(--blue-primary);
}

.offer-item-primary h3 {
  color: var(--text-primary);
}

.offer-level {
  margin-bottom: 0.7rem;
  color: var(--blue-primary) !important;
  font-size: 0.68rem !important;
  font-weight: 650;
  letter-spacing: 0.08em;
}

.offer-item h3 {
  margin-bottom: 0.55rem;
  font-size: 1rem;
  line-height: 1.3;
  color: var(--text-primary);
}

.offer-item p {
  font-size: 0.88rem;
}

@media (min-width: 641px) and (max-width: 900px) {
  .offer-inner {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }

  .offer-heading h2 {
    max-width: none;
  }
}

/* -------------------------------------------------------------------------
   6. EXPERIENCE Section: Apple-Style Minimal iTunes Cover Flow
   ------------------------------------------------------------------------- */
.experience-section {
  background: var(--bg-page);
  padding-top: 3.5rem;
  padding-bottom: 5.5rem;
  position: relative;
  z-index: 10;
}

.experience-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-bottom: 2.75rem;
}

.clean-eyebrow {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--blue-primary);
  margin-bottom: 0.5rem;
}

.clean-title {
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text-primary);
  line-height: 1.15;
  margin-bottom: 0.65rem;
}

.clean-lead {
  font-size: 1.05rem;
  line-height: 1.6;
  color: var(--text-secondary);
}

/* Apple-style Segmented View Switcher */
.view-switcher {
  display: inline-flex;
  background: var(--bg-surface-subtle);
  border: 1px solid var(--border-light);
  border-radius: 9999px;
  padding: 3px;
  gap: 3px;
  box-shadow: var(--shadow-sm);
}

.view-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: transparent;
  border: none;
  border-radius: 9999px;
  color: var(--text-secondary);
  padding: 0.5rem 1.15rem;
  min-height: 38px;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.15s ease;
}

.view-btn:hover {
  color: var(--text-primary);
}

.view-btn.is-active,
.view-btn[aria-pressed="true"] {
  background: #ffffff;
  color: var(--text-primary);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

[hidden],
.caption-tag[hidden],
.caption-link[hidden] {
  display: none !important;
}

#experience {
  scroll-margin-top: 80px;
}

/* 3D Cover Flow Stage */
.portfolio-container.view-flow #flow-stage {
  position: relative;
  perspective: 1100px;
  -webkit-perspective: 1100px;
  height: 530px;
  margin-bottom: 10px;
  outline: none;
  touch-action: pan-y;
  overflow: hidden;
  user-select: none;
}

.portfolio-container.view-flow #flow-track {
  position: relative;
  width: 100%;
  height: 485px;
  display: block;
  transform-style: preserve-3d;
  -webkit-transform-style: preserve-3d;
}

.portfolio-container.view-flow .project-item {
  position: absolute;
  top: 15px;
  left: 50%;
  width: min(86vw, 680px);
  margin-left: calc(-1 * min(86vw, 680px) / 2);
  transform-origin: 50% 50%;
  transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.25, 1), opacity 0.35s ease;
  cursor: pointer;
  will-change: transform, opacity;
}

.portfolio-container.view-flow .project-item .project-caption {
  display: none;
}

.portfolio-container.view-flow .project-media {
  background-color: transparent;
  border-radius: 8px;
  border: 1px solid rgba(20, 32, 52, 0.14);
  box-shadow: 0 18px 40px rgba(4, 12, 28, 0.2);
  overflow: hidden;
  -webkit-box-reflect: below 5px linear-gradient(to bottom, transparent 68%, rgba(0, 0, 0, 0.28));
}

.portfolio-container.view-flow .project-media img {
  height: auto;
  object-position: var(--preview-position, center 12%);
}

.project-media img {
  width: 100%;
  aspect-ratio: 1.48;
  object-fit: cover;
  object-position: var(--preview-position, center 12%);
  background: #e8edf4;
  pointer-events: none;
  display: block;
}

/* Cover Flow Navigation Controls */
.flow-controls {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.5rem;
  margin-top: 0.5rem;
  margin-bottom: 1.25rem;
  position: relative;
  z-index: 5;
}

.flow-nav-btn {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid var(--border-subtle);
  background: #ffffff;
  color: var(--text-primary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: transform 0.1s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}

.flow-nav-btn:hover:not(:disabled) {
  background: var(--blue-primary);
  border-color: var(--blue-primary);
  color: #ffffff;
  transform: scale(1.05);
  box-shadow: 0 2px 8px rgba(0, 85, 255, 0.25);
}

.flow-nav-btn:active:not(:disabled) {
  transform: scale(0.95);
}

.flow-counter {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-secondary);
  min-width: 60px;
  text-align: center;
}

.flow-autoplay-btn {
  min-height: 42px;
  padding: 0 0.9rem;
  border: 1px solid var(--border-subtle);
  border-radius: 999px;
  background: #ffffff;
  color: var(--text-secondary);
  font: 600 0.8rem var(--font-sans);
  cursor: pointer;
  transition: color 0.15s ease, border-color 0.15s ease, background-color 0.15s ease;
}

.flow-autoplay-btn:hover {
  color: var(--blue-primary);
  border-color: var(--blue-primary);
}

/* Active Project Details Card (Calm Apple-Clean Style) */
.flow-details {
  margin-top: 1rem;
  padding: 1.75rem 2rem;
  background: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: 12px;
  box-shadow: var(--shadow-md);
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  text-align: center;
  align-items: center;
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}

.flow-details .caption-head {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.85rem;
  flex-wrap: wrap;
}

.flow-details h3 {
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--text-primary);
}

.caption-tag {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  background: #fef3c7;
  color: #92400e;
  border-radius: 4px;
  padding: 0.2rem 0.55rem;
}

.caption-link {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--blue-primary);
  text-decoration: none;
}

.caption-link:hover {
  text-decoration: underline;
}

.caption-summary {
  font-size: 0.98rem;
  line-height: 1.6;
  color: var(--text-secondary);
}

/* Grid Mode View */
.portfolio-container.view-grid .flow-controls,
.portfolio-container.view-grid #flow-details {
  display: none !important;
}

.portfolio-container.view-grid #flow-stage {
  perspective: none !important;
  height: auto !important;
  overflow: visible !important;
}

.portfolio-container.view-grid #flow-track {
  height: auto !important;
  transform: none !important;
  display: grid !important;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 2rem;
}

.portfolio-container.view-grid .project-item {
  position: relative !important;
  top: auto !important;
  left: auto !important;
  width: 100% !important;
  margin-left: 0 !important;
  transform: none !important;
  opacity: 1 !important;
  display: flex !important;
  flex-direction: column !important;
  background: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: 12px;
  box-shadow: var(--shadow-md);
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.portfolio-container.view-grid .project-item:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.portfolio-container.view-grid .project-media {
  height: 210px;
  width: 100%;
  overflow: hidden;
  background: #e8edf4;
  border-radius: 0;
  border: none;
  border-bottom: 1px solid var(--border-light);
  box-shadow: none;
  -webkit-box-reflect: none !important;
}

.portfolio-container.view-grid .project-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: var(--preview-position, center 12%);
  display: block;
}

.portfolio-container.view-grid .project-caption {
  display: flex !important;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1.25rem 1.5rem;
}

.portfolio-container.view-grid .project-caption .caption-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.portfolio-container.view-grid .project-caption h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-primary);
}

/* -------------------------------------------------------------------------
   7. Final CTA Section
   ------------------------------------------------------------------------- */
.cta-section {
  padding: 2.5rem 0 5rem;
}

.cta-card {
  background: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: 16px;
  box-shadow: var(--shadow-md);
  padding: 3.5rem 2.5rem;
  text-align: center;
  max-width: 820px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.cta-title {
  font-size: clamp(1.8rem, 3.5vw, 2.4rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin-bottom: 0.85rem;
}

.cta-lead {
  font-size: 1.1rem;
  line-height: 1.6;
  color: var(--text-secondary);
  max-width: 580px;
  margin-bottom: 2rem;
}

.btn-clean-cta {
  background: var(--blue-primary);
  color: #ffffff;
  border-radius: 9999px;
  border: none;
  padding: 0.95rem 2rem;
  font-size: 1rem;
  font-weight: 700;
  box-shadow: 0 4px 14px rgba(0, 85, 255, 0.3);
}

.btn-clean-cta:hover {
  background: #0044dd;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0, 85, 255, 0.35);
}

/* -------------------------------------------------------------------------
   8. Site Footer
   ------------------------------------------------------------------------- */
.site-footer {
  background: #ffffff;
  border-top: 1px solid var(--border-light);
  padding: 2.5rem 0;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.footer-left {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.footer-logo-link {
  display: inline-block;
  line-height: 1;
}

.footer-logo-link img {
  display: block;
  height: 24px;
  width: auto;
}

.footer-copy {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.footer-right {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.footer-link-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-family: var(--font-sans);
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: color 0.15s ease;
}

.footer-link-btn:hover {
  color: var(--blue-primary);
}

/* -------------------------------------------------------------------------
   9. Accessible Dialogue Modal (Sanitized, No False Promises)
   ------------------------------------------------------------------------- */
.enquiry-dialog {
  border: none;
  border-radius: 16px;
  padding: 0;
  background: #ffffff;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.25);
  max-width: 520px;
  width: calc(100% - 2rem);
  margin: auto;
  position: fixed;
  inset: 0;
  z-index: 1000;
}

.enquiry-dialog::backdrop {
  background: rgba(2, 6, 18, 0.7);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.dialog-content {
  padding: 2rem 2.25rem;
}

.dialog-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
}

.dialog-badge {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--blue-primary);
  text-transform: uppercase;
}

.dialog-close {
  background: var(--bg-surface-subtle);
  border: 1px solid var(--border-light);
  border-radius: 50%;
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.15s ease;
}

.dialog-close:hover {
  background: var(--border-light);
  color: var(--text-primary);
}

.dialog-title {
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

.dialog-lead {
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.dialog-notice {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  background: var(--bg-surface-subtle);
  border: 1px solid var(--border-light);
  border-radius: 8px;
  padding: 1rem 1.25rem;
  margin-bottom: 1.5rem;
}

.notice-icon {
  color: var(--blue-primary);
  flex-shrink: 0;
  margin-top: 2px;
}

.notice-status {
  display: block;
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.notice-details {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.45;
}

.contact-hint {
  font-size: 0.88rem;
  line-height: 1.5;
  color: var(--text-secondary);
  margin-bottom: 1.75rem;
}

.dialog-footer {
  display: flex;
  justify-content: flex-end;
}

.btn-dialog-close {
  background: var(--bg-surface-subtle);
  color: var(--text-primary);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 0.55rem 1.25rem;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-dialog-close:hover {
  background: var(--border-light);
}

/* -------------------------------------------------------------------------
   10. Prefers-Reduced-Motion Fallbacks
   ------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* -------------------------------------------------------------------------
   11. Mobile Responsiveness (390px Viewport Integrity)
   ------------------------------------------------------------------------- */
@media (max-width: 640px) {
  .header-inner {
    height: 64px;
  }

  .header-actions {
    gap: 0.5rem;
  }

  .theme-btn {
    padding: 0.3rem 0.55rem;
    font-size: 0.7rem;
  }

  .theme-selector {
    display: none;
  }

  .btn-header-cta {
    display: none;
  }

  .poster-hero-section {
    min-height: 80vh;
  }

  .poster-name {
    font-size: 4rem;
  }

  .poster-headline {
    font-size: 1.85rem;
  }

  .poster-intro {
    font-size: 1rem;
  }

  .offer-bridge-section {
    padding: 2.5rem 0 1rem;
  }

  .offer-inner {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .offer-heading h2 {
    max-width: 20ch;
  }

  .offer-list {
    grid-template-columns: 1fr;
  }

  .offer-item,
  .offer-item:not(:first-child) {
    border-left: 0;
    border-bottom: 1px solid var(--border-light);
    padding: 1rem 0;
  }

  .offer-item-primary {
    box-shadow: inset 2px 0 0 var(--blue-primary);
    padding-left: 1rem !important;
  }

  .portfolio-container.view-flow #flow-stage {
    height: 365px;
  }

  .portfolio-container.view-flow #flow-track {
    height: 310px;
  }

  .portfolio-container.view-flow .project-item {
    width: min(90vw, 420px);
    margin-left: calc(-1 * min(90vw, 420px) / 2);
  }

  .flow-details {
    padding: 1.25rem;
  }

  .flow-details h3 {
    font-size: 1.15rem;
  }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }
}
