/* ============================================================
   MABEL — Portfolio Stylesheet
   Shared across all pages. Update once, applies everywhere.
   ============================================================ */

/* RESET & ROOT */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --bg: #FFFFFF;
    --card-bg: #F2F4F6;
    --text: #1E2428;
    --text-secondary: #4A555E;
    --text-tertiary: #8A949C;
    --border: #DEE2E6;
    --tag-border: #D4D9DE;
    --accent-blue: #3A6A8F;
    --accent-lavender: #9B8CBF;
    --accent-sage: #6DB5A8;
    --accent-sky: #82B5C4;
    --accent-butter: #C4B87A;
    --accent-blue-muted: #B08B9B;
    --serif: 'DM Serif Display', Georgia, serif;
    --sans: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
}

html { scroll-behavior: smooth; }

body {
    font-family: var(--sans);
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

::selection { background: var(--accent-blue); color: #fff; }
a { color: inherit; text-decoration: none; }

.container { max-width: 1100px; margin: 0 auto; padding: 0 2rem; position: relative; }

/* ============================================================
   FLOATING SHAPES
   ============================================================ */
.shape { position: absolute; border-radius: 50%; pointer-events: none; z-index: 0; }
.shape-1 { width: 120px; height: 120px; background: var(--accent-blue); opacity: 0.2; top: 80px; right: -30px; animation: float 8s ease-in-out infinite; }
.shape-2 { width: 80px; height: 80px; background: var(--accent-lavender); opacity: 0.18; top: 350px; left: -20px; animation: float 10s ease-in-out infinite 1s; }
.shape-3 { width: 50px; height: 50px; background: var(--accent-sage); opacity: 0.22; top: 600px; right: 60px; animation: float 7s ease-in-out infinite 0.5s; }
.shape-4 { width: 35px; height: 35px; background: var(--accent-butter); opacity: 0.25; top: 60px; right: 18%; left: auto; animation: float 9s ease-in-out infinite 2s; }
.shape-ring { position: absolute; border-radius: 50%; border: 1.5px dashed var(--accent-sage); opacity: 0.2; pointer-events: none; z-index: 0; }
.shape-ring-1 { width: 160px; height: 160px; bottom: 200px; left: -40px; animation: float 12s ease-in-out infinite; }
.shape-ring-2 { width: 90px; height: 90px; top: 480px; right: 10%; animation: float 11s ease-in-out infinite 3s; border-color: var(--accent-lavender); }
.shape-diamond { position: absolute; width: 12px; height: 12px; opacity: 0.3; transform: rotate(45deg); pointer-events: none; z-index: 0; }
.shape-diamond-1 { top: 150px; right: 20%; background: var(--accent-lavender); animation: twinkle 4s ease-in-out infinite; }
.shape-diamond-2 { top: 520px; left: 80%; background: var(--accent-butter); animation: twinkle 5s ease-in-out infinite 1.5s; }
.shape-diamond-3 { bottom: 300px; right: 30%; background: var(--accent-sage); animation: twinkle 3.5s ease-in-out infinite 0.8s; }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-15px); } }
@keyframes twinkle { 0%, 100% { opacity: 0.3; transform: rotate(45deg) scale(1); } 50% { opacity: 0.15; transform: rotate(45deg) scale(0.7); } }

/* ============================================================
   NAV
   ============================================================ */
nav { padding: 1.25rem 2rem; display: flex; justify-content: space-between; align-items: center; max-width: 1100px; margin: 0 auto; }
.nav-bar { position: sticky; top: 0; z-index: 100; width: 100%; background: rgba(255,255,255,0.92); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--border); }
.nav-name { font-weight: 500; font-size: 0.95rem; transition: color 0.3s; display: flex; align-items: center; gap: 0.5rem; }
.nav-logo { width: 28px; height: 28px; background: var(--card-bg); border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 0.6rem; color: var(--text-tertiary); overflow: hidden; }
.nav-logo img { width: 100%; height: 100%; object-fit: contain; }
.nav-name:hover { color: var(--accent-blue); }
.nav-links { display: flex; gap: 2rem; list-style: none; }
.nav-links a { font-size: 0.85rem; color: var(--text-secondary); transition: color 0.2s; position: relative; }
.nav-links a:hover { color: var(--text); }
.nav-links a::after { content: ''; position: absolute; bottom: -2px; left: 0; width: 0; height: 1.5px; background: var(--accent-blue); border-radius: 1px; transition: width 0.3s ease; }
.nav-links a:hover::after { width: 100%; }
.nav-links a.active { color: var(--text); }
.nav-links a.active::after { width: 100%; }
.nav-wrap { max-width: 1100px; margin: 0 auto; padding: 0 2rem; }
.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 4px; }
.nav-toggle svg { width: 22px; height: 22px; stroke: var(--text); }

/* ============================================================
   BREADCRUMB
   ============================================================ */
