/* Ethereal Confections tickets, dressed like the chocolate shop (etherealconfections.com, Shopify "Prestige"):
   white pages, navy ink, Playfair Display for headings and names, Source Sans for reading, Montserrat in spaced
   capitals for the menu and buttons, square corners, and a navy footer with a gold button. */
:root {
  --paper: #ffffff;
  --surface: #f5f5f6;
  --card: #ffffff;
  --ink: #111a2e;        /* the shop's text colour */
  --navy: #0e1b33;       /* the shop's buttons, announcement bar and footer */
  --navy-hover: #1f2d4a;
  --soft: #5d6372;       /* secondary text: 6:1 on white */
  --line: #dbdde0;       /* the shop's hairlines */
  --field: #c3c7ce;      /* input borders */
  --gold: #e8c56b;       /* the shop's footer button */
  --alarm: #cb2b2b;      /* the shop's error text */
  --good: #307a07;       /* the shop's success text */
  --on-navy: rgba(255, 255, 255, .7);
  --serif: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --sans: 'Source Sans 3', 'Source Sans Pro', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  --ui: Montserrat, 'Helvetica Neue', Helvetica, Arial, sans-serif;
  --gutter: 16px;
  --top: 72px;           /* header height, for the sticky panel and jump links */
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--top) + 12px); }
body { margin: 0; background: var(--paper); color: var(--ink); font: 17px/1.65 var(--sans); }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2 { font-family: var(--serif); font-weight: 400; line-height: 1.2; margin: 0; text-wrap: balance; }
p { margin: 0 0 1em; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--navy); color: #fff; padding: 8px 14px; z-index: 20; }
.skip:focus { left: 8px; }

