/**
 * Ensemble — Tischreservierung am Ort (23.10.2026)
 * Nur Variablen --ensemble-*; Themes legen Feinheiten nach.
 */
.es-tr {
    --es-tr-gap: 1.25rem;
    --es-tr-accent: var(--ensemble-primary, #2271b1);
    --es-tr-accent-contrast: var(--ensemble-primary-contrast, #fff);
    --es-tr-line: var(--ensemble-border, #d7d7db);
    --es-tr-surface: var(--ensemble-surface, #fff);
    --es-tr-surface-2: var(--ensemble-surface-secondary, #f4f4f5);
    --es-tr-text: var(--ensemble-text, #1d1d1f);
    --es-tr-muted: var(--ensemble-text-muted, #6b6b70);
    --es-tr-radius: var(--ensemble-radius, 6px);
    color: var(--es-tr-text);
    font-family: var(--ensemble-font-body, inherit);
}
.es-tr__flow { display: grid; gap: var(--es-tr-gap); }
.es-tr__step { border: 0; margin: 0; padding: 0; min-width: 0; }
.es-tr__step[hidden], .es-tr__flow[hidden] { display: none; }
.es-tr__label {
    display: block;
    margin: 0 0 .5rem;
    padding: 0;
    font-family: var(--ensemble-font-display, inherit);
    font-weight: 700;
    font-size: .8rem;
    letter-spacing: .08em;
    text-transform: uppercase;
}
.es-tr__hint { margin: .4rem 0 0; font-size: .875rem; color: var(--es-tr-muted); }
.es-tr__hint:empty { display: none; }
.es-tr__note { margin: 0 0 var(--es-tr-gap); }

/* Kalender */
.es-tr__calendar { max-width: 22rem; }
.es-tr__cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: .4rem; }
.es-tr__cal-title { font-weight: 600; } /* 03.11.2026: kein capitalize mehr, sonst "Noviembre De 2026"; der erste Buchstabe wird im JS gross */
.es-tr__cal-nav {
    width: 2.25rem; height: 2.25rem;
    border: 1px solid var(--es-tr-line); border-radius: var(--es-tr-radius);
    background: var(--es-tr-surface); color: inherit; font-size: 1.25rem; line-height: 1; cursor: pointer;
}
.es-tr__cal-nav:disabled { opacity: .35; cursor: default; }
.es-tr__cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 3px; }
.es-tr__cal-wd { font-size: .7rem; text-align: center; color: var(--es-tr-muted); text-transform: uppercase; padding: .2rem 0; }
.es-tr__day {
    aspect-ratio: 1; min-height: 2.25rem;
    border: 1px solid var(--es-tr-line); border-radius: var(--es-tr-radius);
    background: var(--es-tr-surface); color: inherit; font: inherit; font-size: .9rem; cursor: pointer;
}
.es-tr__day:disabled { border-color: transparent; background: transparent; color: var(--es-tr-muted); opacity: .45; cursor: default; }
.es-tr__day.is-today { font-weight: 700; }
.es-tr__day:not(:disabled):hover { border-color: var(--es-tr-accent); }
.es-tr__day.is-selected { background: var(--es-tr-accent); border-color: var(--es-tr-accent); color: var(--es-tr-accent-contrast); }
.es-tr__calendar[aria-busy="true"] .es-tr__cal-grid { opacity: .5; }

/* Personen */
.es-tr__select, .es-tr__field input:not([type="checkbox"]), .es-tr__field select, .es-tr__field textarea {
    width: 100%; max-width: 22rem; box-sizing: border-box;
    padding: .6rem .75rem;
    border: 1px solid var(--es-tr-line); border-radius: var(--es-tr-radius);
    background: var(--es-tr-surface); color: inherit; font: inherit;
}
.es-tr__field textarea { max-width: none; }

/* Zeiten */
.es-tr__times { display: flex; flex-wrap: wrap; gap: .4rem; }
.es-tr__time {
    min-width: 4.5rem; padding: .55rem .8rem;
    border: 1px solid var(--es-tr-line); border-radius: var(--es-tr-radius);
    background: var(--es-tr-surface); color: inherit; font: inherit; font-variant-numeric: tabular-nums; cursor: pointer;
}
.es-tr__time:hover { border-color: var(--es-tr-accent); }
.es-tr__time.is-selected { background: var(--es-tr-accent); border-color: var(--es-tr-accent); color: var(--es-tr-accent-contrast); }

/* Plan */
.es-tr__plan { background: var(--es-tr-surface-2); border-radius: var(--es-tr-radius); padding: .75rem; }
.es-tr__svg { display: block; width: 100%; height: auto; }
.es-tr__el .es-tr__shape { fill: var(--es-tr-surface); stroke: var(--es-tr-line); stroke-width: 2; }
.es-tr__el--deco .es-tr__shape { fill: var(--es-tr-line); stroke: none; opacity: .6; }
.es-tr__el-label { font-weight: 700; fill: var(--es-tr-text); pointer-events: none; }
.es-tr__el--deco .es-tr__el-label { font-weight: 600; letter-spacing: .06em; fill: var(--es-tr-muted); }
.es-tr__el.is-free { cursor: pointer; }
.es-tr__el.is-free .es-tr__shape { stroke: var(--es-tr-accent); }
.es-tr__el.is-free:hover .es-tr__shape, .es-tr__el.is-free:focus .es-tr__shape { stroke-width: 4; }
.es-tr__el.is-free:focus { outline: none; }
.es-tr__el.is-selected .es-tr__shape { fill: var(--es-tr-accent); stroke: var(--es-tr-accent); }
.es-tr__el.is-selected .es-tr__el-label { fill: var(--es-tr-accent-contrast); }
.es-tr__el.is-taken .es-tr__shape { fill: var(--es-tr-line); stroke: var(--es-tr-line); }
.es-tr__el.is-taken .es-tr__el-label, .es-tr__el.is-small .es-tr__el-label { fill: var(--es-tr-muted); }
.es-tr__el.is-small .es-tr__shape { stroke-dasharray: 5 4; }
.es-tr__legend { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem 1rem; margin: .6rem 0 0; font-size: .8rem; color: var(--es-tr-muted); }
.es-tr__key::before { content: ""; display: inline-block; width: .8em; height: .8em; margin-right: .35em; vertical-align: -.05em; border-radius: 2px; border: 2px solid var(--es-tr-line); }
.es-tr__key--free::before { border-color: var(--es-tr-accent); background: var(--es-tr-surface); }
.es-tr__key--taken::before { background: var(--es-tr-line); }
.es-tr__key--small::before { border-style: dashed; }
.es-tr__any {
    margin-left: auto; padding: .35rem .7rem;
    border: 1px solid var(--es-tr-line); border-radius: var(--es-tr-radius);
    background: var(--es-tr-surface); color: inherit; font: inherit; font-size: .8rem; cursor: pointer;
}
.es-tr__any.is-selected { border-color: var(--es-tr-accent); color: var(--es-tr-accent); }

/* Angaben */
.es-tr__summary { margin: 0 0 .75rem; font-weight: 600; }
.es-tr__field { margin: 0 0 .75rem; }
.es-tr__field > label { display: block; margin-bottom: .25rem; font-size: .875rem; }
.es-tr__field--privacy label { display: flex; gap: .5rem; align-items: flex-start; font-size: .85rem; }
.es-tr__field--privacy input { margin-top: .2rem; }
.es-tr__hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.es-tr__message { margin: 0 0 .75rem; padding: .6rem .8rem; border-left: 3px solid var(--ensemble-error, #b32d2e); background: var(--es-tr-surface-2); }
.es-tr__message[hidden] { display: none; }
.es-tr__submit, .es-tr__again {
    padding: .8rem 1.4rem; border: 0; border-radius: var(--es-tr-radius);
    background: var(--es-tr-accent); color: var(--es-tr-accent-contrast);
    font: inherit; font-weight: 700; cursor: pointer;
}
.es-tr__submit:disabled { opacity: .6; cursor: wait; }

/* Bestätigung */
.es-tr__done { padding: 1.25rem; border: 1px solid var(--es-tr-line); border-left: 4px solid var(--ensemble-success, #00a32a); border-radius: var(--es-tr-radius); background: var(--es-tr-surface); }
.es-tr__done--pending { border-left-color: var(--es-tr-accent); }
.es-tr__done:focus { outline: none; }
.es-tr__done-title { margin: 0 0 .5rem; font-family: var(--ensemble-font-display, inherit); font-size: 1.25rem; font-weight: 700; }
.es-tr__done-list { margin: 0 0 .75rem; padding: 0; list-style: none; }
.es-tr__done-code { display: flex; gap: .6rem; align-items: baseline; margin: 0 0 .5rem; }
.es-tr__done-code span { font-size: .8rem; color: var(--es-tr-muted); text-transform: uppercase; letter-spacing: .06em; }
.es-tr__done-code strong { font-size: 1.4rem; letter-spacing: .1em; font-variant-numeric: tabular-nums; }
.es-tr__done-text { margin: 0 0 1rem; color: var(--es-tr-muted); }
