:root {
  --bg: #faf5ec;
  --paper: #ffffff;
  --ink: #241a17;
  --muted: #6f625b;
  --line: #e8ddcc;
  --maroon: #5c1320;
  --maroon-2: #7d1d2d;
  --gold: #f2c46d;
  --t500: #c8922e;
  --t300: #c24d63;
  --t200: #2c8a80;
  --ok: #1f8a4c;
  --bad: #c0392b;
  --warn: #c77d12;
  --radius: 14px;
  --serif: 'Tiro Bangla', 'Noto Sans Bengali', serif;
  --bn: 'Tiro Bangla', serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.7 'Noto Sans Bengali', system-ui, sans-serif; }
a { color: var(--maroon-2); }
img, svg { max-width: 100%; }
h1, h2, h3 { font-family: var(--serif); line-height: 1.2; margin: 0 0 .5em; }
h1 { font-size: clamp(2rem, 5vw, 3.4rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2rem); }
h3 { font-size: 1.2rem; }
button, input, select, textarea { font: inherit; }
main { min-height: 70vh; outline: none; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.section { padding: 48px 0; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.bn { font-family: var(--bn); }

.demo-banner { background: #2b1f1a; color: #f7e7c6; font-size: .85rem; text-align: center; padding: 8px 16px; }
.topbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding: 10px 20px; background: var(--maroon); color: #fff; }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; }
.brand-mark { width: 40px; height: 40px; color: var(--gold); display: grid; place-items: center; background: rgba(255,255,255,.08); border-radius: 10px; }
.brand-mark svg { width: 32px; height: 32px; }
.brand-bn { display: block; font-family: var(--bn); font-size: 1.15rem; line-height: 1.2; }
.brand-en { display: block; font-size: .78rem; opacity: .85; }
.nav { display: flex; gap: 4px; flex-wrap: wrap; }
.nav a { color: #fbeee0; text-decoration: none; padding: 6px 12px; border-radius: 999px; font-size: .92rem; }
.nav a:hover, .nav a.active { background: rgba(255,255,255,.14); color: #fff; }
.nav a.staff { border: 1px dashed rgba(255,255,255,.35); }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; border-radius: 999px; padding: 12px 22px; background: var(--maroon); color: #fff; font-weight: 600; text-decoration: none; cursor: pointer; transition: transform .1s, background .2s; }
.btn:hover { background: var(--maroon-2); }
.btn:active { transform: scale(.98); }
.btn.gold { background: var(--gold); color: #3a2410; }
.btn.gold:hover { background: #f5cf85; }
.btn.ghost { background: transparent; color: var(--maroon); border: 1.5px solid var(--maroon); }
.btn.ghost:hover { background: rgba(92,19,32,.06); }
.btn.sm { padding: 8px 14px; font-size: .9rem; }
.btn[disabled] { opacity: .45; cursor: not-allowed; }

.hero { background: var(--maroon); color: #fff; position: relative; overflow: hidden; }
.hero::before, .hero::after { content: ''; position: absolute; top: 0; bottom: 0; width: 14%; background: repeating-linear-gradient(90deg, #7a1627 0 18px, #4a0e19 18px 36px); }
.hero::before { left: 0; border-radius: 0 0 60% 0; }
.hero::after { right: 0; border-radius: 0 0 0 60%; }
.hero-inner { position: relative; z-index: 1; text-align: center; padding: 72px 16% 64px; }
.hero .bn-title { font-family: var(--bn); font-size: clamp(2.2rem, 6vw, 4rem); color: var(--gold); line-height: 1.25; margin: 0; }
.hero .en-title { font-family: var(--serif); font-size: clamp(1.1rem, 2.4vw, 1.5rem); margin: 6px 0 18px; letter-spacing: .03em; }
.hero .meta { display: flex; gap: 10px 22px; justify-content: center; flex-wrap: wrap; color: #f6e4d0; margin-bottom: 28px; }
.hero .cta { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

.grid { display: grid; gap: 20px; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.card-body { padding: 16px 18px 18px; }
.drama-card { display: flex; flex-direction: column; text-decoration: none; color: inherit; transition: transform .15s, box-shadow .15s; }
.drama-card:hover { transform: translateY(-3px); box-shadow: 0 10px 30px rgba(60,20,20,.12); }
.drama-card .card-body { flex: 1; display: flex; flex-direction: column; gap: 6px; }

.poster { aspect-ratio: 3 / 2; position: relative; display: flex; flex-direction: column; justify-content: flex-end; padding: 16px 18px; overflow: hidden; }
.poster.tall { aspect-ratio: 3 / 4; border-radius: var(--radius); padding: 26px; }
.poster .p-date { position: absolute; top: 14px; left: 16px; font-size: .8rem; opacity: .9; }
.poster .p-bn { font-family: var(--bn); font-size: 2rem; line-height: 1.2; }
.poster.tall .p-bn { font-size: 3rem; }
.poster .p-en { font-family: var(--serif); font-size: 1rem; opacity: .9; }
.poster.tall .p-en { font-size: 1.4rem; }
.poster .p-art { position: absolute; right: -30px; top: -30px; width: 170px; height: 170px; border-radius: 50%; opacity: .22; }
.poster.tall .p-art { width: 300px; height: 300px; right: -60px; top: -40px; }
.poster .p-line { position: absolute; left: 0; right: 0; bottom: 0; height: 6px; }

.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { font-size: .78rem; padding: 3px 10px; border-radius: 999px; background: #f3eadb; color: #5d4a3c; white-space: nowrap; }
.chip.age { background: #efe3f7; color: #57307a; }
.chip.left { background: #e3f3ea; color: #1b6b3d; }
.chip.low { background: #fdeccf; color: #8a5100; }
.chip.out { background: #f8dcdc; color: #9a2020; }

.steps { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); counter-reset: s; }
.step { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.step::before { counter-increment: s; content: counter(s); display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--gold); color: #3a2410; font-weight: 700; margin-bottom: 10px; }
.tiers { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.tier { border-radius: var(--radius); padding: 20px; color: #fff; }
.tier .price { font-family: var(--serif); font-size: 2.2rem; }
.tier.t500 { background: var(--t500); }
.tier.t300 { background: var(--t300); }
.tier.t200 { background: var(--t200); }
details.faq { background: var(--paper); border: 1px solid var(--line); border-radius: 12px; padding: 14px 18px; margin-bottom: 10px; }
details.faq summary { cursor: pointer; font-weight: 600; }

.detail { display: grid; gap: 32px; grid-template-columns: minmax(0, 340px) minmax(0, 1fr); align-items: start; }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 12px; margin: 18px 0; }
.fact { background: var(--paper); border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; }
.fact .k { font-size: .75rem; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.fact .v { font-weight: 600; }
.callout { border-left: 4px solid var(--gold); background: #fff8ea; padding: 14px 18px; border-radius: 0 12px 12px 0; margin: 16px 0; }
.cast { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); }
.person { display: flex; align-items: center; gap: 12px; background: var(--paper); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; }
.avatar { flex: none; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; font-weight: 600; color: #fff; font-size: .9rem; }
.person .n { font-weight: 600; line-height: 1.3; }
.person .r { font-size: .85rem; color: var(--muted); line-height: 1.3; }

.sched-row { display: grid; grid-template-columns: 90px minmax(0, 1fr) auto; gap: 18px; align-items: center; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 18px; margin-bottom: 12px; }
.datebox { text-align: center; border-radius: 12px; background: var(--maroon); color: #fff; padding: 8px 0; }
.datebox .d { font-family: var(--serif); font-size: 1.8rem; line-height: 1; }
.datebox .m { font-size: .75rem; letter-spacing: .1em; text-transform: uppercase; }

/* Booking */
.book { display: grid; gap: 24px; grid-template-columns: minmax(0, 1fr) 320px; align-items: start; }
.panel { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.stage { margin: 0 auto 22px; max-width: 520px; text-align: center; font-size: .85rem; letter-spacing: .1em; color: var(--muted); border-bottom: 4px solid var(--maroon); border-radius: 0 0 50% 50% / 0 0 100% 100%; padding-bottom: 6px; }
.seatmap { overflow-x: auto; padding-bottom: 6px; }
.seatmap-inner { min-width: 560px; display: flex; flex-direction: column; gap: 5px; align-items: center; }
.srow { display: flex; align-items: center; gap: 4px; }
.srow .rl { width: 18px; font-size: .7rem; color: var(--muted); text-align: center; }
.seat { width: 22px; height: 22px; border-radius: 6px 6px 4px 4px; border: 1.5px solid; background: #fff; cursor: pointer; padding: 0; font-size: 0; }
.seat.t500 { border-color: var(--t500); }
.seat.t300 { border-color: var(--t300); }
.seat.t200 { border-color: var(--t200); }
.seat:hover:not(.sold) { transform: scale(1.12); }
.seat.sel.t500 { background: var(--t500); }
.seat.sel.t300 { background: var(--t300); }
.seat.sel.t200 { background: var(--t200); }
.seat.sold { background: #ddd5ca; border-color: #ddd5ca; cursor: not-allowed; }
.gap { width: 18px; }
.tier-break { height: 8px; }
.legend { display: flex; flex-wrap: wrap; gap: 8px 16px; justify-content: center; font-size: .82rem; margin-top: 16px; }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 14px; height: 14px; border-radius: 4px; display: inline-block; border: 1.5px solid; }
.sum-line { display: flex; justify-content: space-between; gap: 12px; padding: 6px 0; border-bottom: 1px dashed var(--line); font-size: .95rem; }
.sum-total { display: flex; justify-content: space-between; font-weight: 700; font-size: 1.2rem; padding-top: 10px; }
.hold { background: #fff4df; border-radius: 10px; padding: 8px 12px; font-size: .88rem; color: #7a4a00; margin: 12px 0; }

form .field { margin-bottom: 14px; }
label { display: block; font-weight: 500; font-size: .9rem; margin-bottom: 4px; }
input[type=text], input[type=email], input[type=tel], select, textarea { width: 100%; padding: 11px 13px; border: 1.5px solid var(--line); border-radius: 10px; background: #fff; color: var(--ink); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--maroon-2); box-shadow: 0 0 0 3px rgba(125,29,45,.12); }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; font-size: .9rem; }
.check input { margin-top: 4px; }
.err { color: var(--bad); font-size: .82rem; margin-top: 4px; min-height: 1em; }

.paygate { max-width: 440px; margin: 0 auto; border-radius: 18px; overflow: hidden; border: 1px solid var(--line); background: #fff; box-shadow: 0 20px 60px rgba(40,20,20,.15); }
.paygate-head { background: #1f2a44; color: #fff; padding: 16px 20px; display: flex; justify-content: space-between; align-items: center; }
.paygate-body { padding: 20px; }
.paymode { display: flex; align-items: center; gap: 12px; border: 1.5px solid var(--line); border-radius: 12px; padding: 12px 14px; margin-bottom: 10px; cursor: pointer; }
.paymode input { accent-color: #1f2a44; }
.paymode.on { border-color: #1f2a44; background: #f4f6fb; }

/* Tickets */
.ticket { display: grid; grid-template-columns: minmax(0, 1fr) 190px; background: #fff; border-radius: 18px; overflow: hidden; border: 1px solid var(--line); margin-bottom: 18px; position: relative; }
.ticket-main { padding: 20px 22px; border-right: 2px dashed var(--line); }
.ticket-qr { padding: 16px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; text-align: center; }
.ticket-qr svg { width: 160px; height: 160px; }
.ticket-band { height: 8px; }
.ticket .seatbig { font-family: var(--serif); font-size: 2rem; line-height: 1; }
.ticket .kv { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 8px 16px; margin-top: 12px; }
.ticket .kv .k { font-size: .72rem; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.ticket .kv .v { font-weight: 600; }
.code { font-family: ui-monospace, Consolas, monospace; font-size: .7rem; color: var(--muted); word-break: break-all; }
.wa-preview { background: #e7ddd3; border-radius: 16px; padding: 16px; }
.wa-bubble { background: #fff; border-radius: 4px 12px 12px 12px; padding: 10px 12px; max-width: 320px; font-size: .9rem; box-shadow: 0 1px 1px rgba(0,0,0,.1); }
.wa-bubble .wa-btn { display: block; text-align: center; color: #0a7cff; border-top: 1px solid #eee; margin-top: 8px; padding-top: 8px; font-weight: 500; }

/* Scanner */
.scanner { max-width: 560px; margin: 0 auto; }
.video-box { position: relative; background: #111; border-radius: 16px; overflow: hidden; aspect-ratio: 1; display: grid; place-items: center; color: #aaa; }
.video-box video { width: 100%; height: 100%; object-fit: cover; }
.video-box .frame { position: absolute; inset: 18%; border: 3px solid rgba(255,255,255,.8); border-radius: 18px; pointer-events: none; }
.result { border-radius: 16px; padding: 22px; color: #fff; text-align: center; margin: 16px 0; animation: pop .25s ease; }
.result h2 { font-family: 'Noto Sans Bengali', sans-serif; font-size: 1.8rem; margin: 0 0 4px; }
.result .big { font-family: var(--serif); font-size: 2.6rem; line-height: 1.1; margin: 6px 0; }
.result.ok { background: var(--ok); }
.result.bad { background: var(--bad); }
.result.warn { background: var(--warn); }
@keyframes pop { from { transform: scale(.94); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.test-btns { display: flex; flex-wrap: wrap; gap: 8px; }

/* Dashboard */
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 14px; margin-bottom: 20px; }
.kpi { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.kpi .k { font-size: .8rem; color: var(--muted); }
.kpi .v { font-family: var(--serif); font-size: 1.9rem; line-height: 1.2; }
.tier-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 14px; margin-bottom: 20px; }
.tcard { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; border-top: 6px solid; }
.tcard.t500 { border-top-color: var(--t500); }
.tcard.t300 { border-top-color: var(--t300); }
.tcard.t200 { border-top-color: var(--t200); }
.tcard .nums { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin: 12px 0; text-align: center; }
.tcard .nums .v { font-family: var(--serif); font-size: 1.4rem; line-height: 1.1; }
.tcard .nums .k { font-size: .7rem; color: var(--muted); }
.bar { height: 10px; border-radius: 99px; background: #f0e9df; overflow: hidden; display: flex; }
.bar i { display: block; height: 100%; transition: width .4s; }
.feed { max-height: 320px; overflow-y: auto; }
.feed-item { display: flex; justify-content: space-between; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: .9rem; animation: pop .3s ease; }
.dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 6px; }
.live { display: inline-flex; align-items: center; gap: 6px; font-size: .8rem; font-weight: 600; color: var(--bad); }
.live::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--bad); animation: blink 1.2s infinite; }
@keyframes blink { 50% { opacity: .2; } }
table.list { width: 100%; border-collapse: collapse; font-size: .9rem; }
table.list th, table.list td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); }
table.list th { font-size: .75rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.table-wrap { overflow-x: auto; }

.policy { max-width: 760px; }
.policy h3 { margin-top: 1.4em; }

.footer { background: #2b1f1a; color: #e9dcc9; padding: 36px 20px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 24px; margin-top: 40px; }
.footer p { margin: 6px 0 0; font-size: .9rem; opacity: .85; }
.footer-links { display: flex; flex-direction: column; gap: 6px; }
.footer-links a { color: #f2c46d; text-decoration: none; font-size: .92rem; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%) translateY(120px); background: #241a17; color: #fff; padding: 12px 18px; border-radius: 12px; font-size: .92rem; transition: transform .3s; z-index: 50; max-width: calc(100% - 32px); }
.toast.show { transform: translateX(-50%) translateY(0); }

@media (max-width: 820px) {
  .detail, .book { grid-template-columns: minmax(0, 1fr); }
  .poster.tall { aspect-ratio: 4 / 3; }
  .hero-inner { padding: 56px 20px 48px; }
  .hero::before, .hero::after { width: 8%; }
  .ticket { grid-template-columns: minmax(0, 1fr); }
  .ticket-main { border-right: 0; border-bottom: 2px dashed var(--line); }
  .sched-row { grid-template-columns: 70px minmax(0, 1fr); }
  .sched-row .btn { grid-column: 1 / -1; }
  .topbar { padding: 10px 16px; }
}
@media print {
  .demo-banner, .topbar, .footer, .no-print { display: none !important; }
  body { background: #fff; }
}
