/* hinagiku.bar — 雛菊 — analog operations dashboard of a hidden Ginza cocktail bar */

:root {
    --oxblood: #3a0d14;
    --wine: #56171f;
    --cherry: #7a2832;
    --cream: #f4ead6;
    --vellum: #e8dcbf;
    --ink: #1f0a0a;
    --brass: #c89a3c;

    --paper-deckle: polygon(
        0.4% 1.2%, 8% 0.3%, 16% 1.4%, 24% 0.4%, 33% 1.6%, 42% 0.5%, 51% 1.7%, 60% 0.4%, 69% 1.5%, 78% 0.6%, 87% 1.6%, 95% 0.4%, 99.6% 1.3%,
        99.4% 9%, 99.7% 18%, 99.3% 28%, 99.8% 38%, 99.4% 49%, 99.7% 60%, 99.3% 71%, 99.8% 82%, 99.5% 92%, 99.6% 98.8%,
        92% 99.6%, 83% 99.3%, 74% 99.8%, 65% 99.4%, 56% 99.7%, 47% 99.3%, 38% 99.8%, 29% 99.4%, 20% 99.7%, 11% 99.3%, 3% 99.8%, 0.4% 98.7%,
        0.7% 91%, 0.3% 80%, 0.8% 69%, 0.3% 58%, 0.7% 47%, 0.3% 36%, 0.8% 25%, 0.4% 14%
    );
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
    background-color: var(--oxblood);
    color: var(--cream);
    font-family: "Cormorant Garamond", Georgia, serif;
    font-size: 18px;
    line-height: 1.65;
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

/* ---- Candle ambient overlay (static, no flicker) ---- */
.candle-overlay {
    position: fixed;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background:
        radial-gradient(circle at 22% 18%, rgba(200, 154, 60, 0.12), transparent 38%),
        radial-gradient(circle at 78% 82%, rgba(200, 154, 60, 0.07), transparent 32%);
}

/* ---- Daisy SVG ---- */
.daisy ellipse,
.daisy circle {
    fill: none;
    stroke: var(--brass);
    stroke-width: 1.4;
}
.daisy .daisy-disc {
    fill: var(--cherry);
    stroke: var(--brass);
    stroke-width: 1;
}
.daisy-sidebar { width: 34px; height: 34px; margin: 26px auto 0; display: block; }
.daisy-title { width: 22px; height: 22px; vertical-align: -3px; margin-right: 6px; }
.daisy-final { width: 132px; height: 132px; display: block; margin: 0 auto 34px; }

/* ---- Dashboard frame ---- */
.dashboard {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 96px 1fr;
    max-width: 1480px;
    margin: 0 auto;
    padding: 0;
}

/* ---- Sidebar ---- */
.sidebar {
    position: relative;
    width: 96px;
    min-height: 100vh;
    background: linear-gradient(180deg, #6e2029 0%, var(--wine) 22%, #410f17 70%, var(--oxblood) 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 38px 0 28px;
    border-right: 1px solid rgba(122, 40, 50, 0.6);
}
.sconce {
    position: absolute;
    top: -40px;
    left: 50%;
    transform: translateX(-50%);
    width: 320px;
    height: 320px;
    pointer-events: none;
    background: radial-gradient(circle, rgba(200, 154, 60, 0.28), rgba(200, 154, 60, 0.08) 40%, transparent 68%);
}
.sidebar-mark {
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-top: 4px;
}
.kanji {
    font-family: "Shippori Mincho", "Cormorant Garamond", serif;
    font-weight: 500;
    font-size: 2rem;
    letter-spacing: 0.08em;
    writing-mode: vertical-rl;
    color: var(--cream);
    text-shadow: 0 1px 6px rgba(200, 154, 60, 0.25);
}
.romaji {
    font-family: "Libre Baskerville", Georgia, serif;
    font-style: italic;
    font-size: 0.92rem;
    letter-spacing: 0.04em;
    writing-mode: vertical-rl;
    color: var(--vellum);
    opacity: 0.82;
    margin-top: 4px;
}
.knock {
    margin-top: auto;
    margin-bottom: 18px;
    background: transparent;
    border: none;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 14px 6px;
    color: var(--vellum);
    font-family: "Libre Baskerville", Georgia, serif;
    font-style: italic;
}
.knock-label {
    writing-mode: vertical-rl;
    font-size: 0.86rem;
    letter-spacing: 0.16em;
    border-left: 1px solid rgba(200, 154, 60, 0.5);
    padding-left: 5px;
    transition: color 0.4s ease, border-color 0.4s ease;
}
.knock-sub {
    writing-mode: vertical-rl;
    font-size: 0.62rem;
    letter-spacing: 0.1em;
    opacity: 0.55;
}
.knock:hover .knock-label { color: var(--brass); border-color: var(--brass); }
.knock.knocking { animation: knock 320ms ease; }
@keyframes knock {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-3px); }
    50% { transform: translateX(2px); }
    75% { transform: translateX(-1px); }
}
.sidebar-foot {
    writing-mode: vertical-rl;
    font-family: "JetBrains Mono", monospace;
    font-size: 0.56rem;
    letter-spacing: 0.14em;
    color: rgba(232, 220, 191, 0.4);
    text-transform: uppercase;
}