.breadcrumb { max-width: 1100px; margin: 0 auto; padding: 1rem 2rem 0; font-size: 0.8rem; color: var(--text-tertiary); }
.breadcrumb a { transition: color 0.2s; }
.breadcrumb a:hover { color: var(--accent-blue); }
.breadcrumb span { margin: 0 0.4rem; }

/* ============================================================
   HERO
   ============================================================ */
.hero { padding: 4rem 0 4.5rem; position: relative; z-index: 1; }
.hero-wave { font-size: 2rem; display: inline-block; margin-bottom: 1rem; animation: wave 2.5s ease-in-out infinite; transform-origin: 70% 70%; }
@keyframes wave { 0%, 100% { transform: rotate(0deg); } 10% { transform: rotate(14deg); } 20% { transform: rotate(-8deg); } 30% { transform: rotate(14deg); } 40% { transform: rotate(-4deg); } 50% { transform: rotate(0deg); } }
.hero h1 { font-family: var(--serif); font-size: clamp(2rem, 4.5vw, 3.2rem); font-weight: 400; line-height: 1.2; margin-bottom: 1.25rem; }
.hero h1 em { font-style: italic; color: var(--accent-blue); }
.hero p { font-size: 1rem; color: var(--text-secondary); max-width: 620px; line-height: 1.7; font-weight: 300; }
.hero p strong { color: var(--text); font-weight: 500; }
.hero-note { display: inline-block; margin-top: 1rem; font-size: 0.78rem; color: var(--text-tertiary); font-style: italic; }

/* ============================================================
   SECTION & PAGE HEADERS
   ============================================================ */
.section-header { font-size: 0.75rem; font-weight: 400; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-tertiary); margin-bottom: 2rem; padding-bottom: 0.75rem; border-bottom: 1px solid var(--border); position: relative; z-index: 1; }
.page-header { padding: 3rem 0 1.5rem; position: relative; z-index: 1; }
.page-header h1 { font-family: var(--serif); font-size: clamp(1.8rem, 3.5vw, 2.6rem); font-weight: 400; line-height: 1.2; margin-bottom: 0.75rem; }
.page-header p { font-size: 0.95rem; color: var(--text-secondary); max-width: 560px; line-height: 1.7; font-weight: 300; }

/* ============================================================
   PROJECT CARDS (homepage)
   ============================================================ */
