/* MYCastings styles: the mockup's CSS, with inline styles turned into classes. */
/* Layout: a theatre programme on a phone. One column, a bottom bar for the two views, and no decoration that carries no information. */
:root {
  --bg: #1c0f12; --panel: #26161a; --ink: #f6eee6; --mute: #b9a8a0; --line: #3d2a2e; --line2: #5a4046;
  --accent: #e8b84a; --accent-soft: #3a2c16; --ok: #8fd1a6; --warn: #f2a26b; --warn-soft: #3a2418;
  --display: "DM Serif Display", Georgia, serif; --sans: "Figtree", system-ui, sans-serif;
  color-scheme: dark;
}
/* The four themes the user picks in the top bar. Each sets every colour. The first one is the default. */
:root[data-skin="telon"] { --bg: #1c0f12; --panel: #26161a; --ink: #f6eee6; --mute: #b9a8a0; --line: #3d2a2e; --line2: #5a4046; --accent: #e8b84a; --accent-soft: #3a2c16; --ok: #8fd1a6; --warn: #f2a26b; --warn-soft: #3a2418; color-scheme: dark; }
:root[data-skin="rojo"] { --bg: #ffffff; --panel: #fff7f7; --ink: #1a1a1a; --mute: #666666; --line: #f2cccc; --line2: #e39a9a; --accent: #c8102e; --accent-soft: #fde3e6; --ok: #1f7a4a; --warn: #9a4a12; --warn-soft: #fff0dc; color-scheme: light; }
:root[data-skin="azul"] { --bg: #ffffff; --panel: #f4f7fd; --ink: #0f1f3d; --mute: #5a6780; --line: #d6e0f2; --line2: #a8bade; --accent: #1d4ed8; --accent-soft: #dfe8ff; --ok: #15803d; --warn: #92400e; --warn-soft: #fef3c7; color-scheme: light; }
:root[data-skin="noche"] { --bg: #0e1420; --panel: #162030; --ink: #eef3fb; --mute: #9aa8be; --line: #26344a; --line2: #3b4d68; --accent: #7dd3fc; --accent-soft: #16344a; --ok: #86efac; --warn: #fdba74; --warn-soft: #3a2a16; color-scheme: dark; }
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.5 var(--sans); overflow-x: hidden; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.screen { padding: 16px; padding-block: 20px 110px; max-width: 920px; margin: 0 auto; }
.bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; padding: calc(12px + env(safe-area-inset-top, 0px)) 16px 12px; border-bottom: 1px solid var(--line); background: var(--panel); position: sticky; top: env(safe-area-inset-top, 0px); z-index: 3; }
.brand h1 { margin: 0; font: 400 26px/1 var(--display); letter-spacing: .01em; }
.brand p { margin: 4px 0 0; color: var(--mute); font-size: 13px; }
.row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.seg { display: inline-flex; border: 1px solid var(--line2); border-radius: 999px; padding: 3px; gap: 3px; background: var(--bg); }
.seg button { border: 0; background: transparent; border-radius: 999px; padding: 8px 14px; min-height: 44px; cursor: pointer; }
.seg button[aria-pressed="true"] { background: var(--accent); color: var(--bg); font-weight: 600; }
.tools { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; flex-basis: 100%; }
.tools[hidden] { display: none; }
.btn.more { min-width: 44px; padding: 8px 12px; font-size: 20px; line-height: 1; }
.swatches { display: inline-flex; gap: 8px; align-items: center; }
.swatches button { width: 44px; height: 44px; border-radius: 50%; border: 2px solid var(--line2); cursor: pointer; padding: 0; }
.swatches button[aria-pressed="true"] { outline: 2px solid var(--accent); outline-offset: 2px; }
.btn { min-height: 44px; border: 1px solid var(--line2); background: transparent; border-radius: 10px; padding: 8px 16px; cursor: pointer; }
.btn:hover { border-color: var(--accent); }
.btn.primary { background: var(--accent); color: var(--bg); border-color: var(--accent); font-weight: 600; }
.btn:disabled { opacity: .6; cursor: progress; }
.tag { display: inline-block; font-size: 13px; padding: 3px 10px; border-radius: 999px; background: var(--accent-soft); color: var(--ink); }
.tag.ok { color: var(--ok); background: transparent; border: 1px solid var(--ok); }
.tag.warn { color: var(--warn); background: var(--warn-soft); }
.example { margin: 14px 0 0; padding: 10px 14px; border-left: 3px solid var(--accent); background: var(--panel); font-size: 14px; border-radius: 8px; }
h2 { font: 400 30px/1.1 var(--display); margin: 0 0 8px; text-wrap: balance; }
.lead { color: var(--mute); margin: 0 0 18px; }
form { display: grid; gap: 16px; max-width: 600px; }
label { display: grid; gap: 6px; font-size: 15px; }
label > span { color: var(--mute); font-size: 14px; }
input[type="text"], input[type="email"], input[type="password"], input[type="number"], textarea { width: 100%; min-height: 44px; border: 1px solid var(--line2); background: var(--bg); border-radius: 10px; padding: 10px 12px; font-size: 16px; }
textarea { min-height: 80px; resize: vertical; }
input:focus, textarea:focus { outline: 3px solid var(--accent); outline-offset: 1px; }
fieldset { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px 14px; margin: 0; min-width: 0; }
legend { font-size: 14px; color: var(--mute); padding: 0 6px; }
.checks { display: flex; flex-wrap: wrap; gap: 8px 16px; }
.checks label { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; font-size: 15px; color: var(--ink); }
.checks label span { color: var(--ink); }
.err { color: var(--warn); font-size: 14px; min-height: 1.2em; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.note { color: var(--mute); font-size: 13px; margin: 0; }
.cal-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 6px 0 14px; }
.cal-head b { font: 400 22px var(--display); }
.cal { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
.cal .dow { font-size: 12px; color: var(--mute); text-align: center; padding: 4px 0; }
.day { min-height: 84px; background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 5px; min-width: 0; }
.day.off { background: transparent; border-style: dashed; opacity: .5; }
.day.today { border-color: var(--accent); }
.day .n { font-size: 13px; color: var(--mute); font-variant-numeric: tabular-nums; }
.day button { display: block; width: 100%; text-align: left; margin-top: 4px; border: 0; background: var(--accent-soft); color: var(--ink); border-radius: 6px; padding: 4px 6px; font-size: 12px; line-height: 1.25; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; cursor: pointer; min-height: 28px; }
.day button.cb { background: transparent; border: 1px solid var(--ok); }
.day button.fit { background: transparent; border: 1px solid var(--warn); }
.day button.cast { background: transparent; border: 1px solid var(--accent); }
.day button.end { background: transparent; border: 1px dashed var(--line2); color: var(--mute); }
.list { display: grid; gap: 14px; }
.cast { border: 1px solid var(--line); border-radius: 16px; background: var(--panel); padding: 18px; min-width: 0; }
.cast[data-open="true"] { border-color: var(--accent); }
.cast h3 { margin: 0; font: 400 24px/1.15 var(--display); overflow-wrap: anywhere; }
.cast .meta { color: var(--mute); font-size: 14px; margin-top: 4px; }
.cast .head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; align-items: flex-start; }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px 18px; margin: 14px 0 0; }
.fact span { display: block; color: var(--mute); font-size: 13px; }
.fact b { font-weight: 500; overflow-wrap: anywhere; font-variant-numeric: tabular-nums; }
.sec { margin-top: 16px; border-top: 1px solid var(--line); padding-top: 14px; }
.sec h4 { margin: 0 0 10px; font-size: 15px; font-weight: 600; }
ul.plain { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.chk { display: flex; gap: 10px; align-items: flex-start; }
.chk input { margin-top: 6px; width: 18px; height: 18px; }
.copy { min-height: 44px; border: 1px solid var(--line2); background: transparent; border-radius: 8px; font-size: 13px; padding: 4px 10px; cursor: pointer; margin-left: 8px; }
.matched { color: var(--ok); }
.none { color: var(--mute); }
.notes { white-space: pre-wrap; background: var(--bg); border: 1px solid var(--line2); border-radius: 10px; padding: 12px 14px; font-size: 15px; overflow-wrap: anywhere; }
.traits { border: 1px solid var(--line); border-radius: 14px; background: var(--panel); padding: 14px 16px; margin: 0 0 16px; }
.traits h4 { margin: 0; font: 600 16px/1.3 var(--sans); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.chip { min-height: 44px; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line2); background: transparent; cursor: pointer; }
.chip[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--bg); font-weight: 600; }
.chip[aria-pressed="false"] { color: var(--mute); text-decoration: line-through; }
.toast { position: fixed; left: 50%; bottom: calc(96px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); background: var(--ink); color: var(--bg); padding: 12px 18px; border-radius: 12px; font-size: 15px; z-index: 9; max-width: calc(100vw - 32px); }
@media (max-width: 640px) {
  .grid2 { grid-template-columns: 1fr; }
  .cal { grid-template-columns: 1fr; gap: 6px; }
  .cal .dow { display: none; }
  .day { min-height: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; padding: 8px 10px; }
  .day.off, .day:not(:has(button)) { display: none; }
  .day .n { font-size: 15px; color: var(--ink); min-width: 28px; }
  .day button { flex: 1 1 150px; margin-top: 0; font-size: 13px; min-height: 40px; white-space: normal; }
  .viewbar { position: fixed; left: 12px; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom, 0px)); z-index: 4; justify-content: center; background: var(--panel); box-shadow: 0 8px 24px rgb(0 0 0 / .3); }
  .viewbar button { flex: 1; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
.origin { margin: 8px 0 0; font-size: 14px; color: var(--mute); overflow-wrap: anywhere; }
.origin b { color: var(--ink); font-weight: 600; }
.inline { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; }
.inline span { color: var(--ink); }
.slotrow { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.slotrow:last-child { border-bottom: 0; }
.slotrow > div { min-width: 0; flex: 1 1 180px; overflow-wrap: anywhere; }
.slotpick { display: inline-flex; flex-direction: column; gap: 6px; font-size: 14px; max-width: 100%; }
.slotpick input { max-width: 100%; font-size: 14px; }
.sendform { margin-top: 12px; max-width: none; }
.linkbox { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.linkbox code { flex: 1 1 200px; overflow-wrap: anywhere; font-size: 14px; background: var(--bg); border: 1px solid var(--line2); border-radius: 8px; padding: 8px 10px; }
.cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 14px; }
.col { border: 1px solid var(--line); border-radius: 16px; background: var(--panel); padding: 16px; min-width: 0; display: grid; gap: 10px; align-content: start; }
.col .head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; align-items: flex-start; }
.col h3 { margin: 0; font: 400 22px/1.15 var(--display); overflow-wrap: anywhere; }
.files { display: grid; gap: 8px; }
.files li { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.pubh { font: 400 26px/1.1 var(--display); margin: 22px 0 12px; }
.viewbar button { white-space: nowrap; padding: 8px 10px; }

/* ---- classes that replace the mockup's inline style attributes ---- */
.mt10 { margin-top: 10px; }
.mt12 { margin-top: 12px; }
.mt14 { margin-top: 14px; }
.facts.mt12 { margin-top: 12px; }
.lead.big { font-size: 19px; color: var(--ink); }
.toolrow { justify-content: space-between; margin-bottom: 12px; }
.row.tight { gap: 6px; }
.row.spread { justify-content: space-between; }
.note.calnote { margin: 0 0 10px; }
.sw-telon { background: linear-gradient(135deg, #1c0f12 50%, #e8b84a 50%); }
.sw-rojo { background: linear-gradient(135deg, #ffffff 50%, #c8102e 50%); }
.sw-azul { background: linear-gradient(135deg, #ffffff 50%, #1d4ed8 50%); }
.sw-noche { background: linear-gradient(135deg, #0e1420 50%, #7dd3fc 50%); }
/* ---- additions for the live app ---- */
input[type="date"], select { width: 100%; min-height: 44px; border: 1px solid var(--line2); background: var(--bg); border-radius: 10px; padding: 10px 12px; font-size: 16px; }
.classfilter { display: inline-flex; align-items: center; gap: 8px; }
.classfilter select { width: auto; max-width: 100%; }
a.btn { display: inline-flex; align-items: center; text-decoration: none; color: inherit; }
.pdfrow { margin-top: 12px; }
.err { overflow-wrap: anywhere; }

/* ---- I-0001B: the handle field, the address row, the field error ---- */
.sr { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0; }
.field { display: grid; gap: 6px; }
.field > label { color: var(--mute); font-size: 14px; }
.newform input[type], .newform select { border-color: #8a6c73; }
.newform input:focus, .newform button:focus-visible { outline: 2px solid #e8b84a; outline-offset: 2px; }
.newform .note { font-size: 14px; }
.handlefield { display: flex; align-items: stretch; min-width: 0; }
.handlefield input[type] { flex: 1 1 auto; min-width: 0; border-radius: 10px 0 0 10px; }
.handlefield .suffix { display: flex; align-items: center; flex: 0 0 auto; min-width: 0; min-height: 44px; padding: 0 12px; background: var(--panel); border: 1px solid #8a6c73; border-left: 0; border-radius: 0 10px 10px 0; font-size: 16px; white-space: nowrap; user-select: none; }
.handlefield.invalid input[type], .handlefield.invalid .suffix { border: 2px solid var(--warn); }
.handlefield.invalid .suffix { border-left: 0; }
.fielderr { margin: 0; color: var(--warn); font-size: 14px; overflow-wrap: anywhere; }
.fielderr::before { content: "⚠ "; }
.fielderr:empty::before { content: none; }
.btn.full { width: 100%; }
.newform .btn.primary { margin-top: 4px; }
.btn.link { border: 0; background: transparent; color: var(--accent); text-decoration: underline; justify-self: center; }
.addressrow { display: flex; flex-wrap: nowrap; gap: 8px; align-items: flex-start; margin-top: 8px; }
.addressrow .origin { flex: 1 1 0; min-width: 0; margin: 0; padding: 10px 12px; background: var(--panel); border: 1px solid #8a6c73; border-radius: 10px; font-size: 16px; color: var(--ink); overflow-wrap: anywhere; user-select: text; }
.addressrow .origin span { color: var(--mute); font-size: 14px; }
.addressrow .origin b { color: var(--ink); font-weight: 600; user-select: text; }
#copy-address { flex: 0 0 auto; min-width: 44px; min-height: 44px; border-color: #8a6c73; white-space: nowrap; }
.copystatus { margin: 6px 0 0; color: var(--ok); font-size: 14px; }
.copystatus:empty { margin: 0; }
#copy-err { margin-top: 6px; }
#copy-err:empty { margin: 0; }
#address-help { display: block; margin: 6px 0 16px; font-size: 14px; }
#address-help:empty { margin: 0; }
@media (max-width: 339px) { .addressrow { flex-direction: column; align-items: stretch; } }
