:root {
    --primary: #fa6e14;
    --primary-dark: #dc5a14;
    --secondary: #fabe28;
    --accent: #2896a0;
    --ink: #28323c;
    --muted: #67737c;
    --line: #ead9c3;
    --paper: #fff8ec;
    --white: #ffffff;
    --blue: #1e8792;
    --plum: #ff9c3d;
    --green-soft: #e5f7f5;
    --orange-soft: #fff0e3;
    --yellow-soft: #fff5d0;
    --shadow: 0 12px 32px rgba(40, 50, 60, 0.12);
}

* {
    box-sizing: border-box;
}

html {
    color: var(--ink);
    background: var(--paper);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    line-height: 1.5;
}

body {
    margin: 0;
    min-width: 320px;
}

a {
    color: var(--primary-dark);
    text-decoration: none;
}

button,
input,
select,
textarea {
    font: inherit;
}

input,
select,
textarea {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--white);
    color: var(--ink);
    padding: 0.75rem 0.85rem;
}

textarea {
    resize: vertical;
}

label {
    display: grid;
    gap: 0.35rem;
    color: var(--ink);
    font-weight: 700;
    font-size: 0.92rem;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th,
td {
    padding: 0.9rem;
    border-bottom: 1px solid var(--line);
    text-align: left;
    vertical-align: top;
}

th {
    color: var(--muted);
    font-size: 0.82rem;
    text-transform: uppercase;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 1rem;
    justify-content: space-between;
    padding: 0.55rem clamp(1rem, 4vw, 2rem);
    background: rgba(255, 248, 236, 0.96);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(10px);
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 0;
    color: var(--ink);
    font-weight: 900;
    white-space: nowrap;
}

.brand-logo {
    display: block;
    width: clamp(148px, 18vw, 220px);
    max-width: 100%;
    max-height: 112px;
    object-fit: contain;
    object-position: left center;
}

.brand-fallback {
    display: none;
    align-items: center;
    min-height: 2.65rem;
    color: var(--ink);
    font-weight: 900;
}

.brand-mark,
.panel-icon {
    display: inline-grid;
    place-items: center;
    width: 2.35rem;
    aspect-ratio: 1;
    border-radius: 8px;
    background: var(--primary);
    color: var(--white);
    font-size: 0.82rem;
    font-weight: 900;
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    overflow-x: auto;
    padding: 0.25rem;
}

.main-nav a {
    color: var(--ink);
    border-radius: 8px;
    padding: 0.5rem 0.65rem;
    font-weight: 700;
    white-space: nowrap;
}

.main-nav a:hover {
    background: var(--orange-soft);
}

.header-actions,
.button-row,
.vote-actions,
.admin-links {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.65rem;
}

.button,
.ghost-button,
.link-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 2.65rem;
    border: 0;
    border-radius: 8px;
    padding: 0.72rem 1rem;
    cursor: pointer;
    font-weight: 850;
}

.button {
    background: var(--primary);
    color: var(--white);
    box-shadow: 0 8px 18px rgba(250, 110, 20, 0.26);
}

.button:hover {
    background: var(--primary-dark);
}

.button.small,
.ghost-button.small {
    min-height: 2.25rem;
    padding: 0.52rem 0.75rem;
    font-size: 0.9rem;
}

.button.full {
    width: 100%;
}

.ghost-button {
    border: 1px solid var(--line);
    background: var(--white);
    color: var(--ink);
}

.ghost-button.light {
    background: rgba(255, 255, 255, 0.82);
}

.link-button {
    background: transparent;
    color: var(--primary-dark);
    padding-inline: 0;
    min-height: auto;
}

.link-button.danger {
    color: #a33131;
}

.flash {
    max-width: 1120px;
    margin: 1rem auto 0;
    padding: 0.85rem 1rem;
    border-radius: 8px;
    font-weight: 750;
}

.flash.success {
    background: var(--green-soft);
}

.flash.error {
    background: #ffe9e2;
}

.flash.info {
    background: var(--yellow-soft);
}