.project-stack { display: flex; flex-direction: column; gap: 1.25rem; margin-bottom: 5rem; position: relative; z-index: 1; }
.project-card { display: grid; grid-template-columns: 1fr 1fr; background: var(--card-bg); border: 1px solid var(--border); border-radius: 14px; overflow: hidden; transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94), box-shadow 0.4s ease; }
.project-card:hover { transform: translateY(-5px) rotate(-0.3deg); box-shadow: 0 16px 48px rgba(0,0,0,0.08); border-color: var(--accent-blue); }
.project-card-image { aspect-ratio: 16 / 10; display: flex; align-items: center; justify-content: center; min-height: 200px; overflow: hidden; }
.project-card-image img { width: 100%; height: 100%; object-fit: cover; }
.img-placeholder { font-size: 0.72rem; color: var(--text-tertiary); letter-spacing: 0.04em; text-transform: uppercase; }
.fill-1 { background: linear-gradient(135deg, #EDF0F3 0%, #E5E9ED 50%, #DDE2E7 100%); }
.fill-2 { background: linear-gradient(145deg, #EBF0F3 0%, #E3E8ED 50%, #DBE1E7 100%); }
.fill-3 { background: linear-gradient(160deg, #EAEFF3 0%, #E2E8ED 50%, #DAE0E7 100%); }
.project-card-body { padding: 2rem 2rem 2rem 1.75rem; display: flex; flex-direction: column; justify-content: center; background: #FFFFFF; position: relative; z-index: 2; }
.project-card-type { font-size: 0.65rem; font-weight: 400; text-transform: uppercase; letter-spacing: 0.1em; color: var(--accent-blue); margin-bottom: 0.6rem; }
.project-card-title { font-family: var(--serif); font-size: 1.35rem; font-weight: 400; line-height: 1.3; margin-bottom: 0.6rem; }
.project-card-desc { font-size: 0.88rem; color: var(--text-secondary); line-height: 1.65; font-weight: 300; margin-bottom: 1rem; }
.project-card-tags { display: flex; flex-wrap: wrap; gap: 0.4rem; }

/* ============================================================
   CASE STUDY CARDS (work.html)
   ============================================================ */
.case-stack { display: flex; flex-direction: column; gap: 1.25rem; margin-bottom: 5rem; position: relative; z-index: 1; }
.case-card { display: grid; grid-template-columns: 1.1fr 1fr; background: var(--card-bg); border: 1px solid var(--border); border-radius: 14px; overflow: hidden; transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94), box-shadow 0.4s ease; }
.case-card:hover { transform: translateY(-5px) rotate(-0.3deg); box-shadow: 0 16px 48px rgba(0,0,0,0.08); border-color: var(--accent-blue); }
.case-card-image { aspect-ratio: 16 / 10; display: flex; align-items: center; justify-content: center; min-height: 220px; overflow: hidden; border-right: 1px solid var(--border); }
.case-card-image img { width: 100%; height: 100%; object-fit: cover; }
.case-card-body { padding: 2rem; display: flex; flex-direction: column; justify-content: center; background: #FFFFFF; position: relative; z-index: 2; }
.case-card-subtitle { font-size: 0.7rem; font-weight: 400; text-transform: uppercase; letter-spacing: 0.08em; color: var(--accent-blue); margin-bottom: 0.5rem; }
.case-card-title { font-family: var(--serif); font-size: 1.35rem; font-weight: 400; line-height: 1.3; margin-bottom: 0.6rem; }
.case-card-desc { font-size: 0.88rem; color: var(--text-secondary); line-height: 1.65; font-weight: 300; margin-bottom: 1.1rem; }
.case-card-tags { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-bottom: 1.25rem; }
.case-card-link { font-size: 0.8rem; font-weight: 400; display: inline-flex; align-items: center; gap: 0.35rem; transition: gap 0.2s, color 0.2s; }
.case-card:hover .case-card-link, .case-card-link:hover { gap: 0.6rem; color: var(--accent-blue); }

/* ============================================================
   TAGS
   ============================================================ */
.tag { font-size: 0.68rem; padding: 0.22rem 0.6rem; border: 1px solid var(--tag-border); border-radius: 20px; color: var(--text-secondary); background: var(--bg); transition: background 0.2s, border-color 0.2s; }
.project-card:hover .tag, .case-card:hover .tag { border-color: var(--accent-blue); background: rgba(58, 106, 143, 0.1); }

/* ============================================================
   SIDEQUESTS
   ============================================================ */
.quest-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 1.25rem; padding: 2rem 0 5rem; position: relative; z-index: 1; }
.quest-card { display: block; border: 1px solid var(--border); border-radius: 12px; overflow: hidden; background: #FFFFFF; transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94), box-shadow 0.4s ease, border-color 0.25s; }
.quest-card:hover { transform: translateY(-4px) rotate(0.3deg); box-shadow: 0 12px 36px rgba(0,0,0,0.06); border-color: var(--accent-blue); }
.quest-card-image { width: 100%; aspect-ratio: 16 / 10; background: var(--card-bg); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.quest-card-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s ease; }
.quest-card:hover .quest-card-image img { transform: scale(1.04); }
.quest-card-body { padding: 1.25rem 1.35rem 1.4rem; background: #FFFFFF; position: relative; z-index: 2; }
.quest-card-tag { display: inline-block; font-size: 0.62rem; font-weight: 400; text-transform: uppercase; letter-spacing: 0.08em; color: var(--accent-blue); margin-bottom: 0.45rem; }
.quest-card-title { font-family: var(--serif); font-size: 1.1rem; font-weight: 400; line-height: 1.35; margin-bottom: 0.4rem; }
.quest-card-desc { font-size: 0.82rem; color: var(--text-secondary); line-height: 1.6; font-weight: 300; margin-bottom: 0.85rem; }
.quest-card-link { font-size: 0.78rem; font-weight: 400; display: inline-flex; align-items: center; gap: 0.3rem; transition: gap 0.2s, color 0.2s; }
.quest-card:hover .quest-card-link { gap: 0.55rem; color: var(--accent-blue); }
.quest-empty { border: 1px dashed var(--border); border-radius: 12px; padding: 3rem 2rem; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; min-height: 200px; }
.quest-empty p { font-size: 0.85rem; color: var(--text-tertiary); font-weight: 300; line-height: 1.6; }
.quest-empty p:first-child { font-family: var(--serif); font-size: 1rem; color: var(--text-secondary); margin-bottom: 0.25rem; }

/* SIDEQUEST INDIVIDUAL PAGE */
.sq-intro { max-width: 680px; padding: 3rem 0 2.5rem; position: relative; z-index: 1; }
.sq-intro h1 { font-family: var(--serif); font-size: clamp(1.8rem, 3.5vw, 2.6rem); font-weight: 400; line-height: 1.2; margin-bottom: 0.75rem; }
.sq-intro .sq-tag { display: inline-block; font-size: 0.65rem; font-weight: 400; text-transform: uppercase; letter-spacing: 0.1em; color: var(--accent-blue); margin-bottom: 1rem; }
.sq-intro p { font-size: 0.95rem; color: var(--text-secondary); line-height: 1.75; font-weight: 300; margin-bottom: 0.75rem; }
.sq-embed { margin: 0 0 3rem; border-radius: 12px; overflow: hidden; border: 1px solid var(--border); position: relative; z-index: 1; }
.sq-embed iframe { width: 100%; height: 75vh; min-height: 500px; border: none; display: block; }
.sq-back { display: inline-flex; align-items: center; gap: 0.4rem; font-size: 0.82rem; font-weight: 400; color: var(--text-secondary); margin-top: 1.5rem; margin-bottom: 1.5rem; transition: color 0.2s, gap 0.2s; position: relative; z-index: 1; }
.sq-back:hover { color: var(--accent-blue); gap: 0.6rem; }

/* ============================================================
   ABOUT PAGE
   ============================================================ */
.about-page { padding: 3rem 0 5rem; position: relative; z-index: 1; }
.about-grid { display: grid; grid-template-columns: 300px 1fr; gap: 4.5rem; align-items: start; }
.about-photo { width: 100%; aspect-ratio: 3 / 4; background: var(--card-bg); border-radius: 12px; display: flex; align-items: center; justify-content: center; color: var(--text-tertiary); font-size: 0.8rem; font-style: italic; margin-bottom: 1.5rem; overflow: hidden; }
.about-photo img { width: 100%; height: 100%; object-fit: cover; }
.about-contact-links { display: flex; flex-direction: column; gap: 0.6rem; }
.about-contact-link { font-size: 0.82rem; font-weight: 400; display: inline-flex; align-items: center; gap: 0.5rem; transition: color 0.2s; }
.about-contact-link:hover { color: var(--accent-blue); }
.about-contact-link .link-arrow { font-size: 0.75rem; color: var(--text-tertiary); transition: transform 0.2s, color 0.2s; }
.about-contact-link:hover .link-arrow { transform: translateX(3px); color: var(--accent-blue); }
.about-intro { font-family: var(--serif); font-size: clamp(1.5rem, 2.5vw, 2rem); font-weight: 400; line-height: 1.4; margin-bottom: 1.5rem; }
.about-intro em { font-style: italic; color: var(--accent-blue); }
.about-body { font-size: 0.95rem; color: var(--text-secondary); line-height: 1.8; font-weight: 300; margin-bottom: 1rem; max-width: 620px; }
.details-section { margin-top: 3rem; padding-top: 2.5rem; border-top: 1px solid var(--border); }
.details-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 2.5rem; }
.detail-label { font-size: 0.65rem; font-weight: 400; text-transform: uppercase; letter-spacing: 0.1em; color: var(--accent-blue); margin-bottom: 0.35rem; }
.detail-value { font-size: 0.9rem; color: var(--text-secondary); line-height: 1.55; font-weight: 300; }
.skills-section { margin-top: 3rem; padding-top: 2.5rem; border-top: 1px solid var(--border); }
.skills-section h3 { font-family: var(--serif); font-size: 1.15rem; font-weight: 400; margin-bottom: 1.25rem; }
.skills-group { margin-bottom: 1.5rem; }
.skills-group-label { font-size: 0.68rem; font-weight: 400; text-transform: uppercase; letter-spacing: 0.08em; color: var(--accent-blue); margin-bottom: 0.5rem; }
.skills-group p { font-size: 0.88rem; color: var(--text-secondary); line-height: 1.65; font-weight: 300; }

/* ============================================================
   CASE STUDY PAGES — SHARED
   ============================================================ */
.cs-hero { max-width: 1100px; margin: 0 auto; padding: 3rem 2rem 0; position: relative; z-index: 1; text-align: left; width: 100%; }
.cs-hero h1 { font-family: var(--serif); font-size: clamp(2rem, 4vw, 3rem); font-weight: 400; line-height: 1.15; margin-bottom: 0.6rem; max-width: 700px; }
.cs-hero-subtitle { font-family: var(--serif); font-style: italic; font-size: 1.1rem; color: var(--text-secondary); margin-bottom: 2.5rem; max-width: 700px; line-height: 1.5; }
.cs-hero-subtitle--accent { color: var(--accent-blue); }

/* Meta — default 4 columns, 5-column variant */
.cs-meta { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; padding-bottom: 1.5rem; border-bottom: 1px solid var(--border); }
.cs-meta--5 { grid-template-columns: repeat(5, 1fr); }
.cs-meta--borderless { border-bottom: none; padding-bottom: 0; }
.cs-meta-label { font-size: 0.65rem !important; font-weight: 400; text-transform: uppercase; letter-spacing: 0.1em; color: var(--accent-blue) !important; margin-bottom: 0.3rem; }
.cs-meta-value { font-size: 0.88rem !important; color: var(--text-secondary) !important; line-height: 1.5; font-weight: 300; }

.cs-cover { max-width: 1100px; margin: 3rem auto; padding: 0 2rem; }
.cs-cover-inner { width: 100%; aspect-ratio: 16 / 8; background: var(--card-bg); border-radius: 12px; display: flex; align-items: center; justify-content: center; color: var(--text-tertiary); font-size: 0.8rem; letter-spacing: 0.04em; text-transform: uppercase; overflow: hidden; }
.cs-cover-inner img { width: 100%; height: 100%; object-fit: cover; border: 1px solid rgba(0,0,0,0.08); box-shadow: 0 2px 12px rgba(0,0,0,0.08); border-radius: 8px; }

.cs-content { max-width: 760px; margin: 0 auto; padding: 0 2rem; }
.cs-section { padding: 3rem 0; border-top: 1px solid var(--border); }
.cs-section:first-of-type { border-top: none; padding-top: 1rem; }
.cs-section:first-child { border-top: none; padding-top: 2rem; }

/* Section label — consistent across scan and full story */
.cs-section-label { font-size: 0.95rem; font-weight: 400; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-secondary); margin-bottom: 1.25rem; display: block; }

.cs-section h2 { font-family: var(--serif); font-size: 1.55rem; font-weight: 400; line-height: 1.3; margin-bottom: 1.25rem; }
.cs-section h3 { font-family: var(--serif); font-size: 1.15rem; font-weight: 400; line-height: 1.35; margin-bottom: 0.75rem; margin-top: 2rem; }
.cs-section p { font-size: 0.95rem; color: var(--text-secondary); line-height: 1.8; font-weight: 300; margin-bottom: 1rem; }
.cs-section p strong { color: var(--text); font-weight: 500; }
.cs-section p em { font-style: italic; }
.cs-section ul { list-style: none; padding: 0; margin-bottom: 1.25rem; }
.cs-section ul li { font-size: 0.92rem; color: var(--text-secondary); line-height: 1.7; font-weight: 300; padding-left: 1.1rem; position: relative; margin-bottom: 0.5rem; }
.cs-section ul li::before { content: '–'; position: absolute; left: 0; color: var(--accent-blue); }

.cs-quote { margin: 2rem 0; padding: 1.75rem 2rem; border-left: 2.5px solid var(--accent-blue); }
.cs-quote p { font-family: var(--serif); font-style: italic; font-size: 1.1rem; color: var(--text); line-height: 1.55; margin-bottom: 0; }
.cs-quote cite { display: block; margin-top: 0.6rem; font-family: var(--sans); font-style: normal; font-size: 0.78rem; color: var(--text-tertiary); }

.cs-outcomes { margin: 2rem 0; padding: 2rem; background: var(--card-bg); border-radius: 12px; }
.cs-outcomes-title { font-size: 0.65rem; font-weight: 400; text-transform: uppercase; letter-spacing: 0.1em; color: var(--accent-blue); margin-bottom: 1.25rem; }
.cs-outcomes-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
.cs-outcome h4 { font-family: var(--serif); font-size: 1.5rem; font-weight: 400; margin-bottom: 0.25rem; }
.cs-outcome p { font-size: 0.82rem; color: var(--text-secondary); line-height: 1.5; font-weight: 300; margin-bottom: 0; }

/* Images */
.cs-image { margin: 2rem 0; border-radius: 10px; overflow: hidden; }
.cs-image-inner { border-radius: 12px; overflow: hidden; background: var(--card-bg); border: 1px solid var(--border); width: 100%; display: block; }
.cs-image-inner img { width: 100%; height: 100%; object-fit: cover; border: 1px solid rgba(0,0,0,0.08); box-shadow: 0 2px 12px rgba(0,0,0,0.08); border-radius: 6px; }
.cs-image-placeholder { width: 100%; display: flex; align-items: center; justify-content: center; color: var(--text-tertiary); font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; }
.cs-image-caption { font-size: 0.75rem; color: var(--text-tertiary); margin-top: 0.6rem; font-weight: 300; }
.cs-image-inline { margin: 2rem 0; }
.cs-image-wide { max-width: 1100px; margin: 3.5rem auto; padding: 0 2rem; width: 100%; align-self: center; }
.cs-image-wide .cs-image-inner { border-radius: 10px; }

.cs-next { max-width: 1100px; margin: 0 auto; padding: 4rem 2rem; border-top: 1px solid var(--border); }
.cs-next-label { font-size: 0.65rem; font-weight: 400; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-tertiary); margin-bottom: 0.75rem; }
.cs-next-card { display: inline-flex; align-items: center; gap: 0.5rem; font-family: var(--serif); font-size: 1.25rem; font-weight: 400; transition: gap 0.2s, color 0.2s; }
.cs-next-card:hover { gap: 0.8rem; color: var(--accent-blue); }
.cs-next-arrow { font-size: 1rem; color: var(--text-tertiary); }

/* ============================================================
   SCAN ZONE — case study overview (above the fold)
   ============================================================ */
.scan-zone { min-height: calc(100vh - 57px); display: flex; flex-direction: column; justify-content: space-between; align-items: stretch; }
.scan-inner { max-width: 760px; margin: 2rem auto 0; padding: 0 2rem; }
.scan-overview { font-size: 0.95rem; color: var(--text-secondary); line-height: 1.8; font-weight: 300; margin-bottom: 1.5rem; }
.scan-problem-text { font-size: 0.95rem; color: var(--text-secondary); line-height: 1.8; font-weight: 300; margin-bottom: 0; }
.scan-problem-text strong { color: var(--text); font-weight: 500; }
.scan-callouts-wrap { max-width: 1100px; margin: 3.5rem auto 0; padding: 0 2rem; }
.scan-callouts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }

/* Section divider — "Overview" / "Full case study" */
.cs-divider { max-width: 1100px; width: 100%; margin: 1.5rem auto 0; padding: 0 2rem; display: flex; align-items: center; gap: 1rem; }
.cs-divider span { font-size: 0.65rem; font-weight: 400; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-tertiary); white-space: nowrap; }
.cs-divider hr { flex: 1; height: 1px; border: none; background: var(--border); }

/* ============================================================
   CS INSIGHT — numbered callout block
   ============================================================ */
.cs-insight { border: 1px solid var(--border); border-radius: 8px; padding: 1rem 1.25rem; margin: 10px 0; background: var(--bg); display: flex; gap: 14px; align-items: flex-start; }
.cs-insight-num { font-size: 0.65rem; font-weight: 500; color: var(--accent-blue); background: var(--card-bg); border: 1px solid var(--border); border-radius: 4px; padding: 2px 7px; flex-shrink: 0; margin-top: 2px; letter-spacing: 0.04em; }
.cs-insight p { font-size: 0.9rem; color: var(--text-secondary); margin: 0; line-height: 1.7; max-width: 100%; font-weight: 300; }

/* ============================================================
   CS STAT CARD
   ============================================================ */
.cs-stat-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 1.25rem 0; }
.cs-stat-card { background: var(--bg); border: 1px solid var(--border); border-radius: 8px; padding: 1.25rem; }
.cs-stat-card h4 { font-family: var(--serif); font-size: 1.35rem; font-weight: 400; color: var(--text); margin-bottom: 6px; line-height: 1.1; }
.cs-stat-card p { font-size: 0.8rem; color: var(--text-tertiary); margin: 0; max-width: 100%; line-height: 1.5; }

/* ============================================================
   CS TRADEOFF
   ============================================================ */
.cs-tradeoff { margin: 1.75rem 0; border: 1px solid var(--border); border-radius: 10px; overflow: hidden; }
.cs-tradeoff-header { padding: 0.75rem 1.25rem; background: var(--card-bg); border-bottom: 1px solid var(--border); font-size: 0.65rem; font-weight: 500; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-tertiary); }
.cs-tradeoff-row { display: grid; grid-template-columns: 100px 1fr; border-bottom: 1px solid var(--border); }
.cs-tradeoff-row:last-child { border-bottom: none; }
.cs-tradeoff-badge { padding: 1rem 1.25rem; font-size: 0.65rem; font-weight: 500; text-transform: uppercase; letter-spacing: 0.08em; }
.cs-tradeoff-badge.shipped { color: var(--accent-sage); }
.cs-tradeoff-badge.deferred { color: var(--accent-lavender); }
.cs-tradeoff-body { padding: 1rem 1.25rem; border-left: 1px solid var(--border); font-size: 0.88rem; color: var(--text-secondary); line-height: 1.65; font-weight: 300; }

/* ============================================================
   CS ROLE TABLE
   ============================================================ */
.cs-role-table { width: 100%; border-collapse: collapse; margin-top: 0.5rem; font-size: 0.9rem; }
.cs-role-table tr { border-bottom: 1px solid var(--border); }
.cs-role-table tr:last-child { border-bottom: none; }
.cs-role-table td { padding: 0.65rem 0; vertical-align: top; line-height: 1.5; }
.cs-role-table td:first-child { font-size: 0.65rem; font-weight: 500; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-tertiary); width: 120px; padding-right: 1.5rem; padding-top: 0.8rem; }
.cs-role-table td:last-child { color: var(--text-secondary); font-weight: 300; }
.cs-outcomes-table { width: 100%; border-collapse: collapse; margin: 1.5rem 0; font-size: 0.88rem; }
.cs-outcomes-table tr { border-bottom: 1px solid var(--border); }
.cs-outcomes-table tr:last-child { border-bottom: none; }
.cs-outcomes-table td { padding: 0.9rem 0; vertical-align: top; line-height: 1.6; }
.cs-outcomes-table td:first-child { font-weight: 500; color: var(--text); width: 200px; padding-right: 1.5rem; }
.cs-outcomes-table td.stat-cell { font-family: var(--serif); font-size: 1.1rem; color: var(--accent-blue); }
.cs-outcomes-table td:last-child { color: var(--text-secondary); font-weight: 300; }

