:root { --bg: #0b0d12; --card: rgba(28, 32, 42, 0.85); --border: rgba(255,255,255,0.1); --text: #f5f7fa; --muted: #94a3b8; --accent: #38bdf8; --danger: #f87171; --ok: #4ade80; }
* { box-sizing: border-box; }
body { background: radial-gradient(circle at 15% 15%, #1a2234 0%, #0b0d12 60%) fixed; color: var(--text); font-family: system-ui, -apple-system, sans-serif; margin: 0; padding: 14px; padding-bottom: 112px; }
h1, h2, h3 { margin: 0 0 12px 0; }
h1 { font-size: 1.22rem; margin: 0; }
h2 { font-size: 1.08rem; }
.top-bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 12px; }
.top-actions { display: flex; gap: 6px; flex-shrink: 0; }
.btn-pill { background: rgba(56, 189, 248, 0.16); border: 1px solid rgba(56, 189, 248, 0.42); color: #ffffff; border-radius: 999px; padding: 8px 13px; font-size: 0.82rem; font-weight: 600; cursor: pointer; white-space: nowrap; min-height: 34px; display: inline-flex; align-items: center; justify-content: center; }
.btn-pill:hover { background: rgba(56, 189, 248, 0.28); }
.btn-pill:disabled { opacity: 0.55; cursor: not-allowed; }
.btn-pill.secondary { background: rgba(255,255,255,0.08); border-color: var(--border); color: var(--text); }
.btn-pill.danger { background: rgba(248, 113, 113, 0.15); border-color: rgba(248, 113, 113, 0.35); color: #fca5a5; }
.btn-pill.wake-active { background: rgba(74, 222, 128, 0.18); border-color: rgba(74, 222, 128, 0.5); color: #86efac; }
.tabs-bar { display: flex; gap: 6px; margin-bottom: 12px; background: rgba(15, 18, 26, 0.72); padding: 4px; border-radius: 999px; border: 1px solid var(--border); }
.tab-btn { flex: 1; background: transparent; border: none; color: var(--muted); border-radius: 999px; padding: 9px 6px; font-size: 0.82rem; font-weight: 700; cursor: pointer; white-space: nowrap; transition: all 0.15s ease; }
.tab-btn.active { background: rgba(56, 189, 248, 0.22); color: #ffffff; border: 1px solid rgba(56, 189, 248, 0.45); }
.subtabs-bar { display: flex; gap: 6px; margin-bottom: 12px; background: rgba(11, 13, 18, 0.72); padding: 4px; border-radius: 999px; border: 1px solid var(--border); }
.subtab-btn { flex: 1; background: transparent; border: none; color: var(--muted); border-radius: 999px; padding: 8px 8px; font-size: 0.8rem; font-weight: 600; cursor: pointer; white-space: nowrap; transition: all 0.15s ease; }
.subtab-btn.active { background: rgba(255, 255, 255, 0.14); color: #ffffff; }
.search-input { width: 100%; background: rgba(15, 18, 26, 0.7); border: 1px solid var(--border); border-radius: 999px; padding: 11px 16px; color: var(--text); font-size: 0.95rem; margin-bottom: 12px; outline: none; }
.search-input:focus { border-color: var(--accent); }
.filter-bar { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 10px; margin-bottom: 10px; scrollbar-width: none; }
.filter-bar::-webkit-scrollbar { display: none; }
.filter-pill { background: var(--card); border: 1px solid var(--border); color: var(--muted); border-radius: 999px; padding: 7px 14px; font-size: 0.84rem; font-weight: 600; white-space: nowrap; cursor: pointer; transition: all 0.15s ease; }
.filter-pill.active { background: rgba(56, 189, 248, 0.18); border-color: rgba(56, 189, 248, 0.45); color: #ffffff; }
.card { background: var(--card); backdrop-filter: blur(16px); border: 1px solid var(--border); border-radius: 22px; padding: 14px; margin-bottom: 16px; }
.cat-group { margin-bottom: 18px; }
.cat-group:last-child { margin-bottom: 0; }
.cat-header { display: flex; align-items: center; justify-content: space-between; font-size: 0.86rem; font-weight: 700; color: var(--accent); text-transform: uppercase; letter-spacing: 0.04em; padding: 4px 4px 8px 4px; border-bottom: 1px solid rgba(56, 189, 248, 0.22); margin-bottom: 4px; }
.cat-count { font-size: 0.78rem; color: var(--muted); font-weight: 500; }
.recipe-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 11px 4px; border-bottom: 1px solid var(--border); }
.recipe-row:last-child { border-bottom: none; }
.recipe-left { display: flex; align-items: center; gap: 12px; flex: 1; min-width: 0; }
input[type="checkbox"] { width: 22px; height: 22px; accent-color: var(--accent); flex-shrink: 0; cursor: pointer; }
.recipe-info { display: flex; flex-direction: column; min-width: 0; }
.recipe-title { font-weight: 600; font-size: 0.96rem; cursor: pointer; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.recipe-title:hover { color: var(--accent); }
.recipe-actions { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.btn-view { background: rgba(255,255,255,0.08); color: var(--text); border: 1px solid var(--border); border-radius: 999px; padding: 6px 12px; font-size: 0.8rem; font-weight: 600; cursor: pointer; white-space: nowrap; min-height: 32px; display: inline-flex; align-items: center; justify-content: center; }
.btn-view:hover { border-color: var(--accent); color: #ffffff; }
.btn-icon { width: 32px; height: 32px; padding: 0; border-radius: 50%; flex-shrink: 0; }
.servings-box { display: inline-flex; align-items: center; gap: 3px; background: rgba(56, 189, 248, 0.15); border: 1px solid rgba(56, 189, 248, 0.38); border-radius: 999px; padding: 2px 8px; min-height: 34px; }
.servings-box button { background: none; border: none; color: var(--accent); font-weight: 800; font-size: 1.1rem; width: 26px; height: 28px; cursor: pointer; padding: 0; display: flex; align-items: center; justify-content: center; }
.servings-val { font-size: 0.82rem; font-weight: 700; min-width: 58px; text-align: center; white-space: nowrap; }
.bottom-dock { position: fixed; bottom: 0; left: 0; right: 0; padding: 10px 14px calc(10px + env(safe-area-inset-bottom)) 14px; background: linear-gradient(to top, rgba(11, 13, 18, 0.98) 65%, rgba(11, 13, 18, 0)); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); z-index: 100; }
.primary-btn { width: 100%; background: var(--accent); color: #0b0d12; border: none; border-radius: 999px; padding: 13px 18px; font-weight: 800; cursor: pointer; font-size: 0.94rem; box-shadow: 0 6px 20px rgba(56, 189, 248, 0.3); }
.people-banner { display: flex; align-items: center; justify-content: space-between; gap: 8px; background: rgba(15, 18, 26, 0.65); border: 1px solid var(--border); border-radius: 16px; padding: 9px 12px; margin-bottom: 12px; }
.people-banner-label { font-size: 0.84rem; font-weight: 600; color: var(--text); }
.week-toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; gap: 8px; flex-wrap: wrap; }
.week-toolbar-btns { display: flex; gap: 6px; flex-wrap: wrap; }
.day-card { background: rgba(15, 18, 26, 0.62); border: 1px solid var(--border); border-radius: 18px; padding: 12px; margin-bottom: 10px; }
.day-title { font-weight: 800; font-size: 0.96rem; color: var(--accent); margin-bottom: 6px; }
.slot-block { border-top: 1px solid rgba(255,255,255,0.07); padding: 10px 0; }
.slot-block:last-child { padding-bottom: 2px; }
.slot-header-line { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.slot-title-wrap { display: flex; align-items: baseline; gap: 8px; flex: 1; min-width: 0; }
.slot-label { font-size: 0.72rem; font-weight: 800; color: var(--muted); letter-spacing: 0.04em; text-transform: uppercase; flex-shrink: 0; }
.slot-content { flex: 1; min-width: 0; font-size: 0.94rem; line-height: 1.35; }
.slot-empty { color: var(--muted); font-style: italic; font-size: 0.84rem; }
.slot-controls-bar { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-top: 8px; }
.slot-controls-left { display: flex; align-items: center; gap: 6px; }
.slot-controls-right { display: flex; align-items: center; gap: 6px; margin-left: auto; }
.slot-servings-badge { font-size: 0.78rem; color: var(--muted); font-weight: 600; background: rgba(255,255,255,0.05); border: 1px solid var(--border); border-radius: 999px; padding: 5px 10px; min-height: 32px; display: inline-flex; align-items: center; }
.slot-inline-steps { display: none; margin-top: 10px; background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.08); border-radius: 14px; padding: 10px 12px; font-size: 0.86rem; line-height: 1.5; }
.slot-inline-steps h4 { margin: 0 0 6px 0; font-size: 0.78rem; text-transform: uppercase; color: var(--accent); letter-spacing: 0.03em; }
.slot-inline-steps ul { margin: 0 0 10px 0; padding-left: 16px; color: #e2e8f0; }
.slot-inline-steps ol { margin: 0; padding-left: 18px; color: #cbd5e1; }
.slot-inline-steps li { margin-bottom: 6px; }
.timer-chip { display: inline-flex; align-items: center; gap: 4px; background: rgba(56, 189, 248, 0.22); border: 1px solid rgba(56, 189, 248, 0.55); color: #7dd3fc; border-radius: 999px; padding: 2px 10px; font-size: 0.84rem; font-weight: 700; cursor: pointer; margin: 0 2px; }
.timer-chip:hover { background: rgba(56, 189, 248, 0.35); color: #fff; }
.timers-dock { position: fixed; bottom: 72px; left: 14px; right: 14px; display: flex; gap: 8px; overflow-x: auto; z-index: 650; pointer-events: none; scrollbar-width: none; }
.timers-dock::-webkit-scrollbar { display: none; }
.active-timer { pointer-events: auto; display: flex; align-items: center; gap: 10px; background: rgba(20, 24, 33, 0.97); border: 1px solid rgba(56, 189, 248, 0.65); box-shadow: 0 8px 24px rgba(0,0,0,0.65); border-radius: 999px; padding: 8px 14px; white-space: nowrap; }
.active-timer.ringing { border-color: #f87171; background: rgba(127, 29, 29, 0.97); animation: pulseTimer 0.8s infinite alternate; }
@keyframes pulseTimer { from { transform: scale(1); } to { transform: scale(1.04); } }
.timer-clock { font-variant-numeric: tabular-nums; font-weight: 800; font-size: 1.05rem; color: #fff; }
.timer-label { font-size: 0.76rem; color: var(--muted); max-width: 130px; overflow: hidden; text-overflow: ellipsis; }
.timer-ctrl { background: rgba(255,255,255,0.14); border: none; color: #fff; border-radius: 999px; width: 28px; height: 28px; cursor: pointer; font-size: 0.82rem; display: flex; align-items: center; justify-content: center; }
.shop-header { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.extra-bar { display: flex; gap: 8px; margin-bottom: 14px; }
.extra-bar input { flex: 1; background: rgba(15, 18, 26, 0.7); border: 1px solid var(--border); border-radius: 999px; padding: 9px 14px; color: var(--text); font-size: 0.9rem; outline: none; }
.aisle-group { margin-bottom: 16px; }
.aisle-group:last-child { margin-bottom: 0; }
.aisle-title { font-size: 0.9rem; font-weight: 700; color: var(--accent); text-transform: uppercase; letter-spacing: 0.04em; padding: 6px 4px; border-bottom: 1px solid rgba(56, 189, 248, 0.25); margin-bottom: 6px; }
.ing-item { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 4px; border-bottom: 1px solid rgba(255,255,255,0.05); cursor: pointer; }
.ing-item:last-child { border-bottom: none; }
.ing-left { display: flex; align-items: center; gap: 12px; flex: 1; }
.ing-item.done span { text-decoration: line-through; opacity: 0.45; }
.modal-backdrop { display: none; position: fixed; inset: 0; background: rgba(5, 7, 11, 0.84); backdrop-filter: blur(8px); z-index: 500; padding: 14px; overflow-y: auto; }
.modal-card { background: #141821; border: 1px solid var(--border); border-radius: 24px; max-width: 640px; margin: 14px auto 90px auto; padding: 20px; position: relative; }
.modal-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.modal-close { background: rgba(255,255,255,0.12); color: var(--text); border: none; border-radius: 999px; width: 32px; height: 32px; font-size: 1.05rem; cursor: pointer; flex-shrink: 0; }
.modal-toolbar { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.recipe-img { width: 100%; max-height: 220px; object-fit: cover; border-radius: 16px; margin-bottom: 14px; display: none; }
.meta-bar { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; font-size: 0.84rem; color: var(--muted); }
.meta-pill { background: rgba(255,255,255,0.06); padding: 4px 10px; border-radius: 999px; }
.step-item { background: rgba(255,255,255,0.04); border-radius: 14px; padding: 10px 12px; margin-bottom: 8px; line-height: 1.5; font-size: 0.93rem; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
@media (max-width: 520px) { .form-grid { grid-template-columns: 1fr; } }
.form-label { display: block; font-size: 0.82rem; color: var(--muted); margin-bottom: 5px; font-weight: 600; }
.form-input, .form-select, .form-textarea { width: 100%; background: rgba(11, 13, 18, 0.88); border: 1px solid var(--border); border-radius: 14px; padding: 10px 13px; color: var(--text); font-size: 0.92rem; margin-bottom: 12px; outline: none; font-family: inherit; }
.form-select { cursor: pointer; appearance: auto; }
.form-textarea { min-height: 120px; resize: vertical; line-height: 1.5; }
.form-input:focus, .form-select:focus, .form-textarea:focus { border-color: var(--accent); }
.btn-submit { background: var(--accent); color: #0b0d12; border: none; border-radius: 999px; padding: 12px 18px; font-weight: 700; width: 100%; cursor: pointer; font-size: 0.95rem; }
.btn-submit:disabled { opacity: 0.55; cursor: not-allowed; }
.status-msg { font-size: 0.88rem; margin-top: 12px; padding: 10px 12px; border-radius: 12px; display: none; }
.status-ok { background: rgba(34, 197, 94, 0.16); border: 1px solid rgba(34, 197, 94, 0.4); color: #86efac; }
.status-err { background: rgba(239, 68, 68, 0.16); border: 1px solid rgba(239, 68, 68, 0.4); color: #fca5a5; }