.page-shell {
    width: min(1120px, calc(100% - 2rem));
    margin: 0 auto;
    padding: 2rem 0 4rem;
}

.page-shell.narrow {
    width: min(680px, calc(100% - 2rem));
}

.hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 2rem;
    min-height: 72vh;
    padding: clamp(2rem, 6vw, 5rem) clamp(1rem, 5vw, 4rem) 2rem;
    align-items: center;
    background:
        linear-gradient(90deg, rgba(255, 248, 236, 0.96), rgba(255, 248, 236, 0.72)),
        repeating-linear-gradient(135deg, var(--paper) 0 18px, #ffefd8 18px 36px);
}

.hero-copy {
    max-width: 720px;
}

.eyebrow {
    margin: 0 0 0.45rem;
    color: var(--primary-dark);
    font-weight: 900;
    text-transform: uppercase;
    font-size: 0.78rem;
}

h1,
h2,
h3,
p {
    overflow-wrap: anywhere;
}

h1 {
    margin: 0;
    font-size: clamp(2.35rem, 8vw, 5.5rem);
    line-height: 0.95;
}

h2 {
    margin: 0 0 0.75rem;
    font-size: 1.35rem;
    line-height: 1.12;
}

h3 {
    margin: 0 0 0.45rem;
}

.hero-lede {
    max-width: 650px;
    color: #4a5861;
    font-size: 1.14rem;
}

.hero-board {
    width: min(100%, 430px);
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 1rem;
    background: var(--white);
    box-shadow: var(--shadow);
}

.board-header,
.mini-plan,
.list-row,
.notice-row,
.grocery-row,
.reminder-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

.mini-plan,
.notice-row {
    padding: 0.8rem 0;
    border-top: 1px solid var(--line);
}

.mini-plan span {
    color: var(--muted);
    font-weight: 800;
}

.challenge-chip,
.pill,
.check-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    width: fit-content;
    border-radius: 8px;
    padding: 0.42rem 0.65rem;
    background: var(--yellow-soft);
    color: #735000;
    font-weight: 850;
}

.home-grid,
.dashboard-grid,
.settings-grid,
.tools-grid,
.stat-grid {
    display: grid;
    gap: 1rem;
}

.home-grid {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.feature-panel,
.panel,
.meal-card,
.vote-card,
.day-card,
.auth-card,
.table-card,
.stat-card,
.challenge-hero,
.winner-banner,
.empty-state {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--white);
    box-shadow: var(--shadow);
}

.feature-panel,
.panel,
.meal-card,
.vote-card,
.day-card,
.auth-card,
.stat-card,
.empty-state {
    padding: 1rem;
}

.feature-panel:nth-child(2) .panel-icon {
    background: var(--blue);
}

.feature-panel:nth-child(3) .panel-icon {
    background: var(--accent);
}

.section-heading {
    margin-bottom: 1.25rem;
}

.section-heading.with-action,
.panel-heading,
.day-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.dashboard-hero {
    display: grid;
    gap: 1rem;
    grid-template-columns: minmax(0, 1fr);
    margin-bottom: 1rem;
    padding: 1.25rem;
    border-radius: 8px;
    background: var(--ink);
    color: var(--white);
}

.dashboard-hero .eyebrow,
.dashboard-hero .muted {
    color: var(--secondary);
}

.tonight-meal {
    margin: 0.75rem 0;
    font-size: clamp(1.5rem, 6vw, 3.6rem);
    font-weight: 900;
    line-height: 1;
}

.points-card {
    display: grid;
    align-content: center;
    gap: 0.25rem;
    border-radius: 8px;
    background: var(--secondary);
    color: var(--ink);
    padding: 1rem;
}

.points-card strong,
.stat-card strong {
    font-size: 2.2rem;
    line-height: 1;
}

.dashboard-grid {
    grid-template-columns: minmax(0, 1fr);
}

.span-2 {
    grid-column: auto;
}

.week-strip {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.65rem;
}

.week-strip article {
    display: grid;
    gap: 0.25rem;
    min-height: 6rem;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 0.75rem;
    background: var(--paper);
}

