/* Edu Balestra — site styles (dark index layout) */
:root {
  --ink: #0E0E0E;
  --paper: #F3F3F1;
  --soft: #D8D8D4;
  --muted: #A8A8A3;
  --muted-light: #4A4A47;
  --line: #3A3A38;
  --panel: #232322;
  --accent: #FF5A1F;   /* change this one value to recolour the site */
  --sans: 'Archivo', 'Helvetica Neue', Arial, sans-serif;
  --serif: 'Instrument Serif', Georgia, serif;
  --wrap: 1360px;
}

:root { color-scheme: dark; }
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--ink); color: var(--paper); font-family: var(--sans); line-height: 1.5; }
img { max-width: 100%; display: block; }
a { color: var(--paper); }
a:hover { color: var(--accent); }
a:focus-visible, button:focus-visible, summary:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding-left: 24px; padding-right: 24px; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; z-index: 100; background: var(--paper); color: var(--ink); padding: 12px 16px; }
.eyebrow { margin: 0; font-size: 13px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.serif { font-family: var(--serif); font-style: italic; font-weight: 400; }
.line { display: block; }
.nowrap { white-space: nowrap; }

/* Header */
.site-header { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; background: rgba(14,14,14,.9); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.site-header .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 24px; padding-top: 14px; padding-bottom: 14px; }
.logo { text-decoration: none; font-weight: 900; font-size: 20px; letter-spacing: -.02em; }
.nav { display: flex; flex-wrap: wrap; align-items: center; gap: 0 22px; font-size: 15px; font-weight: 500; }
.nav a { text-decoration: none; min-height: 44px; display: inline-flex; align-items: center; }
.nav a[aria-current="page"] { text-decoration: underline; text-underline-offset: 6px; text-decoration-color: var(--accent); }
.btn { background: var(--accent); color: var(--ink) !important; padding: 0 18px; border-radius: 999px; font-weight: 700; }
.btn:hover { background: var(--paper); }

/* Hero */
.hero { padding-top: 80px; padding-bottom: 88px; display: flex; flex-wrap: wrap; align-items: flex-start; gap: 64px 96px; }
.hero-main { flex: 3 1 560px; min-width: 0; }
.hero .tagline { margin-top: 48px; }
.hero .creds { flex: 2 1 340px; min-width: 0; padding-top: 8px; }
.creds dl { margin: 0; }
.creds dl > div { border-top: 1px solid var(--line); padding: 18px 0 20px; }
.creds dt { margin: 0 0 6px; font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); }
.creds dd { margin: 0; font-size: 18px; line-height: 1.45; font-weight: 500; }
.contact-card { border-top: 1px solid var(--line); padding-top: 16px; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; gap: 12px 24px; }
.based { margin: 0; font-size: 14px; font-weight: 500; line-height: 1.4; color: var(--paper); }
.based span { display: block; font-size: 13px; font-weight: 400; color: var(--muted); }
.mail { display: flex; flex-direction: column; align-items: flex-end; text-align: right; }
.mail-link { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 700; line-height: 1.4; color: var(--paper); text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: 1.5px; text-underline-offset: 4px; overflow-wrap: anywhere; }
.mail-link:hover { color: var(--accent); }
.copy { margin: 0; padding: 0; border: 0; background: none; color: var(--muted); font: inherit; font-size: 13px; line-height: 1.4; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--line); }
.copy:hover { color: var(--paper); }
.hero-intro { margin: 0 0 28px; font-size: clamp(20px, 2.2vw, 30px); line-height: 1.25; font-weight: 500; color: var(--soft); }
.hero-intro strong { color: var(--paper); font-weight: 700; }
.balance { text-wrap: balance; }
.yes { margin: 0 0 12px; font-size: clamp(24px, 2.4vw, 34px); line-height: 1; color: var(--soft); }
.hero h1 { margin: 0; font-weight: 900; font-size: clamp(36px, calc((100vw - 48px) * 0.105), 56px); line-height: .88; letter-spacing: -.045em; text-transform: uppercase; }
.page-hero h1 { margin: 0; font-weight: 900; font-size: clamp(34px, 11vw, 188px); line-height: .86; letter-spacing: -.045em; text-transform: uppercase; }
.outline { display: block; color: transparent; -webkit-text-stroke: 2px var(--paper); }
@supports not (-webkit-text-stroke: 2px white) { .outline { color: var(--paper); } }
.solid { display: block; white-space: nowrap; color: var(--accent); }
.hero-foot { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 24px; margin-top: 56px; }
.tagline { margin: 0; font-size: clamp(26px, 3vw, 42px); line-height: 1.1; }
.location { margin: 0; font-size: 15px; color: var(--soft); }

