* { box-sizing: border-box; }
body { margin: 0; background: #fbfaf7; color: #222222; }
.main-content { flex: 1; min-width: 0; padding: 2.25rem clamp(1.25rem, 4vw, 4.5rem); }
.page { display: flex; max-width: 1040px; min-height: calc(100vh - 4.5rem); flex-direction: column; margin: 0 auto; }
.page-header { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 1.5rem; }
.page-header h1 { margin: 0; color: #000; font-size: clamp(1.8rem, 3vw, 2.4rem); letter-spacing: -.04em; }
.eyebrow, .meal-type { margin: 0 0 .4rem; color: #000; font-size: .72rem; font-weight: 700; letter-spacing: .12em; }
.week-open { display: inline-flex; align-items: center; gap: .6rem; margin: 0; padding: .65rem 1rem; border: 1px solid #d8cebf; border-radius: 999px; background: #fff; color: #000; font: inherit; font-weight: 600; cursor: pointer; }
.week-open span { display: grid; place-items: center; min-width: 1.45rem; height: 1.45rem; padding: 0 .3rem; border-radius: 50%; background: #eee7dc; font-size: .8rem; }
.week-context { margin-bottom: 1.3rem; padding: 1rem 1.1rem .9rem; border: 1px solid #ece5d9; border-radius: 16px; background: #fff; }
.week-context-heading { display: flex; justify-content: space-between; gap: .8rem; margin-bottom: .75rem; color: #666666; font-size: .82rem; }
.week-context-heading strong { color: #000; }
.week-strip { display: grid; grid-template-columns: repeat(7, 1fr); gap: .5rem; }
.week-day { position: relative; display: grid; justify-items: center; gap: .15rem; min-height: 66px; padding: .45rem .15rem .25rem; border-radius: 12px; background: #f7f5f0; color: #666666; }
.week-day span { font-size: .7rem; }
.week-day strong { color: #000; font-size: .92rem; }
.week-day i { font-size: .7rem; font-style: normal; color: #b7ad9c; line-height: 1; }
.week-day.is-planned { background: #e9efe4; }
.week-day.is-planned i { color: #55704d; font-weight: 700; }
.week-message { padding: .8rem 1rem; border-radius: 12px; background: #edf2e9; color: #496143; }
.added-toast { margin: 0 0 1rem; padding: .75rem 1rem; border: 1px solid #dce6d5; border-radius: 12px; background: #f2f6ed; color: #496143; }
.browse-progress { display: flex; align-items: center; gap: .85rem; margin: 1.2rem 0 .75rem; color: #666666; font-size: .82rem; }
.progress-track { flex: 1; height: 5px; overflow: hidden; border-radius: 99px; background: #ebe5da; }
.progress-track i { display: block; height: 100%; border-radius: inherit; background: #9b7951; }
.suggestion-stage { display: flex; flex: 1; flex-direction: column; justify-content: center; padding-bottom: 1rem; }
.recipe-card { display: grid; grid-template-columns: 56% 44%; width: 100%; max-width: 960px; height: 390px; margin: 0 auto; overflow: hidden; border: 1px solid #eee8df; border-radius: 22px; background: #fff; box-shadow: 0 12px 32px #53442b12; touch-action: pan-y; transition: transform 180ms ease, box-shadow 180ms ease; }
.recipe-card.is-dragging { transition: none; box-shadow: 0 20px 42px #53442b24; }
.hero-image { display: block; width: 100%; height: 100%; min-height: 0; object-fit: cover; background: #eee8de; }
.placeholder { display: grid; place-items: center; color: #222; font-size: 1.1rem; }
.recipe-body { display: flex; min-height: 0; flex-direction: column; justify-content: center; overflow: hidden; padding: clamp(1.4rem, 3vw, 2rem); }
.recipe-body h2 { display: -webkit-box; margin: 0; overflow: hidden; color: #000; font-size: clamp(1.5rem, 3vw, 2rem); letter-spacing: -.035em; line-height: 1.15; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.recipe-meta { margin: .65rem 0 0; color: #666; font-size: .9rem; }
.actions { display: grid; gap: .75rem; margin-top: 1.5rem; }
.actions > * { flex: 1; }
.actions form { margin: 0; }
.actions button { width: 100%; min-height: 48px; margin: 0; padding: .75rem 1rem; border-radius: 999px; font: inherit; font-weight: 650; cursor: pointer; transition: background .15s ease, transform .15s ease; }
.action-arrow { margin-right: .35rem; font-size: 1.05rem; }
.action-primary { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: .75rem 1.25rem; border: 1px solid #705332; border-radius: 999px; background: #705332; color: white; font: inherit; font-weight: 650; text-decoration: none; cursor: pointer; }
.action-primary:hover { background: #5b4228; }
.action-secondary { border: 1px solid #d8cebf; background: #fff; color: #000; }
.action-secondary:hover { background: #f6f2ea; }
.back-button { display: block; width: max-content; margin: .65rem auto 0; padding: .3rem .5rem; border: 0; background: transparent; color: #000; font: inherit; font-size: .82rem; text-align: center; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.empty { display: flex; flex-direction: column; align-items: center; gap: .65rem; padding: 3rem 1.5rem; border: 1px solid #ece5d9; border-radius: 20px; background: #fff; text-align: center; }
.empty h2 { margin: 0; color: #000; }
.empty p { max-width: 34rem; color: #666666; line-height: 1.55; }
.empty-spark { color: #000; font-size: 2rem; }
.slot-dialog, .week-drawer { color: #222222; border: 1px solid #e7dfd2; background: #fffdf9; box-shadow: 0 20px 65px #24190f33; }
.slot-dialog { width: min(440px, calc(100vw - 2rem)); padding: 1.4rem; border-radius: 20px; }
.slot-dialog::backdrop, .week-drawer::backdrop { background: #22222266; backdrop-filter: blur(2px); }
.dialog-top, .drawer-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; }
.dialog-top h2, .drawer-heading h2 { margin: 0; color: #000; font-size: 1.35rem; }
.dialog-close { display: grid; place-items: center; flex: 0 0 36px; width: 36px; height: 36px; margin: 0; padding: 0; border: 1px solid #e5ddd0; border-radius: 50%; background: #fff; color: #000000; font-size: 1.5rem; line-height: 1; cursor: pointer; }
.slot-dialog label { display: block; margin: 1.4rem 0 .45rem; color: #333; font-size: .88rem; font-weight: 600; }
.slot-dialog select { width: 100%; min-height: 48px; margin: 0; padding: .7rem .8rem; border: 1px solid #d8cebf; border-radius: 10px; background: white; color: #222; font: inherit; }
.dialog-submit { width: 100%; margin-top: 1rem; }
.week-drawer { position: fixed; inset: 0 0 0 auto; width: min(440px, 100vw); max-width: none; height: 100dvh; max-height: none; margin: 0 0 0 auto; padding: 1.5rem; border-width: 0 0 0 1px; border-radius: 20px 0 0 20px; }
.week-drawer[open] { animation: drawer-in 180ms ease-out; }
.drawer-count { margin: .5rem 0 1rem; color: #666666; }
.drawer-days { display: grid; gap: .55rem; }
.drawer-day { padding: .75rem .85rem; border: 1px solid #ede7dd; border-radius: 12px; background: #fff; }
.drawer-day > div { display: flex; justify-content: space-between; gap: .75rem; color: #666666; font-size: .75rem; }
.drawer-day strong { color: #000; font-size: .86rem; }
.drawer-day p { margin: .35rem 0 0; color: #777777; font-size: .85rem; }
.drawer-day.is-planned { border-color: #dce6d5; background: #f4f7f1; }
.drawer-day.is-planned p { color: #496143; font-weight: 600; }
.drawer-plan-link { display: inline-block; margin-top: 1.1rem; color: #000; font-weight: 650; text-decoration: none; }
.drawer-plan-link:hover { text-decoration: underline; }
@keyframes drawer-in { from { transform: translateX(24px); opacity: .7; } to { transform: translateX(0); opacity: 1; } }
@media (max-width: 760px) { .page { min-height: calc(100vh - 3.25rem); } .recipe-card { display: block; height: 500px; max-width: 680px; margin: 0 auto; } .hero-image { height: 260px; min-height: 0; } .recipe-body { height: 240px; padding: 1.25rem; } .actions { display: flex; margin-top: 1rem; } }
@media (max-width: 700px) { .main-content { padding: 1.25rem 1rem 2rem; } .page-header { align-items: flex-start; } .eyebrow { max-width: 15rem; } .week-open { padding: .55rem .75rem; font-size: .86rem; } .week-drawer { border-radius: 18px 0 0 18px; } }
@media (max-width: 420px) { .page-header { flex-direction: column; } .week-strip { gap: .25rem; } .week-day { min-height: 60px; } .recipe-card { height: 560px; } .hero-image { height: 250px; } .recipe-body { height: 310px; } .actions { flex-direction: column; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; } }