.week-strip span,
.week-strip small,
.muted,
.reason-line,
.form-note,
.meta-row,
.notice-row p {
    color: var(--muted);
}

.progress {
    height: 0.7rem;
    overflow: hidden;
    border-radius: 8px;
    background: #f3dfc9;
}

.progress span {
    display: block;
    height: 100%;
    background: var(--accent);
}

.meal-card-grid,
.vote-grid,
.planner-grid,
.grocery-groups {
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.meal-card,
.vote-card {
    position: relative;
    display: grid;
    align-content: start;
    gap: 0.7rem;
}

.score-badge {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    display: grid;
    place-items: center;
    min-width: 2.3rem;
    height: 2.3rem;
    border-radius: 8px;
    background: var(--accent);
    color: var(--ink);
    font-weight: 900;
}

.meta-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.45rem;
    font-size: 0.88rem;
    font-weight: 750;
}

.meta-row span {
    border-radius: 8px;
    background: var(--paper);
    padding: 0.32rem 0.5rem;
}

.filter-bar,
.inline-add {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.65rem;
    align-items: end;
    margin-bottom: 1rem;
}

.stack-form {
    display: grid;
    gap: 0.85rem;
}

.stack-form.compact {
    margin-top: 1rem;
}

.two-col,
.three-col,
.four-col {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.8rem;
}

.checkbox-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.checkbox-row label,
.check-pill {
    font-weight: 750;
    font-size: 0.9rem;
}

.check-pill input,
.checkbox-row input,
.reminder-row input[type="checkbox"] {
    width: auto;
}

.form-drawer {
    margin: 1rem 0;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--white);
    padding: 1rem;
}

.form-drawer summary {
    cursor: pointer;
    font-weight: 900;
}

.auth-shell {
    display: grid;
    place-items: center;
    min-height: calc(100vh - 74px);
    padding: 2rem 1rem;
}

.auth-card {
    width: min(100%, 430px);
    display: grid;
    gap: 1rem;
}

.auth-card.wide {
    width: min(100%, 680px);
}

.planner-form {
    display: grid;
    gap: 1rem;
}

.day-card {
    display: grid;
    gap: 0.8rem;
}

.fixed-save {
    position: sticky;
    bottom: 1rem;
    justify-self: end;
}

.spinner-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 1rem;
    align-items: center;
}

.spinner-wheel {
    position: relative;
    width: min(80vw, 320px);
    aspect-ratio: 1;
    justify-self: center;
    border-radius: 50%;
    border: 10px solid var(--white);
    background: conic-gradient(var(--primary) 0 16.6%, var(--secondary) 16.6% 33.2%, var(--accent) 33.2% 49.8%, var(--blue) 49.8% 66.4%, var(--plum) 66.4% 83%, var(--primary-dark) 83% 100%);
    box-shadow: var(--shadow);
    transition: transform 2.4s cubic-bezier(.12, .78, .16, 1);
}

.spinner-pointer {
    position: absolute;
    top: -18px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 15px solid transparent;
    border-right: 15px solid transparent;
    border-top: 28px solid var(--ink);
}

.spinner-center {
    position: absolute;
    inset: 36%;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: var(--white);
    font-weight: 900;
}

.spin-options {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    margin-top: 1rem;
}

.spin-options span,
.spin-options a,
.spinner-result-link a {
    border-radius: 8px;
    background: var(--paper);
    padding: 0.35rem 0.55rem;
    font-size: 0.86rem;
    font-weight: 750;
}

.spin-options a {
    color: var(--ink);
    text-decoration: none;
}

.spinner-result-link {
    min-height: 2.25rem;
    margin: 0 0 1rem;
}

.winner-banner,
.challenge-hero {
    display: grid;
    gap: 1rem;
    padding: 1rem;
    margin-bottom: 1rem;
    background: var(--yellow-soft);
}

.winner-banner strong {
    font-size: 1.6rem;
}

.grocery-row {
    padding: 0.75rem 0;
    border-top: 1px solid var(--line);
}

.grocery-row.done strong {
    text-decoration: line-through;
    color: var(--muted);
}