/* ── Header ─────────────────────────────────────────────────────────────── */
.top { position: sticky; top: 0; z-index: 6; background: #fff; border-bottom: 1px solid var(--line); }
.top-in { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 12px 24px; max-width: 1440px; margin: 0 auto; padding: 0 var(--gutter); min-height: var(--top); }
.brand { display: inline-flex; align-items: center; text-decoration: none; justify-self: start; }
.brand-logo { width: auto; height: 44px; }
.top-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 34px; }
.top-links a { font: 500 13px/1.6 var(--ui); letter-spacing: .2em; text-transform: uppercase; text-decoration: none; padding: 6px 0; border-bottom: 1px solid transparent; }
.top-links a:hover { border-bottom-color: var(--line); }
.top-links a[aria-current] { border-bottom-color: var(--ink); }
.menu-btn { display: none; padding: 10px 16px; border: 1px solid var(--ink); border-radius: 0; background: transparent; color: var(--ink); font: 600 12px/1 var(--ui); letter-spacing: .2em; text-transform: uppercase; cursor: pointer; }
@media (max-width: 1099px) {
  /* Too narrow for the links in a row: they sit behind a Menu button. Without scripts they simply show, wrapped. */
  .top-in { flex-wrap: wrap; padding-top: 10px; padding-bottom: 10px; }
  .js .top-in { flex-wrap: nowrap; padding-top: 0; padding-bottom: 0; }
  .js .menu-btn { display: inline-flex; }
  .js .top-links { display: none; position: absolute; left: 0; right: 0; top: 100%; flex-direction: column; gap: 0; padding: 4px var(--gutter) 12px; background: #fff; border-bottom: 1px solid var(--line); box-shadow: 0 16px 24px rgba(17, 26, 46, .08); }
  .js .top-links.is-open { display: flex; }
  .js .top-links a { padding: 15px 0; border-bottom: 1px solid var(--line); }
  .js .top-links a:last-child { border-bottom: 0; }
  .js .top-links a[aria-current] { font-weight: 600; }
}
@media (min-width: 1100px) {
  :root { --top: 104px; }
  /* Logo left, menu in the middle, as on the shop. */
  .top-in { display: grid; grid-template-columns: 1fr auto 1fr; padding: 0 40px; }
  .brand-logo { height: 66px; }
}

/* ── Footer: navy, three columns ─────────────────────────────────────────── */
.foot { margin-top: 88px; background: var(--navy); color: var(--on-navy); }
.foot-in { display: grid; gap: 40px; max-width: 1440px; margin: 0 auto; padding: 56px var(--gutter) 24px; }
.foot-head { margin: 0 0 14px; font: 400 15.6px/1.4 var(--serif); color: #fff; }
.foot p { margin: 0 0 8px; }
.foot a { color: var(--on-navy); text-decoration: none; }
.foot a:hover { color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.foot-links { list-style: none; margin: 0; padding: 0; }
.foot-links li { margin: 0 0 6px; }
.foot-copy { max-width: 1440px; margin: 0 auto; padding: 24px var(--gutter) 32px; font-size: 13px; }
.foot :focus-visible { outline-color: var(--gold); }
@media (min-width: 760px) {
  .foot-in { grid-template-columns: 1.3fr 1fr 1fr; padding: 64px 40px 32px; }
  .foot-copy { padding-left: 40px; padding-right: 40px; }
}

/* "Hear about events first", in the footer, like the shop's "Letters from the Square" */
.signup { scroll-margin-top: calc(var(--top) + 16px); }
.signup-form { display: flex; flex-direction: column; gap: 12px; margin-top: 16px; max-width: 22rem; }
.signup-form input[type=email] { width: 100%; height: 50px; padding: 0 13px; border: 1px solid #323d52; border-radius: 0; background: transparent; color: #fff; font: 17px/1.2 var(--sans); }
.signup-form input[type=email]::placeholder { color: rgba(255, 255, 255, .55); }
.signup-form input[type=email]:focus { outline: none; border-color: var(--gold); }
.signup-form .btn { align-self: flex-start; }
.signup-label, .signup-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.signup-msg { margin: 12px 0 0; color: #fff; font-weight: 600; min-height: 1.5em; }
.signup-msg:empty { display: none; }
.signup.is-done .signup-form { display: none; }

/* ── Buttons and small labels ───────────────────────────────────────────── */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 15px 28px; border: 1px solid var(--navy); border-radius: 0; background: var(--navy); color: #fff; font: 600 13px/1.3 var(--ui); letter-spacing: .18em; text-transform: uppercase; text-decoration: none; cursor: pointer; }
.btn:hover { background: var(--navy-hover); border-color: var(--navy-hover); }
.btn[disabled] { opacity: .45; cursor: default; }
.btn-big { width: 100%; padding: 18px 28px; font-size: 14px; }
.btn-quiet { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn-quiet:hover { background: var(--surface); border-color: var(--ink); }
.btn-gold { background: var(--gold); border-color: var(--gold); color: var(--navy); }
.btn-gold:hover { background: #f0d48c; border-color: #f0d48c; }
.flag { display: inline-block; padding: 4px 8px; background: var(--gold); color: var(--navy); font: 600 11px/1.3 var(--ui); letter-spacing: .12em; text-transform: uppercase; white-space: nowrap; }
.flag.is-sold { background: #efefef; color: rgba(0, 0, 0, .65); }

/* ── The list ───────────────────────────────────────────────────────────── */
.list, .event { max-width: 1200px; margin: 0 auto; padding: 0 var(--gutter); }
.intro { padding: 40px 0 12px; max-width: 44rem; margin: 0 auto; text-align: center; }
.intro h1 { font-size: clamp(1.9rem, 5.6vw, 2.6rem); }
.lede { margin: 14px auto 0; color: var(--soft); font-size: 1.06rem; max-width: 36rem; }
.note { margin: 0 0 22px; padding: 12px 16px; background: var(--surface); border-left: 3px solid var(--navy); font-weight: 600; text-align: left; }

.month { margin-top: 44px; }
.month-name { font-size: clamp(1.45rem, 4.4vw, 1.75rem); padding-bottom: 12px; border-bottom: 1px solid var(--ink); }
.rows { list-style: none; margin: 0; padding: 0; }
.row { border-bottom: 1px solid var(--line); }
.row-link { display: grid; grid-template-columns: 3rem minmax(0, 1fr) 5.6rem; grid-template-areas: "day what pic" "day go pic"; column-gap: 16px; row-gap: 12px; align-items: start; padding: 20px 0; text-decoration: none; }
.row-day { grid-area: day; display: flex; flex-direction: column; align-items: flex-start; }
.row-dow { font: 500 11px/1.4 var(--ui); letter-spacing: .18em; text-transform: uppercase; color: var(--soft); }
.row-num { font-family: var(--serif); font-weight: 400; font-size: clamp(2.1rem, 9vw, 2.9rem); line-height: 1; font-variant-numeric: lining-nums; }
.row-pic { grid-area: pic; aspect-ratio: 4 / 5; overflow: hidden; background: var(--surface); }
.row-pic img { width: 100%; height: 100%; object-fit: cover; }
.row-pic.is-whole img { object-fit: contain; }
.row-pic.is-empty { background: var(--surface) linear-gradient(135deg, transparent 49%, var(--line) 49% 51%, transparent 51%); }
.row-what { grid-area: what; display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.row-name { font-family: var(--serif); font-weight: 400; font-size: 1.2rem; line-height: 1.3; overflow-wrap: anywhere; }
.row-when { color: var(--soft); font-size: .95rem; line-height: 1.45; }
.row-cost { display: flex; align-items: center; gap: 10px; margin-top: 4px; }
.row-price { font-family: var(--serif); font-size: 1.02rem; }
.row-go { grid-area: go; justify-self: start; padding: 11px 18px; background: var(--navy); color: #fff; font: 600 11.5px/1.3 var(--ui); letter-spacing: .16em; text-transform: uppercase; white-space: nowrap; }
.row.is-sold .row-name, .row.is-sold .row-num { color: var(--soft); }
.row.is-sold .row-pic img { filter: grayscale(1); opacity: .7; }
.row.is-sold .row-go { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.row-link:hover .row-name { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; }
.row-link:hover .row-go { background: var(--navy-hover); }
.row.is-sold .row-link:hover .row-go { background: var(--surface); }

.empty { margin: 36px auto 0; padding: 32px 24px; background: var(--surface); max-width: 40rem; text-align: center; }
.empty h2 { font-size: 1.5rem; margin-bottom: 10px; }

@media (min-width: 760px) {
  :root { --gutter: 28px; }
  .intro { padding-top: 56px; }
  .row-link { grid-template-columns: 5rem 12rem minmax(0, 1fr) auto; grid-template-areas: "day pic what go"; column-gap: 28px; align-items: center; padding: 24px 0; }
  .row-pic { aspect-ratio: 4 / 3; }
  .row-name { font-size: 1.45rem; }
  .row-when { font-size: 1rem; }
  .row-go { justify-self: end; padding: 14px 24px; font-size: 12.5px; }
  .row-num { font-size: 3.2rem; }
}

/* ── The calendar, framed ───────────────────────────────────────────────── */
.cal-page { max-width: 1200px; margin: 0 auto; padding: 0 var(--gutter); }
.cal-page .lede a { color: var(--ink); text-underline-offset: 3px; }
.cal-frame { display: block; width: 100%; min-height: 900px; margin-top: 28px; border: 0; background: var(--paper); }

/* ── One event ──────────────────────────────────────────────────────────── */
.back { display: inline-block; margin: 24px 0 16px; font: 500 11.5px/1.4 var(--ui); letter-spacing: .16em; text-transform: uppercase; color: var(--soft); text-underline-offset: 4px; }
.event-pic { margin: 22px 0 0; overflow: hidden; background: var(--surface); }
.event-pic img { width: 100%; max-height: min(54vh, 34rem); object-fit: cover; }
.event-pic.is-whole img { object-fit: contain; }
.event h1 { font-size: clamp(1.9rem, 5.6vw, 2.6rem); }
.event-when { margin: 14px 0 2px; font-size: 1.12rem; }
.event-when time { font-weight: 600; }
.event-when span::before { content: ", "; }
.event-where { color: var(--soft); margin-bottom: 10px; }
.event-where a { text-underline-offset: 3px; }
.event-jump { display: flex; align-items: center; gap: 12px; margin: 0; }
.event-price { font-family: var(--serif); font-size: 1.1rem; }
.event-text { max-width: 62ch; margin-top: 24px; padding-top: 24px; border-top: 1px solid var(--line); }
.more { margin-top: 64px; }
.more-head { font-size: 1.6rem; }
.more .month { margin-top: 22px; }

.buy { margin-top: 30px; padding: 24px 20px 26px; background: var(--card); border: 1px solid var(--line); scroll-margin-top: calc(var(--top) + 12px); }
.buy h2 { font-size: 1.5rem; margin-bottom: 14px; }
.buy-each { color: var(--soft); margin: 0 0 16px; }
.qty { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 6px; }
.qty-label { font-weight: 600; }
.qty-box { display: inline-flex; align-items: center; gap: 4px; }
.qty-btn { width: 44px; height: 44px; border-radius: 0; border: 1px solid var(--field); background: #fff; color: var(--ink); font-size: 1.3rem; line-height: 1; cursor: pointer; }
.qty-btn:hover:not([disabled]) { border-color: var(--ink); }
.qty-btn[disabled] { opacity: .4; cursor: default; }
.qty-n { min-width: 2.4ch; text-align: center; font-family: var(--serif); font-size: 1.6rem; }

.ask { border: 0; padding: 0; margin: 0 0 16px; }
.ask legend { font-weight: 600; padding: 0; margin-bottom: 6px; }
.ask-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 8px 0; border-top: 1px solid var(--line); }
.ask-pick { justify-content: flex-start; }
.ask-pick input { width: 20px; height: 20px; accent-color: var(--navy); }
.ask-cost { color: var(--soft); font-size: .93rem; white-space: nowrap; }
.buy .ask-row input[type=number] { width: 4.6rem; flex: none; text-align: center; padding: 0 6px; }
.ask-row > span { min-width: 0; }

.sum { margin: 16px 0 20px; padding: 14px 0 0; border-top: 1px solid var(--line); }
.sum div { display: flex; justify-content: space-between; gap: 16px; padding: 3px 0; }
.sum dt { color: var(--soft); }
.sum dd { margin: 0; font-variant-numeric: tabular-nums; }
.sum .sum-total { margin-top: 8px; padding-top: 10px; border-top: 1px solid var(--line); font-size: 1.14rem; }
.sum .sum-total dt, .sum .sum-total dd { color: var(--ink); font-weight: 700; }

.who label, .gift label { display: block; margin: 14px 0 6px; font-size: .92rem; font-weight: 600; }
.buy input[type=text], .buy input[type=email], .buy input[type=tel], .buy input[type=number] { width: 100%; height: 50px; padding: 0 13px; border: 1px solid var(--field); border-radius: 0; background: #fff; color: var(--ink); font: 17px/1.2 var(--sans); }
.buy input:focus { outline: none; border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.buy input.is-bad { border-color: var(--alarm); box-shadow: inset 0 0 0 1px var(--alarm); }
.gift { margin: 18px 0 4px; }
.gift summary { cursor: pointer; font-weight: 600; text-decoration: underline; text-underline-offset: 4px; width: fit-content; }
.gift-line { display: flex; gap: 8px; }
.gift-line input { flex: 1; min-width: 0; letter-spacing: .04em; }
.gift-line .btn { flex: none; padding-left: 20px; padding-right: 20px; }
.gift-note { margin: 8px 0 0; font-size: .93rem; color: var(--soft); min-height: 1.4em; }
.gift-note.is-good { color: var(--good); font-weight: 600; }
.gift-note.is-bad { color: var(--alarm); }

.pay-with { margin-top: 18px; }
.wallet { margin-bottom: 10px; min-height: 48px; }
.apple-pay-button { display: block; width: 100%; height: 48px; border: 0; border-radius: 0; cursor: pointer; -webkit-appearance: -apple-pay-button; -apple-pay-button-type: buy; -apple-pay-button-style: black; }
.or { margin: 14px 0 10px; text-align: center; color: var(--soft); font-size: .92rem; }
.card-box { min-height: 92px; }
.buy-error { margin: 6px 0 14px; padding: 12px 14px; background: #f3cccc; color: #8f1d1d; font-weight: 600; }
.fine { margin: 12px 0 0; font-size: .88rem; color: var(--soft); text-align: center; }
[hidden] { display: none !important; }

.bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 5; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 10px var(--gutter) calc(10px + env(safe-area-inset-bottom)); background: #fff; border-top: 1px solid var(--line); box-shadow: 0 -8px 20px rgba(17, 26, 46, .08); }
.bar-price { font-family: var(--serif); font-size: 1.3rem; }
.bar-price small { font: 400 .9rem var(--sans); color: var(--soft); }
.has-bar .foot { padding-bottom: 80px; }

/* The page after paying */
.done { max-width: 40rem; margin: 0 auto; padding: 40px var(--gutter) 0; }
.done h1 { font-size: clamp(1.9rem, 5.6vw, 2.6rem); }
.done-card { margin: 24px 0; padding: 24px 20px; background: var(--card); border: 1px solid var(--line); }
.done-card h2 { font-size: 1.4rem; margin-bottom: 8px; }
.done-card dl { margin: 14px 0 0; }
.done-card dl div { display: flex; justify-content: space-between; gap: 16px; padding: 4px 0; }
.done-card dt { color: var(--soft); }
.done-card dd { margin: 0; text-align: right; }
.done-acts { display: flex; flex-wrap: wrap; gap: 10px; }

@media (min-width: 900px) {
  .event-cols { display: grid; grid-template-columns: minmax(0, 1fr) 25rem; gap: 64px; align-items: start; }
  .buy { margin-top: 0; padding: 28px 26px 30px; }
  /* A short panel follows the reader down the page, under the header. The full form does not: it can be taller
     than the window, and its Pay button must always be reachable by scrolling. */
  .buy:not(:has(.buy-form)) { position: sticky; top: calc(var(--top) + 16px); }
  .event-jump, .bar { display: none; }
  .has-bar .foot { padding-bottom: 0; }
}

@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