/* ============================================================
   CS PROBLEM STATEMENT
   ============================================================ */
.cs-problem-statement { background: var(--card-bg); border: 1px solid var(--border); border-left: 3px solid var(--accent-sage); border-radius: 0 8px 8px 0; padding: 1.25rem 1.5rem; margin: 1.5rem 0; }
.cs-problem-statement p { font-family: var(--serif); font-style: italic; font-size: 1rem; color: var(--text); line-height: 1.65; margin: 0; max-width: 100%; }

/* ============================================================
   CS DELIVERABLES
   ============================================================ */
.cs-deliverables { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.cs-deliverable { display: flex; align-items: center; gap: 10px; padding: 10px 14px; background: var(--bg); border: 1px solid var(--border); border-radius: 8px; font-size: 0.87rem; color: var(--text-secondary); }
.cs-deliverable-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent-blue); flex-shrink: 0; }

/* ============================================================
   CS ROLE ROWS
   ============================================================ */
.cs-role { display: flex; align-items: flex-start; gap: 14px; padding: 1rem 0; border-bottom: 1px solid var(--border); }
.cs-role:first-of-type { border-top: 1px solid var(--border); }
.cs-role-icon { width: 32px; height: 32px; background: var(--card-bg); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 14px; flex-shrink: 0; margin-top: 2px; }
.cs-role-title { font-size: 0.65rem; font-weight: 500; color: var(--accent-blue); text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 4px; }
.cs-role-desc { font-size: 0.9rem; color: var(--text-secondary); line-height: 1.65; font-weight: 300; }