.checkbox-button {
    display: grid;
    place-items: center;
    width: 2rem;
    height: 2rem;
    border: 2px solid var(--accent);
    border-radius: 8px;
    background: var(--white);
    color: var(--ink);
    font-weight: 900;
    cursor: pointer;
}

.table-card {
    overflow-x: auto;
}

.settings-grid,
.tools-grid {
    grid-template-columns: minmax(0, 1fr);
}

.reminder-row {
    display: grid;
    grid-template-columns: 1fr;
    align-items: center;
    border-top: 1px solid var(--line);
    padding-top: 0.75rem;
}

.theme-card,
.copy-box {
    border-radius: 8px;
    background: var(--paper);
    padding: 1rem;
    font-weight: 900;
}

.recipe-box-shell {
    width: min(1240px, calc(100% - 2rem));
}

.recipe-admin-shell {
    width: min(1180px, calc(100% - 2rem));
}

.recipe-submit-drawer,
.recipe-edit-drawer {
    box-shadow: var(--shadow);
}

.recipe-admin-list {
    display: grid;
    gap: 0.8rem;
}

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

.recipe-modal {
    position: fixed;
    z-index: 1000;
    inset: 0;
    display: grid;
    place-items: center;
    padding: clamp(0.75rem, 2vw, 1.5rem);
}

.recipe-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(24, 32, 38, 0.72);
}

.recipe-modal-panel {
    position: relative;
    z-index: 1;
    width: min(1120px, 100%);
    max-height: min(92vh, 980px);
    overflow: auto;
    border-radius: 8px;
    background: var(--white);
    box-shadow: 0 30px 90px rgba(0, 0, 0, 0.34);
}

.recipe-modal-body {
    padding: clamp(0.75rem, 2vw, 1.25rem);
}

.recipe-modal-close {
    position: sticky;
    top: 0.75rem;
    left: calc(100% - 3rem);
    z-index: 4;
    display: grid;
    place-items: center;
    width: 2.35rem;
    height: 2.35rem;
    margin: 0.75rem 0.75rem -2.35rem auto;
    border: 0;
    border-radius: 999px;
    background: var(--ink);
    color: var(--white);
    font-weight: 900;
    cursor: pointer;
}

.recipe-modal-loading {
    padding: 3rem 1rem;
    text-align: center;
    font-weight: 900;
}

.recipe-modal-open {
    overflow: hidden;
}

.recipe-card h2 a,
.featured-recipe h2 a {
    color: inherit;
    text-decoration: none;
}

.recipe-card h2,
.featured-recipe h2 {
    cursor: pointer;
}

.recipe-card h2 a:hover,
.featured-recipe h2 a:hover,
.recipe-card h2:hover,
.featured-recipe h2:hover {
    text-decoration: underline;
}

.page-shell.narrow.recipe-print-shell {
    width: min(1280px, calc(100% - 2rem));
}

.recipe-detail-shell {
    padding-top: clamp(1rem, 3vw, 2.4rem);
}

.recipe-detail-heading {
    max-width: 1120px;
    margin: 0 auto clamp(0.75rem, 1.5vw, 1.2rem);
}

.recipe-detail-heading h1 {
    max-width: 940px;
    font-size: clamp(1.45rem, 2.8vw, 2.35rem);
    line-height: 1.06;
}

.recipe-detail-heading.with-action {
    flex-wrap: wrap;
}

.recipe-box-hero {
    display: grid;
    gap: 1rem;
    align-items: end;
    margin-bottom: 1rem;
    padding: clamp(1rem, 4vw, 2rem);
    border: 1px solid var(--line);
    border-radius: 8px;
    background:
        linear-gradient(120deg, rgba(255, 248, 236, 0.94), rgba(229, 247, 245, 0.88)),
        repeating-linear-gradient(90deg, var(--paper) 0 32px, var(--orange-soft) 32px 34px);
    box-shadow: var(--shadow);
}

.recipe-count-card {
    display: grid;
    justify-items: start;
    width: fit-content;
    border-radius: 8px;
    background: var(--ink);
    color: var(--white);
    padding: 1rem;
}

