@layer components {
:focus-visible {
outline: 2px solid var(--accent);
outline-offset: 2px;
}
.card {
background: var(--surface);
border: 1px solid var(--border);
border-radius: var(--radius-card);
box-shadow: var(--shadow-card);
}
.card-head {
display: flex;
align-items: center;
justify-content: space-between;
padding: 10px 14px;
border-bottom: 1px solid var(--border);
}
.card-head h2,
.card-head h3 {
margin: 0;
font-size: var(--text-label);
font-weight: 600;
letter-spacing: .06em;
text-transform: uppercase;
color: var(--text-muted);
}
.card-head.plain h2,
.card-head.plain h3 {
font-size: var(--text-body);
font-weight: 600;
letter-spacing: 0;
text-transform: none;
color: var(--text);
}
.card-head .count {
font-size: var(--text-meta);
color: var(--text-faint);
font-variant-numeric: tabular-nums;
}
.nav-card {
background: var(--surface);
border: 1px solid var(--border);
border-radius: var(--radius-card);
box-shadow: var(--shadow-card);
margin-bottom: 2rem;
}
.btn {
display: inline-flex;
align-items: center;
gap: 8px;
height: 40px;
padding: 0 16px;
border-radius: var(--radius-control);
font-size: var(--text-body);
font-weight: 500;
white-space: nowrap;
cursor: pointer;
text-decoration: none;
background: var(--surface);
color: var(--text);
border: 1px solid var(--border-strong);
}
.btn:hover {
background: var(--surface-sunk);
}
.btn:active { background: var(--surface-sunk); filter: brightness(.97); }
.btn-primary:active { background: var(--accent-strong); filter: brightness(.9); }
.btn-danger:active { background: var(--danger); filter: brightness(.97); }
.btn svg { width: 20px; height: 20px; flex: 0 0 auto; }
.btn-primary {
background: var(--accent-strong);
border-color: var(--accent-strong);
color: var(--accent-ink);
}
.btn-primary:hover {
background: var(--accent-strong);
filter: brightness(.94);
}
.btn-danger {
background: var(--danger);
border-color: var(--danger);
color: var(--danger-ink);
}
.btn-danger:hover {
background: var(--danger);
filter: brightness(1.06);
}
.btn-sm {
height: 32px;
padding: 0 12px;
font-size: var(--text-ui);
}
.btn-sm svg { width: 16px; height: 16px; }
.icon-btn {
width: 36px;
height: 36px;
display: inline-flex;
align-items: center;
justify-content: center;
border: 0;
border-radius: var(--radius-control);
background: transparent;
color: var(--text-muted);
cursor: pointer;
text-decoration: none;
}
.icon-btn:hover {
background: var(--surface-sunk);
color: var(--text);
}
.icon-btn svg { width: 20px; height: 20px; }
.select {
height: 40px;
padding: 0 10px;
border-radius: var(--radius-control);
border: 1px solid var(--border-strong);
background: var(--surface);
color: var(--text);
font-size: var(--text-body);
font-weight: 500;
cursor: pointer;
}
.select:hover { background: var(--surface-sunk); }
.stepper {
display: inline-flex;
align-items: center;
height: 40px;
overflow: hidden;
background: var(--surface);
border: 1px solid var(--border-strong);
border-radius: var(--radius-control);
}
.stepper button {
width: 32px;
height: 100%;
border: 0;
background: transparent;
color: var(--text-muted);
cursor: pointer;
font-size: var(--text-read);
}
.stepper button:hover {
background: var(--surface-sunk);
color: var(--text);
}
.stepper button:active { background: var(--surface-sunk); filter: brightness(.97); }
.stepper input {
width: 56px;
height: 100%;
border: 0;
background: transparent;
color: var(--text);
text-align: center;
font-size: var(--text-body);
font-weight: 600;
font-variant-numeric: tabular-nums;
-moz-appearance: textfield;
appearance: textfield;
}
.stepper input::-webkit-outer-spin-button,
.stepper input::-webkit-inner-spin-button {
-webkit-appearance: none;
margin: 0;
}
.stepper input:focus { outline: none; }
.stepper:focus-within {
border-color: var(--accent);
box-shadow: 0 0 0 2px var(--accent-soft);
}
.search-input {
width: 100%;
height: 44px;
padding: 0 16px 0 40px;
border-radius: var(--radius-control);
border: 1px solid var(--border-strong);
background: var(--surface);
color: var(--text);
font-size: var(--text-body);
}
.search-input::placeholder { color: var(--text-faint); }
.search-input:focus {
outline: none;
border-color: var(--accent);
box-shadow: 0 0 0 2px var(--accent-soft);
}
.nav-pill {
padding: .5rem 1.25rem;
border-radius: 9999px;
font-size: var(--text-body);
font-weight: 500;
color: var(--text-muted);
text-decoration: none;
white-space: nowrap;
}
.nav-pill:hover {
background: var(--surface-sunk);
color: var(--text);
}
.nav-pill.active {
background: var(--accent-soft);
color: var(--accent-text);
font-weight: 600;
}
.menu-item {
display: flex;
align-items: center;
gap: 12px;
width: 100%;
padding: 10px 16px;
font-size: var(--text-body);
color: var(--text-muted);
text-decoration: none;
background: transparent;
border: 0;
text-align: left;
cursor: pointer;
}
.menu-item:hover {
background: var(--surface-sunk);
color: var(--text);
}
.menu-item.active {
color: var(--accent-text);
font-weight: 600;
}
.dark .brand-mark {
background: var(--text);
padding: 2px;
}
.row {
display: flex;
align-items: center;
gap: 10px;
padding: 7px 14px;
font-size: var(--text-body);
}
.row + .row { border-top: 1px solid var(--border); }
.row .row-name { flex: 1; min-width: 0; }
.row-value {
white-space: nowrap;
font-weight: 600;
color: var(--accent-text);
font-variant-numeric: tabular-nums;
}
.row-note {
color: var(--text-faint);
font-size: var(--text-meta);
}
.ref-checkbox { width: 16px; height: 16px; }
.list-checkbox { width: 20px; height: 20px; }
.list-checkbox:checked + label .item-name {
text-decoration: line-through;
opacity: .6;
}
.ingredient-list { list-style: none; margin: 0; padding: 0; }
.ingredient-row {
display: flex;
justify-content: space-between;
align-items: center;
padding: .5rem .75rem;
border-radius: var(--radius-control);
background: var(--surface-sunk);
}
.section-label {
font-size: var(--text-label);
font-weight: 600;
letter-spacing: .06em;
text-transform: uppercase;
color: var(--text-faint);
margin: 18px 0 8px;
padding: 0 14px;
}
.metaline {
display: flex;
flex-wrap: wrap;
align-items: center;
gap: 6px 0;
font-size: var(--text-ui);
color: var(--text-muted);
}
.metaline > *:not(:last-child)::after {
content: "·";
margin: 0 8px;
color: var(--text-faint);
}
.metaline b { font-weight: 600; color: var(--text); }
a.text-info { text-decoration: underline; text-underline-offset: 2px; }
.item-status-dot {
flex: 0 0 auto;
width: 8px;
height: 8px;
border-radius: 50%;
}
.item-status-dot.in-stock { background: var(--ok); }
.item-status-dot.low-stock { background: var(--accent); }
.item-status-dot.out-of-stock { background: var(--danger); }
.ingredient-badge {
color: var(--accent-text);
font-weight: 600;
white-space: nowrap;
}
.cookware-badge {
color: var(--text);
font-weight: 600;
white-space: nowrap;
text-decoration: underline dotted var(--inactive);
text-underline-offset: 3px;
}
.timer-badge {
padding: 1px 6px;
border-radius: 5px;
background: var(--surface-sunk);
border: 1px solid var(--border);
color: var(--text);
font-weight: 600;
font-variant-numeric: tabular-nums;
white-space: nowrap;
}
.cooking-overlay .timer-badge[data-timer] {
cursor: pointer;
}
.cooking-overlay .timer-badge[data-timer]:hover,
.cooking-overlay .timer-badge[data-timer]:focus-visible {
border-color: var(--border-strong);
}
.timer-badge.timer-running {
background: var(--accent-soft);
border-color: var(--accent);
color: var(--accent-text);
}
.timer-badge.timer-done {
background: var(--danger-soft);
border-color: var(--danger);
color: var(--danger);
}
.timer-chip {
display: inline-flex;
align-items: center;
flex: 0 0 auto;
padding: 1px 8px;
border-radius: 9999px;
font-size: var(--text-meta);
font-weight: 600;
font-variant-numeric: tabular-nums;
white-space: nowrap;
background: var(--accent-soft);
border: 1px solid var(--accent);
color: var(--accent-text);
cursor: pointer;
}
.timer-chip.timer-done {
background: var(--danger-soft);
border-color: var(--danger);
color: var(--danger);
}
.timer-modal-time {
font-size: 3rem;
font-weight: 700;
font-variant-numeric: tabular-nums;
color: var(--accent-text);
}
.timer-modal-time.timer-done {
color: var(--danger);
}
.step-number {
flex: 0 0 32px;
width: 32px;
height: 32px;
border-radius: 50%;
display: flex;
align-items: center;
justify-content: center;
background: var(--accent-soft);
color: var(--accent-text);
font-size: var(--text-body);
font-weight: 700;
font-variant-numeric: tabular-nums;
}
.tag {
display: inline-block;
padding: 1px 8px;
border-radius: 9999px;
font-size: var(--text-meta);
font-weight: 500;
background: var(--surface-sunk);
border: 1px solid var(--border);
color: var(--text-muted);
}
.metadata-pill {
display: inline-flex;
align-items: center;
padding: .25rem .75rem;
border-radius: 9999px;
font-size: var(--text-body);
font-weight: 500;
white-space: nowrap;
background: var(--surface);
border: 1px solid var(--border);
color: var(--text-muted);
}
.metadata-original {
background: var(--accent-soft);
border-color: transparent;
color: var(--accent-ink);
}
.metadata-original:hover {
text-decoration: underline;
}
.metadata-pill svg {
width: 1rem;
height: 1rem;
margin-right: .5rem;
}
.recipe-card {
display: flex;
flex-direction: column;
overflow: hidden;
text-decoration: none;
background: var(--surface);
border: 1px solid var(--border);
border-radius: var(--radius-card);
box-shadow: var(--shadow-card);
}
.recipe-card:hover { border-color: var(--border-strong); }
.recipe-card-icon {
width: 64px;
height: 64px;
display: flex;
align-items: center;
justify-content: center;
border-radius: 50%;
background: var(--surface-sunk);
border: 1px solid var(--border);
font-size: 24px;
margin-bottom: 1rem;
}
.recipe-card-title {
display: block;
margin: 0 0 .5rem;
font-size: var(--text-title);
font-weight: 700;
line-height: 1.35;
color: var(--text);
}
.recipe-card-sub {
display: block;
font-size: var(--text-meta);
color: var(--text-faint);
}
.step-list { list-style: none; margin: 0; padding: 0; }
.step-box {
background: var(--surface-sunk);
border: 1px solid var(--border);
border-radius: var(--radius-card);
padding: 1rem;
}
.step-body {
font-size: var(--text-read);
line-height: 2;
color: var(--text);
}
.step-refs {
margin-top: .5rem;
padding-left: 1rem;
border-left: 2px solid var(--accent);
font-size: var(--text-body);
color: var(--text-muted);
}
.recipe-note {
display: flex;
gap: 8px;
padding: 12px 14px;
border-radius: var(--radius-card);
border: 1px solid var(--border);
border-left: 3px solid var(--accent);
background: var(--surface-sunk);
color: var(--text-muted);
font-style: italic;
}
.image-step {
@apply w-full max-h-80 object-contain;
border-radius: var(--radius-card);
}
.recipe-image-placeholder {
background: var(--surface-sunk);
border: 1px solid var(--border);
color: var(--accent-text);
@apply w-30 h-30 rounded-full flex items-center justify-center text-5xl;
}
.plan-day-today {
border-color: var(--accent);
box-shadow: 0 0 0 1px var(--accent);
}
.plan-day-past {
background: var(--surface-sunk);
}
.plan-day-past > h2 {
color: var(--text-faint);
}
.plan-add,
.plan-line-button {
flex: none;
width: 24px;
height: 24px;
display: inline-flex;
align-items: center;
justify-content: center;
border-radius: var(--radius-control);
color: var(--text-muted);
cursor: pointer;
}
.plan-add svg,
.plan-line-button svg { width: 16px; height: 16px; }
.plan-add:hover,
.plan-line-button:hover,
.plan-line-button[aria-expanded="true"] {
background: var(--surface-sunk);
color: var(--text);
}
.plan-line[draggable="true"] { cursor: grab; }
.plan-line .ingredient-badge { white-space: normal; }
.plan-line > div > * { min-width: 0; max-width: 100%; }
.plan-meal.plan-drop {
outline: 2px dashed var(--accent);
outline-offset: 2px;
border-radius: var(--radius-control);
}
.plan-popup {
position: absolute;
z-index: 40;
padding: 4px;
display: flex;
flex-direction: column;
background: var(--surface);
border: 1px solid var(--border);
border-radius: var(--radius-card);
box-shadow: var(--shadow-overlay);
}
.plan-popup[hidden] { display: none; }
.plan-popup [role="menuitem"] {
height: 32px;
padding: 0 12px;
text-align: left;
white-space: nowrap;
border-radius: var(--radius-control);
font-size: var(--text-ui);
color: var(--text);
cursor: pointer;
}
.plan-popup [role="menuitem"]:hover,
.plan-popup [role="menuitem"]:focus {
background: var(--surface-sunk);
outline: none;
}
.pantry-item {
background: var(--surface-sunk);
border: 1px solid transparent;
border-radius: var(--radius-control);
padding: 1rem;
}
.pantry-item:hover { border-color: var(--border); }
.pantry-item .quantity-display { color: var(--text-muted); }
.pantry-item .item-quantity { font-weight: 500; }
.pantry-item.out-of-stock {
background: var(--danger-soft);
border-color: var(--danger);
}
.pantry-item.out-of-stock .quantity-display,
.pantry-item.out-of-stock .out-of-stock-icon {
color: var(--danger);
}
.pantry-item.out-of-stock .item-quantity { font-weight: 600; }
.pantry-item.low-stock {
background: var(--accent-soft);
border-color: var(--accent);
}
.pantry-item.low-stock .quantity-display,
.pantry-item.low-stock .out-of-stock-icon {
color: var(--accent-text);
}
.pantry-item.low-stock .item-quantity { font-weight: 600; }
.pantry-actions { opacity: 0; }
.pantry-item:hover .pantry-actions,
.pantry-item:focus-within .pantry-actions { opacity: 1; }
.pantry-actions .icon-btn { width: 28px; height: 28px; }
.pantry-actions .icon-btn svg { width: 16px; height: 16px; }
.editor-toolbar {
display: flex;
flex-wrap: wrap;
align-items: center;
gap: 8px 12px;
padding: 6px;
margin-bottom: 8px;
background: var(--surface);
border: 1px solid var(--border);
border-radius: var(--radius-card);
}
.editor-toolbar-group {
display: flex;
flex-wrap: wrap;
gap: 4px;
min-width: 0;
}
.editor-toolbar-group + .editor-toolbar-group {
padding-left: 12px;
border-left: 1px solid var(--border);
}
@media (max-width: 767px) {
.editor-toolbar-group + .editor-toolbar-group {
padding-left: 0;
border-left: 0;
}
}
.editor-toolbar .btn-sm { padding: 0 10px; gap: 6px; }
.editor-toolbar-glyph {
font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
font-weight: 600;
color: var(--accent-text);
}
.editor-toolbar-date {
height: 32px;
padding: 0 8px;
border-radius: var(--radius-control);
border: 1px solid var(--border-strong);
background: var(--surface);
color: var(--text);
font-size: var(--text-ui);
}
.editor-toolbar-menu { position: relative; }
.editor-toolbar-popup {
position: absolute;
top: calc(100% + 4px);
left: 0;
z-index: 40;
min-width: 100%;
padding: 4px;
display: flex;
flex-direction: column;
background: var(--surface);
border: 1px solid var(--border);
border-radius: var(--radius-card);
box-shadow: var(--shadow-overlay);
}
.editor-toolbar-popup[hidden] { display: none; }
.editor-toolbar-popup [role="menuitem"] {
height: 32px;
padding: 0 12px;
text-align: left;
white-space: nowrap;
border-radius: var(--radius-control);
font-size: var(--text-ui);
color: var(--text);
cursor: pointer;
}
.editor-toolbar-popup [role="menuitem"]:hover,
.editor-toolbar-popup [role="menuitem"]:focus {
background: var(--surface-sunk);
outline: none;
}
.picker-search,
.picker-servings {
height: 40px;
padding: 0 12px;
border-radius: var(--radius-control);
border: 1px solid var(--border-strong);
background: var(--surface);
color: var(--text);
font-size: var(--text-body);
}
.picker-search { width: 100%; }
.picker-servings { width: 7rem; }
.picker-search:focus,
.picker-servings:focus {
outline: none;
border-color: var(--accent);
box-shadow: 0 0 0 2px var(--accent-soft);
}
.picker-results {
margin-top: 8px;
max-height: 18rem;
overflow-y: auto;
border: 1px solid var(--border);
border-radius: var(--radius-control);
}
.picker-results:empty { display: none; }
.picker-option {
display: flex;
flex-direction: column;
padding: 8px 12px;
cursor: pointer;
border-bottom: 1px solid var(--border);
}
.picker-option:last-child { border-bottom: 0; }
.picker-option:hover { background: var(--surface-sunk); }
.picker-option[aria-selected="true"] {
background: var(--accent-soft);
box-shadow: inset 3px 0 0 var(--accent);
}
.picker-option-name { color: var(--text); font-weight: 500; }
.picker-option-path {
font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
font-size: var(--text-ui);
color: var(--text-muted);
overflow-wrap: anywhere;
}
@media (pointer: coarse) {
.btn { height: 44px; }
.select { height: 44px; }
.stepper { height: 46px; }
.stepper button { width: 44px; }
.icon-btn { width: 44px; height: 44px; }
.ref-checkbox,
.list-checkbox { width: 24px; height: 24px; }
.pantry-actions { opacity: 1; }
.plan-add,
.plan-line-button { width: 36px; height: 36px; }
}
}