/* ============================================================
   CS PHASES — vertical timeline
   ============================================================ */
.cs-phases { display: flex; flex-direction: column; margin: 1.25rem 0; }
.cs-phase { display: flex; gap: 0; position: relative; }
.cs-phase-track { display: flex; flex-direction: column; align-items: center; width: 28px; flex-shrink: 0; }
.cs-phase-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--accent-blue); border: 2px solid var(--bg); box-shadow: 0 0 0 2px var(--accent-blue); margin-top: 4px; flex-shrink: 0; z-index: 1; }
.cs-phase-line { width: 2px; flex: 1; background: var(--border); margin: 3px 0; min-height: 18px; }
.cs-phase:last-child .cs-phase-line { display: none; }
.cs-phase-body { padding: 0 0 1.75rem 1rem; flex: 1; }
.cs-phase-label { font-size: 0.62rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent-blue); margin-bottom: 3px; font-weight: 400; }
.cs-phase-title { font-size: 0.92rem; font-weight: 500; color: var(--text); margin-bottom: 6px; }
.cs-phase-body p { font-size: 0.875rem; color: var(--text-secondary); line-height: 1.65; margin: 0; max-width: 100%; font-weight: 300; }

/* ============================================================
   CS RETRO CARDS
   ============================================================ */