.recipe-count-card strong {
    font-size: 2.5rem;
    line-height: 1;
}

.recipe-count-card span,
.recipe-protein,
.recipe-source {
    color: var(--muted);
    font-weight: 850;
    text-transform: uppercase;
    font-size: 0.78rem;
}

.recipe-filter {
    align-items: stretch;
}

.featured-recipe,
.recipe-page-summary,
.pagination {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.featured-recipe {
    display: grid;
    grid-template-columns: 1fr;
    align-items: center;
    margin-bottom: 1rem;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--white);
    box-shadow: var(--shadow);
    padding: 1rem;
}

.featured-recipe h2 {
    font-size: clamp(1.4rem, 4vw, 2.2rem);
}

.featured-recipe-picture {
    display: block;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--orange-soft);
}

.featured-recipe-picture img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.featured-recipe-body {
    display: grid;
    gap: 0.7rem;
}

.featured-recipe-body > p {
    margin: 0;
}

.featured-recipe > .button {
    justify-self: start;
}

.recipe-page-summary {
    justify-content: space-between;
    margin-bottom: 1rem;
    color: var(--muted);
    font-size: 0.9rem;
    font-weight: 800;
}

.recipe-card-grid {
    display: grid;
    gap: 1rem;
    grid-template-columns: 1fr;
}

.recipe-card,
.recipe-sheet {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--white);
    box-shadow: var(--shadow);
}

.recipe-card {
    display: grid;
    grid-template-rows: auto 1fr;
    overflow: hidden;
    padding: 0;
}

.recipe-card-picture,
.recipe-sheet-picture {
    display: block;
    overflow: hidden;
    margin: 0;
    background: var(--orange-soft);
}

.recipe-card-picture {
    aspect-ratio: 4 / 3;
    border-bottom: 1px solid var(--line);
}

.recipe-card-picture img,
.recipe-sheet-picture img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.recipe-card-body {
    display: grid;
    align-content: start;
    gap: 0.7rem;
    min-height: 100%;
    padding: 1rem;
}

.recipe-protein {
    margin: 0;
    color: var(--primary-dark);
}

.recipe-card h2 {
    margin: 0;
}

.recipe-card-body > p:not(.recipe-protein) {
    margin: 0;
}

.recipe-card-body .ghost-button {
    justify-self: start;
    margin-top: auto;
}

.recipe-sheet {
    display: grid;
    gap: 1.25rem;
    padding: clamp(1rem, 4vw, 2rem);
}

