/* ==========================================================================
   RC51 · Glocal Intersections — Oaxaca 2026
   Design language transposed from the printed programme handout:
   parchment paper, Zapotec step-fret geometry, papel-picado triangle bands,
   constellation lines, teal / burnt orange / rust / gold / plum palette.
   ========================================================================== */

:root{
  --paper:#f2e9d5;
  --paper-2:#f7f1e2;
  --card:#faf5e9;
  --ink:#39352c;
  --ink-strong:#28251f;
  --muted:#6f6752;
  --teal:#2a7f7c;
  --teal-deep:#1e5f5d;
  --orange:#e08a26;
  --rust:#bf4b33;
  --gold:#e0a437;
  --plum:#8e4a72;
  --rose-tint:#f3e2d8;
  --coffee-tint:#dceceb;
  --lunch-tint:#f7e7c8;
  --social-tint:#dfecd7;
  --line:#d8ccae;
  --shadow:0 10px 30px rgba(72,58,32,.14);
  --serif:"Alegreya",Georgia,"Times New Roman",serif;
  --sans:"Lato","Helvetica Neue",Arial,sans-serif;
  --script:"Caveat","Bradley Hand",cursive;
}
html[data-theme="dark"]{
  --paper:#1d2523;
  --paper-2:#222b29;
  --card:#26302e;
  --ink:#e8dfc8;
  --ink-strong:#f4ecd8;
  --muted:#b0a58a;
  --teal:#4fb3ae;
  --teal-deep:#7fd0cb;
  --orange:#eda04a;
  --rust:#e0765c;
  --gold:#e9b95f;
  --plum:#c47ba6;
  --rose-tint:#37302c;
  --coffee-tint:#243634;
  --lunch-tint:#38312256;
  --social-tint:#28362556;
  --line:#3d4a47;
  --shadow:0 10px 30px rgba(0,0,0,.45);
}