/* ---- Operations grid ---- */
.grid {
    display: grid;
    grid-template-columns: 1fr 1fr 320px;
    grid-template-rows: auto auto auto;
    gap: 30px;
    padding: 56px 52px 80px;
    align-items: start;
}

/* ---- Panels (paper on velvet) ---- */
.panel {
    position: relative;
    background: var(--cream);
    color: var(--ink);
    padding: 30px 32px 32px;
    clip-path: var(--paper-deckle);
    box-shadow: inset 0 1px 3px rgba(31, 10, 10, 0.08), 0 6px 22px rgba(0, 0, 0, 0.45);
    opacity: 0;
    transform: translateY(6px);
}
.panel::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background-image: radial-gradient(rgba(31, 10, 10, 0.045) 0.6px, transparent 0.7px);
    background-size: 3px 3px;
    mix-blend-mode: multiply;
}
.panel.revealed { animation: fadeReveal 500ms ease forwards; }
@keyframes fadeReveal {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

/* lopsided placement */
.panel-reservations { grid-column: 1 / 3; grid-row: 1; }
.panel-stock       { grid-column: 3; grid-row: 1 / 3; align-self: stretch; }
.panel-flower      { grid-column: 1; grid-row: 2; }
.panel-record      { grid-column: 2; grid-row: 2; }
.panel-weather     { grid-column: 1 / 3; grid-row: 3; }
.panel-close       { grid-column: 3; grid-row: 3; }

/* ---- Kicker / titles ---- */
.kicker {
    display: block;
    font-family: "Libre Baskerville", Georgia, serif;
    font-style: italic;
    font-size: 0.7rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--cherry);
    margin-bottom: 10px;
}
.panel-title,
.log-title {
    font-family: "Libre Baskerville", Georgia, serif;
    font-style: italic;
    font-weight: 400;
    font-size: clamp(1.6rem, 3.4vw, 2.6rem);
    line-height: 1.2;
    color: var(--ink);
    margin-bottom: 18px;
}

/* ---- Reservation list ---- */
.reservation-list { list-style: none; }
.reservation-list li {
    display: grid;
    grid-template-columns: 64px 1fr auto;
    grid-template-areas: "time name party" "time note note";
    column-gap: 18px;
    row-gap: 2px;
    padding: 13px 0;
    border-bottom: 1px dashed rgba(122, 40, 50, 0.35);
}
.reservation-list li:last-child { border-bottom: none; }
.res-time {
    grid-area: time;
    font-family: "JetBrains Mono", monospace;
    font-size: 0.78rem;
    color: var(--cherry);
    padding-top: 4px;
}
.res-name {
    grid-area: name;
    font-family: "Libre Baskerville", Georgia, serif;
    font-style: italic;
    font-size: 1.18rem;
    color: var(--ink);
}
.res-note {
    grid-area: note;
    font-size: 1rem;
    color: rgba(31, 10, 10, 0.78);
}
.res-party {
    grid-area: party;
    font-family: "JetBrains Mono", monospace;
    font-size: 0.78rem;
    color: rgba(31, 10, 10, 0.5);
    padding-top: 4px;
}

/* ---- Stock list ---- */
.panel-stock { background: var(--vellum); }
.stock-list { list-style: none; }
.stock-list li {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 8px 0;
    border-bottom: 1px dotted rgba(122, 40, 50, 0.3);
}
.stock-name { font-size: 1.04rem; color: rgba(31, 10, 10, 0.85); }
.stock-count {
    font-family: "JetBrains Mono", monospace;
    font-size: 0.78rem;
    color: var(--cherry);
    border: 1px solid rgba(122, 40, 50, 0.35);
    border-radius: 2px;
    padding: 1px 7px;
}
.stock-foot {
    margin-top: 16px;
    font-family: "JetBrains Mono", monospace;
    font-size: 0.66rem;
    letter-spacing: 0.06em;
    color: rgba(31, 10, 10, 0.45);
}

