@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,wght@0,400;0,500;0,600;0,700;1,400&family=Playfair+Display:ital,wght@0,600;0,700;0,800;1,700&display=swap');

:root {
  --paper: #f8f3eb;
  --paper-elevated: #fffaf3;
  --paper-subtle: #f2e8da;
  --ink: #2d211e;
  --muted: #65554d;
  --red: #892f29;
  --dark-red: #6f231f;
  --amber: #b86b1b;
  --amber-bg: #fdf1e1;
  --green: #236341;
  --green-bg: #e7f4ec;
  --danger: #992626;
  --danger-bg: #fbeaea;
  --line: #e6dbce;
  --line-strong: #d4c3b0;
  --serif: 'Playfair Display', Georgia, serif;
  --sans: 'DM Sans', system-ui, sans-serif;
  font: 100%/1.5 var(--sans);
  color: var(--ink);
  background: var(--paper);
  scroll-padding-top: 1.5rem;
}
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
button:disabled { cursor: wait; opacity: .65; }
:focus-visible { outline: 3px solid #a24931; outline-offset: 3px; }
[hidden] { display: none !important; }
.sr-only, .skip:not(:focus) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip:focus { position: fixed; z-index: 10; padding: 1rem; background: white; }
.container { width: min(1280px, calc(100% - 96px)); margin-inline: auto; }

/* Platform Banner */
.platform-banner { background: var(--ink); color: #fcf0de; padding: .6rem 1rem; text-align: center; font-size: .88rem; font-weight: 500; border-bottom: 1px solid #442f2a; }
.platform-banner strong { color: #edb379; margin-right: .35rem; }

/* Header */
.site-header { border-bottom: 1px solid var(--line); background: var(--paper); position: sticky; top: 0; z-index: 5; }
.header-inner { width: min(1280px, calc(100% - 96px)); margin-inline: auto; min-height: 78px; display: grid; grid-template-columns: auto 1fr auto; gap: 1.5rem; align-items: center; }
.brand { display: inline-flex; width: fit-content; gap: 0; align-items: center; text-decoration: none; letter-spacing: -.065em; font: 800 2rem/1 var(--serif); }
.brand-logo { display: block; height: 38px; width: auto; }
.footer-inner .brand-logo { height: 30px; }
.sidebar-header .brand-logo { height: 32px; }
.main-nav { display: flex; justify-content: center; align-self: stretch; gap: 1.8rem; }
.main-nav a { display: flex; align-items: center; padding: 0 .1rem; text-decoration: none; font-weight: 600; font-size: .94rem; border-bottom: 2px solid transparent; transition: color .15s, border-color .15s; }
.main-nav a.active, .main-nav a:hover { color: var(--red); border-bottom-color: var(--red); }
.management-header .header-inner { grid-template-columns: auto 1fr; }
.management-header .header-inner > :last-child { justify-self: end; font-weight: 700; }
.area-nav { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: .25rem 1rem; }
.area-nav a { text-decoration: none; padding-block: .35rem; }
.area-nav a.active, .area-nav a:hover { color: var(--red); text-decoration: underline; text-underline-offset: .3em; }

/* Buttons */
.button { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; width: fit-content; min-height: 42px; padding: .58rem 1rem; border: 1px solid var(--red); border-radius: 7px; color: white; background: var(--red); font-weight: 700; text-decoration: none; font-size: .9rem; transition: background .15s, color .15s, border-color .15s, transform .1s; }
.button:hover { background: var(--dark-red); }
.button:active { transform: translateY(1px); }
.button-small { min-height: 36px; padding: .35rem .8rem; font-size: .84rem; }
.button-outline { color: var(--red); background: transparent; border-color: var(--line-strong); }
.button-outline:hover { color: white; background: var(--red); border-color: var(--red); }
.button-subtle { color: var(--ink); background: var(--paper-subtle); border-color: var(--line); }
.button-subtle:hover { background: #e8dac7; color: var(--ink); }
.button-success { background: var(--green); border-color: var(--green); color: white; }
.button-success:hover { background: #1a4d32; }
.button-danger { color: var(--danger); background: transparent; border-color: #e2baba; }
.button-danger:hover { background: var(--danger); border-color: var(--danger); color: white; }
.text-button { color: var(--red); font-weight: 700; font-size: .9rem; background: none; border: 0; padding: 0; text-decoration: none; }
.text-button:hover { text-decoration: underline; }

/* Hero */
.hero { position: relative; isolation: isolate; display: flex; align-items: center; min-height: 460px; color: #fff6e8; margin-top: 26px; padding: 54px clamp(28px, 6.1vw, 94px) 68px; border-radius: 14px; overflow: hidden; background: #381515 url('/assets/teatro-castro-alves.webp') center 52% / cover no-repeat; }
.hero::before { content: ''; position: absolute; z-index: -1; inset: 0; background: linear-gradient(90deg, #190e0cf2, #200e0ccf 25%, #27100d55 58%, #27100d14 82%), linear-gradient(0deg, #1b0908b3, transparent 37%); }
.eyebrow { display: flex; align-items: center; gap: .58rem; font-size: .78rem; font-weight: 700; letter-spacing: .15em; margin: 0 0 .55rem; text-transform: uppercase; }
.eyebrow span { width: 18px; height: 1px; background: currentColor; }
.hero-kicker { color: #f2c28d; margin-bottom: 1rem; }
.hero h1 { font: 700 clamp(3.6rem, 7vw, 7rem)/.96 var(--serif); margin: 0; letter-spacing: -.068em; }
.hero h1 em { color: #edb379; }
.hero-copy { max-width: 400px; color: #f1e4d6; margin: 1.25rem 0 1.5rem; font-size: 1.05rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .75rem; align-items: center; }
.button-hero { background: #fcf0de; color: #59251e; border-color: #fcf0de; padding-inline: 1.15rem; }
.button-hero:hover { background: #edb379; border-color: #edb379; color: #2d120e; }
.button-hero-secondary { background: rgba(25, 14, 12, .55); color: #fcf0de; border-color: rgba(252, 240, 222, .45); backdrop-filter: blur(4px); }
.button-hero-secondary:hover { background: rgba(252, 240, 222, .18); border-color: #fcf0de; }
.hero-credit { position: absolute; right: 26px; bottom: 18px; left: 26px; margin: 0; color: #fff6e8; text-align: right; font-size: .8rem; opacity: .88; }
.hero-credit a { text-underline-offset: .18em; }

/* Agenda */
.agenda { margin-top: 48px; }
.agenda-heading { display: flex; gap: 1rem 2rem; justify-content: space-between; align-items: end; }
.section-kicker { color: var(--red); }
h2, .agenda-title, .theaters-intro h1 { font: 700 clamp(2.2rem, 4.4vw, 3.6rem)/1.06 var(--serif); letter-spacing: -.045em; margin: 0; }
.section-copy { color: var(--muted); margin: .55rem 0 0; }
.search { min-height: 46px; display: flex; align-items: center; gap: 12px; background: var(--paper-elevated); border: 1px solid #ded2c5; border-radius: 8px; padding-inline: 14px; width: min(330px, 100%); flex: none; }
.search input { border: 0; background: transparent; min-width: 0; width: 100%; padding-block: 10px; outline: 0; }
.search:focus-within { outline: 2px solid var(--red); }
.search-icon { width: 14px; height: 14px; border: 1.6px solid var(--muted); border-radius: 50%; position: relative; flex: none; }
.search-icon::after { content: ''; width: 6px; height: 1.6px; background: var(--muted); position: absolute; right: -4px; bottom: -2px; transform: rotate(45deg); }
.filters { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .8rem; padding: 1.35rem 0 1rem; border-bottom: 1px solid var(--line); }
.filter-selects { display: flex; flex-wrap: wrap; gap: .55rem; align-items: center; }
.pills { display: flex; flex-wrap: wrap; align-items: center; gap: .45rem; }
.pill { min-height: 36px; background: transparent; color: #594740; border: 1px solid #e4d7c8; padding: .32rem .9rem; border-radius: 999px; font-size: .88rem; font-weight: 600; transition: all .15s; }
.pill:hover, .pill[aria-pressed=true] { border-color: var(--red); color: var(--red); }
.pill[aria-pressed=true] { background: var(--red); color: white; }
select { appearance: none; background: linear-gradient(45deg, transparent 50%, var(--muted) 50%) calc(100% - 17px) 50% / 5px 5px no-repeat, linear-gradient(135deg, var(--muted) 50%, transparent 50%) calc(100% - 12px) 50% / 5px 5px no-repeat, var(--paper-elevated); }
.date-choice select { font-size: .88rem; min-height: 36px; padding: .32rem 2rem .32rem .75rem; border: 1px solid #e4d7c8; border-radius: 7px; font-weight: 600; }
.agenda-status { color: var(--muted); margin: 1rem 0; font-size: .9rem; }
.agenda-status:empty { display: none; }
.next-show { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .75rem 1.25rem; padding: 1rem 1.25rem; border: 1px solid var(--line); border-radius: 10px; background: var(--paper-elevated); }
.next-show p { margin: 0; }

/* Event Cards */
.event-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.15rem; margin-top: 1.15rem; }
.event-card { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--paper-elevated); display: flex; flex-direction: column; transition: transform .15s, box-shadow .15s, border-color .15s; }
.event-card:hover { transform: translateY(-2px); box-shadow: 0 8px 24px -12px rgba(45, 33, 30, .15); border-color: var(--line-strong); }
.event-card.is-featured { border-color: #d6a46c; box-shadow: 0 4px 16px -8px rgba(184, 107, 27, .22); }
.event-card-header { display: flex; justify-content: space-between; align-items: center; gap: .5rem; padding: .75rem 1rem; border-bottom: 1px solid var(--line); background: #f3e9dd; }
.card-badges { display: flex; flex-wrap: wrap; align-items: center; gap: .38rem; }
.card-category { padding: .22rem .62rem; border-radius: 999px; background: var(--paper-elevated); color: var(--red); font-size: .8rem; font-weight: 700; }
.card-featured { padding: .2rem .55rem; border-radius: 999px; background: var(--amber-bg); color: var(--amber); border: 1px solid #ebcba0; font-size: .76rem; font-weight: 700; }
.card-rating { padding: .2rem .55rem; border-radius: 999px; background: #2d211e; color: #f6c47b; font-size: .78rem; font-weight: 700; }
.date-stamp { display: grid; min-width: 48px; padding: .28rem .45rem; text-align: center; line-height: 1.1; background: #fbf0df; border-radius: 6px; border: 1px solid #eadbc7; }
.date-stamp strong { font: 800 1.28rem/1.05 var(--serif); }
.date-stamp small { text-transform: uppercase; color: var(--red); font-size: .72rem; font-weight: 700; margin-top: .18rem; }
.event-content { padding: 1rem; display: flex; flex-direction: column; flex: 1; }
.card-meta { color: var(--red); font-weight: 700; font-size: .82rem; margin: 0 0 .3rem; }
.event-content h3 { font: 700 clamp(1.3rem, 1.9vw, 1.65rem)/1.16 var(--serif); letter-spacing: -.025em; margin: 0; overflow-wrap: anywhere; }
.card-place { color: var(--muted); margin: .4rem 0 .65rem; font-size: .92rem; }
.card-tags { display: flex; flex-wrap: wrap; gap: .35rem; margin-bottom: .85rem; }
.card-tags:empty { display: none; }
.card-footer { margin-top: auto; padding-top: .65rem; border-top: 1px dashed var(--line); display: flex; justify-content: space-between; align-items: center; gap: .5rem; }

/* Badges & Tags */
.badge { display: inline-flex; align-items: center; gap: .28rem; padding: .18rem .58rem; border-radius: 999px; font-size: .76rem; font-weight: 700; line-height: 1.3; white-space: nowrap; }
.badge-approved { background: var(--green-bg); color: var(--green); border: 1px solid #bddrc9; }
.badge-pending { background: var(--amber-bg); color: var(--amber); border: 1px solid #ebd1ad; }
.badge-rejected, .badge-suspended { background: var(--danger-bg); color: var(--danger); border: 1px solid #ebcccc; }
.badge-archived { background: #eae3da; color: var(--muted); }
.badge-featured { background: #2d211e; color: #f5c276; }
.badge-neutral { background: var(--paper-subtle); color: var(--muted); border: 1px solid var(--line); }
.badge-price { background: #f6efe4; color: #4f3d36; border: 1px solid var(--line); font-weight: 600; }
.badge-age { background: #efe4d6; color: var(--ink); font-weight: 700; }

/* Theaters CTA section */
.theaters { margin: 4rem 0; padding: clamp(1.4rem, 4vw, 2.8rem); border: 1px solid var(--line); border-radius: 13px; background: var(--paper-subtle); display: grid; grid-template-columns: 1.2fr 1fr; gap: 2rem; align-items: center; }
.theaters-intro p:not(.eyebrow) { max-width: 44ch; color: var(--muted); margin-bottom: 1.2rem; }
.plans { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem; }
.plan { border: 1px solid var(--line); padding: 1.1rem; border-radius: 10px; background: #fffbf4; display: flex; flex-direction: column; gap: .25rem; }
.plan h2 { margin: 0; font-size: 1rem; letter-spacing: 0; }
.plan p { color: var(--red); font: 700 1.28rem/1.3 var(--serif); margin: .25rem 0; }
.plan small { color: var(--muted); font: 500 .8rem var(--sans); white-space: nowrap; }
.plan-note { font-size: .78rem; color: var(--muted); }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 1.5rem 0; color: var(--muted); margin-top: 3rem; }
.footer-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem; }
.footer-inner .brand { font-size: 1.5rem; color: var(--ink); }
.footer-actions { display: flex; gap: 1.15rem; align-items: center; font-size: .9rem; }
.footer-actions a { color: var(--red); text-underline-offset: .24em; font-weight: 600; }

/* Panel & Views */
.panel { margin: 2rem auto 3rem; padding: clamp(1.25rem, 3.5vw, 2.25rem); border-radius: 14px; border: 1px solid var(--line-strong); background: var(--paper-elevated); box-shadow: 0 10px 30px -16px rgba(45, 33, 30, .12); }
.panel h1, .panel h2 { margin: 0 0 .35rem; font: 700 clamp(1.85rem, 3.5vw, 2.75rem)/1.06 var(--serif); letter-spacing: -.045em; }
.panel h3 { margin: 1.5rem 0 .75rem; font: 700 1.35rem/1.2 var(--serif); letter-spacing: -.02em; }
.panel h4 { margin: 0 0 .35rem; font-size: 1.05rem; }
.panel-header, .row-actions, .form-actions { display: flex; flex-wrap: wrap; gap: .65rem; align-items: center; }
.panel-header { justify-content: space-between; padding-bottom: 1rem; border-bottom: 1px solid var(--line); margin-bottom: 1.15rem; }
.panel-subtitle { color: var(--muted); margin: .2rem 0 0; font-size: .95rem; }

/* Sub-navigation Tabs inside Panel */
.panel-tabs { display: flex; flex-wrap: wrap; gap: .4rem; border-bottom: 1px solid var(--line); padding-bottom: .75rem; margin: 1.15rem 0 1.4rem; }
.tab-btn { display: inline-flex; align-items: center; gap: .45rem; padding: .48rem .95rem; border-radius: 8px; border: 1px solid transparent; background: transparent; color: var(--muted); font-weight: 600; font-size: .9rem; transition: all .15s; }
.tab-btn:hover { background: var(--paper-subtle); color: var(--ink); }
.tab-btn[aria-selected="true"] { background: var(--red); color: white; border-color: var(--red); }
.tab-count { display: inline-flex; align-items: center; justify-content: center; min-width: 20px; height: 20px; padding: 0 .38rem; border-radius: 999px; font-size: .74rem; font-weight: 700; background: rgba(0,0,0,.12); }
.tab-btn[aria-selected="true"] .tab-count { background: rgba(255,255,255,.24); color: white; }

/* Stats / KPI Grid */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: .85rem; margin: 1rem 0 1.35rem; }
.stat-card { border: 1px solid var(--line); border-radius: 10px; padding: 1rem 1.1rem; background: var(--paper); display: flex; flex-direction: column; gap: .2rem; }
.stat-label { font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.stat-value { font: 700 clamp(1.65rem, 2.6vw, 2.2rem)/1.1 var(--serif); color: var(--ink); letter-spacing: -.03em; }
.stat-value.is-accent { color: var(--red); }
.stat-sub { font-size: .82rem; color: var(--muted); margin-top: .15rem; }

/* Callout / Alerts */
.callout { padding: .9rem 1.1rem; border-radius: 9px; border: 1px solid var(--line); background: var(--paper); margin: .85rem 0; font-size: .92rem; }
.callout-warning { background: var(--amber-bg); border-color: #e6c499; color: #5c3409; }
.callout-danger { background: var(--danger-bg); border-color: #e6b8b8; color: #661717; }
.callout-success { background: var(--green-bg); border-color: #b7dec6; color: #16472c; }
.callout strong { display: block; margin-bottom: .2rem; }

/* Toolbars & Filters inside Panel */
.toolbar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .75rem; margin: 1rem 0; padding: .75rem .9rem; border-radius: 9px; background: var(--paper); border: 1px solid var(--line); }
.toolbar-search { min-height: 38px; border: 1px solid #d9c9b8; border-radius: 6px; padding: .4rem .75rem; background: #fffdf9; min-width: 220px; flex: 1; max-width: 340px; }

/* Forms */
.form-grid { display: grid; gap: 1rem; max-width: 760px; margin: 1.15rem 0; }
.form-row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-row-3 { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 1rem; }
.form-grid label { display: grid; gap: .32rem; font-weight: 600; font-size: .92rem; }
.form-grid input, .form-grid textarea, .form-grid select { width: 100%; min-height: 42px; border: 1px solid #d9c9b8; border-radius: 6px; padding: .55rem .75rem; background-color: #fffdf9; font-weight: 400; }
.form-grid textarea { resize: vertical; }
.form-hint { font-size: .8rem; color: var(--muted); font-weight: 400; }
.form-message { color: var(--red); font-weight: 600; margin: .5rem 0; }
.form-message:empty { display: none; }
.form-grid label.checkbox-field { display: inline-flex; align-items: center; gap: .5rem; cursor: pointer; width: fit-content; }
.form-grid .checkbox-field input { order: -1; width: 1.15rem; min-height: 0; height: 1.15rem; accent-color: var(--red); }

/* Multi-session Schedule Builder */
.sessions-builder { border: 1px solid var(--line); border-radius: 9px; padding: .95rem; background: var(--paper); display: grid; gap: .65rem; }
.session-row { display: flex; flex-wrap: wrap; align-items: center; gap: .55rem; }
.session-row input { flex: 1; min-width: 210px; }

/* Records & Cards */
.records { display: grid; gap: .75rem; }
.records-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: .85rem; }
.record { border: 1px solid var(--line); border-radius: 10px; padding: 1rem 1.1rem; background: #fffdf9; display: grid; gap: .45rem; overflow-wrap: anywhere; transition: border-color .15s; }
.record:hover { border-color: var(--line-strong); }
.record-header { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: start; gap: .5rem; }
.record-title { font: 700 1.15rem/1.25 var(--serif); text-decoration: none; }
a.record-title:hover { color: var(--red); text-decoration: underline; }
.record p { margin: 0; }
.record small { color: var(--muted); font-size: .86rem; }
.record .button { min-height: 34px; padding: .28rem .75rem; font-size: .84rem; }
.record summary { cursor: pointer; color: var(--red); font-weight: 600; font-size: .9rem; }

/* Letterboxd Play Page & Rating Histogram */
.play-hero { display: grid; grid-template-columns: 1.5fr 1fr; gap: 1.75rem; align-items: start; padding-bottom: 1.5rem; border-bottom: 1px solid var(--line); margin-bottom: 1.5rem; }
.play-meta-line { display: flex; flex-wrap: wrap; align-items: center; gap: .45rem; margin: .5rem 0 .85rem; }
.credits-box { padding: .85rem 1rem; border-radius: 8px; background: var(--paper); border: 1px solid var(--line); font-size: .9rem; color: var(--muted); margin-top: .85rem; }
.credits-box strong { color: var(--ink); }

.scorecard { border: 1px solid var(--line-strong); border-radius: 12px; padding: 1.15rem; background: var(--paper); display: grid; gap: .9rem; }
.scorecard-top { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-bottom: .75rem; border-bottom: 1px solid var(--line); }
.score-number { font: 800 2.5rem/1 var(--serif); color: var(--ink); letter-spacing: -.04em; }
.score-stars { color: #c87d20; font-size: 1.15rem; letter-spacing: .06em; }
.score-counts { font-size: .82rem; color: var(--muted); }
.community-pills { display: flex; flex-wrap: wrap; gap: .45rem; font-size: .82rem; color: var(--muted); }
.community-pill { padding: .25rem .6rem; border-radius: 6px; background: var(--paper-elevated); border: 1px solid var(--line); font-weight: 600; }

.histogram { display: grid; gap: .32rem; }
.hist-row { display: grid; grid-template-columns: 36px 1fr 34px; align-items: center; gap: .5rem; font-size: .78rem; color: var(--muted); }
.hist-label { font-weight: 700; text-align: right; color: var(--ink); }
.hist-track { height: 9px; border-radius: 999px; background: #e8ddd0; overflow: hidden; }
.hist-fill { height: 100%; border-radius: 999px; background: linear-gradient(90deg, var(--red), #c87d20); transition: width .3s ease; }
.hist-count { text-align: right; font-variant-numeric: tabular-nums; }

/* Interactive Star Picker & Review Logger */
.diary-logger { border: 1px solid var(--line-strong); border-radius: 12px; padding: 1.2rem; background: var(--paper); margin: 1.25rem 0; }
.logger-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 1.1rem; margin-bottom: .85rem; }
.star-picker { display: inline-flex; align-items: center; gap: .2rem; background: var(--paper-elevated); padding: .3rem .55rem; border-radius: 8px; border: 1px solid var(--line); }
.star-btn { background: none; border: 0; font-size: 1.55rem; line-height: 1; padding: .1rem .18rem; color: #d6c7b5; transition: transform .1s, color .12s; }
.star-btn.is-active, .star-btn:hover { color: #c87d20; transform: scale(1.1); }
.star-clear { font-size: .76rem; color: var(--muted); background: none; border: 0; margin-left: .35rem; text-decoration: underline; }

.heart-toggle { display: inline-flex; align-items: center; gap: .38rem; padding: .42rem .85rem; border-radius: 8px; border: 1px solid var(--line-strong); background: var(--paper-elevated); font-weight: 700; font-size: .88rem; color: var(--muted); transition: all .15s; }
.heart-toggle[aria-pressed="true"] { background: #fbe9e7; border-color: var(--red); color: var(--red); }

/* Review Cards & Applause */
.review-header { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .5rem; }
.review-author { font-weight: 700; text-decoration: none; color: var(--ink); }
a.review-author:hover { color: var(--red); text-decoration: underline; }
.review-stars { color: #c87d20; font-weight: 700; letter-spacing: .04em; }
.review-heart { color: var(--red); font-weight: 700; }
.review-copy { white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.55; color: var(--ink); margin: .25rem 0; }
.review-footer { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .5rem; margin-top: .25rem; padding-top: .45rem; border-top: 1px dashed var(--line); }
.applause-btn { display: inline-flex; align-items: center; gap: .35rem; padding: .24rem .68rem; border-radius: 999px; border: 1px solid var(--line-strong); background: var(--paper); font-size: .8rem; font-weight: 700; color: var(--muted); transition: all .15s; }
.applause-btn:hover, .applause-btn.is-liked { border-color: var(--red); color: var(--red); background: #fbe9e7; }

/* Dialog */
dialog { width: min(680px, calc(100% - 2rem)); max-height: 88vh; padding: clamp(1.25rem, 4.5vw, 2rem); color: var(--ink); background: var(--paper-elevated); border: 1px solid var(--line-strong); border-radius: 14px; box-shadow: 0 20px 50px rgba(25, 14, 12, .35); }
dialog::backdrop { background: #20110dc7; backdrop-filter: blur(2px); }
dialog h2 { padding-right: 2.2rem; font-size: clamp(1.85rem, 5vw, 2.5rem); margin-bottom: .5rem; }
dialog p { overflow-wrap: anywhere; white-space: pre-wrap; }
.close { position: absolute; top: .75rem; right: .75rem; border: 1px solid var(--line); background: var(--paper); border-radius: 50%; width: 42px; height: 42px; font-size: 1.4rem; display: flex; align-items: center; justify-content: center; }
.close:hover { background: var(--paper-subtle); }

/* Show Posters (Cartazes) */
.card-poster-wrap { width: 100%; aspect-ratio: 16 / 10; background: #221412; border-bottom: 1px solid var(--line); overflow: hidden; position: relative; }
.card-poster { width: 100%; height: 100%; object-fit: cover; object-position: center 20%; display: block; transition: transform .35s ease; }
.event-card:hover .card-poster { transform: scale(1.03); }

.poster-uploader { border: 1px solid var(--line-strong); border-radius: 10px; padding: 1rem; background: var(--paper); display: grid; grid-template-columns: auto 1fr; gap: 1rem; align-items: center; }
.poster-preview-box { width: 108px; aspect-ratio: 2 / 3; border-radius: 8px; border: 1px dashed var(--line-strong); background: var(--paper-elevated); display: flex; align-items: center; justify-content: center; overflow: hidden; text-align: center; font-size: .75rem; color: var(--muted); padding: .35rem; flex: none; }
.poster-preview-box img { width: 100%; height: 100%; object-fit: cover; border-radius: 6px; display: block; }
.poster-controls { display: grid; gap: .6rem; min-width: 0; }
.poster-file-label { display: inline-flex; align-items: center; gap: .45rem; cursor: pointer; width: fit-content; }
.poster-file-label input[type="file"] { display: none; }

.play-detail-with-poster { display: grid; grid-template-columns: 180px 1fr; gap: 1.35rem; align-items: start; }
.play-poster-frame { width: 100%; aspect-ratio: 2 / 3; border-radius: 10px; overflow: hidden; border: 1px solid var(--line-strong); background: #221412; box-shadow: 0 10px 24px -10px rgba(25, 14, 12, .28); }
.play-poster-frame img { width: 100%; height: 100%; object-fit: cover; display: block; }

.record-with-poster { display: grid; grid-template-columns: 72px 1fr; gap: .9rem; align-items: start; }
.poster-thumb { width: 72px; aspect-ratio: 2 / 3; border-radius: 7px; object-fit: cover; border: 1px solid var(--line-strong); background: #221412; display: block; flex: none; }

/* PWA Update Toast */
.update-toast { position: fixed; right: 1.25rem; bottom: 1.25rem; z-index: 20; display: flex; flex-wrap: wrap; align-items: center; gap: .85rem; padding: .75rem 1rem; border-radius: 10px; background: var(--ink); color: #fcf0de; border: 1px solid #593b34; box-shadow: 0 12px 32px rgba(25, 14, 12, .35); font-size: .9rem; font-weight: 600; }

/* Mobile Sidebar Drawer & Carousel Base (hidden on desktop) */
body.sidebar-open { overflow: hidden; }
.menu-toggle { display: none; flex-direction: column; justify-content: center; align-items: center; gap: 5px; width: 44px; height: 44px; padding: 0; border-radius: 9px; border: 1px solid var(--line-strong); background: var(--paper-elevated); color: var(--ink); transition: background .15s, border-color .15s; }
.menu-toggle:hover { background: var(--paper-subtle); border-color: var(--red); }
.menu-toggle span { width: 20px; height: 2px; border-radius: 2px; background: currentColor; transition: transform .22s ease, opacity .18s ease; }
.menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.sidebar-backdrop { position: fixed; inset: 0; z-index: 30; background: rgba(25, 14, 12, .52); backdrop-filter: blur(2px); opacity: 0; transition: opacity .22s ease; }
.sidebar-backdrop.is-visible { opacity: 1; }

.mobile-sidebar { position: fixed; top: 0; left: 0; bottom: 0; z-index: 35; width: min(300px, 84vw); background: var(--paper-elevated); border-right: 1px solid var(--line-strong); box-shadow: 16px 0 40px rgba(25, 14, 12, .25); display: flex; flex-direction: column; padding: 1.1rem 1rem 1.4rem; transform: translateX(-104%); visibility: hidden; transition: transform .26s cubic-bezier(.22, 1, .36, 1), visibility .26s; }
.mobile-sidebar.is-open { transform: translateX(0); visibility: visible; }
.sidebar-header { display: flex; align-items: center; justify-content: space-between; gap: .75rem; padding-bottom: .95rem; border-bottom: 1px solid var(--line); }
.sidebar-header .brand { font-size: 1.55rem; }
.sidebar-close { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line); background: var(--paper); font-size: 1.45rem; line-height: 1; display: flex; align-items: center; justify-content: center; color: var(--ink); }
.sidebar-close:hover { background: var(--paper-subtle); }
.sidebar-nav { display: grid; gap: .32rem; padding: 1rem 0; }
.sidebar-nav a { display: flex; align-items: center; gap: .78rem; min-height: 48px; padding: .6rem .9rem; border-radius: 10px; text-decoration: none; font-weight: 600; font-size: 1rem; color: var(--ink); transition: background .15s, color .15s; }
.sidebar-nav a:hover { background: var(--paper-subtle); color: var(--red); }
.sidebar-nav a.active { background: #fbe9e5; color: var(--red); font-weight: 700; }
.sidebar-icon { width: 22px; text-align: center; font-size: 1.05rem; }
.sidebar-footer { margin-top: auto; padding-top: 1rem; border-top: 1px solid var(--line); display: grid; gap: .85rem; }
.sidebar-cta { width: 100%; min-height: 46px; }
.sidebar-secondary-links { display: flex; align-items: center; justify-content: space-between; gap: .75rem; padding-inline: .25rem; font-size: .88rem; }
.sidebar-secondary-links a { color: var(--muted); font-weight: 600; text-decoration: none; }
.sidebar-secondary-links a:hover { color: var(--red); text-decoration: underline; }

/* Shows Carousel Controls (shown on mobile) */
.carousel-shell { position: relative; }
.carousel-controls { display: none; justify-content: space-between; align-items: center; gap: .75rem; margin: .6rem 0 .45rem; }
.carousel-counter { font-size: .84rem; font-weight: 700; color: var(--muted); }
.carousel-arrows { display: flex; align-items: center; gap: .4rem; }
.carousel-btn { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line-strong); background: var(--paper-elevated); color: var(--ink); font-size: 1.35rem; line-height: 1; display: inline-flex; align-items: center; justify-content: center; transition: background .15s, border-color .15s, color .15s; }
.carousel-btn:hover:not(:disabled) { border-color: var(--red); color: var(--red); background: var(--paper-subtle); }
.carousel-btn:disabled { opacity: .35; cursor: default; }
.carousel-dots { display: none; justify-content: center; align-items: center; gap: .42rem; margin-top: .5rem; padding-block: .25rem; }
.carousel-dot { width: 8px; height: 8px; padding: 0; border: 0; border-radius: 999px; background: var(--line-strong); transition: width .22s ease, background .2s ease; }
.carousel-dot.is-active { width: 22px; background: var(--red); }

/* Responsive */
@media (max-width: 1020px) {
  .main-nav { gap: 1.1rem; }
  .event-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .play-hero { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  .container, .header-inner { width: calc(100% - 48px); }
  .hero { min-height: 420px; }
  .theaters { grid-template-columns: 1fr; }
}
@media (max-width: 820px) {
  .header-inner { grid-template-columns: 1fr auto; min-height: 64px; gap: .75rem; }
  .main-nav { display: none; }
  .menu-toggle { display: inline-flex; }
  .form-row-2, .form-row-3 { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .carousel-controls { display: flex; }
  .carousel-dots { display: flex; }
  .event-grid {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    gap: .85rem;
    margin-top: .35rem;
    padding: .25rem 14px .85rem;
    margin-inline: -14px;
    scrollbar-width: none;
  }
  .event-grid::-webkit-scrollbar { display: none; }
  .event-grid .event-card {
    flex: 0 0 84%;
    max-width: 340px;
    scroll-snap-align: center;
  }
  .event-grid.is-single .event-card {
    flex: 0 0 100%;
    max-width: 100%;
  }
  .pills {
    flex-wrap: nowrap;
    overflow-x: auto;
    width: 100%;
    padding-bottom: .2rem;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .pills::-webkit-scrollbar { display: none; }
  .pill { flex: none; white-space: nowrap; }
  .panel-tabs {
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .panel-tabs::-webkit-scrollbar { display: none; }
  .tab-btn { flex: none; white-space: nowrap; }
}
@media (max-width: 650px) {
  .container, .header-inner { width: calc(100% - 28px); }
  .brand { font-size: 1.65rem; }
  .brand-logo { height: 32px; }
  .hero { min-height: 320px; margin-top: 14px; padding: 30px 20px 44px; background-position: 60% center; }
  .hero::before { background: linear-gradient(90deg,#190e0ce8,#200e0c88 72%,#27100d50),linear-gradient(0deg,#1b0908b3,transparent 37%); }
  .hero h1 { font-size: clamp(2.85rem, 11.5vw, 4.4rem); }
  .hero-copy { font-size: .96rem; margin: .9rem 0 1.15rem; }
  .hero-credit { right: 14px; bottom: 10px; left: 14px; font-size: .72rem; }
  .agenda { margin-top: 26px; }
  .agenda-heading { align-items: start; flex-direction: column; gap: .75rem; }
  .search { width: 100%; }
  .filters { align-items: stretch; flex-direction: column; padding: 1rem 0 .85rem; }
  .filter-selects { width: 100%; display: grid; grid-template-columns: 1fr 1fr; gap: .5rem; }
  .filter-selects .date-choice, .filter-selects select { width: 100%; }
  .theaters { margin: 2.2rem 0; gap: 1.15rem; }
  .plans { grid-template-columns: 1fr; }
  .panel { margin: 1.1rem auto 2rem; padding: 1.05rem; }
  .stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; }
  .stat-card { padding: .8rem .85rem; }
  .records-grid { grid-template-columns: 1fr; }
  .update-toast { left: 14px; right: 14px; bottom: 14px; justify-content: space-between; }
}
@media (max-width: 600px) {
  .play-detail-with-poster { grid-template-columns: 1fr; }
  .play-poster-frame { max-width: 200px; margin-inline: auto; }
  .poster-uploader { grid-template-columns: 1fr; justify-items: start; }
}