*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{
  margin:0;
  font-family:var(--sans);
  font-size:16.5px;
  line-height:1.6;
  color:var(--ink);
  background-color:var(--paper);
  background-image:url("../assets/img/paper.jpg");
  background-size:620px;
}
html[data-theme="dark"] body{background-blend-mode:multiply;background-color:#20302d}

img{max-width:100%;height:auto;display:block}
a{color:var(--teal-deep)}
h1,h2,h3{font-family:var(--serif);color:var(--ink-strong);line-height:1.15;margin:0 0 .4em}
p{margin:.4em 0 .9em}

.skip-link{position:absolute;left:-999px;top:0;background:var(--teal);color:#fff;padding:.6em 1em;z-index:100;border-radius:0 0 8px 0}
.skip-link:focus{left:0}

/* ---------- papel picado band (from the handout's page-bottom border) ---- */
.picado{
  height:26px;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='150' height='26'%3E%3Cpath d='M2 26L15 3l13 23z' fill='%232a7f7c'/%3E%3Cpath d='M32 26L45 3l13 23z' fill='%23e08a26'/%3E%3Cpath d='M62 26L75 3l13 23z' fill='%23bf4b33'/%3E%3Cpath d='M92 26L105 3l13 23z' fill='%23e0a437'/%3E%3Cpath d='M122 26L135 3l13 23z' fill='%238e4a72'/%3E%3C/svg%3E");
  background-repeat:repeat-x;
  background-position:bottom center;
}
.picado-flip{transform:scaleY(-1)}

/* ---------- top bar ------------------------------------------------------ */
.topbar{
  position:sticky;top:0;z-index:50;
  display:flex;align-items:center;gap:1.2rem;
  padding:.55rem clamp(1rem,4vw,2.4rem);
  background:color-mix(in srgb,var(--paper-2) 88%,transparent);
  backdrop-filter:blur(8px);
  border-bottom:1px solid var(--line);
}
.brand{display:flex;align-items:center;gap:.55rem;text-decoration:none;color:var(--ink-strong)}
.brand-mark{width:30px;height:30px;flex:none}
.brand-text{font-family:var(--serif);font-size:1.06rem;white-space:nowrap}
.brand-text strong{color:var(--rust)}
.topnav{display:flex;gap:1.1rem;margin-left:auto;flex-wrap:wrap}
.topnav a{text-decoration:none;color:var(--ink);font-weight:700;font-size:.92rem;letter-spacing:.02em}
.topnav a:hover{color:var(--rust)}
.topbar-actions{display:flex;gap:.4rem}
.icon-btn{
  border:1px solid var(--line);background:var(--card);border-radius:8px;
  font-size:1rem;padding:.3rem .55rem;cursor:pointer;color:var(--ink);
}
.icon-btn:hover{border-color:var(--teal)}

/* ---------- hero ---------------------------------------------------------- */
.hero{position:relative;overflow:hidden}
.hero-net{position:absolute;inset:0;width:100%;height:100%;pointer-events:none}
.hero-medallion{
  position:absolute;width:min(46vw,540px);right:-90px;top:-110px;opacity:.16;
  animation:spin 240s linear infinite;pointer-events:none;
}
@keyframes spin{to{transform:rotate(360deg)}}
.hand{
  position:absolute;font-family:var(--script);font-size:clamp(1.2rem,2.4vw,1.7rem);
  color:var(--muted);transform:rotate(-6deg);pointer-events:none;opacity:.65;z-index:0;
}
.hand-1{top:14%;left:4%}
.hand-2{top:8%;right:34%;transform:rotate(4deg)}
.hand-3{bottom:6%;left:3%;transform:rotate(-8deg)}
.hand-4{bottom:26%;right:4%;transform:rotate(5deg)}

.hero-inner{
  position:relative;z-index:1;display:flex;gap:clamp(1.5rem,5vw,4rem);align-items:center;
  max-width:1150px;margin:0 auto;padding:clamp(2.5rem,7vw,5rem) clamp(1rem,4vw,2.4rem) 3.5rem;
}
.hero-copy{flex:1.25;min-width:0}
.kicker{
  font-size:.82rem;font-weight:700;letter-spacing:.14em;text-transform:uppercase;margin:0 0 .6rem;
}
.kicker-rust{color:var(--rust)}
.kicker-teal{color:var(--teal)}
.kicker-orange{color:var(--orange)}
.kicker-plum{color:var(--plum)}
.hero-title{
  font-size:clamp(3rem,8vw,5.4rem);font-weight:800;color:var(--rust);margin:.05em 0 .15em;
}
.hero-title span{color:var(--orange)}
.hero-sub{font-family:var(--serif);font-size:1.25rem;margin:.2em 0;color:var(--ink-strong)}
.hero-meta{color:var(--muted);margin:.2em 0 1em}
.hero-countdown{font-family:var(--script);font-size:1.5rem;color:var(--teal-deep);margin:.1em 0 1.1em;min-height:1.2em}
.hero-cta{display:flex;gap:.8rem;flex-wrap:wrap;margin-bottom:1.6rem}

.btn{
  display:inline-block;border-radius:10px;padding:.65rem 1.2rem;font-weight:700;font-family:var(--sans);
  text-decoration:none;font-size:.95rem;border:2px solid transparent;cursor:pointer;
}
.btn-primary{background:var(--teal);color:#fff}
.btn-primary:hover{background:var(--teal-deep);color:#fff}
html[data-theme="dark"] .btn-primary{color:#10201e}
.btn-ghost{border-color:var(--rust);color:var(--rust);background:transparent}
.btn-ghost:hover{background:var(--rust);color:var(--paper)}
.btn-small{font-size:.83rem;padding:.42rem .8rem;border:1px solid var(--line);background:var(--card);color:var(--ink);border-radius:8px}
.btn-small:hover{border-color:var(--teal)}
.btn-small[aria-pressed="true"]{border-color:var(--teal);background:var(--teal);color:#fff}
html[data-theme="dark"] .btn-small[aria-pressed="true"]{color:#10201e}

.hero-stats{display:flex;gap:1.6rem;flex-wrap:wrap;list-style:none;margin:0;padding:0}
.hero-stats li{display:flex;flex-direction:column;line-height:1.15}
.hero-stats strong{font-family:var(--serif);font-size:1.7rem;color:var(--ink-strong)}
.hero-stats span{font-size:.8rem;text-transform:uppercase;letter-spacing:.08em;color:var(--muted)}

.hero-poster{flex:.9;margin:0;max-width:360px;min-width:230px}
.hero-poster img{
  border:10px solid var(--card);box-shadow:var(--shadow);border-radius:4px;
  transform:rotate(1.6deg);
}
.hero-poster figcaption{font-size:.8rem;color:var(--muted);text-align:center;margin-top:.7rem;font-style:italic}

/* ---------- sections ------------------------------------------------------ */
.section{max-width:1150px;margin:0 auto;padding:clamp(2.2rem,6vw,4rem) clamp(1rem,4vw,2.4rem)}
.section-head{position:relative;border-left:6px solid var(--teal);padding-left:1rem;margin-bottom:1.6rem}
.section-head h2{font-size:clamp(1.9rem,4.5vw,2.6rem);margin:0}
.section-head .kicker{margin-bottom:.2rem}
.sub-head{margin-top:3rem}
.constellation{
  position:absolute;right:0;top:-8px;width:150px;color:var(--muted);opacity:.55;fill:currentColor;
}
.lede{max-width:62ch}

.pill{
  display:inline-block;font-size:.74rem;font-weight:700;letter-spacing:.1em;text-transform:uppercase;
  color:#fff;border-radius:999px;padding:.28em 1em;margin-bottom:.6rem;
}
html[data-theme="dark"] .pill{color:#10201e}
.pill-teal{background:var(--teal)}
.pill-orange{background:var(--orange)}
.pill-rust{background:var(--rust)}
.pill-plum{background:var(--plum)}
.pill-standalone{margin:1.6rem 0 1rem}

.card{
  background:var(--card);border:1px solid var(--line);border-radius:14px;
  padding:1.2rem 1.4rem;box-shadow:0 2px 10px rgba(72,58,32,.06);
}
.note-card{margin:0 0 1.4rem}
.note-card p{margin:.3em 0 0}
.muted{color:var(--muted)}

.grid-2{display:grid;grid-template-columns:repeat(auto-fit,minmax(300px,1fr));gap:1.2rem;margin-bottom:1.2rem}
.grid-3{display:grid;grid-template-columns:repeat(auto-fill,minmax(270px,1fr));gap:1.2rem;margin-bottom:1.2rem}
.grid-4{display:grid;grid-template-columns:repeat(auto-fit,minmax(210px,1fr));gap:1.2rem;margin-bottom:1.2rem}

/* ---------- timetable ----------------------------------------------------- */
.live-banner{
  margin:0 0 1rem;padding:.7rem 1.1rem;border-radius:12px;
  background:var(--teal);color:#fff;font-weight:700;
  display:flex;align-items:center;gap:.6rem;
}
.live-banner[hidden]{display:none}
html[data-theme="dark"] .live-banner{color:#10201e}
.live-dot{width:10px;height:10px;border-radius:50%;background:#ffdf6b;flex:none;animation:pulse 1.6s ease-in-out infinite}
@keyframes pulse{50%{opacity:.25}}

.toolbar{margin-bottom:1.6rem}
.daytabs{display:flex;gap:.5rem;flex-wrap:wrap;margin-bottom:.9rem}
.daytab{
  border:1px solid var(--line);background:var(--card);border-radius:12px;cursor:pointer;
  padding:.5rem 1rem;text-align:left;color:var(--ink);font-family:var(--sans);
}
.daytab strong{display:block;font-family:var(--serif);font-size:1.05rem;color:var(--ink-strong)}
.daytab span{font-size:.74rem;color:var(--muted);text-transform:uppercase;letter-spacing:.06em}
.daytab.is-on{background:var(--teal);border-color:var(--teal)}
.daytab.is-on strong,.daytab.is-on span{color:#fff}
html[data-theme="dark"] .daytab.is-on strong,html[data-theme="dark"] .daytab.is-on span{color:#10201e}
.daytab .today-flag{display:inline-block;background:var(--gold);color:#3a2c07;font-size:.62rem;border-radius:6px;padding:0 .45em;margin-left:.4em;letter-spacing:.05em}

.toolbar-row{display:flex;gap:.8rem;flex-wrap:wrap;align-items:center}
.search-wrap{
  display:flex;align-items:center;gap:.5rem;background:var(--card);border:1px solid var(--line);
  border-radius:10px;padding:.4rem .8rem;flex:1;min-width:230px;color:var(--muted);
}
.search-wrap svg{width:16px;height:16px;flex:none}
.search-wrap input{
  border:none;background:transparent;outline:none;font-size:.95rem;width:100%;
  color:var(--ink);font-family:var(--sans);
}
.chips{display:flex;gap:.4rem;flex-wrap:wrap}
.chip{
  border:1px solid var(--line);background:var(--card);color:var(--ink);border-radius:999px;
  padding:.35rem .9rem;font-size:.83rem;font-weight:700;cursor:pointer;
}
.chip.is-on{background:var(--rust);border-color:var(--rust);color:#fff}
html[data-theme="dark"] .chip.is-on{color:#10201e}
.toolbar-actions{display:flex;gap:.5rem;flex-wrap:wrap}
.tz-hint{font-size:.83rem;color:var(--muted);margin:.6rem 0 0}

.day-section{margin-bottom:1rem}
.day-title{
  display:flex;align-items:baseline;gap:.8rem;flex-wrap:wrap;
  border-left:6px solid var(--rust);padding-left:1rem;margin:1.8rem 0 .4rem;
}
.day-title h3{font-size:clamp(1.4rem,3.4vw,1.9rem);margin:0}
.day-title .venue-tag{font-size:.82rem;color:var(--muted)}
.day-title .venue-tag a{color:inherit}

.rows{list-style:none;margin:1rem 0 0;padding:0;border:1px solid var(--line);border-radius:14px;overflow:hidden;background:var(--card)}
.row{
  display:grid;grid-template-columns:130px minmax(0,1fr) auto;gap:0 1rem;align-items:center;
  padding:.65rem 1rem;border-top:1px solid var(--line);
}
.rows .row:first-child{border-top:none}
.row-time{
  font-weight:700;font-size:.9rem;color:var(--ink-strong);white-space:nowrap;
  display:flex;flex-direction:column;line-height:1.3;
}
.row-time .t2{font-weight:400;color:var(--muted);font-size:.78rem}
.row-main{min-width:0}
.row-title{font-weight:700;color:var(--ink-strong)}
.row-authors{font-style:italic;color:var(--muted);font-size:.9rem}
.row-note{font-size:.8rem;color:var(--rust);font-weight:700;text-align:right;max-width:180px}
.row-side{display:flex;align-items:center;gap:.45rem;justify-content:flex-end}

.badge{font-size:.78rem;font-weight:700;white-space:nowrap}
.badge-onsite{color:var(--orange)}
.badge-online{color:var(--teal)}

.row-talk{background:color-mix(in srgb,var(--rose-tint) 46%,var(--card))}
.row-talk:nth-child(even){background:var(--card)}
.row-break{background:var(--coffee-tint);font-weight:700}
.row-lunch{background:var(--lunch-tint);font-weight:700}
.row-social{background:var(--social-tint)}
.row-social .row-title{color:var(--teal-deep)}
.row-admin{background:var(--card)}

.row.is-live{outline:2px solid var(--teal);outline-offset:-2px}
.live-chip,.next-chip{
  display:inline-block;font-size:.66rem;font-weight:700;letter-spacing:.08em;border-radius:6px;
  padding:.1em .55em;margin-left:.5em;vertical-align:2px;
}
.live-chip{background:var(--rust);color:#fff}
.next-chip{background:var(--gold);color:#3a2c07}

.session-banner{
  background:var(--plum);color:#fff;padding:.8rem 1.1rem;
}
.session-banner .sb-kicker{
  font-size:.68rem;letter-spacing:.14em;text-transform:uppercase;opacity:.85;display:block;
}
.session-banner .sb-title{font-family:var(--serif);font-size:1.18rem;font-weight:700;line-height:1.25}
html[data-theme="dark"] .session-banner{color:#f7efe0}
.row.in-session{box-shadow:inset 5px 0 0 var(--plum)}

.iconbtn{
  border:none;background:transparent;cursor:pointer;font-size:1.02rem;line-height:1;
  padding:.25rem;border-radius:6px;color:var(--muted);
}
.iconbtn:hover{background:color-mix(in srgb,var(--teal) 14%,transparent)}
.star-btn[aria-pressed="true"]{color:var(--gold)}
.star-btn[aria-pressed="true"]::after{content:""}

.day-hidden{display:none}
.row-hidden{display:none}
.searching .daytabs,.mine-mode .daytabs{opacity:.35;pointer-events:none}
.results-note{font-size:.86rem;color:var(--muted);margin:.6rem 0 0}
.no-results{padding:1rem;color:var(--muted);font-style:italic}

/* ---------- venues / reception ------------------------------------------- */
.venue-card{padding:0;overflow:hidden;display:flex;flex-direction:column}
.venue-card img{width:100%;aspect-ratio:3/2;object-fit:cover}
.venue-body{padding:1.1rem 1.3rem}
.venue-body h3{color:var(--teal-deep)}
.maplink{font-size:.85rem;font-weight:700;text-decoration:none;color:var(--rust)}
.maplink:hover{text-decoration:underline}

.reception-card{display:flex;gap:1.4rem;align-items:flex-start}
.clock-badge{
  flex:none;width:110px;height:110px;border-radius:50%;background:var(--plum);color:#fff;
  display:flex;flex-direction:column;align-items:center;justify-content:center;line-height:1.1;
}
.clock-badge strong{font-size:1.6rem;font-family:var(--serif)}
.clock-badge span{font-size:.68rem;text-transform:uppercase;letter-spacing:.12em;opacity:.85}
.reception-card h3{color:var(--teal-deep)}

/* ---------- guide cards ---------------------------------------------------- */
.photo-card,.feature-card,.transport-card{padding:0;overflow:hidden}
.photo-card img{width:100%;aspect-ratio:16/10;object-fit:cover}
.feature-card img{width:100%;aspect-ratio:16/9;object-fit:cover}
.transport-card img{width:100%;aspect-ratio:16/9;object-fit:cover}
.photo-body{padding:1rem 1.2rem}
.photo-body h3{font-size:1.15rem;color:var(--rust)}
.feature-card .photo-body h3{color:var(--orange);font-size:1.35rem}

.cuisine-card{margin-top:1.4rem}
.cuisine-flex{display:flex;gap:1.6rem;align-items:flex-start;flex-wrap:wrap}
.cuisine-flex>div{flex:1.2;min-width:260px}
.cuisine-flex img{flex:1;min-width:240px;max-width:380px;border-radius:10px}
.dot-list{list-style:none;padding:0;margin:.4rem 0;columns:1}
.dot-list li{margin:.35rem 0;display:flex;align-items:baseline;gap:.6rem}
.dot{width:10px;height:10px;border-radius:50%;flex:none;transform:translateY(1px)}
.dot-rust{background:var(--rust)}
.dot-orange{background:var(--orange)}
.dot-teal{background:var(--teal)}
.dot-plum{background:var(--plum)}
.veg-band{
  margin:1.2rem 0 0;background:var(--social-tint);border-radius:10px;padding:.7rem 1.1rem;font-weight:700;
}

/* ---------- practical ------------------------------------------------------ */
.info-card{border-left-width:6px;border-left-style:solid;border-radius:10px}
.info-card h3{font-size:1.1rem;color:var(--ink-strong);margin-bottom:.2em}
.info-card p{margin:0;font-size:.93rem}
.bar-rust{border-left-color:var(--rust)}
.bar-teal{border-left-color:var(--teal)}
.bar-gold{border-left-color:var(--gold)}
.bar-plum{border-left-color:var(--plum)}

.diamond-list{list-style:none;margin:0 0 1rem;padding:0}
.diamond-list li{display:flex;align-items:baseline;gap:.7rem;margin:.5rem 0}
.diamond{width:11px;height:11px;flex:none;transform:rotate(45deg) translateY(1px)}
.diamond-teal{background:var(--teal)}
.diamond-orange{background:var(--orange)}
.diamond-rust{background:var(--rust)}
.diamond-plum{background:var(--plum)}

.farewell{text-align:center;max-width:640px;margin:3rem auto 0}
.farewell-title{font-family:var(--serif);color:var(--orange);font-size:clamp(1.8rem,4.5vw,2.5rem)}
.farewell p{color:var(--ink)}

/* ---------- footer --------------------------------------------------------- */
.footer{background:var(--paper-2);border-top:1px solid var(--line);margin-top:2rem}
.footer .picado-flip{margin-top:-1px}
.footer-inner{max-width:1150px;margin:0 auto;padding:2.4rem clamp(1rem,4vw,2.4rem) 2.8rem;text-align:center}
.footer-title{font-family:var(--serif);font-size:1.7rem;color:var(--teal-deep);font-weight:700;margin:0}
.footer-meta{color:var(--muted);margin:.2em 0 1.4em}
.credits{display:flex;justify-content:center;gap:2.4rem;flex-wrap:wrap;margin-bottom:1.4rem}
.credits div{display:flex;flex-direction:column;line-height:1.35}
.credit-role{font-size:.72rem;text-transform:uppercase;letter-spacing:.12em;color:var(--muted)}
.credit-name{font-family:var(--serif);font-size:1.12rem;color:var(--ink-strong);font-weight:700}
.orgs{font-size:.85rem;color:var(--muted)}
.footer-links{font-size:.88rem;margin-top:1rem}

/* ---------- responsive ------------------------------------------------------ */
@media (max-width:860px){
  .hero-inner{flex-direction:column-reverse;text-align:center}
  .hero-poster{max-width:250px}
  .hero-cta,.hero-stats{justify-content:center}
  .hero-medallion{right:-130px;top:auto;bottom:-120px}
  .topnav{display:none}
  .reception-card{flex-direction:column;align-items:center;text-align:center}
  .constellation{display:none}
}
@media (max-width:640px){
  .row{grid-template-columns:1fr;gap:.15rem}
  .row-time{flex-direction:row;gap:.6rem;align-items:baseline}
  .row-side{justify-content:flex-start}
  .row-note{text-align:left;max-width:none}
}

/* ---------- motion --------------------------------------------------------- */
@media (prefers-reduced-motion:reduce){
  .hero-medallion{animation:none}
  .live-dot{animation:none}
  html{scroll-behavior:auto}
}

/* ---------- print ----------------------------------------------------------- */
@media print{
  .topbar,.toolbar,.hero-cta,.hero-net,.hero-medallion,.hand,.iconbtn,
  .picado,.live-banner,.maplink,.footer-links,.skip-link{display:none !important}
  body{background:#fff;color:#000;font-size:11.5px}
  .card,.rows{box-shadow:none}
  .day-hidden{display:block}
  .row-hidden{display:grid}
  .hero-inner{padding:1rem}
  .hero-poster{display:none}
  .section{padding:1rem 0}
  .row{break-inside:avoid}
  .day-section{break-before:auto}
  a{text-decoration:none;color:#000}
}