/* ---- small panels body ---- */
.flower-body, .weather-body { font-size: 1.08rem; color: rgba(31, 10, 10, 0.82); }
.flower-body em { font-style: italic; color: var(--cherry); }
.record-title {
    font-family: "Libre Baskerville", Georgia, serif;
    font-style: italic;
    font-size: 1.5rem;
    color: var(--ink);
    margin-bottom: 6px;
}
.record-artist { font-size: 1rem; color: rgba(31, 10, 10, 0.7); }

/* ---- Close panel + lens flare ---- */
.panel-close { overflow: hidden; text-align: center; }
.flare-band {
    position: absolute;
    left: -10%;
    top: 50%;
    width: 120%;
    height: 30px;
    transform: translateY(-50%) rotate(-1.5deg);
    background: linear-gradient(90deg, transparent, rgba(200, 154, 60, 0.32) 45%, rgba(200, 154, 60, 0.5) 50%, rgba(200, 154, 60, 0.32) 55%, transparent);
    pointer-events: none;
}
.close-digit {
    position: relative;
    display: inline-block;
    font-family: "Libre Baskerville", Georgia, serif;
    font-weight: 700;
    font-size: clamp(3.4rem, 7vw, 5rem);
    line-height: 1;
    color: var(--brass);
    margin: 16px 0 12px;
    text-shadow: 0 0 8px rgba(200, 154, 60, 0.9), 0 0 22px rgba(200, 154, 60, 0.55), 0 0 60px rgba(200, 154, 60, 0.3);
}
.close-body { font-size: 0.98rem; color: rgba(31, 10, 10, 0.7); }

/* ---- Evening log ---- */
.evening-log {
    position: relative;
    z-index: 2;
    max-width: 920px;
    margin: 30px auto 0;
    padding: 0 52px 90px 148px;
}
.log-kicker { color: var(--brass); }
.log-title { color: var(--cream); }
.log-paper {
    background: var(--cream);
    color: var(--ink);
    padding: 36px 40px;
    clip-path: var(--paper-deckle);
    box-shadow: inset 0 1px 3px rgba(31, 10, 10, 0.08), 0 6px 22px rgba(0, 0, 0, 0.45);
    transform: rotate(-0.4deg);
    position: relative;
}
.log-paper::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background-image: radial-gradient(rgba(31, 10, 10, 0.045) 0.6px, transparent 0.7px);
    background-size: 3px 3px;
    mix-blend-mode: multiply;
}
.log-entry {
    font-family: "JetBrains Mono", monospace;
    font-size: 0.78rem;
    line-height: 1.9;
    color: rgba(31, 10, 10, 0.86);
    white-space: pre-wrap;
    min-height: 1.9em;
    margin-bottom: 4px;
}
.log-entry.log-current.typed::after {
    content: "";
    display: inline-block;
    width: 7px;
    height: 1em;
    margin-left: 2px;
    background: var(--cherry);
    vertical-align: -2px;
    animation: blink 1s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0; } }

/* ---- Closing daisy ---- */
.closing {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: 100px 20px 140px;
}
.closing-date {
    font-family: "Libre Baskerville", Georgia, serif;
    font-style: italic;
    font-size: 1.05rem;
    letter-spacing: 0.04em;
    color: rgba(244, 234, 214, 0.55);
}

/* ---- Responsive ---- */
@media (max-width: 960px) {
    .grid {
        grid-template-columns: 1fr;
        grid-template-rows: none;
        padding: 40px 24px 60px;
        gap: 24px;
    }
    .panel-reservations, .panel-stock, .panel-flower, .panel-record, .panel-weather, .panel-close {
        grid-column: 1;
        grid-row: auto;
    }
    .evening-log { padding: 30px 24px 70px; }
}
@media (max-width: 560px) {
    body { font-size: 16px; }
    .dashboard { grid-template-columns: 64px 1fr; }
    .sidebar { width: 64px; }
    .kanji { font-size: 1.5rem; }
    .reservation-list li {
        grid-template-columns: 56px 1fr;
        grid-template-areas: "time name" "note note" "party party";
    }
    .res-party { padding-top: 0; }
}