.cs-retro { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 1.5rem; }
.cs-retro-card { border: 1px solid var(--border); border-radius: 10px; padding: 1.25rem; background: var(--bg); }
.cs-retro-card.went-well  { border-top: 3px solid var(--accent-sage); }
.cs-retro-card.improve    { border-top: 3px solid var(--accent-lavender); }
.cs-retro-card.validated  { border-top: 3px solid var(--accent-sage); }
.cs-retro-card.challenged { border-top: 3px solid var(--accent-lavender); }
.cs-retro-label { font-size: 0.62rem; letter-spacing: 0.1em; text-transform: uppercase; margin-bottom: 10px; display: flex; align-items: center; gap: 6px; font-weight: 500; }
.cs-retro-label::before { content: ''; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.cs-retro-card.went-well  .cs-retro-label { color: var(--accent-sage); }
.cs-retro-card.improve    .cs-retro-label { color: var(--accent-lavender); }
.cs-retro-card.validated  .cs-retro-label { color: var(--accent-sage); }
.cs-retro-card.challenged .cs-retro-label { color: var(--accent-lavender); }
.cs-retro-card p { font-size: 0.875rem; color: var(--text-secondary); line-height: 1.65; margin: 0; max-width: 100%; font-weight: 300; }

/* ============================================================
   CS PROTOTYPE EMBED
   ============================================================ */
.cs-proto-wrap { border: 1px solid var(--border); border-radius: 10px; overflow: hidden; box-shadow: 0 4px 24px rgba(0,0,0,0.07), 0 1px 4px rgba(0,0,0,0.04); margin-top: 1rem; }
.cs-proto-chrome { height: 36px; background: var(--card-bg); border-bottom: 1px solid var(--border); display: flex; align-items: center; padding: 0 14px; gap: 10px; }
.cs-proto-dots { display: flex; gap: 5px; }
.cs-proto-dot { width: 10px; height: 10px; border-radius: 50%; }
.cs-proto-dot:nth-child(1) { background: #ff5f57; }
.cs-proto-dot:nth-child(2) { background: #febc2e; }
.cs-proto-dot:nth-child(3) { background: #28c840; }
.cs-proto-url { flex: 1; font-size: 0.72rem; color: var(--text-tertiary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cs-proto-open { font-size: 0.72rem; color: var(--accent-blue); text-decoration: none; white-space: nowrap; flex-shrink: 0; transition: color 0.15s; }
.cs-proto-open:hover { text-decoration: underline; }
.cs-proto-iframe { width: 100%; height: 600px; border: none; display: block; background: var(--card-bg); }

/* ============================================================
   INLINE CODE
   ============================================================ */
code { font-size: 0.88em; background: var(--card-bg); padding: 0.15em 0.4em; border-radius: 4px; font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace; }

/* ============================================================
   CALLOUT
   ============================================================ */
.callout { margin-bottom: 4rem; padding: 2.5rem; border: 1px solid var(--border); border-radius: 16px; text-align: center; position: relative; z-index: 1; background: rgba(255,255,255,0.4); backdrop-filter: blur(4px); }
.callout p { font-family: var(--serif); font-size: 1.2rem; font-weight: 400; line-height: 1.45; margin-bottom: 0.6rem; }
.callout .callout-sub { font-family: var(--sans); font-size: 0.88rem; color: var(--text-secondary); font-weight: 300; margin-bottom: 1.25rem; }
.callout-link { display: inline-flex; align-items: center; gap: 0.4rem; font-size: 0.85rem; font-weight: 400; color: var(--text); padding: 0.5rem 1.2rem; border: 1.5px solid var(--text); border-radius: 30px; transition: all 0.3s ease; }
.callout-link:hover { background: var(--text); color: var(--bg); gap: 0.65rem; }

/* ============================================================
   FOOTER
   ============================================================ */
footer { padding: 3rem 0 2rem; border-top: 1px solid var(--border); position: relative; z-index: 1; }
.footer-cta { text-align: right; margin-bottom: 1.5rem; }
.footer-cta-text { font-family: var(--serif); font-size: 1.15rem; font-weight: 400; color: var(--text-tertiary); margin-bottom: 0.25rem; }
.footer-email { font-size: 1.1rem; font-weight: 400; color: var(--text); transition: color 0.2s; }
.footer-email:hover { color: var(--accent-blue); }
.footer-icons { display: flex; justify-content: flex-end; gap: 1rem; margin-top: 1rem; }
.footer-icons a { color: var(--text-tertiary); transition: color 0.2s, transform 0.2s; display: flex; }
.footer-icons a:hover { color: var(--accent-blue); transform: translateY(-2px); }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; font-size: 0.75rem; color: var(--text-tertiary); }
.footer-left { color: var(--text-tertiary); }
.footer-heart { color: var(--accent-blue-muted); }
.footer-nav { display: flex; gap: 1.25rem; }
.footer-nav a { font-size: 0.75rem; color: var(--text-tertiary); transition: color 0.2s; }
.footer-nav a:hover { color: var(--accent-blue); }
.footer-credit {
    font-size: 0.72rem;
    color: var(--text-tertiary);
    opacity: 0.7;
    margin: 0;
    padding-bottom: 0.25rem;
}

/* ============================================================
   ANIMATIONS
   ============================================================ */
.fade-in { opacity: 0; transform: translateY(24px); transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94); }
.fade-in.visible { opacity: 1; transform: translateY(0); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 768px) {
    .container, .nav-wrap, .breadcrumb, .cs-hero, .cs-cover, .cs-content, .cs-image-wide, .cs-next { padding-left: 1.25rem; padding-right: 1.25rem; }
    .nav-toggle { display: block; }
    .nav-links { display: none; position: absolute; top: 100%; right: 1.25rem; background: #fff; border: 1px solid var(--border); border-radius: 10px; padding: 1rem 1.5rem; flex-direction: column; gap: 1rem; box-shadow: 0 8px 24px rgba(0,0,0,0.08); }
    .nav-links.open { display: flex; }
    nav { position: relative; padding-left: 1.25rem; padding-right: 1.25rem; }
    .hero { padding: 2.5rem 0 3rem; }
    .page-header { padding: 2rem 0 1rem; }
    .project-card, .case-card { grid-template-columns: 1fr; }
    .project-card-image, .case-card-image { aspect-ratio: 16 / 10; display: flex; align-items: center; justify-content: center; min-height: 200px; overflow: hidden; border-right: 1px solid var(--border); }
    .project-stack, .case-stack { margin-bottom: 3.5rem; }
    .quest-grid { grid-template-columns: 1fr; padding-bottom: 3.5rem; }
    .about-grid { grid-template-columns: 1fr; gap: 2.5rem; }
    .about-photo { max-width: 240px; }
    .about-contact-links { flex-direction: row; flex-wrap: wrap; gap: 1rem; }
    .cs-meta { grid-template-columns: 1fr 1fr; gap: 1.25rem; }
    .cs-outcomes-grid { grid-template-columns: 1fr; }
    .cs-section { padding: 2rem 0; }
    .scan-callouts { grid-template-columns: 1fr; }
    .cs-tradeoff-row { grid-template-columns: 1fr; }
    .cs-tradeoff-body { border-left: none; border-top: 1px solid var(--border); }
    .shape, .shape-ring, .shape-diamond { display: none; }
    .footer-bottom { flex-direction: column; gap: 0.75rem; text-align: center; }
    .footer-nav { justify-content: center; }
    .footer-cta { text-align: center; }
    .footer-icons { justify-content: center; }
    .sq-embed iframe { height: 60vh; min-height: 400px; }
    .sq-intro { padding: 2rem 0 2rem; }
}

@media (max-width: 480px) {
    .cs-meta { grid-template-columns: 1fr; }
    .details-grid { grid-template-columns: 1fr; gap: 1.25rem; }
}