.recipe-index-card {
    position: relative;
    z-index: 0;
    overflow: visible;
    gap: clamp(1.25rem, 2.4vw, 2.2rem);
    border-color: #d3b27a;
    background:
        repeating-linear-gradient(to bottom, rgba(255, 255, 255, 0) 0 2.05rem, rgba(46, 117, 151, 0.16) 2.05rem calc(2.05rem + 1px)),
        linear-gradient(145deg, #fffdf5 0%, #fff3dc 58%, #f9e5c4 100%);
    box-shadow: 0 34px 70px rgba(65, 47, 30, 0.22), 0 10px 22px rgba(40, 50, 60, 0.12);
}

.recipe-index-card::before,
.recipe-index-card::after {
    content: "";
    position: absolute;
    pointer-events: none;
}

.recipe-index-card::before {
    z-index: 1;
    top: 0;
    bottom: 0;
    left: clamp(1.25rem, 2.6vw, 2.2rem);
    width: 2px;
    background: rgba(176, 74, 52, 0.34);
}

.recipe-index-card::after {
    z-index: -1;
    inset: 0.85rem -0.55rem -0.75rem 0.85rem;
    border: 1px solid rgba(163, 117, 62, 0.22);
    border-radius: 8px;
    background: rgba(216, 176, 111, 0.28);
    box-shadow: 0 20px 38px rgba(65, 47, 30, 0.16);
    transform: rotate(-1.1deg);
}

.recipe-index-card > * {
    position: relative;
    z-index: 2;
}

.recipe-sheet-head {
    display: grid;
    gap: 1rem;
    border-bottom: 2px solid var(--line);
    padding-bottom: 1rem;
}

.recipe-index-card .recipe-sheet-head {
    border-bottom-color: rgba(176, 74, 52, 0.26);
    padding-bottom: clamp(1rem, 2.4vw, 1.75rem);
}

.recipe-sheet-title {
    display: grid;
    gap: 0.7rem;
}

.recipe-sheet-title > p {
    margin: 0;
}

.recipe-index-card .recipe-sheet-title {
    align-content: start;
    gap: 0.85rem;
}

.recipe-index-card .recipe-sheet-title > p:not(.eyebrow) {
    max-width: 58rem;
    color: #5e5042;
    font-size: clamp(1rem, 1.7vw, 1.24rem);
}

.recipe-index-card .eyebrow {
    color: #a95532;
}

.recipe-sheet-head h1 {
    font-size: clamp(2rem, 7vw, 4rem);
}

.recipe-index-card .recipe-sheet-head h1 {
    color: #35271d;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(2.35rem, 5.1vw, 4.35rem);
    line-height: 1.02;
}

.recipe-index-card .meta-row {
    gap: 0.55rem;
}

.recipe-index-card .meta-row span {
    border: 1px solid rgba(163, 117, 62, 0.24);
    background: rgba(255, 248, 236, 0.82);
    color: #4f4438;
    box-shadow: inset 0 -1px 0 rgba(163, 117, 62, 0.12);
}

.recipe-sheet-picture {
    aspect-ratio: 16 / 9;
    border: 1px solid var(--line);
    border-radius: 8px;
}

.recipe-index-card .recipe-sheet-picture {
    border-color: #d2b177;
    background: #f0cca0;
    box-shadow: 0 14px 30px rgba(82, 58, 35, 0.22);
    transform: rotate(1deg);
}

.recipe-index-card .recipe-sheet-picture img {
    filter: saturate(1.06) contrast(0.99);
}

.recipe-columns {
    display: grid;
    gap: 1.25rem;
}

.recipe-index-card .recipe-columns {
    gap: clamp(1.15rem, 2.8vw, 2.6rem);
}

.recipe-index-card .recipe-card-section h2,
.recipe-index-card .recipe-note h2 {
    border-bottom: 1px solid rgba(176, 74, 52, 0.22);
    padding-bottom: 0.45rem;
    color: #493421;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(1.2rem, 1.9vw, 1.55rem);
}

.recipe-list {
    margin: 0;
    padding-left: 1.2rem;
}

.recipe-list li {
    margin: 0.45rem 0;
}

.recipe-index-card .recipe-list {
    padding-left: 1.35rem;
    color: #3d352d;
    font-size: clamp(1rem, 1.15vw, 1.08rem);
}

.recipe-index-card .recipe-list li {
    margin: 0.62rem 0;
    padding-left: 0.18rem;
}

.recipe-index-card .recipe-list li::marker {
    color: #b64f32;
    font-weight: 900;
}

.recipe-note {
    border-top: 1px solid var(--line);
    padding-top: 1rem;
}

.recipe-index-card .recipe-note {
    border-top-color: rgba(176, 74, 52, 0.22);
    padding-top: 1.1rem;
}

.recipe-index-card .recipe-note p {
    margin: 0;
    color: #5d5042;
    font-size: clamp(1rem, 1.25vw, 1.12rem);
}

.recipe-source {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    justify-content: space-between;
    border-top: 1px solid var(--line);
    padding-top: 1rem;
}

.recipe-index-card .recipe-source {
    border-top-color: rgba(176, 74, 52, 0.22);
    color: #7a6755;
}

.pagination {
    justify-content: center;
    margin-top: 1.25rem;
}

.pagination span {
    color: var(--muted);
    font-weight: 900;
}

.pagination .active {
    background: var(--ink);
    color: var(--white);
}

.stat-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (min-width: 720px) {
    .hero {
        grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
    }

    .dashboard-hero {
        grid-template-columns: minmax(0, 1fr) 220px;
    }

    .dashboard-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .span-2 {
        grid-column: span 2;
    }

    .week-strip {
        grid-template-columns: repeat(7, minmax(0, 1fr));
    }

    .filter-bar,
    .inline-add {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .two-col {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .three-col {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .four-col {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .spinner-layout {
        grid-template-columns: 360px minmax(0, 1fr);
    }

    .settings-grid,
    .tools-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .reminder-row {
        grid-template-columns: minmax(150px, 1fr) 130px 150px 70px;
    }

    .recipe-box-hero {
        grid-template-columns: minmax(0, 1fr) auto;
    }

    .recipe-filter {
        grid-template-columns: minmax(260px, 1fr) 220px auto auto;
    }

    .recipe-card-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .featured-recipe {
        grid-template-columns: minmax(180px, 0.35fr) minmax(0, 1fr) auto;
    }

    .featured-recipe > .button {
        justify-self: end;
    }

    .recipe-columns {
        grid-template-columns: minmax(220px, 0.82fr) minmax(0, 1.18fr);
    }

    .recipe-index-card .recipe-columns {
        grid-template-columns: minmax(230px, 0.72fr) minmax(0, 1.28fr);
    }
}

@media (min-width: 1000px) {
    .dashboard-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .span-2 {
        grid-column: span 3;
    }

    .stat-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .recipe-card-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .recipe-index-card {
        min-height: calc(100vh - 10rem);
        padding: clamp(2.25rem, 4vw, 4rem);
    }

    .recipe-index-card .recipe-sheet-head {
        grid-template-columns: minmax(0, 1.08fr) minmax(300px, 0.62fr);
        align-items: stretch;
    }

    .recipe-index-card .recipe-sheet-picture {
        aspect-ratio: 4 / 3;
        min-height: 100%;
    }
}

@media (max-width: 920px) {
    .site-header {
        align-items: flex-start;
        flex-direction: column;
    }

    .main-nav {
        width: 100%;
    }

    .header-actions {
        width: 100%;
        justify-content: space-between;
    }

    .public-home .site-header {
        align-items: center;
        flex-direction: row;
    }

    .public-home .public-nav {
        width: auto;
        margin-left: auto;
    }

    .public-home .brand-logo {
        width: 150px;
        max-height: 90px;
    }
}

@media (max-width: 640px) {
    .page-shell.narrow.recipe-print-shell {
        width: min(680px, calc(100% - 0.75rem));
        padding-top: 0.75rem;
        padding-bottom: 2.5rem;
    }

    .recipe-detail-heading {
        margin-bottom: 0.75rem;
    }

    .recipe-detail-heading h1 {
        font-size: clamp(1.45rem, 9vw, 2.4rem);
    }

    .recipe-index-card {
        padding: 1rem 0.95rem 1.2rem 1.15rem;
    }

    .recipe-index-card::before {
        left: 0.72rem;
        width: 1px;
        opacity: 0.5;
    }

    .recipe-index-card::after {
        inset: 0.45rem -0.25rem -0.45rem 0.45rem;
        transform: rotate(-0.5deg);
    }

    .recipe-index-card .recipe-sheet-head {
        gap: 0.85rem;
    }

    .recipe-index-card .recipe-sheet-head h1 {
        font-size: clamp(2.05rem, 12vw, 3.15rem);
    }

    .recipe-index-card .recipe-sheet-picture {
        aspect-ratio: 4 / 3;
        transform: none;
    }
}

@media print {
    .site-header,
    .section-heading,
    .print-hide,
    .inline-add,
    .ghost-button,
    .button,
    .link-button {
        display: none !important;
    }

    body {
        background: #fff;
    }

    .panel,
    .table-card,
    .recipe-sheet {
        box-shadow: none;
    }

    .recipe-print-shell {
        width: 100%;
        padding: 0;
    }

    .recipe-sheet {
        border: 0;
        padding: 0;
    }

    .recipe-index-card {
        min-height: 0;
        background: #fff;
    }

    .recipe-index-card::before,
    .recipe-index-card::after {
        display: none;
    }
}