/* Work index */
.work { padding-bottom: 104px; }
.work-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 24px; }
.work-head h2 { margin: 0; font-size: 13px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.work-head p { margin: 0; font-size: 22px; color: var(--soft); }
.index { border-bottom: 1px solid var(--line); }
.item { border-top: 1px solid var(--line); }
.item > summary { list-style: none; cursor: pointer; padding: 22px 0; min-height: 88px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 24px; }
.item > summary::-webkit-details-marker { display: none; }
.item .num { flex: 0 0 40px; color: var(--accent); font-size: 14px; font-weight: 700; }
.item .title { flex: 1 1 300px; min-width: 0; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 16px; }
.item .name { font-size: clamp(26px, 3.2vw, 44px); font-weight: 900; letter-spacing: -.03em; line-height: 1; }
.item .brand { font-size: clamp(15px, 1.4vw, 19px); font-weight: 500; color: var(--muted); }
.item .tag { flex: 0 1 240px; font-size: 13px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.item .toggle { flex: 0 0 44px; height: 44px; border: 1.5px solid var(--paper); border-radius: 999px; display: inline-flex; align-items: center; justify-content: center; }
.item .toggle .v { transition: transform .2s ease; transform-origin: center; }
.item[open] .toggle .v { transform: scaleY(0); }
.item > summary:hover .name { color: var(--accent); }
.panel { display: flex; flex-wrap: wrap; gap: 32px 56px; padding: 8px 0 48px; }
.panel-text { flex: 1 1 340px; min-width: 0; display: flex; flex-direction: column; gap: 18px; }
.panel-text h3 { margin: 0; font-weight: 900; font-size: clamp(24px, 2.4vw, 34px); line-height: 1.08; letter-spacing: -.02em; text-wrap: balance; }
.aside { margin: 0; font-size: 24px; line-height: 1.15; color: var(--soft); }
.credit { margin: 0; font-size: 15px; line-height: 1.5; color: var(--muted); }
.panel-media { flex: 1.5 1 440px; min-width: 0; display: flex; flex-direction: column; gap: 12px; }

/* Video slot */
.video { position: relative; aspect-ratio: 16 / 9; background: var(--panel); border-radius: 6px; overflow: hidden; }
.video.vertical { aspect-ratio: 9 / 16; }
.video iframe, .video video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-empty { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; color: var(--soft); text-align: center; padding: 16px; }
.play { width: 64px; height: 64px; border-radius: 999px; background: var(--accent); display: flex; align-items: center; justify-content: center; }
a.video-link { text-decoration: none; color: var(--soft); }
a.video-link:hover .play { transform: scale(1.06); }
.play { transition: transform .15s ease; }
.video-empty span { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.video-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.panel-text h3 .line + .line { margin-top: .35em; }
.reels { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }

/* Images */
.pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.trio { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.trio img { width: 100%; height: auto; border-radius: 6px; background: var(--panel); }
figure { margin: 0; }
figure.missing img { display: none; }
figure.missing::before { content: "Image"; aspect-ratio: 4 / 5; display: flex; align-items: center; justify-content: center; background: var(--panel); border-radius: 6px; color: var(--muted); font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.pair img, .gallery img { width: 100%; height: auto; border-radius: 6px; background: var(--panel); }
figcaption { margin-top: 8px; font-family: var(--serif); font-style: italic; font-size: 18px; color: var(--soft); }
.gallery { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 8px; }
.gallery figure { flex: 0 0 min(78%, 300px); scroll-snap-align: start; }
.gallery-hint { margin: 0; font-size: 13px; color: var(--muted); }

/* Light credentials band */
.light { background: var(--paper); color: var(--ink); }
.light a { color: var(--ink); }

/* Pitch */
.pitch { padding-top: 104px; }
.pitch .eyebrow { color: var(--accent); margin-bottom: 16px; }
.pitch h2 { margin: 0; font-weight: 900; font-size: clamp(32px, 4.6vw, 68px); line-height: 1; letter-spacing: -.035em; max-width: 1050px; text-wrap: balance; }
.pitch p:last-child { margin: 24px 0 0; font-size: clamp(18px, 1.6vw, 22px); line-height: 1.45; max-width: 760px; color: var(--soft); }

/* Contact */
.contact { padding-top: 120px; padding-bottom: 40px; }
.contact .lead { margin: 0 0 16px; font-size: clamp(22px, 2.4vw, 32px); line-height: 1.15; color: var(--soft); max-width: 760px; text-wrap: balance; }
.email { font-weight: 900; font-size: clamp(28px, 6.4vw, 96px); letter-spacing: -.04em; line-height: 1.05; text-decoration-thickness: 4px; text-underline-offset: 10px; text-decoration-color: var(--accent); overflow-wrap: anywhere; }
.footer-bar { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; margin-top: 96px; padding-top: 20px; border-top: 1px solid var(--line); font-size: 14px; color: var(--muted); }
.footer-bar strong { color: var(--paper); font-weight: 900; }

/* About page */
.page-hero { padding-top: 96px; padding-bottom: 64px; }
.page-hero { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 40px 64px; }
.page-hero-text { flex: 3 1 480px; min-width: 0; }
.portrait { flex: 0 1 300px; margin: 0; }
.portrait img { width: 100%; height: auto; aspect-ratio: 3 / 4; object-fit: cover; object-position: 50% 40%; border-radius: 6px; }
.lede { margin: 32px 0 0; font-size: clamp(20px, 2.2vw, 28px); line-height: 1.35; max-width: 860px; color: var(--soft); text-wrap: balance; }
.pills { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 40px; padding: 0; list-style: none; }
.pills li { border: 1.5px solid var(--paper); border-radius: 999px; padding: 8px 14px; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.block { border-top: 1px solid var(--line); padding: 56px 0; display: flex; flex-wrap: wrap; gap: 24px 56px; }
.block > h2 { flex: 1 1 240px; margin: 0; font-weight: 900; font-size: clamp(28px, 2.6vw, 38px); letter-spacing: -.025em; line-height: 1.05; }
.block > .block-body { flex: 3 1 520px; min-width: 0; }
.rows { margin: 0; padding: 0; list-style: none; }
.rows li { display: flex; flex-wrap: wrap; gap: 4px 24px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.rows li:first-child { padding-top: 0; }
.rows .when { flex: 0 0 120px; font-weight: 700; color: var(--accent); font-variant-numeric: tabular-nums; }
.rows .what { flex: 1 1 300px; min-width: 0; color: var(--soft); }
.rows .what strong { display: block; font-size: 19px; color: var(--paper); }
.awards { columns: 3 200px; column-gap: 32px; }
.awards > div { break-inside: avoid; padding-bottom: 20px; }
.awards h3 { margin: 0 0 2px; font-size: 18px; font-weight: 700; color: var(--paper); }
.awards ul { margin: 0; padding: 0; list-style: none; font-size: 15px; line-height: 1.45; color: var(--soft); font-variant-numeric: tabular-nums; }
.block-body .sub { margin: 48px 0 20px; padding-top: 24px; border-top: 1px solid var(--line); font-size: 13px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--accent); }
.sectors { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 28px 32px; }
.sectors h3 { margin: 0 0 6px; font-size: 13px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.sectors p { margin: 0; font-size: 17px; }

@media (max-width: 640px) {
  .hero, .page-hero { padding-top: 56px; padding-bottom: 64px; }
  .nav { gap: 0 16px; font-size: 14px; }
  .creds dd br { display: none; }
  .mail { align-items: flex-start; text-align: left; }
  .hero { gap: 48px; }
  .item .num { flex-basis: 28px; }
  .item .title { flex-basis: 0; flex-grow: 1; }
  .item .tag { order: 3; flex: 1 0 100%; padding-left: 52px; }
  .pair { grid-template-columns: minmax(0, 1fr); }
  .trio { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 75%; overflow-x: auto; scroll-snap-type: x mandatory; }
  .trio figure { scroll-snap-align: start; }
  .reels { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 70%; overflow-x: auto; scroll-snap-type: x mandatory; }
  .reels .video { scroll-snap-align: start; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } .item .toggle .v { transition: none; } }

/* Full-screen viewer */
.zoom { position: relative; display: block; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; border-radius: 6px; }
.zoom img { display: block; }
.zoom-badge { position: absolute; top: 10px; right: 10px; width: 34px; height: 34px; border-radius: 999px; background: rgba(14,14,14,.75); color: var(--paper); display: flex; align-items: center; justify-content: center; opacity: .85; transition: opacity .15s ease, background .15s ease; }
.zoom:hover .zoom-badge, .zoom:focus-visible .zoom-badge { opacity: 1; background: var(--accent); color: var(--ink); }
html.lb-open { overflow: hidden; }
.lightbox { position: fixed; inset: 0; z-index: 100; background: rgba(8,8,8,.98); display: flex; align-items: center; justify-content: center; gap: 12px; padding: max(16px, env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) max(16px, env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); }
.lightbox[hidden] { display: none; }
.lb-figure { margin: 0; flex: 1 1 auto; min-width: 0; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; }
.lb-figure img { max-width: 100%; max-height: calc(100% - 40px); width: auto; height: auto; object-fit: contain; border-radius: 4px; }
.lb-figure figcaption { display: flex; gap: 16px; align-items: baseline; color: var(--soft); font-family: var(--serif); font-style: italic; font-size: 18px; margin: 0; }
.lb-count { font-family: var(--sans); font-style: normal; font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; }
.lightbox button { border: 1.5px solid var(--line); background: rgba(14,14,14,.6); color: var(--paper); border-radius: 999px; width: 48px; height: 48px; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; flex: 0 0 auto; }
.lightbox button:hover { border-color: var(--paper); }
.lightbox button[hidden] { display: none; }
.lb-close { position: absolute; top: max(16px, env(safe-area-inset-top, 0px)); right: max(16px, env(safe-area-inset-right, 0px)); }
@media (max-width: 640px) {
  .lb-nav { position: absolute; bottom: max(16px, env(safe-area-inset-bottom, 0px)); }
  .lb-prev { left: max(16px, env(safe-area-inset-left, 0px)); }
  .lb-next { right: max(16px, env(safe-area-inset-right, 0px)); }
  .lb-figure img { max-height: calc(100% - 120px); }
}
