@font-face { font-family: 'Gloock'; src: url('/bloem/fonts/gloock-400.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Jost'; src: url('/bloem/fonts/jost.woff2') format('woff2'); font-weight: 400 500; font-display: swap; }
@font-face { font-family: 'Caveat'; src: url('/bloem/fonts/caveat.woff2') format('woff2'); font-weight: 500 700; font-display: swap; }

:root {
  --bg: #fbfaf7; --ink: #1d1d1d; --acc: #e0451f; --acc-text: #c13a17; --line: #e9e5dd; --muted: #6b6660; --tape: #ffd98acc;
  --gut: clamp(16px, 4vw, 40px);
  color-scheme: light;
}
* { box-sizing: border-box; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 17px/1.55 'Jost', system-ui, sans-serif; overflow-x: clip; }
#main { overflow-x: clip; }
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { font-family: 'Gloock', Georgia, serif; font-weight: 400; color: var(--acc); letter-spacing: -.01em; margin: 0; }
.hand { font-family: 'Caveat', cursive; font-weight: 700; color: var(--acc); }
.wrap { max-width: 1120px; margin: 0 auto; padding-inline: var(--gut); }

/* nav */
#nav { position: sticky; top: 0; z-index: 20; background: var(--bg); display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 14px var(--gut); }
#nav .brand { font-family: 'Gloock', serif; color: var(--acc); font-size: 24px; text-decoration: none; }
#nav nav { display: flex; align-items: center; gap: clamp(12px, 2.5vw, 24px); font-size: 15px; }
#nav nav a { text-decoration: none; }
#nav nav a[aria-current="page"] { color: var(--acc-text); text-decoration: underline; text-underline-offset: 5px; }
#nav .lang { border: 1px solid currentColor; border-radius: 99px; padding: 0 10px; font-size: 13px; }

/* footer */
#footer { border-top: 1px solid var(--line); margin-top: 80px; }
.foot { display: flex; flex-wrap: wrap; gap: 24px; padding-block: 28px 40px; font-size: 15px; }

/* page head (career, history, sources) */
.page-head { padding-block: clamp(60px, 10vw, 120px) 30px; }
.page-head h1 { font-size: clamp(52px, 10vw, 120px); line-height: .92; }
.page-head p { max-width: 560px; }

/* polaroid */
.pol { margin: 0; background: #fff; padding: 8px 8px 36px; box-shadow: 0 10px 30px #0002; position: relative; }
.pol img, .pol .ph-empty { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; display: block; }
.pol .ph-empty { background: linear-gradient(160deg, #2a1d33, var(--acc)); }
.pol:nth-of-type(4n+2) .ph-empty { background: linear-gradient(160deg, #f4b860, #4b2a5c); }
.pol:nth-of-type(4n+3) .ph-empty { background: linear-gradient(160deg, #111, #7a4ad6); }
.pol:nth-of-type(4n+4) .ph-empty { background: linear-gradient(160deg, #ffb3a1, #2b6b5e); }
.pol figcaption { position: absolute; inset: auto 0 6px; text-align: center; font: 600 20px/1 'Caveat', cursive; }
.pol::before { content: ''; position: absolute; top: -12px; left: 50%; width: 70px; height: 22px; margin-left: -35px; background: var(--tape); rotate: -4deg; }

/* example label + integrity banner */
.ex { display: inline-block; font: 600 12px/1 'Jost', sans-serif; letter-spacing: .08em; text-transform: uppercase; color: #fff; background: var(--acc-text); border-radius: 99px; padding: 4px 8px; vertical-align: middle; margin-left: 8px; }
.warn { margin-block: 16px; padding-block: 12px; background: #fff3cd; border: 2px dashed #c99a00; font-size: 14px; }
.warn ul { margin: 6px 0 0; padding-left: 20px; }

/* ===== sections (Tasks 3–5) ===== */

/* home: hero */
.hero { position: relative; overflow-x: clip; min-height: clamp(620px, 100vh, 900px); padding: clamp(80px, 14vw, 140px) var(--gut) 120px; text-align: center; }
.hero h1 { font-size: clamp(46px, 8.5vw, 108px); line-height: .95; position: relative; z-index: 3; }
.hero h1 .w { display: inline-block; }
.hero .pol { position: absolute; z-index: 2; width: clamp(110px, 14vw, 190px); }
.hero .hp1 { left: 4%; top: 70px; rotate: -8deg; }
.hero .hp2 { right: 4%; top: 300px; rotate: 7deg; }
.hero .hp3 { left: 16%; top: 520px; rotate: 4deg; }
.hero .hp4 { right: 20%; top: 600px; rotate: -6deg; }
.sticker { position: absolute; right: 12%; top: 90px; z-index: 4; width: 110px; aspect-ratio: 1; border-radius: 50%; background: var(--acc); color: #fff; display: grid; place-items: center; text-align: center; font: 700 24px/.95 'Caveat', cursive; }

/* home: intro */
.intro { display: grid; grid-template-columns: minmax(180px, 320px) 1fr; gap: clamp(24px, 5vw, 64px); align-items: center; padding-block: 40px 100px; font-size: 19px; }
.intro .portrait { rotate: -3deg; }

/* home: marquee bands */
.marquee { overflow: hidden; white-space: nowrap; padding: 14px 0; border-block: 1px solid var(--ink); background: var(--acc); color: #fff; }
.marquee div { display: inline-block; font: 400 clamp(28px, 5vw, 48px)/1.1 'Gloock', serif; }
.marquee.m2 { background: var(--bg); color: var(--acc); border-top: 0; }

/* home: experience + throw stack */
.sec { display: grid; grid-template-columns: 1fr 1.1fr; gap: 30px; align-items: center; padding-block: 110px; }
.sec h2, .block-sec h2 { font-size: clamp(40px, 6vw, 72px); line-height: 1; margin-bottom: 24px; }
.item { margin-bottom: 26px; max-width: 460px; }
.item h3 { font-size: 26px; }
.meta { color: var(--muted); margin: 4px 0 8px; }
.throw { position: relative; min-height: 520px; }
.throw .pol { position: absolute; width: clamp(160px, 20vw, 230px); }
.throw .t1 { right: 10px; top: 10px; rotate: 6deg; }
.throw .t2 { right: 34%; top: 150px; rotate: -7deg; }
.throw .t3 { right: 8%; top: 290px; rotate: 3deg; }
.note { position: absolute; left: 0; top: 20px; font-size: 30px; line-height: 1; rotate: -6deg; }

/* home: skills, education, contact */
.block-sec { padding-block: 70px; }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 20px; }
.card { background: #fff; border-top: 4px solid var(--acc); padding: 20px 22px; }
.card h3 { font-size: 24px; margin-bottom: 6px; }
.cta { display: inline-block; margin-right: 18px; color: var(--acc-text); font-weight: 500; text-decoration-thickness: 2px; text-underline-offset: 5px; }

/* hours teaser + shared hours visuals */
.teaser { padding-block: 90px; }
.bignum { font: 400 clamp(90px, 16vw, 200px)/.85 'Gloock', serif; color: var(--acc); }
.bignum small { font-size: .3em; color: var(--ink); }
.teaser .hand { font-size: 28px; margin: 6px 0 20px; }
.bar { height: 10px; background: var(--line); border-radius: 10px; overflow: hidden; margin: 18px 0 10px; }
.bar i { display: block; height: 100%; width: calc(var(--pct, 0) * 100%); background: var(--acc); border-radius: 10px; transform-origin: left; }

@media (max-width: 720px) {
  .hero .hp3, .hero .hp4 { display: none; }
  .hero .hp1 { top: 30px; left: 4px; } .hero .hp2 { top: auto; bottom: 40px; right: 4px; }
  .sticker { width: 84px; font-size: 19px; right: 6%; top: auto; bottom: 150px; }
  .intro, .sec { grid-template-columns: 1fr; }
  .intro .portrait { max-width: 260px; }
  .throw { min-height: 420px; }
  .throw .pol { width: 46vw; }
}

/* career */
.block { padding-block: 50px 70px; border-top: 1px solid var(--line); }
.block h2 { font-size: clamp(34px, 5vw, 56px); margin-bottom: 10px; }
.block h2 small { font: 400 18px 'Jost', sans-serif; color: var(--muted); margin-left: 10px; }
.table-scroll { overflow-x: auto; margin-top: 24px; }
.hours-table { width: 100%; border-collapse: collapse; font-size: 16px; min-width: 640px; }
.hours-table th { text-align: left; font-weight: 500; color: var(--muted); border-bottom: 2px solid var(--ink); padding: 8px 10px; }
.hours-table td { border-bottom: 1px solid var(--line); padding: 12px 10px; vertical-align: top; }
.hours-table tfoot td { border-bottom: 0; border-top: 2px solid var(--ink); }
.num { text-align: right; white-space: nowrap; }
.muted { color: var(--muted); }
.chip { display: inline-block; font: 500 13px/1 'Jost', sans-serif; border: 1px solid var(--acc-text); color: var(--acc-text); border-radius: 99px; padding: 4px 8px; text-decoration: none; }
.goals { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 24px; }
.goal { background: #fff; padding: 24px; scroll-margin-top: 80px; }
.goal h3 { font-size: 26px; margin-bottom: 8px; }
.goal h4, .activity h4 { font: 500 14px 'Jost', sans-serif; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin: 18px 0 4px; }
.goal-hours { font-size: 26px; margin: 8px 0 4px; }
.activity { display: grid; grid-template-columns: minmax(160px, 280px) 1fr; gap: clamp(20px, 4vw, 48px); padding-block: 48px; border-top: 1px solid var(--line); scroll-margin-top: 80px; }
.act-photos { display: grid; gap: 22px; }
.act-photos .pol:nth-child(odd) { rotate: -3deg; } .act-photos .pol:nth-child(even) { rotate: 3deg; }
.activity h3 { font-size: clamp(26px, 3vw, 34px); margin: 6px 0 10px; }
blockquote { margin: 0; padding: 4px 0 4px 18px; border-left: 4px solid var(--acc); font-style: italic; }
blockquote footer { font-style: normal; color: var(--muted); font-size: 15px; }
@media (max-width: 720px) { .activity { grid-template-columns: 1fr; } .act-photos { max-width: 240px; } }

/* history: own lesson in 90s rave-flyer style (the one loud section) */
.nineties { background: #0b0b0b radial-gradient(#ffffff14 1px, transparent 1px) 0 0 / 6px 6px; color: #f2f2f2; padding-block: 80px 100px; overflow: hidden; }
.nineties h2 { color: #ff2bd6; text-shadow: 3px 3px 0 #c6ff00; font-size: clamp(36px, 6vw, 72px); line-height: 1; margin-bottom: 30px; max-width: 900px; }
.nineties h3 { color: #c6ff00; font: 700 15px 'Jost', sans-serif; letter-spacing: .1em; text-transform: uppercase; margin-top: 28px; }
.n-tag { display: inline-block; background: #c6ff00; color: #000; font-weight: 500; letter-spacing: .1em; text-transform: uppercase; padding: 4px 10px; rotate: -3deg; }
.n-decade { font: 400 clamp(110px, 24vw, 300px)/.8 'Gloock', serif; color: transparent; -webkit-text-stroke: 2px #ff2bd6; margin: 10px 0 20px; }
.n-grid { display: grid; grid-template-columns: 1.2fr 1fr; gap: 40px; }
.n-photos { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-content: start; }
.n-photos .pol { box-shadow: 6px 6px 0 #ff2bd6; } .n-photos .pol:nth-child(2) { rotate: 5deg; margin-top: 40px; }
.n-link { color: #c6ff00; font-weight: 500; }
.nineties .ex { background: #c6ff00; color: #000; }

/* history: timeline */
.timeline { list-style: none; padding: 0; margin: 0; border-left: 3px solid var(--acc); }
.timeline li { display: grid; grid-template-columns: 130px 1fr; gap: 20px; padding: 0 0 36px 24px; position: relative; }
.timeline li::before { content: ''; position: absolute; left: -10px; top: 8px; width: 17px; height: 17px; border-radius: 50%; background: var(--bg); border: 3px solid var(--acc); }
.timeline .is-own::before { background: #ff2bd6; border-color: #c6ff00; }
.timeline .decade { font: 400 34px/1 'Gloock', serif; color: var(--acc); }
.timeline h3 { font-size: 26px; }

/* sources (APA hanging indent) */
.sources { padding-left: 0; list-style: none; max-width: 820px; }
.sources li { padding-left: 2em; text-indent: -2em; margin-bottom: 14px; }

@media (max-width: 720px) { .n-grid { grid-template-columns: 1fr; } .timeline li { grid-template-columns: 1fr; gap: 4px; } }

/* ===== motion (Task 6) ===== */
@media (prefers-reduced-motion: no-preference) {
  /* hero title words fly in on load (time-based; works without scroll-timeline support) */
  .hero h1 .w { animation: var(--a, w-up) .9s cubic-bezier(.2,.8,.2,1) both; }
  .hero h1 .w:nth-of-type(3n+1) { --a: w-left; }
  .hero h1 .w:nth-of-type(3n+2) { --a: w-up; }
  .hero h1 .w:nth-of-type(3n)   { --a: w-right; }
  .hero h1 .w.name { --a: w-down; }
  .hero h1 .w:nth-of-type(1) { animation-delay: 0s; }
  .hero h1 .w:nth-of-type(2) { animation-delay: .09s; }
  .hero h1 .w:nth-of-type(3) { animation-delay: .18s; }
  .hero h1 .w:nth-of-type(4) { animation-delay: .27s; }
  .hero h1 .w:nth-of-type(5) { animation-delay: .36s; }
  .hero h1 .w:nth-of-type(6) { animation-delay: .45s; }
  .hero h1 .w:nth-of-type(7) { animation-delay: .54s; }
  .hero h1 .w:nth-of-type(8) { animation-delay: .63s; }
  @keyframes w-left  { from { translate: -60vw 0; rotate: -20deg; opacity: 0; } }
  @keyframes w-right { from { translate: 60vw 0; rotate: 20deg; opacity: 0; } }
  @keyframes w-up    { from { translate: 0 -200px; scale: 2; opacity: 0; } }
  @keyframes w-down  { from { translate: 0 200px; scale: .3; opacity: 0; } }

  @media (max-width: 720px) {
    @keyframes w-left  { from { translate: -40vw 0; rotate: -15deg; opacity: 0; } }
    @keyframes w-right { from { translate: 40vw 0; rotate: 15deg; opacity: 0; } }
  }

  @supports (animation-timeline: view()) {


    /* hero polaroids + sticker drift and spin away with page scroll */
    .hero .pol, .sticker { animation: var(--p) linear both; animation-timeline: scroll(root); animation-range: 0 120vh; }
    .hero .hp1 { --p: p1; } .hero .hp2 { --p: p2; } .hero .hp3 { --p: p3; } .hero .hp4 { --p: p4; } .sticker { --p: spin; }
    @keyframes p1 { to { translate: -140px -700px; rotate: -30deg; } }
    @keyframes p2 { to { translate: 160px -1000px; rotate: 35deg; } }
    @keyframes p3 { to { translate: -200px -1300px; rotate: 25deg; } }
    @keyframes p4 { to { translate: 220px -1500px; rotate: -40deg; } }
    @keyframes spin { to { rotate: 540deg; translate: 0 -400px; scale: 1.6; } }

    /* marquee bands move with scroll, opposite directions */
    .marquee div { animation: slide linear both; animation-timeline: view(); }
    .marquee.m2 div { animation-name: slide-back; }
    @keyframes slide { from { translate: 0; } to { translate: -50%; } }
    @keyframes slide-back { from { translate: -50%; } to { translate: 0; } }

    /* experience polaroids thrown onto the table */
    .throw .pol { animation: var(--t) cubic-bezier(.2,.9,.25,1.15) both; animation-timeline: view(); animation-range: entry 0% cover 50%; }
    .throw .t1 { --t: throw1; } .throw .t2 { --t: throw2; } .throw .t3 { --t: throw3; }
    @keyframes throw1 { from { translate: 120vw -300px; rotate: 120deg; scale: 1.6; } }
    @keyframes throw2 { from { translate: -120vw 200px; rotate: -140deg; scale: 1.6; } }
    @keyframes throw3 { from { translate: 40vw 900px; rotate: 200deg; scale: 1.8; } }
    .note { animation: pop cubic-bezier(.2,.9,.3,1.6) both; animation-timeline: view(); animation-range: cover 30% cover 45%; }
    @keyframes pop { from { scale: 0; rotate: -40deg; } }

    /* generic reveals */
    .reveal { animation: up ease-out both; animation-timeline: view(); animation-range: entry 0% cover 30%; }
    @keyframes up { from { opacity: 0; translate: 0 80px; } }
    .zoom { animation: zoom cubic-bezier(.2,.8,.2,1) both; animation-timeline: view(); animation-range: entry 0% cover 35%; }
    @keyframes zoom { from { scale: .3; opacity: 0; rotate: -8deg; } }

    /* table rows slide in alternately; bars fill with a bounce */
    .hours-table tbody tr:nth-child(odd)  { animation: from-l ease-out both; animation-timeline: view(); animation-range: entry 0% cover 25%; }
    .hours-table tbody tr:nth-child(even) { animation: from-r ease-out both; animation-timeline: view(); animation-range: entry 0% cover 25%; }
    @keyframes from-l { from { translate: -40px 0; opacity: 0; } }
    @keyframes from-r { from { translate: 40px 0; opacity: 0; } }
    .bar i { animation: fill cubic-bezier(.3,1.4,.5,1) both; animation-timeline: view(); animation-range: entry 30% cover 50%; }
    @keyframes fill { from { transform: scaleX(0); } }

    /* 90s section: decade slams in */
    .n-decade { animation: slam cubic-bezier(.2,1.6,.4,1) both; animation-timeline: view(); animation-range: entry 10% cover 40%; }
    @keyframes slam { from { scale: 3; rotate: -12deg; opacity: 0; } }

    @media (max-width: 720px) {
      @keyframes p1 { to { translate: -60px -500px; rotate: -25deg; } }
      @keyframes p2 { to { translate: 60px -600px; rotate: 25deg; } }
      @keyframes spin { to { rotate: 360deg; translate: 0 -250px; scale: 1.2; } }
    }
  }
}
