/* ============================================================
   recycle.cafe — Repair Cafe
   Colors:
     #F7F2EA Linen Ground (warm parchment)
     #FFFFFF Paper White
     #EDE6D8 Hero right (slightly darker linen)
     #D4BC94 Cork Tint (board brown)
     #B8A88A Counter Edge (taupe)
     #4A3728 Roasted Bean (display)
     #5C4A3A Coffee Dark (body)
     #5A8C6F Mended Green (accent)
     #E8A46C Apricot Glow (highlight)
     #7A7268 Workshop Grey (caption)
   Fonts: Fredoka (display), Nunito (body, nav), Kalam (handwritten)
   ============================================================ */

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Nunito', system-ui, -apple-system, sans-serif;
    font-weight: 400;
    font-size: 17px;
    line-height: 1.7;
    color: #5C4A3A;
    background: #F7F2EA;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

/* ============== NAVIGATION ============== */
.nav-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 48px;
    background: rgba(247, 242, 234, 0.9);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-bottom: 1px solid rgba(184, 168, 138, 0.4);
    z-index: 100;
    transition: background 300ms ease;
}

.nav-bar.scrolled {
    background: rgba(247, 242, 234, 0.96);
    border-bottom-color: rgba(184, 168, 138, 0.7);
}

.nav-inner {
    max-width: 1280px;
    height: 100%;
    margin: 0 auto;
    padding: 0 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-brand {
    font-family: 'Fredoka', sans-serif;
    font-weight: 600;
    font-size: 18px;
    color: #4A3728;
    text-decoration: none;
    letter-spacing: -0.01em;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 28px;
}

.nav-link {
    position: relative;
    font-family: 'Nunito', sans-serif;
    font-weight: 600;
    font-size: 13px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #4A3728;
    text-decoration: none;
    padding: 4px 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: 0;
    height: 2px;
    width: 0;
    background: #5A8C6F;
    transform: translateX(-50%);
    transition: width 400ms ease;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

/* ============== HERO ============== */
.hero {
    position: relative;
    min-height: 100vh;
    padding-top: 48px;
}

.hero-grid {
    position: relative;
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: calc(100vh - 48px);
}

.hero-grid::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 1px;
    background: #B8A88A;
    z-index: 2;
}

.hero-left {
    background: #F7F2EA;
    padding: 96px 80px 64px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 28px;
}

.hero-eyebrow {
    font-family: 'Nunito', sans-serif;
    font-weight: 600;
    font-size: 13px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #5A8C6F;
}

.hero-title {
    font-family: 'Fredoka', sans-serif;
    font-weight: 600;
    font-size: clamp(44px, 6vw, 80px);
    line-height: 1.05;
    letter-spacing: -0.015em;
    color: #4A3728;
}

.hero-title .accent {
    position: relative;
    color: #5A8C6F;
    display: inline-block;
}

.hero-title .accent::after {
    content: '';
    position: absolute;
    left: -2%;
    right: -2%;
    bottom: 0.05em;
    height: 0.18em;
    background: rgba(232, 164, 108, 0.45);
    z-index: -1;
    border-radius: 2px;
}

.hero-lede {
    font-size: 18px;
    line-height: 1.7;
    color: #5C4A3A;
    max-width: 36em;
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 24px 36px;
    margin-top: 16px;
    padding-top: 24px;
    border-top: 1px dashed #B8A88A;
}

.meta-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.meta-key {
    font-family: 'Nunito', sans-serif;
    font-weight: 600;
    font-size: 12px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #7A7268;
}

.meta-val {
    font-family: 'Fredoka', sans-serif;
    font-weight: 500;
    font-size: 17px;
    color: #4A3728;
}

.hero-right {
    background: #EDE6D8;
    padding: 96px 56px 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.icon-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
    width: 100%;
    max-width: 460px;
}

.icon-cell {
    aspect-ratio: 1 / 1;
    background: rgba(255, 255, 255, 0.55);
    border: 1px solid rgba(184, 168, 138, 0.45);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 14px;
    transition: transform 600ms ease, background 600ms ease, border-color 600ms ease;
    opacity: 0;
    transform: translateY(14px) scale(0.94);
}

.icon-cell.in {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.icon-cell:hover {
    transform: translateY(-4px) rotate(-2deg);
    background: #FFFFFF;
    border-color: #5A8C6F;
}

.icon-cell svg {
    width: 100%;
    height: 100%;
    overflow: visible;
}

.icon-cell .line-thin {
    fill: none;
    stroke: #4A3728;
    stroke-width: 1.5;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* ============== STITCH TRANSITION ============== */
.stitch-transition {
    width: 100%;
    height: 80px;
    overflow: hidden;
    background: transparent;
    position: relative;
    margin: 0;
}

.stitch-svg {
    width: 100%;
    height: 100%;
    display: block;
}

.stitch-path {
    fill: none;
    stroke: #5A8C6F;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-dasharray: 12 6;
    stroke-dashoffset: 0;
}

.stitch-path-mini {
    fill: none;
    stroke: #5A8C6F;
    stroke-width: 1.5;
    stroke-linecap: round;
    stroke-dasharray: 6 4;
}

/* Background continuity for transitions sitting between alternating sections */
.station-light + .stitch-transition,
.stitch-transition.bg-light {
    background: linear-gradient(to bottom, #F7F2EA 50%, #FFFFFF 50%);
}

.station-white + .stitch-transition {
    background: linear-gradient(to bottom, #FFFFFF 50%, #F7F2EA 50%);
}

/* hero -> first station (light) */
.hero + .stitch-transition {
    background: linear-gradient(to bottom, #EDE6D8 50%, #F7F2EA 50%);
}

/* last station -> community board */
.station:last-of-type + .stitch-transition {
    background: linear-gradient(to bottom, #F7F2EA 50%, #F0E5D0 50%);
}

/* ============== STATIONS ============== */
.station {
    width: 100%;
    min-height: 90vh;
    display: flex;
    align-items: center;
    padding: 96px 0;
}

.station-light {
    background: #F7F2EA;
}

.station-white {
    background: #FFFFFF;
}

.station-inner {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 80px;
    display: flex;
    align-items: center;
    gap: 80px;
}

.station[data-side="right"] .station-inner {
    flex-direction: row-reverse;
}

.station-illustration {
    flex: 0 0 60%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.illus-card {
    position: relative;
    width: 100%;
    max-width: 520px;
    aspect-ratio: 1 / 1;
    background: #FFFFFF;
    border: 1px solid #B8A88A;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 56px;
    box-shadow: 0 8px 30px rgba(74, 55, 40, 0.06);
}

.station-white .illus-card {
    background: #F7F2EA;
}

.illus-card::before {
    content: '';
    position: absolute;
    inset: 8px;
    border: 1px dashed rgba(184, 168, 138, 0.55);
    border-radius: 4px;
    pointer-events: none;
}

.illus-tag {
    position: absolute;
    bottom: 16px;
    right: 18px;
    font-family: 'Nunito', sans-serif;
    font-weight: 600;
    font-size: 11px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #7A7268;
}

.big-illus {
    width: 100%;
    height: 100%;
    overflow: visible;
}

.line-thin {
    fill: none;
    stroke: #4A3728;
    stroke-width: 1.5;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.line-thin.dashed {
    stroke-dasharray: 4 3;
    opacity: 0.7;
}

.line-thin.curly {
    stroke-dasharray: 2 3;
}

.line-thin.spark {
    stroke: #E8A46C;
}

.line-thin.steam {
    stroke: #B8A88A;
    opacity: 0.85;
}

.stitch-illus {
    fill: none;
    stroke: #5A8C6F;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-dasharray: 6 4;
}

.station-text {
    flex: 0 0 calc(40% - 80px);
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.station-number {
    font-family: 'Fredoka', sans-serif;
    font-weight: 500;
    font-size: 14px;
    letter-spacing: 0.16em;
    color: #5A8C6F;
}

.station-title {
    font-family: 'Fredoka', sans-serif;
    font-weight: 600;
    font-size: clamp(40px, 5vw, 64px);
    line-height: 1.0;
    color: #4A3728;
    letter-spacing: -0.01em;
}

.station-lede {
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    font-size: 19px;
    line-height: 1.45;
    color: #4A3728;
}

.station-body {
    font-size: 16px;
    line-height: 1.75;
    color: #5C4A3A;
}

.station-list {
    list-style: none;
    margin-top: 8px;
    border-top: 1px dashed #B8A88A;
    padding-top: 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.station-list li {
    position: relative;
    padding-left: 24px;
    font-size: 15px;
    color: #5C4A3A;
}

.station-list li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.65em;
    width: 14px;
    height: 2px;
    background: #5A8C6F;
    border-radius: 2px;
}

/* slide-reveal entrance */
.station .station-illustration,
.station .station-text {
    opacity: 0;
    transition: opacity 700ms ease, transform 900ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.station[data-side="left"] .station-illustration {
    transform: translateX(-60px);
}

.station[data-side="right"] .station-illustration {
    transform: translateX(60px);
}

.station .station-text {
    transform: translateY(20px);
}

.station.in .station-illustration {
    opacity: 1;
    transform: translateX(0);
}

.station.in .station-text {
    opacity: 1;
    transform: translateY(0);
}

/* stitch path-draw (animated when in viewport) */
.stitch-transition .stitch-path {
    stroke-dasharray: 1200;
    stroke-dashoffset: 1200;
    transition: stroke-dashoffset 1200ms ease-out;
}

.stitch-transition.in .stitch-path {
    stroke-dashoffset: 0;
}

/* ============== COMMUNITY BOARD ============== */
.community {
    background: #F0E5D0; /* approximation of D4BC94 @15% over F7F2EA */
    padding: 120px 0 140px;
    position: relative;
}

.community::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(rgba(184, 168, 138, 0.18) 1px, transparent 1px);
    background-size: 5px 5px;
    pointer-events: none;
    opacity: 0.5;
}

.community-inner {
    position: relative;
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 80px;
}

.community-header {
    text-align: center;
    margin-bottom: 64px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: center;
}

.community-title {
    font-family: 'Fredoka', sans-serif;
    font-weight: 600;
    font-size: clamp(36px, 4.5vw, 56px);
    color: #4A3728;
    letter-spacing: -0.01em;
}

.community-sub {
    font-family: 'Kalam', cursive;
    font-weight: 400;
    font-size: 19px;
    color: #5C4A3A;
}

.community-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px 16px;
}

.note-card {
    --rot: 0deg;
    position: relative;
    background: #FFFFFF;
    padding: 34px 22px 22px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
    transform: rotate(var(--rot));
    transition: transform 300ms ease, box-shadow 300ms ease;
    min-height: 180px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    border-radius: 2px;
}

.note-card:hover {
    transform: translateY(-3px) rotate(var(--rot));
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.note-card:hover .pushpin {
    transform: translateX(-50%) scale(1.2);
}

.pushpin {
    position: absolute;
    top: 8px;
    left: 50%;
    width: 10px;
    height: 10px;
    background: #E8A46C;
    border-radius: 50%;
    transform: translateX(-50%);
    box-shadow: 0 1px 2px rgba(74, 55, 40, 0.35);
    transition: transform 300ms ease;
}

.pushpin::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 3px;
    height: 3px;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 50%;
}

.note-title {
    font-family: 'Kalam', cursive;
    font-weight: 700;
    font-size: 19px;
    line-height: 1.25;
    color: #4A3728;
}

.note-body {
    font-family: 'Kalam', cursive;
    font-weight: 400;
    font-size: 15px;
    line-height: 1.5;
    color: #5C4A3A;
    flex: 1;
}

.note-sig {
    font-family: 'Kalam', cursive;
    font-weight: 400;
    font-size: 14px;
    color: #7A7268;
    align-self: flex-end;
}

/* ============== FOOTER ============== */
.site-footer {
    background: #4A3728;
    color: #EDE6D8;
    padding: 64px 0 0;
}

.footer-inner {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 80px 56px;
    display: grid;
    grid-template-columns: 2fr 1fr 1.2fr 1.2fr;
    gap: 48px;
}

.footer-block {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.footer-mark {
    font-family: 'Fredoka', sans-serif;
    font-weight: 600;
    font-size: 24px;
    color: #FFFFFF;
    margin-bottom: 8px;
}

.footer-tag {
    font-family: 'Nunito', sans-serif;
    font-size: 15px;
    line-height: 1.6;
    color: rgba(237, 230, 216, 0.78);
    max-width: 28em;
}

.footer-key {
    font-family: 'Nunito', sans-serif;
    font-weight: 600;
    font-size: 12px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #5A8C6F;
    margin-bottom: 4px;
}

.footer-val {
    font-family: 'Fredoka', sans-serif;
    font-weight: 500;
    font-size: 17px;
    color: #FFFFFF;
}

.footer-val.muted {
    font-size: 14px;
    color: rgba(237, 230, 216, 0.6);
    font-weight: 400;
}

.footer-strip {
    border-top: 1px dashed rgba(237, 230, 216, 0.25);
    padding: 22px 80px 28px;
    max-width: 1280px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    font-family: 'Nunito', sans-serif;
    font-size: 13px;
    letter-spacing: 0.04em;
    color: rgba(237, 230, 216, 0.6);
}

.footer-stitch svg {
    display: block;
}

.footer-strip .stitch-path-mini {
    stroke: #5A8C6F;
    opacity: 0.7;
}

/* ============== RESPONSIVE ============== */
@media (max-width: 1080px) {
    .hero-left, .hero-right { padding: 88px 56px 56px; }
    .station-inner { padding: 0 56px; gap: 56px; }
    .station-text { flex: 0 0 calc(40% - 56px); }
    .community-inner { padding: 0 56px; }
    .footer-inner { padding: 0 56px 56px; grid-template-columns: 1fr 1fr; gap: 40px; }
    .footer-strip { padding: 22px 56px 28px; }
}

@media (max-width: 768px) {
    .nav-inner { padding: 0 20px; }
    .nav-links { gap: 16px; }
    .nav-link { font-size: 11px; letter-spacing: 0.06em; }

    .hero-grid {
        grid-template-columns: 1fr;
    }
    .hero-grid::before {
        display: none;
    }
    .hero-left {
        order: 2;
        padding: 48px 24px 56px;
    }
    .hero-right {
        order: 1;
        min-height: 320px;
        padding: 80px 24px 32px;
        border-bottom: 1px solid #B8A88A;
    }
    .icon-grid { max-width: 360px; gap: 14px; }

    .station {
        min-height: auto;
        padding: 64px 0;
    }
    .station-inner {
        flex-direction: column !important;
        padding: 0 24px;
        gap: 36px;
    }
    .station-illustration,
    .station-text {
        flex: 0 0 100%;
        width: 100%;
    }
    .illus-card { max-width: 380px; padding: 36px; }

    .community {
        padding: 72px 0 88px;
    }
    .community-inner { padding: 0 24px; }
    .community-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .footer-inner {
        padding: 0 24px 48px;
        grid-template-columns: 1fr;
        gap: 32px;
    }
    .footer-strip {
        padding: 22px 24px 28px;
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (max-width: 480px) {
    .nav-links { gap: 10px; }
    .nav-link { font-size: 10px; }
    .nav-brand { font-size: 16px; }
    .hero-title { font-size: 44px; }
    .station-title { font-size: 40px; }
    .icon-grid { grid-template-columns: repeat(3, 1fr); }
}
