/* DG Menu additions on top of DG Book Pro's tokens.css + app.css. Same tokens, same shapes. */

.top-title { font: var(--head-weight) var(--fs-md)/1.2 var(--font-head); color: var(--ink); flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (min-width: 900px) { .top-title { visibility: hidden; } }
.admin-foot { margin-top: 32px; padding-top: 12px; border-top: 1px solid var(--line); }
.dropdown .menu form { margin: 0; }
.dropdown .menu form button { all: unset; box-sizing: border-box; display: flex; align-items: center; gap: 8px; width: 100%; padding: 8px 10px; border-radius: 7px; cursor: pointer; font-size: var(--fs-sm); color: var(--ink); }
.dropdown .menu form button:hover { background: var(--surface-2); }
.dropdown .menu form button.danger { color: var(--danger); }

/* Stat tiles */
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 20px; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-card); box-shadow: var(--shadow-card); padding: 14px 16px; }
.stat span { display: block; font-size: var(--fs-xs); color: var(--ink-3); }
.stat b { display: block; font: 700 24px/1.2 var(--font-head); color: var(--ink); margin-top: 2px; }
.stat b a { color: inherit; text-decoration: none; }
@media (max-width: 700px) { .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Scan bars */
.bars { display: grid; grid-template-columns: repeat(7, 1fr); gap: 8px; align-items: end; height: 150px; }
.bar { display: grid; grid-template-rows: auto 1fr auto; height: 100%; text-align: center; gap: 4px; }
.bar i { align-self: end; display: block; background: var(--svc); border-radius: 6px 6px 2px 2px; min-height: 3px; }
.bar-n { font-size: var(--fs-xs); color: var(--ink-2); }
.bar small { font-size: var(--fs-xs); color: var(--ink-3); }

.setup .setup-list { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.setup-list li { display: flex; align-items: center; gap: 10px; }
.setup-list li.done { color: var(--ink-3); }
.setup-list li.done a { color: var(--ink-3); text-decoration: line-through; }
.setup { margin-bottom: 20px; }

.plain-list { list-style: none; margin: 0; padding: 0; }
.plain-list li { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 18px; border-bottom: 1px solid var(--line); min-height: 52px; }
.plain-list li:last-child { border-bottom: 0; }
.card-b .plain-list li { padding-left: 0; padding-right: 0; }

/* Switch (role=switch button) */
.switch { --w: 46px; --h: 28px; position: relative; flex: none; width: var(--w); height: var(--h); border-radius: 999px; border: 0; background: var(--line-strong); cursor: pointer; padding: 0; transition: background .15s; }
.switch i { position: absolute; top: 3px; left: 3px; width: calc(var(--h) - 6px); height: calc(var(--h) - 6px); border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(10, 37, 64, .3); transition: transform .15s; }
.switch[aria-checked="true"] { background: var(--success); }
.switch[aria-checked="true"] i { transform: translateX(calc(var(--w) - var(--h))); }
.switch.lg { --w: 56px; --h: 34px; }
.switch[aria-busy="true"] { opacity: .6; }
.switch:focus-visible { box-shadow: var(--focus); outline: none; }
@media (prefers-reduced-motion: reduce) { .switch, .switch i { transition: none; } }

/* Sortable rows */
.sortable { list-style: none; margin: 0; padding: 0; }
.srow { display: flex; align-items: center; gap: 10px; padding: 8px 14px 8px 6px; border-bottom: 1px solid var(--line); background: var(--surface); }
.srow:last-child { border-bottom: 0; }
.sections > .srow { display: block; padding: 0; border-bottom: 0; margin-bottom: 16px; }
.grip { flex: none; width: 36px; height: 44px; border: 0; background: none; color: var(--ink-3); cursor: grab; display: grid; place-items: center; touch-action: none; border-radius: 8px; }
.grip:hover { background: var(--surface-2); color: var(--ink); }
.srow-main { flex: 1; min-width: 0; display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); padding: 4px 0; }
.srow-main b { display: block; font-weight: 600; }
.srow-main small, .srow-text small { display: block; color: var(--ink-3); font-size: var(--fs-xs); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.srow-text { min-width: 0; }
.menu-list .srow-main { flex-direction: column; align-items: flex-start; gap: 0; }
.srow.dragging { opacity: .9; box-shadow: var(--shadow-pop); position: relative; z-index: 5; }
.srow.placeholder-target { outline: 2px dashed var(--svc); outline-offset: -2px; }
.thumb { width: 44px; height: 44px; border-radius: 8px; object-fit: cover; flex: none; background: var(--surface-2); }
.thumb.none { display: grid; place-items: center; color: var(--ink-3); border: 1px dashed var(--line-strong); }
.item.is-sold .srow-text b { color: var(--ink-3); text-decoration: line-through; }
.item.is-hidden { background: repeating-linear-gradient(135deg, var(--surface) 0 8px, var(--surface-2) 8px 16px); }
.sec-h { display: flex; align-items: center; gap: 8px; }
.sec-h h2 { flex: 1; min-width: 0; }
.sec-edit { border-bottom: 1px solid var(--line); background: var(--surface-2); }
.sec-empty { margin: 0; }
.items:empty { min-height: 40px; }
.add-inline { display: flex; gap: 10px; }
.add-inline .input { flex: 1; }
.add-section { margin-top: 8px; }

/* Forms */
.input-affix { display: flex; align-items: stretch; }
.input-affix .input { border-top-right-radius: 0; border-bottom-right-radius: 0; min-width: 0; flex: 1; }
.input-affix span { display: grid; place-items: center; padding: 0 10px; border: 1px solid var(--line-strong); border-left: 0; border-radius: 0 var(--r-input) var(--r-input) 0; background: var(--surface-2); color: var(--ink-3); font-size: var(--fs-sm); white-space: nowrap; }
.checks { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.checks.col { flex-direction: column; }
fieldset.field { border: 0; padding: 0; margin: 0; min-width: 0; }
fieldset.field legend { font-weight: 600; font-size: var(--fs-sm); margin-bottom: 6px; color: var(--ink); }
.form-h { font: var(--head-weight) var(--fs-md)/1.3 var(--font-head); margin: 8px 0 0; }
.row-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
@media (max-width: 640px) { .row-3 { grid-template-columns: 1fr 1fr; } .row-3 > :last-child { grid-column: 1 / -1; } }
.stack { display: grid; gap: 20px; align-content: start; }
.sticky-actions { position: sticky; bottom: 0; z-index: 4; display: flex; justify-content: flex-end; gap: 10px; flex-wrap: wrap; padding: 12px 0; margin-top: 16px; background: linear-gradient(transparent, var(--bg) 30%); }
.photo-preview { max-width: 100%; max-height: 220px; border-radius: var(--r-card); object-fit: cover; }
.logo-preview { max-width: 160px; max-height: 100px; object-fit: contain; background: var(--surface-2); border-radius: 8px; padding: 6px; }
.variant { border: 1px solid var(--line); border-radius: var(--r-input); padding: 10px 12px; display: grid; gap: 6px; }
.variants { display: grid; gap: 10px; }
.variant-tr summary { cursor: pointer; font-size: var(--fs-sm); color: var(--ink-2); }
.al-table { display: grid; border: 1px solid var(--line); border-radius: var(--r-input); overflow: hidden; }
.al-row { display: grid; grid-template-columns: 1fr 80px 70px; align-items: center; padding: 6px 10px; border-bottom: 1px solid var(--line); }
.al-row:last-child { border-bottom: 0; }
.al-row > span:not(.al-name) { text-align: center; }
.al-row input { width: 22px; height: 22px; accent-color: var(--svc); }
.al-head { background: var(--surface-2); font-size: var(--fs-xs); font-weight: 600; color: var(--ink-3); }
.al-name { display: flex; align-items: center; gap: 8px; }
.al-ic { width: 20px; height: 20px; fill: none; stroke: var(--ink-2); stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.hours-day { border: 0; padding: 0; margin: 0; display: grid; grid-template-columns: 60px 1fr 1fr; gap: 8px; align-items: center; }
.hours-day legend { float: left; font-weight: 600; font-size: var(--fs-sm); }
.hours-slot { display: flex; align-items: center; gap: 4px; }
.hours-slot .input { padding-left: 6px; padding-right: 4px; min-width: 0; }
@media (max-width: 560px) { .hours-day { grid-template-columns: 1fr 1fr; } .hours-day legend { grid-column: 1 / -1; float: none; } }
.theme-pick { display: flex; gap: 10px; flex-wrap: wrap; }
.theme-opt { display: flex; align-items: center; gap: 8px; border: 1px solid var(--line-strong); border-radius: var(--r-input); padding: 8px 12px; cursor: pointer; }
.theme-opt:has(input:checked) { border-color: var(--ink); box-shadow: var(--focus); }
.theme-opt .sw { width: 22px; height: 22px; border-radius: 6px; border: 1px solid var(--line-strong); }
.theme-light .sw { background: #fff; } .theme-warm .sw { background: #FBF7F0; } .theme-dark .sw { background: #141414; }
.color-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.color-row input[type="color"] { width: 48px; height: 40px; border: 1px solid var(--line-strong); border-radius: var(--r-input); padding: 2px; background: var(--surface); }
.color-chip { width: 30px; height: 30px; border-radius: 50%; border: 2px solid var(--surface); box-shadow: 0 0 0 1px var(--line-strong); background: var(--c); cursor: pointer; }
.row-edit summary { list-style: none; }
.row-edit summary::-webkit-details-marker { display: none; }
.row-edit[open] { text-align: left; }
.row-edit[open] form { margin-top: 10px; min-width: 240px; }
code.pw { font-size: var(--fs-md); background: var(--surface-2); padding: 2px 8px; border-radius: 6px; user-select: all; }
.toolbar { display: flex; gap: 12px; align-items: center; margin-bottom: 16px; flex-wrap: wrap; }
.toolbar .input { max-width: 360px; flex: 1; }
.sticky-search { position: sticky; top: 0; z-index: 4; background: var(--bg); padding: 8px 0; }
.list-h { font: var(--head-weight) var(--fs-lg)/1.3 var(--font-head); margin: 20px 0 10px; }
.so-sec { margin-bottom: 14px; }
.so li.is-sold > span { color: var(--ink-3); text-decoration: line-through; }
.so li.is-filtered, .so-sec.is-filtered { display: none; }
.t.prices .c-price { width: 150px; }
.t.prices .variant-row td { padding-top: 0; }
.input.num { text-align: right; font-variant-numeric: tabular-nums; }
@media (max-width: 900px) { .grid-2 { grid-template-columns: 1fr; } }

/* Landing */
.landing { background: var(--bg); }
.l-top { display: flex; justify-content: space-between; align-items: center; padding: 16px 20px; max-width: 1080px; margin: 0 auto; }
.l-nav { display: flex; gap: 16px; }
.l-nav a { color: var(--ink-2); text-decoration: none; font-weight: 600; font-size: var(--fs-sm); }
.l-hero { text-align: center; padding: 48px 20px 32px; max-width: 760px; margin: 0 auto; }
.l-hero h1 { font: 800 clamp(28px, 5vw, 44px)/1.15 var(--font-head); color: var(--navy); margin: 0 0 14px; letter-spacing: -.02em; }
.l-hero .lead { font-size: var(--fs-lg); color: var(--ink-2); margin: 0 0 24px; }
.l-features { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; max-width: 1080px; margin: 0 auto; padding: 0 20px; }
.l-feature { padding: 18px; }
.l-feature h2 { font: 700 var(--fs-md)/1.3 var(--font-head); margin: 10px 0 4px; }
.l-feature p { margin: 0; color: var(--ink-2); font-size: var(--fs-sm); }
.l-feature .tile { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 10px; background: var(--v-wash); color: var(--svc-ink); }
.l-forms { display: grid; grid-template-columns: 2fr 1fr; gap: 20px; max-width: 1080px; margin: 32px auto; padding: 0 20px; align-items: start; }
@media (max-width: 800px) { .l-forms { grid-template-columns: 1fr; } }
.l-foot { text-align: center; padding: 24px; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
