/* ==========================================================================
   Digital Invitations — creator app
   ========================================================================== */

:root {
    --gold: #BD945A;
    --gold-dark: #9d7a45;
    --gold-soft: #f4ece0;
    --ink: #16130f;
    --body: #5f5952;
    --muted: #918a81;
    --paper: #f7f4ef;
    --card: #ffffff;
    --line: #e6ded2;
    --green: #3f7d58;
    --green-soft: #e8f2ec;
    --red: #b0483f;
    --red-soft: #f9ebea;
    --amber: #b5852a;
    --amber-soft: #fbf1dd;
    --blue: #3d6a8f;
    --blue-soft: #e9f0f6;
    --radius: 6px;
    --shadow: 0 1px 2px rgba(22, 19, 15, .05), 0 8px 24px rgba(22, 19, 15, .05);
    --sidebar: 248px;
}

*, *::before, *::after { box-sizing: border-box; }

html, body { height: 100%; }

body {
    margin: 0;
    background: var(--paper);
    color: var(--body);
    font-family: 'Nunito Sans', sans-serif;
    font-size: 15px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4 {
    font-family: 'Cormorant Garamond', serif;
    color: var(--ink);
    line-height: 1.2;
    margin: 0 0 12px;
    font-weight: 600;
}

h1 { font-size: 34px; }
h2 { font-size: 26px; }
h3 { font-size: 20px; }
h4 { font-size: 17px; font-family: 'Nunito Sans', sans-serif; font-weight: 700; }

p { margin: 0 0 14px; }

a { color: var(--gold-dark); }

hr { border: 0; border-top: 1px solid var(--line); margin: 26px 0; }

.script { font-family: 'Alex Brush', cursive; color: var(--gold); }

.muted { color: var(--muted); }
.small { font-size: 13px; }
.tiny { font-size: 12px; }
.center { text-align: center; }
.right { text-align: right; }
.nowrap { white-space: nowrap; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12px; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.mb-8 { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.hidden { display: none !important; }

/* ==========================================================================
   Layout
   ========================================================================== */
.layout { display: flex; min-height: 100vh; }

.sidebar {
    width: var(--sidebar);
    flex: 0 0 var(--sidebar);
    background: var(--ink);
    color: rgba(255, 255, 255, .72);
    padding: 24px 0;
    display: flex;
    flex-direction: column;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
}

.sidebar .brand {
    display: block;
    padding: 0 20px 22px;
    font-family: 'Cormorant Garamond', serif;
    font-size: 17px;
    letter-spacing: .1em;
    text-transform: uppercase;
    white-space: nowrap;
    color: #fff;
    text-decoration: none;
    border-bottom: 1px solid rgba(255, 255, 255, .1);
}

.sidebar .brand span { color: var(--gold); }

.nav { list-style: none; margin: 18px 0 0; padding: 0; flex: 1; }

.nav a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 24px;
    color: rgba(255, 255, 255, .68);
    text-decoration: none;
    font-size: 14px;
    border-left: 3px solid transparent;
    transition: .2s;
}

.nav a:hover { color: #fff; background: rgba(255, 255, 255, .05); }

.nav a.active {
    color: #fff;
    background: rgba(189, 148, 90, .16);
    border-left-color: var(--gold);
}

.nav .ico { width: 18px; text-align: center; opacity: .85; }

.nav .count {
    margin-left: auto;
    font-size: 11px;
    background: rgba(255, 255, 255, .12);
    border-radius: 20px;
    padding: 1px 8px;
}

.sidebar-foot { padding: 18px 24px 0; border-top: 1px solid rgba(255, 255, 255, .1); font-size: 12px; }
.sidebar-foot a { color: var(--gold); text-decoration: none; }
.sidebar-foot a:hover { text-decoration: underline; }
.sidebar-foot .saved { color: rgba(255, 255, 255, .45); display: block; margin-top: 8px; }

.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }

.topbar {
    background: #fff;
    border-bottom: 1px solid var(--line);
    padding: 14px 32px;
    display: flex;
    align-items: center;
    gap: 16px;
    position: sticky;
    top: 0;
    z-index: 20;
}

.topbar .title { font-family: 'Cormorant Garamond', serif; font-size: 22px; color: var(--ink); font-weight: 600; }
.topbar .event-name { font-size: 13px; color: var(--muted); }
.topbar .spacer { flex: 1; }

.menu-toggle {
    display: none;
    background: none;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 6px 10px;
    font-size: 16px;
    cursor: pointer;
    color: var(--ink);
}

.content { padding: 30px 32px 80px; max-width: 1180px; width: 100%; }

.view { display: none; }
.view.active { display: block; animation: fade .25s ease; }

@keyframes fade { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

.page-head { margin-bottom: 26px; }
.page-head h1 { margin-bottom: 6px; }
.page-head p { margin: 0; color: var(--muted); }

/* ==========================================================================
   Cards, grids
   ========================================================================== */
.card {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 24px;
    margin-bottom: 22px;
}

.card > h3:first-child, .card > h4:first-child { margin-top: 0; }

.card-head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 18px;
    flex-wrap: wrap;
}

.card-head h3, .card-head h4 { margin: 0; }
.card-head .spacer { flex: 1; }

.grid { display: grid; gap: 20px; }
.grid.cols-2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.grid.cols-3 { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.grid.cols-4 { grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }

/* stat tiles */
.stat {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 20px;
    box-shadow: var(--shadow);
}

.stat .label {
    font-size: 11px;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: var(--muted);
    font-weight: 600;
}

.stat .value {
    font-family: 'Cormorant Garamond', serif;
    font-size: 42px;
    line-height: 1.1;
    color: var(--ink);
    margin: 6px 0 2px;
    font-weight: 600;
}

.stat .sub { font-size: 13px; color: var(--muted); }
.stat.accent { border-color: var(--gold); background: linear-gradient(180deg, #fff, var(--gold-soft)); }
.stat.good .value { color: var(--green); }
.stat.bad .value { color: var(--red); }
.stat.wait .value { color: var(--amber); }

/* progress */
.bar { height: 8px; border-radius: 8px; background: var(--gold-soft); overflow: hidden; margin: 10px 0 6px; }
.bar span { display: block; height: 100%; background: var(--gold); border-radius: 8px; transition: width .4s; }

.tally { margin: 0; padding: 0; list-style: none; }

.tally li { padding: 9px 0; border-bottom: 1px solid var(--line); }
.tally li:last-child { border-bottom: 0; }

.tally .row { display: flex; align-items: baseline; gap: 10px; }
.tally .name { flex: 1; color: var(--ink); font-weight: 600; font-size: 14px; }
.tally .num { font-family: 'Cormorant Garamond', serif; font-size: 22px; color: var(--gold-dark); font-weight: 600; }
.tally .track { height: 6px; border-radius: 6px; background: var(--paper); margin-top: 6px; overflow: hidden; }
.tally .track span { display: block; height: 100%; background: var(--gold); }

/* ==========================================================================
   Forms
   ========================================================================== */
.field { margin-bottom: 16px; }

label, .label {
    display: block;
    font-size: 12px;
    letter-spacing: .1em;
    text-transform: uppercase;
    font-weight: 700;
    color: var(--ink);
    margin-bottom: 6px;
}

.hint { font-size: 12px; color: var(--muted); margin-top: 5px; text-transform: none; letter-spacing: 0; font-weight: 400; }

input[type=text], input[type=email], input[type=tel], input[type=url],
input[type=date], input[type=time], input[type=number], input[type=search],
select, textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    font-family: inherit;
    font-size: 15px;
    color: var(--ink);
    transition: border-color .2s, box-shadow .2s;
}

input:focus, select:focus, textarea:focus {
    outline: 0;
    border-color: var(--gold);
    box-shadow: 0 0 0 3px rgba(189, 148, 90, .16);
}

textarea { min-height: 110px; resize: vertical; line-height: 1.6; }

select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath fill='%23918a81' d='M0 0h10L5 6z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 32px; }

.check { display: flex; align-items: flex-start; gap: 10px; margin-bottom: 12px; cursor: pointer; }
.check input { margin-top: 3px; accent-color: var(--gold); width: 16px; height: 16px; flex: 0 0 auto; }
.check span { font-size: 14px; text-transform: none; letter-spacing: 0; font-weight: 400; color: var(--body); }
.check strong { display: block; color: var(--ink); font-weight: 600; }

.row { display: grid; gap: 16px; }
.row.two { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.row.three { grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); }

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 18px;
    border: 1px solid var(--gold);
    border-radius: var(--radius);
    background: var(--gold);
    color: #fff;
    font-family: inherit;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    text-decoration: none;
    cursor: pointer;
    transition: .2s;
    white-space: nowrap;
}

.btn:hover { background: var(--gold-dark); border-color: var(--gold-dark); color: #fff; }
.btn:disabled { opacity: .5; cursor: not-allowed; }

.btn.ghost { background: #fff; color: var(--ink); border-color: var(--line); }
.btn.ghost:hover { border-color: var(--gold); color: var(--gold-dark); background: #fff; }

.btn.danger { background: #fff; color: var(--red); border-color: #e3c7c4; }
.btn.danger:hover { background: var(--red); color: #fff; border-color: var(--red); }

.btn.small { padding: 6px 12px; font-size: 11px; }
.btn.block { width: 100%; }
.btn.big { padding: 14px 26px; font-size: 14px; }

.btn-row { display: flex; gap: 10px; flex-wrap: wrap; }

.icon-btn {
    background: none;
    border: 0;
    color: var(--muted);
    cursor: pointer;
    padding: 4px 6px;
    border-radius: 4px;
    font-size: 14px;
    transition: .15s;
}

.icon-btn:hover { color: var(--gold-dark); background: var(--gold-soft); }
.icon-btn.danger:hover { color: var(--red); background: var(--red-soft); }

/* ==========================================================================
   Tables
   ========================================================================== */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }

table { width: 100%; border-collapse: collapse; font-size: 14px; }

th {
    text-align: left;
    padding: 12px 14px;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    font-size: 11px;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--muted);
    font-weight: 700;
    white-space: nowrap;
}

td { padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: top; color: var(--body); }

tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: #fdfbf8; }

td .name { color: var(--ink); font-weight: 600; }

.empty { padding: 44px 24px; text-align: center; color: var(--muted); }
.empty .big { font-size: 30px; color: var(--line); margin-bottom: 8px; }

/* ==========================================================================
   Pills / badges
   ========================================================================== */
.pill {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    white-space: nowrap;
}

.pill.yes { background: var(--green-soft); color: var(--green); }
.pill.no { background: var(--red-soft); color: var(--red); }
.pill.maybe { background: var(--blue-soft); color: var(--blue); }
.pill.pending { background: var(--amber-soft); color: var(--amber); }
.pill.neutral { background: var(--paper); color: var(--muted); border: 1px solid var(--line); }
.pill.gold { background: var(--gold-soft); color: var(--gold-dark); }

.tag {
    display: inline-block;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 3px;
    padding: 1px 7px;
    font-size: 11px;
    color: var(--muted);
    margin: 0 4px 4px 0;
}

/* ==========================================================================
   Toolbar / filters
   ========================================================================== */
.toolbar {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center;
    margin-bottom: 18px;
}

.toolbar input[type=search], .toolbar select { width: auto; min-width: 170px; }
.toolbar .spacer { flex: 1; }

.chips { display: flex; gap: 8px; flex-wrap: wrap; }

.chip {
    border: 1px solid var(--line);
    background: #fff;
    border-radius: 20px;
    padding: 5px 14px;
    font-size: 12px;
    font-weight: 600;
    color: var(--body);
    cursor: pointer;
    transition: .18s;
}

.chip:hover { border-color: var(--gold); color: var(--gold-dark); }
.chip.active { background: var(--ink); border-color: var(--ink); color: #fff; }

/* ==========================================================================
   Modal
   ========================================================================== */
.modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(22, 19, 15, .55);
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 40px 16px;
    z-index: 60;
    overflow-y: auto;
}

.modal-backdrop[hidden] { display: none; }

.modal {
    background: #fff;
    border-radius: var(--radius);
    width: 100%;
    max-width: 620px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, .3);
    animation: pop .2s ease;
}

.modal.wide { max-width: 860px; }

@keyframes pop { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: none; } }

.modal header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--line);
    display: flex;
    align-items: center;
    gap: 12px;
}

.modal header h3 { margin: 0; flex: 1; }
.modal .body { padding: 24px; }
.modal footer { padding: 16px 24px; border-top: 1px solid var(--line); display: flex; gap: 10px; justify-content: flex-end; background: var(--paper); border-radius: 0 0 var(--radius) var(--radius); }

/* ==========================================================================
   Toast
   ========================================================================== */
.toasts { position: fixed; bottom: 24px; right: 24px; z-index: 80; display: flex; flex-direction: column; gap: 10px; }

.toast {
    background: var(--ink);
    color: #fff;
    padding: 12px 18px;
    border-radius: var(--radius);
    font-size: 14px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, .28);
    animation: slide .25s ease;
    max-width: 340px;
}

.toast.good { background: var(--green); }
.toast.bad { background: var(--red); }

@keyframes slide { from { opacity: 0; transform: translateX(20px); } to { opacity: 1; transform: none; } }

/* ==========================================================================
   Menu items (dinner / wine)
   ========================================================================== */
.menu-item {
    display: flex;
    gap: 14px;
    align-items: flex-start;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    margin-bottom: 10px;
    background: #fff;
}

.menu-item .info { flex: 1; min-width: 0; }
.menu-item .info strong { color: var(--ink); display: block; }
.menu-item .info p { margin: 2px 0 4px; font-size: 13px; color: var(--muted); }
.menu-item .actions { display: flex; gap: 2px; }

.swatch { width: 10px; height: 10px; border-radius: 50%; display: inline-block; margin-right: 6px; vertical-align: middle; }
.swatch.red { background: #7b2233; }
.swatch.white { background: #e4d79a; }
.swatch.rose { background: #e5a3a0; }
.swatch.sparkling { background: #cbb26a; }
.swatch.none { background: #cfd6da; }

/* ==========================================================================
   Theme picker
   ========================================================================== */
.theme-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 12px; }

.theme-opt { cursor: pointer; }
.theme-opt input { position: absolute; opacity: 0; pointer-events: none; }

.theme-opt .preview {
    height: 78px;
    border-radius: var(--radius);
    border: 2px solid var(--line);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Alex Brush', cursive;
    font-size: 24px;
    transition: .2s;
}

.theme-opt input:checked + .preview { border-color: var(--ink); box-shadow: 0 0 0 3px rgba(189, 148, 90, .25); }
.theme-opt .caption { display: block; text-align: center; font-size: 12px; margin-top: 6px; color: var(--body); }

.theme-opt .preview.t-gold { background: #fffdfa; color: #BD945A; }
.theme-opt .preview.t-noir { background: #16130f; color: #d8c9ad; }
.theme-opt .preview.t-blush { background: #fdf3f1; color: #c08981; }
.theme-opt .preview.t-evergreen { background: #f2f6f2; color: #3f6b4d; }
.theme-opt .preview.t-midnight { background: #101a2b; color: #a8bedd; }
.theme-opt .preview.t-sand { background: #f8f4ec; color: #9a8464; }

/* ==========================================================================
   Share / links
   ========================================================================== */
.link-box {
    display: flex;
    gap: 8px;
    align-items: stretch;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 8px;
}

.link-box input {
    border: 0;
    background: transparent;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 12px;
    flex: 1;
    min-width: 0;
}

.link-box input:focus { box-shadow: none; }

.notice {
    border-left: 3px solid var(--gold);
    background: var(--gold-soft);
    padding: 14px 16px;
    border-radius: 0 var(--radius) var(--radius) 0;
    font-size: 14px;
    margin-bottom: 18px;
}

.notice.warn { border-left-color: var(--amber); background: var(--amber-soft); }
.notice.good { border-left-color: var(--green); background: var(--green-soft); }
.notice.danger { border-left-color: var(--red); background: var(--red-soft); }
.notice p:last-child { margin-bottom: 0; }
.notice strong { color: var(--ink); }

/* preview frame */
.preview-frame {
    width: 100%;
    height: 760px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: var(--shadow);
}

.preview-frame.phone { max-width: 400px; height: 720px; margin: 0 auto; display: block; }

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 900px) {
    .menu-toggle { display: inline-flex; }

    .sidebar {
        position: fixed;
        left: 0;
        top: 0;
        bottom: 0;
        z-index: 50;
        transform: translateX(-100%);
        transition: transform .25s ease;
    }

    .sidebar.open { transform: none; box-shadow: 0 0 60px rgba(0, 0, 0, .4); }

    .scrim { position: fixed; inset: 0; background: rgba(22, 19, 15, .5); z-index: 40; }
    .scrim[hidden] { display: none; }

    .content { padding: 22px 18px 70px; }
    .topbar { padding: 12px 18px; }
    h1 { font-size: 27px; }
}

@media (max-width: 560px) {
    .card { padding: 18px; }
    .toolbar input[type=search], .toolbar select { width: 100%; min-width: 0; }
    .toasts { left: 16px; right: 16px; bottom: 16px; }
    .toast { max-width: none; }
}

@media (prefers-reduced-motion: reduce) {
    * { animation: none !important; transition: none !important; }
}

@media print {
    .sidebar, .topbar, .toolbar, .btn, .icon-btn, .toasts { display: none !important; }
    body { background: #fff; }
    .card { box-shadow: none; border-color: #ddd; break-inside: avoid; }
}

/* ==========================================================================
   First-run wizard
   ========================================================================== */
.wizard-overlay {
    position: fixed;
    inset: 0;
    z-index: 70;
    background: var(--paper);
    overflow-y: auto;
    padding: clamp(16px, 4vw, 48px) 16px;
}

.wizard-overlay[hidden] { display: none; }

.wizard {
    max-width: 640px;
    margin: 0 auto;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: 0 20px 60px rgba(22, 19, 15, .12);
    animation: fade .3s ease;
}

.wizard-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 20px 28px;
    border-bottom: 1px solid var(--line);
}

.wizard-brand {
    font-family: 'Cormorant Garamond', serif;
    font-size: 17px;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--ink);
    white-space: nowrap;
}

.wizard-brand span { color: var(--gold); }

.wizard-skip {
    background: none;
    border: 0;
    color: var(--muted);
    font-size: 12px;
    letter-spacing: .1em;
    text-transform: uppercase;
    cursor: pointer;
    padding: 4px 0;
    border-bottom: 1px solid transparent;
}

.wizard-skip:hover { color: var(--gold-dark); border-bottom-color: var(--gold-dark); }

.wizard-dots { display: flex; gap: 8px; justify-content: center; padding: 18px 0 0; }

.wizard-dots .dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--line);
    transition: .25s;
}

.wizard-dots .dot.on { background: var(--gold); transform: scale(1.3); }
.wizard-dots .dot.done { background: var(--gold-light, #e6d3b3); }

.wizard-body { padding: 22px 28px 6px; }

.wizard-body h2 { margin-bottom: 6px; }
.wizard-body > p:first-of-type { margin-bottom: 20px; }

.wizard-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 28px 24px;
}

@media (max-width: 560px) {
    .wizard-top, .wizard-body, .wizard-foot { padding-left: 18px; padding-right: 18px; }
}

/* ==========================================================================
   Motion
   ========================================================================== */
.view-enter .card,
.view-enter .stat,
.view-enter .table-wrap,
.view-enter .toolbar,
.view-enter .page-head {
    animation: rise-in .5s cubic-bezier(.2, .7, .3, 1) both;
}

.view-enter .page-head { animation-delay: 0s; }
.view-enter .toolbar { animation-delay: .04s; }
.view-enter .stat:nth-child(1), .view-enter .card:nth-of-type(1) { animation-delay: .05s; }
.view-enter .stat:nth-child(2), .view-enter .card:nth-of-type(2) { animation-delay: .1s; }
.view-enter .stat:nth-child(3), .view-enter .card:nth-of-type(3) { animation-delay: .15s; }
.view-enter .stat:nth-child(4), .view-enter .card:nth-of-type(4) { animation-delay: .2s; }
.view-enter .card:nth-of-type(5) { animation-delay: .25s; }
.view-enter .table-wrap { animation-delay: .12s; }

@keyframes rise-in {
    from { opacity: 0; transform: translateY(14px); }
    to { opacity: 1; transform: none; }
}

/* micro-interactions. `will-change` is deliberately not set here: leaving
   every button on its own compositor layer for the sake of a 1px press
   costs memory, and a promoted layer can be hit-tested against stale
   geometry while the machine is busy — which shows up as a click landing
   just beside the button. */
.btn:active { transform: translateY(1px) scale(.985); }

.btn:not(.ghost):not(.danger) {
    position: relative;
    overflow: hidden;
}

.btn:not(.ghost):not(.danger)::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(105deg, transparent 42%, rgba(255, 255, 255, .28) 50%, transparent 58%);
    transform: translateX(-120%);
    transition: transform .5s ease;
    pointer-events: none;
}

.btn:not(.ghost):not(.danger):hover::after { transform: translateX(120%); }

.stat { transition: transform .3s cubic-bezier(.2, .7, .3, 1), box-shadow .3s; }
.stat:hover { transform: translateY(-3px); box-shadow: 0 12px 30px rgba(22, 19, 15, .1); }

.nav a { transition: color .2s, background .2s, border-color .2s, padding-left .25s; }
.nav a:hover { padding-left: 28px; }

.menu-item { transition: border-color .25s, transform .25s, box-shadow .25s; }
.menu-item:hover { border-color: var(--gold); transform: translateX(3px); box-shadow: 0 6px 18px rgba(22, 19, 15, .06); }

tbody tr { transition: background .2s; }

.modal { animation: pop-spring .32s cubic-bezier(.2, .9, .3, 1.15); }

@keyframes pop-spring {
    from { opacity: 0; transform: translateY(-14px) scale(.97); }
    to { opacity: 1; transform: none; }
}

.chip { transition: .2s cubic-bezier(.2, .7, .3, 1); }
.chip:hover { transform: translateY(-1px); }

.pill { transition: transform .2s; }

/* wizard step transitions */
.wizard-body.step-enter { animation: step-in .4s cubic-bezier(.2, .7, .3, 1) both; }

@keyframes step-in {
    from { opacity: 0; transform: translateX(22px); }
    to { opacity: 1; transform: none; }
}

.wizard-body.step-back { animation: step-back-in .4s cubic-bezier(.2, .7, .3, 1) both; }

@keyframes step-back-in {
    from { opacity: 0; transform: translateX(-22px); }
    to { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
    .view-enter .card, .view-enter .stat, .view-enter .table-wrap,
    .view-enter .toolbar, .view-enter .page-head,
    .wizard-body.step-enter, .wizard-body.step-back, .modal { animation: none; }
    .btn::after { display: none; }
}

/* ==========================================================================
   Pro
   ========================================================================== */
.pro-badge {
    display: inline-block;
    background: linear-gradient(120deg, var(--gold), #d9b87e);
    color: #fff;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    border-radius: 3px;
    padding: 1px 6px;
    margin-left: 6px;
    vertical-align: 2px;
}

.theme-opt .preview { position: relative; }

.theme-opt .preview .pro-badge {
    position: absolute;
    top: 6px;
    right: 6px;
    margin: 0;
    font-size: 8px;
}

.nav .count.gold { background: rgba(189, 148, 90, .35); color: #f0e2c8; }
.nav .count.gold.lit { background: var(--gold); color: #fff; }

/* premium + custom theme swatches */
.theme-opt .preview.t-burgundy { background: #f9f4f2; color: #7b2233; }
.theme-opt .preview.t-marble { background: #f6f7f8; color: #5f6b75; }
.theme-opt .preview.t-olive { background: #f7f7f0; color: #6b6f3d; }
.theme-opt .preview.t-lavender { background: #f8f6fb; color: #7c6ba8; }
.theme-opt .preview.t-custom {
    background: conic-gradient(from 200deg, #bd945a, #c08981, #7c6ba8, #3f6b4d, #bd945a);
    color: #fff;
    text-shadow: 0 1px 4px rgba(0, 0, 0, .4);
}

/* the custom color pickers */
.color-row { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 8px; }

.color-pick {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 11px;
    letter-spacing: .1em;
    text-transform: uppercase;
    font-weight: 700;
    color: var(--ink);
}

.color-pick input[type=color] {
    width: 74px;
    height: 40px;
    padding: 2px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    cursor: pointer;
}

/* ==========================================================================
   Type + theme pickers
   ========================================================================== */
.mood-group { margin-bottom: 18px; }

.mood-label {
    display: block;
    font-size: 10px;
    letter-spacing: .22em;
    text-transform: uppercase;
    color: var(--muted);
    font-weight: 700;
    margin-bottom: 8px;
}

.theme-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 10px; }

.theme-row .theme-opt .preview { height: 58px; font-size: 20px; }
.theme-row .theme-opt .caption { font-size: 11px; }

.font-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; }

.font-opt { cursor: pointer; display: block; }
.font-opt input { position: absolute; opacity: 0; pointer-events: none; }

.font-opt .preview {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 62px;
    border: 2px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    color: var(--ink);
    font-size: 27px;
    transition: .25s;
}

.font-opt:hover .preview { border-color: var(--gold); transform: translateY(-3px); }

.font-opt input:checked + .preview {
    border-color: var(--ink);
    box-shadow: 0 0 0 3px rgba(189, 148, 90, .25);
}

.font-opt .caption { display: block; text-align: center; font-size: 11px; margin-top: 5px; color: var(--body); }

/* ==========================================================================
   Stationery tiles, brand picker, campaign step
   ========================================================================== */
.stationery-tile .tile-preview {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 132px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 16px;
    text-align: center;
    overflow: hidden;
}

.tile-eyebrow {
    font-size: 9px;
    letter-spacing: .22em;
    text-transform: uppercase;
    opacity: .85;
}

.tile-headline {
    font-family: 'Cormorant Garamond', serif;
    font-size: 22px;
    line-height: 1.15;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.brand-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 8px; margin-top: 8px; }

.brand-opt { cursor: pointer; }
.brand-opt input { position: absolute; opacity: 0; pointer-events: none; }

.brand-chip {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 9px 12px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    font-size: 13px;
    color: var(--body);
    transition: .2s;
}

.brand-opt:hover .brand-chip { border-color: var(--brand, var(--gold)); transform: translateY(-1px); }

.brand-opt input:checked + .brand-chip {
    border-color: var(--brand, var(--gold));
    box-shadow: inset 0 0 0 1px var(--brand, var(--gold));
    color: var(--ink);
    font-weight: 600;
}

.brand-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--brand, var(--gold)); flex: 0 0 auto; }

.brand-tag {
    margin-left: auto;
    font-size: 9px;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--muted);
}

.linkish {
    background: none;
    border: 0;
    padding: 0;
    color: var(--gold-dark);
    font: inherit;
    font-size: 12px;
    text-decoration: underline;
    cursor: pointer;
}

.campaign-step .bar { height: 5px; }

/* Card tile headers must stay on one line however long the type name is. */
.stationery-tile .card-head { flex-wrap: nowrap; }

.stationery-tile .card-head h4 {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ==========================================================================
   Print shop
   ========================================================================== */
.section-head {
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: .16em;
    color: var(--muted);
    margin: 26px 0 12px;
    font-weight: 600;
}
.section-head:first-child { margin-top: 0; }

.print-controls .toolbar { margin-bottom: 12px; }
.print-controls .field { margin-bottom: 0; display: flex; align-items: center; gap: 8px; }
.print-controls .field label { margin: 0; white-space: nowrap; }
.print-controls .check { margin-bottom: 0; align-items: center; }

.print-tile { position: relative; }

.print-pick { position: absolute; top: 14px; right: 14px; z-index: 2; cursor: pointer; }
.print-pick input { width: 18px; height: 18px; accent-color: var(--gold); cursor: pointer; }
.print-pick input:disabled { cursor: not-allowed; opacity: .4; }

.print-preview {
    position: relative;
    height: 290px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-radius: 6px;
    border: 1px solid var(--line);
    background: #f4f4f5;
    box-shadow: inset 0 1px 6px rgba(0, 0, 0, .06);
    transition: transform .35s cubic-bezier(.2, .8, .3, 1), box-shadow .35s ease;
}

.print-tile:hover .print-preview {
    transform: translateY(-3px);
    box-shadow: 0 12px 26px rgba(0, 0, 0, .14);
}

.print-preview .paper {
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, .16);
}

.print-blank {
    font-size: 12px;
    color: var(--muted);
    letter-spacing: .08em;
    text-transform: uppercase;
}

@media (prefers-reduced-motion: reduce) {
    .print-preview, .print-tile:hover .print-preview { transition: none; transform: none; }
}

/* Column mapping when a guest list arrives from somewhere else */
.map-table { max-height: 300px; overflow-y: auto; margin-bottom: 16px; }
.map-table table { font-size: 13px; }
.map-table td, .map-table th { padding: 6px 8px; }
.map-table select { width: 100%; min-width: 150px; padding: 6px 8px; font-size: 13px; }

/* ==========================================================================
   Day-of arrivals board
   ========================================================================== */
.checkin-group .bar { margin: 4px 0 14px; }

.checkin-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
    gap: 8px;
}

.checkin {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    text-align: left;
    padding: 10px 12px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--card);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: border-color .2s ease, background .25s ease, transform .18s cubic-bezier(.2,.8,.3,1);
}

.checkin:hover { border-color: var(--gold); transform: translateY(-1px); }
.checkin:active { transform: translateY(0) scale(.99); }

.checkin .tick {
    flex: 0 0 auto;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 1.5px solid var(--line);
    display: flex;
    align-items: center;
    justify-content: center;
    color: transparent;
    font-size: 12px;
    transition: background .25s ease, border-color .25s ease, color .25s ease, transform .3s cubic-bezier(.2,1.4,.4,1);
}

.checkin .who { min-width: 0; flex: 1; }
.checkin .who .n { display: block; font-size: 14px; color: var(--ink); }
.checkin .who .d {
    display: block;
    font-size: 11px;
    color: var(--muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.checkin .at { font-size: 11px; color: var(--green); white-space: nowrap; }
.checkin .vip { color: var(--gold); font-size: 10px; }

.checkin.in { background: var(--green-soft); border-color: var(--green); }
.checkin.in .tick {
    background: var(--green);
    border-color: var(--green);
    color: #fff;
    transform: scale(1.08);
}
.checkin.in .who .n { color: var(--green); }

@media (prefers-reduced-motion: reduce) {
    .checkin, .checkin .tick { transition: none; }
    .checkin:hover, .checkin:active { transform: none; }
}

/* ==========================================================================
   Reply curve
   ========================================================================== */
.curve { width: 100%; height: 150px; display: block; overflow: visible; }
.curve .area { fill: var(--gold-soft, rgba(189, 148, 90, .16)); }
.curve .line { fill: none; stroke: var(--gold); stroke-width: 2; stroke-linejoin: round; }
.curve .projection { fill: none; stroke: var(--muted); stroke-width: 1.5; stroke-dasharray: 4 4; }
.curve .goal { stroke: var(--line); stroke-width: 1; }
.curve .dot { fill: var(--gold); }
.curve-legend { display: flex; gap: 18px; flex-wrap: wrap; font-size: 12px; color: var(--muted); }
.curve-legend b { color: var(--ink); font-weight: 600; }

@media (prefers-reduced-motion: no-preference) {
    .curve .line {
        stroke-dasharray: 1600;
        stroke-dashoffset: 1600;
        animation: draw 1.1s cubic-bezier(.25, .8, .3, 1) forwards;
    }
    .curve .area, .curve .dot { animation: fadeUp .7s ease .35s backwards; }
    @keyframes draw { to { stroke-dashoffset: 0; } }
}

/* ==========================================================================
   Seating floor plan
   ========================================================================== */
.plan-wrap { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 18px; align-items: start; }
.plan-card { min-width: 0; }

.floor {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 10px;
    touch-action: none;
    user-select: none;
}

.floor-bg { fill: var(--paper, #faf8f5); }
.floor-grid { color: var(--line); }

.tbl { cursor: grab; }
.tbl:focus { outline: none; }
.tbl:focus-visible .shape { stroke: var(--gold); stroke-width: 3; }
.tbl.dragging { cursor: grabbing; }

.tbl .shape {
    fill: var(--card);
    stroke: var(--line);
    stroke-width: 2;
    transition: fill .25s ease, stroke .25s ease, filter .2s ease;
}

.tbl:hover .shape { stroke: var(--gold); filter: drop-shadow(0 3px 8px rgba(0, 0, 0, .16)); }
.tbl.part .shape { fill: var(--gold-soft); }
.tbl.full .shape { fill: var(--green-soft); stroke: var(--green); }
.tbl.over .shape { fill: var(--red-soft); stroke: var(--red); }
.tbl.over .nm { fill: var(--red); }
.tbl.over .fill { fill: var(--red); }

.tbl.dragging .shape { filter: drop-shadow(0 6px 14px rgba(0, 0, 0, .22)); }

/* The table a household is being dragged onto. */
.tbl.drop .shape {
    stroke: var(--gold);
    stroke-width: 4;
    filter: drop-shadow(0 6px 16px rgba(0, 0, 0, .25));
}

.tbl .nm {
    font-size: 17px;
    text-anchor: middle;
    fill: var(--ink);
    font-weight: 600;
    pointer-events: none;
}

.tbl .ct { font-size: 13px; text-anchor: middle; fill: var(--muted); pointer-events: none; }
.tbl .track { fill: var(--line); }
.tbl .fill { fill: var(--gold); transition: width .3s ease; }
.tbl.full .fill { fill: var(--green); }

.seat-pool { display: flex; flex-direction: column; gap: 7px; max-height: 460px; overflow-y: auto; }

.pool-chip {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    font-size: 13px;
    cursor: grab;
    background: var(--card);
    touch-action: none;
    transition: border-color .2s ease, transform .18s ease;
}

.pool-chip:hover { border-color: var(--gold); transform: translateX(2px); }
.pool-chip.lifted { opacity: .35; }
.pool-chip .n { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pool-chip .s { color: var(--muted); font-size: 11px; }

.drag-ghost {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 200;
    pointer-events: none;
    padding: 6px 12px;
    border-radius: 8px;
    background: var(--ink);
    color: #fff;
    font-size: 12px;
    box-shadow: 0 8px 22px rgba(0, 0, 0, .3);
    margin: -14px 0 0 12px;
}

.chips.seg { border: 1px solid var(--line); border-radius: 999px; padding: 3px; gap: 3px; }
.chips.seg .chip { border: none; }

@media (max-width: 960px) {
    .plan-wrap { grid-template-columns: 1fr; }
    .seat-pool { max-height: 240px; }
}

@media (prefers-reduced-motion: reduce) {
    .tbl .shape, .tbl .fill, .pool-chip { transition: none; }
    .pool-chip:hover { transform: none; }
}

/* ==========================================================================
   How the invitation lands in Messages
   ========================================================================== */
.imessage-preview {
    margin-top: 16px;
    padding: 18px 16px 12px;
    border-radius: 12px;
    background: var(--paper);
    border: 1px solid var(--line);
}

.imessage-preview .bubble {
    max-width: 330px;
    margin: 0 auto 10px;
    padding: 11px 14px 12px;
    border-radius: 18px 18px 4px 18px;
    background: #1c8cf8;
    color: #fff;
    font-size: 13.5px;
    line-height: 1.45;
    box-shadow: 0 4px 14px rgba(28, 140, 248, .28);
}

.imessage-preview .preview-card {
    display: flex;
    align-items: center;
    gap: 11px;
    margin-top: 10px;
    padding: 10px;
    border-radius: 12px;
    background: rgba(255, 255, 255, .96);
    color: var(--ink);
}

.imessage-preview .preview-card img,
.imessage-preview .preview-icon {
    width: 52px;
    height: 52px;
    border-radius: 10px;
    flex: 0 0 auto;
    background: var(--paper);
}

.imessage-preview .preview-text { min-width: 0; }
.imessage-preview .preview-text strong {
    display: block;
    font-size: 13px;
    color: var(--ink);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.imessage-preview .preview-text span {
    display: block;
    font-size: 11px;
    color: var(--muted);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.imessage-preview .preview-text .host { font-size: 9.5px; letter-spacing: .1em; margin-top: 2px; }

@media (max-width: 560px) {
    .imessage-preview .bubble { max-width: 100%; }
}

/* ==========================================================================
   The venue designer
   ========================================================================== */
.designer {
    display: grid;
    grid-template-columns: 216px minmax(0, 1fr) 300px;
    gap: 14px;
    align-items: start;
}

.designer-palette {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 10px;
    max-height: 74vh;
    overflow-y: auto;
    position: sticky;
    top: 16px;
}

.designer-palette input[type=search] { margin-bottom: 8px; }

.pal-group + .pal-group { margin-top: 4px; }

.pal-head {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border: none;
    background: none;
    font-family: inherit;
    font-size: 11px;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--muted);
    padding: 7px 4px;
    cursor: pointer;
}

.pal-head:hover { color: var(--ink); }
.pal-head span { font-size: 10px; opacity: .7; }
.pal-group .pal-items { display: none; }
.pal-group.open .pal-items { display: block; }

.pal-item {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr);
    grid-template-rows: auto auto;
    gap: 0 9px;
    width: 100%;
    text-align: left;
    padding: 6px 6px;
    border: 1px solid transparent;
    border-radius: 8px;
    background: none;
    font-family: inherit;
    cursor: pointer;
    transition: background .2s ease, border-color .2s ease;
}

.pal-item:hover { background: var(--paper); border-color: var(--line); }
.pal-glyph { grid-row: 1 / 3; width: 34px; height: 34px; }
.pal-glyph circle, .pal-glyph rect, .pal-glyph ellipse {
    fill: var(--gold-soft);
    stroke: var(--gold);
    stroke-width: 1.2;
}
.pal-item .pn { font-size: 13px; color: var(--ink); align-self: end; }
.pal-item .pd { font-size: 10.5px; color: var(--muted); align-self: start; }

.designer-stage { min-width: 0; }

.plan-frame {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 8px;
    overflow: hidden;
}

.plan {
    width: 100%;
    height: 62vh;
    min-height: 420px;
    display: block;
    touch-action: none;
    user-select: none;
    cursor: default;
}

.plan-bg { fill: var(--paper); }
.room-floor { fill: var(--card); }
.room-grid { color: var(--line); pointer-events: none; }
.room-wall { fill: none; stroke: var(--ink); stroke-width: 6; stroke-linejoin: round; }

.room-handle {
    fill: var(--card);
    stroke: var(--gold);
    stroke-width: 2.5;
    cursor: grab;
    opacity: .85;
}
.room-handle:hover { fill: var(--gold-soft); opacity: 1; }

.vi { cursor: grab; }
.vi.locked { cursor: not-allowed; }
.vi:focus { outline: none; }

.vi .shape {
    fill: var(--card);
    stroke: var(--muted);
    stroke-width: 2;
    transition: fill .2s ease, stroke .2s ease;
}

.vi:hover .shape { stroke: var(--gold); }
.vi.picked .shape { stroke: var(--gold); stroke-width: 3; }
.vi.full .shape { fill: var(--green-soft); stroke: var(--green); }
.vi.over .shape { fill: var(--red-soft); stroke: var(--red); }

.vi .chair { fill: var(--card); stroke: var(--line); stroke-width: 1.2; }
.vi.picked .chair { stroke: var(--gold); }

.vi .floor { fill: var(--gold-soft); stroke: var(--gold); }
.vi .floor-inner { fill: none; stroke: var(--gold); stroke-width: 1; opacity: .5; }
.vi .aisle { fill: var(--paper); stroke: var(--line); stroke-dasharray: 10 8; }
.vi .wall { fill: var(--ink); stroke: none; }
.vi .door { fill: var(--card); stroke: var(--ink); stroke-width: 2; }
.vi .window { fill: var(--card); stroke: var(--gold); stroke-width: 3; }
.vi .door-swing { fill: none; stroke: var(--muted); stroke-width: 1; stroke-dasharray: 5 5; opacity: .6; }
.vi .arch { fill: none; stroke: var(--gold); stroke-width: 4; }
.vi .floral { fill: var(--gold-soft); stroke: var(--gold); }
.vi .truss { fill: var(--muted); }
.vi .step { stroke: var(--line); stroke-width: 1.2; }

.vi .vl { text-anchor: middle; fill: var(--ink); font-weight: 600; pointer-events: none; }
.vi .vc { text-anchor: middle; fill: var(--muted); pointer-events: none; }

.floral-mark { pointer-events: none; }
.floral-ring { fill: none; stroke: var(--gold); stroke-width: 1; opacity: .7; }
.vendor-mark circle { fill: var(--ink); }
.vendor-mark .vm { fill: #fff; font-size: 11px; text-anchor: middle; font-weight: 600; }

.pick-box {
    fill: none;
    stroke: var(--gold);
    stroke-width: 1.2;
    stroke-dasharray: 6 5;
    pointer-events: none;
}

.handle { fill: var(--card); stroke: var(--gold); stroke-width: 2; cursor: grab; }
.handle.rotate { cursor: alias; }
.handle.resize { cursor: nwse-resize; }
.handle-stem { stroke: var(--gold); stroke-width: 1.5; pointer-events: none; }

.dims line { stroke: var(--muted); stroke-width: 1.2; }
.dims text { font-size: 15px; text-anchor: middle; fill: var(--muted); }
.scale-bar line { stroke: var(--ink); stroke-width: 2; }
.scale-bar text { font-size: 13px; text-anchor: middle; fill: var(--muted); }

.plan-status {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
    padding: 10px 4px 0;
    font-size: 12px;
    color: var(--muted);
}
.plan-status b { color: var(--ink); font-size: 14px; }
.plan-status .spacer { flex: 1; }

.chip.tiny { padding: 4px 10px; font-size: 11px; }
.chip.tiny.good { border-color: var(--green); color: var(--green); }
.chip.tiny.warn { border-color: var(--amber); color: var(--amber); }
.chip.tiny.bad { border-color: var(--red); color: var(--red); }

.layer-toggles { display: flex; gap: 4px; flex-wrap: wrap; }

.designer-inspector { position: sticky; top: 16px; max-height: 74vh; overflow-y: auto; }
.designer-inspector .card { margin-bottom: 0; }
.icon-btn.on { color: var(--gold); }

.template-card { text-align: left; cursor: pointer; border: 1px solid var(--line); }
.template-card:hover { border-color: var(--gold); }

@media (max-width: 1200px) {
    .designer { grid-template-columns: 190px minmax(0, 1fr); }
    .designer-inspector { grid-column: 1 / -1; position: static; max-height: none; }
}

@media (max-width: 780px) {
    .designer { grid-template-columns: 1fr; }
    .designer-palette { position: static; max-height: 260px; }
    .plan { height: 46vh; }
}

@media (prefers-reduced-motion: reduce) {
    .pal-item, .vi .shape { transition: none; }
}

/* ==========================================================================
   Florals
   ========================================================================== */
.swatch-row { display: flex; gap: 4px; }
.swatch {
    flex: 1;
    height: 34px;
    border-radius: 5px;
    border: 1px solid rgba(0, 0, 0, .08);
}

.stem-list { list-style: none; margin: 0 0 10px; padding: 0; }
.stem-list li {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 0;
    border-bottom: 1px solid var(--line);
    font-size: 13px;
}
.stem-list li:last-child { border-bottom: none; }
.stem-list .n { flex: 1; min-width: 0; }
.stem-list .q { font-weight: 600; color: var(--ink); }

.dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: 1px solid rgba(0, 0, 0, .12);
    flex: 0 0 auto;
}

.stem-row {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) 46px 72px 34px;
    gap: 6px;
    margin-bottom: 6px;
    align-items: center;
}
.stem-row input { margin: 0; }
.stem-row input[type=color] { padding: 2px; height: 38px; }

.bar.tiny { height: 4px; margin: 4px 0 0; }

.palette-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 10px; }
.palette-swatch {
    position: relative;
    border: 1px solid var(--line);
    border-radius: 10px;
    overflow: hidden;
    padding-bottom: 8px;
    text-align: center;
}
.palette-swatch span { display: block; height: 54px; }
.palette-swatch strong { display: block; font-size: 12px; margin-top: 7px; }
.palette-swatch em { font-size: 10px; color: var(--muted); font-style: normal; }
.palette-swatch .icon-btn { position: absolute; top: 4px; right: 4px; }

.floral-card .card-head { margin-bottom: 2px; }

/* ==========================================================================
   Vendors
   ========================================================================== */
.vendor-facts { display: flex; flex-direction: column; gap: 5px; margin-bottom: 12px; }
.vfact { font-size: 12.5px; color: var(--body); display: flex; align-items: center; gap: 7px; }
.vfact i { color: var(--gold); font-size: 12px; }

.tiny-chips { margin-bottom: 10px; }
.tiny-chips .chip { cursor: default; }

.badges { display: flex; gap: 6px; margin-bottom: 12px; }
.badge {
    font-size: 10.5px;
    letter-spacing: .1em;
    text-transform: uppercase;
    padding: 3px 9px;
    border-radius: 999px;
    border: 1px solid var(--line);
    color: var(--muted);
}
.badge.on { border-color: var(--green); color: var(--green); background: var(--green-soft); }

.scope-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 4px 18px; }
.check.inline { margin-bottom: 0; }
td.owed { color: var(--red); font-weight: 600; }
tr.total td { border-top: 2px solid var(--line); }
tr.edge td { background: var(--paper); }

/* ==========================================================================
   Grouped navigation, photographs, production
   ========================================================================== */
.nav-group {
    font-size: 10px;
    letter-spacing: .18em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, .34);
    padding: 16px 22px 5px;
    pointer-events: none;
}
.nav-group:first-child { padding-top: 6px; }

.photo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 10px;
}

.photo {
    position: relative;
    margin: 0;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid var(--line);
    background: var(--paper);
}
.photo img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; display: block; background: var(--paper); }
.photo figcaption { padding: 6px; }
.photo .cap { width: 100%; font-size: 12px; padding: 5px 7px; border-radius: 6px; }
.photo .icon-btn {
    position: absolute;
    top: 5px;
    right: 5px;
    background: rgba(255, 255, 255, .92);
    border-radius: 6px;
}

.strip {
    position: relative;
    height: 22px;
    border-radius: 6px;
    background: #1a2233;
    overflow: hidden;
    margin-bottom: 4px;
}
.strip .day { position: absolute; top: 0; bottom: 0; background: linear-gradient(180deg, #8ec5e8, #cfe6f3); }
.strip .golden { position: absolute; top: 0; bottom: 0; background: linear-gradient(90deg, #f0c274, #e08b4a); }
.strip .blue { position: absolute; top: 0; bottom: 0; background: linear-gradient(90deg, #4a6ea8, #1a2233); }
.strip .mark { position: absolute; top: -3px; bottom: -3px; width: 2px; background: #fff; box-shadow: 0 0 0 1px rgba(0,0,0,.4); }
.strip-labels { display: flex; justify-content: space-between; font-size: 10px; color: var(--muted); margin-bottom: 14px; }

td.gold strong { color: var(--gold); }
.struck { text-decoration: line-through; opacity: .55; }

.ordered-list { list-style: decimal; padding-left: 22px; margin: 0; }
.ordered-list li { display: flex; align-items: center; gap: 6px; padding: 7px 0; border-bottom: 1px solid var(--line); }
.ordered-list li:last-child { border-bottom: none; }
.ol-body { flex: 1; min-width: 0; font-size: 14px; }

.chip-x { border: none; background: none; cursor: pointer; font-size: 15px; line-height: 1; color: inherit; padding: 0 0 0 4px; }

/* Seating rules */
.rule-add {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr) auto;
    gap: 7px;
    align-items: center;
    margin-bottom: 14px;
}
.rule-add select { margin: 0; }
.rule-list { list-style: none; margin: 0; padding: 0; }
.rule-list li {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 8px 0;
    border-bottom: 1px solid var(--line);
    font-size: 14px;
}
.rule-list li:last-child { border-bottom: none; }
.rule-list .icon-btn { margin-left: auto; }

/* ==========================================================================
   The room in three dimensions
   ========================================================================== */
.plan.iso { cursor: default; }

.iso-floor {
    fill: var(--paper);
    stroke: var(--line);
    stroke-width: 1.5;
}

.iso-wall {
    fill: var(--card);
    stroke: var(--line);
    stroke-width: 1;
    opacity: .8;
}

.iso .it { fill: #efe9df; stroke: #b9ad99; stroke-width: 1; }
.iso .it.linen { fill: #fbf8f2; stroke: var(--gold); }
.iso .it.floorcloth { fill: var(--gold-soft); stroke: var(--gold); }
.iso .it.struct { fill: #ded8cd; stroke: #a49a87; }
.iso .it.chairtop { fill: #f4efe6; stroke: #c9bda6; stroke-width: .8; }

.iso .if { stroke: none; }
.iso .ifl { fill: rgba(102, 90, 70, .32); }
.iso .ifr { fill: rgba(102, 90, 70, .18); }

.iso .iso-item { cursor: pointer; }
.iso .iso-item:hover .it { stroke: var(--gold); stroke-width: 2; }
.iso .iso-item.picked .it { stroke: var(--gold); stroke-width: 2.5; }

.iso-label {
    font-size: 15px;
    text-anchor: middle;
    fill: var(--ink);
    font-weight: 600;
    paint-order: stroke;
    stroke: var(--card);
    stroke-width: 4px;
    stroke-linejoin: round;
    pointer-events: none;
}

/* Budget + phased checklist */
.phase-head {
    font-size: 11px;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: var(--muted);
    margin: 18px 0 4px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.phase-head:first-of-type { margin-top: 4px; }
.phase-head span { font-size: 10px; opacity: .7; }
.phase-head.overdue { color: var(--red); }
.bar.tiny.over span { background: var(--red); }
.field.inline { display: flex; align-items: center; gap: 8px; }
.field.inline label { margin: 0; white-space: nowrap; }

/* Now / next on the day */
.now-bar {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 18px;
}
.now-bar .now, .now-bar .next {
    display: flex;
    align-items: baseline;
    gap: 10px;
    padding: 14px 18px;
    border-radius: 12px;
    border: 1px solid var(--line);
    background: var(--card);
}
.now-bar .now { border-color: var(--gold); background: var(--gold-soft); }
.now-bar .tag {
    font-size: 10px;
    letter-spacing: .18em;
    text-transform: uppercase;
    color: var(--gold);
}
.now-bar strong { font-size: 16px; color: var(--ink); }
.now-bar .at { font-size: 12px; color: var(--muted); margin-left: auto; }
@media (max-width: 700px) { .now-bar { grid-template-columns: 1fr; } }
