:root {
  --canvas: #f6f1ec;
  --paper: #fffdfb;
  --ink: #242426;
  --muted: #827d79;
  --line: #e8e0da;
  --line-strong: #d9cec7;
  --coral: #c85f50;
  --coral-dark: #a6483c;
  --coral-soft: #f3dfda;
  --sage: #b7c6b8;
  --sage-deep: #476153;
  --butter: #ece0ad;
  --shadow: 0 14px 34px rgba(67, 48, 40, 0.055), 0 2px 8px rgba(67, 48, 40, 0.03);
  --radius: 10px;
}

* { box-sizing: border-box; }
html { background: var(--canvas); }
body { margin: 0; color: var(--ink); background: var(--canvas); font-family: "DM Sans", "Noto Sans SC", "PingFang SC", sans-serif; -webkit-font-smoothing: antialiased; }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible { outline: 2px solid var(--coral); outline-offset: 2px; }
.app-shell { min-height: 100vh; display: flex; }

.sidebar { width: 252px; flex: 0 0 252px; padding: 26px 16px 18px; background: #f0ebe6; border-right: 1px solid var(--line); display: flex; flex-direction: column; }
.brand-lockup { display: flex; align-items: center; gap: 11px; padding: 0 10px 26px; }
.brand-mark { width: 36px; height: 36px; border-radius: 12px 12px 12px 4px; background: var(--coral); color: #fff9f5; display: grid; place-items: center; font-family: Georgia, serif; font-size: 18px; box-shadow: 0 5px 10px rgba(200,95,80,.18); }
.brand-name { font-weight: 800; letter-spacing: .02em; font-size: 16px; line-height: 1.15; }
.brand-sub { margin-top: 3px; color: #9a8f88; font-family: "DM Mono", monospace; font-size: 9px; letter-spacing: .15em; }
.workspace-select { margin: 0 4px 28px; padding: 10px; border: 1px solid #dfd4cd; background: rgba(255,253,251,.66); border-radius: 9px; display: flex; align-items: center; gap: 9px; transition: border-color .2s, background .2s; }
.workspace-select:hover { border-color: #cdbdb4; background: var(--paper); }
.workspace-avatar { width: 28px; height: 28px; border-radius: 8px; background: #313334; color: #fff; display: grid; place-items: center; font-size: 12px; font-weight: 700; }
.workspace-copy { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.workspace-copy strong { font-size: 12px; font-weight: 700; white-space: nowrap; }
.workspace-copy span { color: #988e87; font-size: 10px; margin-top: 2px; }
.workspace-select svg { width: 15px; height: 15px; color: #9b918b; }
.nav-caption { padding: 0 12px 9px; color: #9b918b; font-size: 10px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.nav-caption-spaced { margin-top: 28px; }
.nav-list { flex: 1; }
.nav-item { width: 100%; height: 42px; padding: 0 12px; border: 0; border-radius: 7px; background: transparent; color: #746d67; display: flex; align-items: center; gap: 11px; text-align: left; font-size: 13px; transition: background .2s, color .2s; }
.nav-item svg { width: 17px; height: 17px; stroke-width: 1.8; }
.nav-item:hover { color: var(--ink); background: rgba(255,253,251,.55); }
.nav-item.active { color: var(--ink); background: var(--paper); box-shadow: 0 3px 12px rgba(68,48,42,.04); font-weight: 700; }
.nav-item.active svg { color: var(--coral); }
.nav-badge { margin-left: auto; padding: 3px 7px; border-radius: 4px; background: var(--coral-soft); color: var(--coral-dark); font-size: 10px; font-weight: 700; }
.nav-count { margin-left: auto; color: #9f9690; font-family: "DM Mono", monospace; font-size: 10px; }
.nav-count.coral { color: var(--coral); font-weight: 700; }
.sidebar-bottom { margin-top: 24px; }
.support-note { position: relative; display: flex; align-items: flex-start; gap: 9px; padding: 12px 10px; margin: 0 2px 14px; border-radius: 8px; background: #e4ebdf; color: #3d5142; }
.support-icon { width: 25px; height: 25px; flex: 0 0 25px; display: grid; place-items: center; border-radius: 7px; background: #f6f7f1; }
.support-icon svg { width: 14px; height: 14px; }
.support-note strong, .support-note span { display: block; }
.support-note strong { font-size: 11px; font-weight: 700; }
.support-note span { margin-top: 3px; font-size: 10px; color: #718171; }
.support-note .tiny { margin-left: auto; color: #607461; }
.profile-row { display: flex; align-items: center; gap: 9px; padding: 9px 8px 0; border-top: 1px solid #dfd5ce; }
.profile-avatar { width: 30px; height: 30px; border-radius: 50%; background: #d5b4a9; color: #67443c; display: grid; place-items: center; font-size: 12px; font-weight: 700; }
.profile-copy { flex: 1; display: flex; flex-direction: column; }
.profile-copy strong { font-size: 12px; }
.profile-copy span { color: #988e88; font-size: 10px; margin-top: 2px; }

.main-content { min-width: 0; flex: 1; }
.topbar { height: 72px; padding: 0 38px; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; }
.topbar-context { display: flex; align-items: center; gap: 9px; font-size: 12px; color: #57514e; }
.context-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--coral); box-shadow: 0 0 0 4px var(--coral-soft); }
.slash { color: #c8bdb7; }
.muted { color: var(--muted); }
.topbar-actions { display: flex; align-items: center; gap: 8px; }
.icon-button { width: 32px; height: 32px; padding: 0; border: 0; background: transparent; color: #77706b; border-radius: 7px; display: grid; place-items: center; transition: background .2s, color .2s; }
.icon-button:hover { color: var(--ink); background: rgba(255,253,251,.85); }
.icon-button svg { width: 16px; height: 16px; stroke-width: 1.8; }
.icon-button.tiny { width: 26px; height: 26px; }
.icon-button.tiny svg { width: 14px; height: 14px; }
.icon-button.light { color: #fff; background: rgba(20,18,18,.28); backdrop-filter: blur(4px); }
.notification { position: relative; }
.notification > span { position: absolute; top: 6px; right: 6px; width: 5px; height: 5px; border-radius: 50%; background: var(--coral); border: 1px solid var(--canvas); }
.top-divider { width: 1px; height: 24px; background: var(--line); margin: 0 8px; }
.button { min-height: 34px; border: 1px solid transparent; border-radius: 6px; padding: 0 13px; display: inline-flex; align-items: center; justify-content: center; gap: 7px; font-size: 12px; font-weight: 700; transition: transform .2s, background .2s, border-color .2s; }
.button:hover { transform: translateY(-1px); }
.button svg { width: 15px; height: 15px; stroke-width: 2; }
.primary-button { background: var(--coral); color: #fff; box-shadow: 0 5px 12px rgba(200,95,80,.16); }
.primary-button:hover { background: var(--coral-dark); }
.secondary-button { border-color: var(--line-strong); background: var(--paper); color: #5d5651; }
.secondary-button:hover { border-color: #bbaaa0; }
.mobile-brand { display: none; align-items: center; gap: 8px; font-weight: 800; }

.page-wrap { max-width: 1500px; padding: 35px 38px 60px; margin: 0 auto; }
.page-intro { display: flex; justify-content: space-between; align-items: flex-end; gap: 32px; margin-bottom: 28px; }
.eyebrow { display: flex; align-items: center; gap: 9px; color: var(--coral); font-size: 10px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.eyebrow-line { width: 26px; height: 1px; background: #d6a89e; }
.eyebrow .mono { color: #a79a92; font-family: "DM Mono", monospace; font-size: 10px; letter-spacing: .04em; }
h1, h2, h3, p { margin: 0; }
h1 { max-width: 700px; margin-top: 11px; font-size: clamp(28px, 3vw, 42px); line-height: 1.12; letter-spacing: -.03em; font-weight: 800; }
.page-subtitle { max-width: 630px; margin-top: 12px; color: #766f69; font-size: 13px; line-height: 1.7; }
.intro-meta { width: 235px; flex: 0 0 235px; padding-bottom: 4px; }
.week-progress { padding: 10px 0 12px; border-bottom: 1px solid var(--line); }
.progress-head { display: flex; align-items: center; justify-content: space-between; color: #817870; font-size: 10px; }
.progress-head strong { color: var(--ink); font-size: 13px; }
.progress-head em { color: #a49a94; font-style: normal; font-size: 10px; font-weight: 500; }
.progress-track { height: 4px; margin-top: 9px; overflow: hidden; background: #e7dfd8; border-radius: 4px; }
.progress-track span { display: block; height: 100%; border-radius: inherit; background: var(--coral); }
.text-button { padding: 0; border: 0; background: transparent; color: var(--coral-dark); font-size: 11px; font-weight: 700; display: inline-flex; align-items: center; gap: 6px; }
.text-button:hover { color: var(--coral); }
.text-button svg { width: 13px; height: 13px; }
.intro-meta > .text-button { margin-top: 13px; }

.metric-strip { min-height: 78px; margin-bottom: 22px; padding: 0 20px; border: 1px solid var(--line); background: rgba(255,253,251,.64); border-radius: var(--radius); display: grid; grid-template-columns: 1fr 1fr 1fr 2.2fr; align-items: center; box-shadow: 0 5px 16px rgba(70,54,46,.025); }
.metric { min-height: 42px; padding: 0 18px; border-right: 1px solid var(--line); display: grid; grid-template-columns: auto 1fr; column-gap: 11px; align-items: center; }
.metric:first-child { padding-left: 4px; }
.metric:last-child { border-right: 0; }
.metric-label { grid-column: 1 / -1; color: #978e88; font-size: 10px; }
.metric strong { font-family: "DM Mono", monospace; font-size: 18px; letter-spacing: -.04em; }
.metric-change { display: inline-flex; align-items: center; gap: 3px; font-size: 10px; white-space: nowrap; }
.metric-change svg { width: 12px; height: 12px; }
.metric-change.up { color: var(--sage-deep); }
.metric-change.neutral { color: #a49b95; }
.metric-note { display: flex; gap: 9px; color: #786e67; font-size: 11px; line-height: 1.5; }
.metric-note > svg { flex: 0 0 auto; width: 16px; height: 16px; color: #c49b39; }
.metric-note strong { font-family: inherit; color: var(--coral-dark); font-size: 11px; }

.workspace-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(330px, .72fr); gap: 22px; align-items: start; }
.panel-surface { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.composer-panel { padding: 26px 28px 22px; }
.panel-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
.panel-header.small { align-items: center; }
.panel-kicker { color: #a39a94; font-family: "DM Mono", monospace; font-size: 9px; letter-spacing: .14em; line-height: 1; }
h2 { margin-top: 7px; font-size: 18px; letter-spacing: -.02em; line-height: 1.2; }
.header-actions { display: flex; align-items: center; gap: 9px; }
.status-pill { height: 25px; padding: 0 9px; border-radius: 4px; display: inline-flex; align-items: center; gap: 6px; font-size: 10px; font-weight: 700; }
.status-pill.pending { color: #966b2c; background: #f5ead0; }
.status-pill span { width: 6px; height: 6px; border-radius: 50%; background: #d49b35; }
.channel-tabs { display: flex; gap: 5px; margin: 22px 0 19px; padding: 3px; width: fit-content; background: #f3efeb; border-radius: 6px; }
.channel-tab { min-width: 66px; height: 28px; padding: 0 11px; border: 0; border-radius: 4px; color: #918780; background: transparent; font-size: 11px; }
.channel-tab.active { color: var(--ink); background: #fff; box-shadow: 0 2px 6px rgba(54,42,36,.06); font-weight: 700; }
.cover-editor { display: grid; grid-template-columns: minmax(0, 1fr) 82px; gap: 9px; height: 294px; margin-bottom: 24px; }
.cover-main { position: relative; min-width: 0; overflow: hidden; border-radius: 8px; background: #e7dfd9; }
.cover-main img { width: 100%; height: 100%; display: block; object-fit: cover; object-position: center 22%; filter: saturate(.87) contrast(.98); transition: opacity .28s; }
.cover-gradient { position: absolute; inset: auto 0 0; height: 80px; background: linear-gradient(transparent, rgba(24,18,16,.43)); pointer-events: none; }
.cover-overlay { position: absolute; inset: 12px 12px auto; display: flex; align-items: center; justify-content: space-between; }
.cover-label { padding: 5px 8px; display: inline-flex; align-items: center; gap: 5px; border-radius: 4px; background: rgba(35,26,23,.4); color: #fff; backdrop-filter: blur(4px); font-size: 10px; }
.cover-label svg { width: 13px; height: 13px; }
.cover-side { min-width: 0; display: flex; flex-direction: column; gap: 7px; }
.cover-thumb { min-width: 0; height: 57px; position: relative; overflow: hidden; padding: 0; border: 2px solid transparent; border-radius: 6px; background: #eee6e1; }
.cover-thumb.active { border-color: var(--coral); }
.cover-thumb img { width: 100%; height: 100%; display: block; object-fit: cover; filter: saturate(.82); }
.cover-thumb span { position: absolute; bottom: 4px; left: 5px; padding: 2px 4px; color: white; background: rgba(30,22,20,.55); border-radius: 2px; font-size: 8px; }
.replace-cover { min-height: 32px; margin-top: auto; padding: 0; border: 1px dashed #cfbeb4; border-radius: 5px; color: #927e74; background: transparent; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; font-size: 9px; }
.replace-cover:hover { border-color: var(--coral); color: var(--coral); }
.replace-cover svg { width: 14px; height: 14px; }
.asset-toolbar { min-height: 40px; padding: 11px 0 10px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.asset-summary { display: flex; align-items: center; gap: 7px; color: #938981; font-size: 10px; }
.asset-summary strong { color: var(--ink); font-size: 11px; }
.asset-summary-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--sage-deep); box-shadow: 0 0 0 4px #eaf0e9; }
.asset-actions { display: flex; align-items: center; gap: 14px; }
.asset-actions .text-button { gap: 5px; font-size: 10px; }
.asset-actions .text-button svg { width: 13px; height: 13px; }
.asset-disclaimer { margin: 12px 0 22px; padding: 10px 11px; border-radius: 5px; color: #887a68; background: #fbf6e9; display: flex; align-items: flex-start; gap: 8px; font-size: 10px; line-height: 1.55; }
.asset-disclaimer svg { flex: 0 0 auto; width: 14px; height: 14px; margin-top: 1px; color: #b68e3f; }
.field-group { margin-bottom: 20px; }
.field-label { margin-bottom: 8px; display: flex; align-items: center; justify-content: space-between; color: #7d746e; font-size: 11px; }
.field-label label { color: #4e4743; font-weight: 700; }
.field-label > span { color: #aaa19b; font-family: "DM Mono", monospace; font-size: 9px; }
.title-input, .body-field textarea { width: 100%; border: 1px solid var(--line); border-radius: 6px; outline: 0; color: var(--ink); background: #fdfbf9; transition: border .2s, box-shadow .2s; }
.title-input:focus, .body-field textarea:focus { border-color: #cb8f84; box-shadow: 0 0 0 3px var(--coral-soft); }
.title-input { height: 42px; padding: 0 13px; font-size: 14px; font-weight: 600; }
.body-field textarea { min-height: 177px; padding: 13px; resize: vertical; line-height: 1.75; font-size: 12px; }
.inline-action { border: 0; padding: 0; color: var(--coral-dark); background: transparent; display: inline-flex; align-items: center; gap: 5px; font-size: 10px; font-weight: 700; }
.inline-action:hover { color: var(--coral); }
.inline-action svg { width: 13px; height: 13px; }
.tags-field { margin-bottom: 22px; }
.tag-editor { display: flex; flex-wrap: wrap; gap: 6px; }
.tag-chip, .tag-add { min-height: 27px; padding: 0 9px; border: 1px solid var(--line); border-radius: 4px; background: #fdfbf9; color: #837972; font-size: 10px; }
.tag-chip:hover { border-color: #cdb4aa; }
.tag-chip.selected { color: var(--coral-dark); border-color: #e5c4bd; background: #fcf0ed; }
.tag-add { width: 28px; padding: 0; display: grid; place-items: center; color: var(--coral); border-style: dashed; }
.tag-add svg { width: 13px; height: 13px; }
.composer-footer { min-height: 45px; padding-top: 18px; border-top: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.footer-tools, .footer-actions { display: flex; align-items: center; gap: 7px; }
.tool-button { width: 27px; height: 27px; padding: 0; border: 0; border-radius: 4px; color: #8c837d; background: transparent; display: grid; place-items: center; }
.tool-button:hover { background: #f3efeb; color: var(--ink); }
.tool-button svg { width: 15px; height: 15px; }
.footer-divider { height: 18px; width: 1px; margin: 0 4px; background: var(--line); }
.save-state { display: inline-flex; align-items: center; gap: 5px; color: #aaa099; font-size: 10px; }
.save-state svg { width: 13px; height: 13px; }

.preview-column { display: flex; flex-direction: column; gap: 18px; }
.preview-panel { padding: 26px 23px 17px; }
.preview-header { align-items: flex-start; }
.preview-tabs { min-height: 34px; margin: 20px 0 15px; display: flex; align-items: center; gap: 15px; border-bottom: 1px solid var(--line); }
.preview-tab { height: 34px; padding: 0 0 9px; border: 0; border-bottom: 2px solid transparent; background: transparent; color: #9a9089; font-size: 11px; }
.preview-tab.active { border-color: var(--coral); color: var(--ink); font-weight: 700; }
.preview-platform { margin-left: auto; padding-bottom: 9px; display: inline-flex; align-items: center; gap: 5px; color: #a39a94; font-size: 10px; }
.platform-dot { width: 5px; height: 5px; border-radius: 50%; background: #c15345; }
.phone-frame { width: min(100%, 285px); margin: 0 auto; padding: 8px; border: 1px solid #d2c7c0; border-radius: 25px; background: #252526; box-shadow: 0 18px 25px rgba(44,33,29,.12); }
.phone-speaker { width: 60px; height: 5px; margin: 0 auto 7px; border-radius: 3px; background: #111; }
.phone-screen { overflow: hidden; border-radius: 18px; background: #fff; }
.phone-top { height: 34px; padding: 0 11px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid #f0eeec; color: #554d49; font-size: 9px; font-weight: 700; }
.phone-top svg { width: 14px; height: 14px; }
.phone-image-wrap { position: relative; aspect-ratio: 1 / 1.08; overflow: hidden; background: #eee8e4; }
.phone-image-wrap img { width: 100%; height: 100%; display: block; object-fit: cover; object-position: center 22%; }
.page-count { position: absolute; right: 8px; bottom: 8px; padding: 3px 5px; border-radius: 3px; background: rgba(22,18,16,.58); color: white; font-size: 8px; }
.phone-copy { padding: 12px 12px 8px; }
.phone-copy h3 { font-size: 12px; line-height: 1.45; font-weight: 800; }
.phone-copy p { max-height: 74px; margin-top: 7px; overflow: hidden; color: #6f6863; font-size: 9px; line-height: 1.65; white-space: pre-line; }
.preview-tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 8px; color: #4d7aa3; font-size: 8px; }
.preview-author { display: flex; align-items: center; gap: 5px; margin-top: 12px; color: #5d5550; font-size: 8px; }
.mini-avatar { width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; background: #e7c9bf; color: #7a4e44; font-size: 8px; font-weight: 700; }
.follow-btn { margin-left: auto; border: 0; padding: 0; color: #c45c4e; background: transparent; font-size: 8px; font-weight: 700; }
.phone-actions { min-height: 34px; padding: 0 12px; border-top: 1px solid #f3efed; display: flex; align-items: center; gap: 12px; color: #8a827c; font-size: 8px; }
.phone-actions span { display: inline-flex; align-items: center; gap: 3px; }
.phone-actions svg { width: 13px; height: 13px; }
.phone-actions > svg:last-child { margin-left: auto; }
.preview-footer { min-height: 31px; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; color: #9b918b; font-size: 9px; }
.preview-footer > span { display: inline-flex; align-items: center; gap: 5px; }
.preview-footer svg { width: 13px; height: 13px; color: var(--sage-deep); }
.preview-footer .text-button svg { color: currentColor; }
.inspiration-panel { padding: 20px 21px 10px; }
.keyword-list { margin-top: 14px; }
.keyword-row { width: 100%; min-height: 46px; padding: 0; border: 0; border-bottom: 1px solid var(--line); background: transparent; display: flex; align-items: center; gap: 10px; text-align: left; }
.keyword-row:last-child { border-bottom: 0; }
.keyword-row:hover .keyword-name { color: var(--coral-dark); }
.rank { width: 17px; color: #b0a59e; font-family: "DM Mono", monospace; font-size: 9px; }
.keyword-name { flex: 1; font-size: 11px; font-weight: 700; }
.keyword-score { color: #9d938d; font-family: "DM Mono", monospace; font-size: 9px; }
.keyword-row svg { width: 13px; height: 13px; color: #b4a9a2; }

.bottom-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(330px, .72fr); gap: 22px; margin-top: 22px; }
.calendar-panel, .task-panel { padding: 21px 23px 18px; }
.week-row { display: grid; grid-template-columns: repeat(7, 1fr); gap: 7px; margin-top: 20px; }
.day { position: relative; min-width: 0; height: 80px; padding: 10px 4px 7px; border: 1px solid transparent; border-radius: 7px; color: #8d847e; background: #f7f3f0; display: flex; flex-direction: column; align-items: center; gap: 3px; }
.day:hover { border-color: #d7c5bc; }
.day span { font-size: 9px; }
.day strong { color: #3e3936; font-family: "DM Mono", monospace; font-size: 17px; }
.day svg { width: 13px; height: 13px; color: #bcb2ab; margin-top: auto; }
.day.done { color: var(--sage-deep); background: #edf2ec; }
.day.done strong { color: var(--sage-deep); }
.day.done svg { color: var(--sage-deep); }
.day.active { border-color: var(--coral); background: #fff7f4; box-shadow: 0 4px 9px rgba(200,95,80,.08); }
.day.active strong { color: var(--coral-dark); }
.day em { margin-top: auto; color: var(--coral); font-size: 8px; font-style: normal; font-weight: 700; }
.queue-note { min-height: 36px; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); display: flex; align-items: center; gap: 7px; color: #665e58; font-size: 10px; }
.queue-marker { width: 7px; height: 7px; border-radius: 50%; background: var(--coral); box-shadow: 0 0 0 4px var(--coral-soft); }
.queue-note strong { color: var(--coral-dark); }
.queue-separator { height: 13px; width: 1px; margin-left: 5px; background: var(--line-strong); }
.queue-note .icon-button { margin-left: auto; }
.check-progress { color: var(--coral); font-family: "DM Mono", monospace; font-size: 10px; }
.task-list { margin-top: 16px; }
.task-item { min-height: 39px; display: flex; align-items: center; gap: 9px; color: #5c5550; font-size: 11px; border-bottom: 1px solid var(--line); }
.task-item:last-child { border-bottom: 0; }
.task-item input { position: absolute; opacity: 0; pointer-events: none; }
.custom-checkbox { width: 16px; height: 16px; border: 1px solid #d0c4bd; border-radius: 4px; display: grid; place-items: center; color: white; background: white; }
.custom-checkbox svg { width: 11px; height: 11px; display: none; }
.task-item.checked { color: #9b918b; text-decoration: line-through; }
.task-item.checked .custom-checkbox { border-color: var(--sage-deep); background: var(--sage-deep); }
.task-item.checked .custom-checkbox svg { display: block; }

.modal-backdrop { position: fixed; inset: 0; z-index: 20; padding: 22px; background: rgba(34,29,27,.4); display: none; align-items: center; justify-content: center; }
.modal-backdrop.open { display: flex; }
.modal { width: min(100%, 430px); padding: 25px; border: 1px solid var(--line-strong); border-radius: 11px; background: var(--paper); box-shadow: 0 22px 55px rgba(34,26,21,.18); }
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; }
.modal-copy { margin-top: 14px; color: #7d746e; font-size: 12px; line-height: 1.65; }
.schedule-fields { display: grid; grid-template-columns: 1.4fr .8fr; gap: 10px; margin-top: 20px; }
.schedule-fields label { display: flex; flex-direction: column; gap: 7px; color: #7c736d; font-size: 10px; }
.schedule-fields select { height: 38px; padding: 0 9px; border: 1px solid var(--line); border-radius: 5px; color: #49423d; background: #fdfbf9; font-size: 11px; }
.modal-note { margin-top: 16px; padding: 10px; border-radius: 6px; color: #776a50; background: #faf4dc; display: flex; align-items: center; gap: 7px; font-size: 10px; }
.modal-note svg { width: 14px; height: 14px; color: #b58c2e; }
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 25px; }
.toast { position: fixed; z-index: 30; left: 50%; bottom: 25px; transform: translate(-50%, 20px); min-height: 38px; padding: 0 14px; border: 1px solid #d8cec8; border-radius: 6px; background: #292827; color: #fff; display: flex; align-items: center; gap: 8px; opacity: 0; pointer-events: none; box-shadow: 0 10px 22px rgba(35,28,24,.16); transition: opacity .25s, transform .25s; font-size: 11px; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast svg { width: 15px; height: 15px; color: #b7d1ba; }

@media (max-width: 1120px) {
  .sidebar { width: 220px; flex-basis: 220px; }
  .topbar, .page-wrap { padding-left: 26px; padding-right: 26px; }
  .workspace-grid, .bottom-grid { grid-template-columns: minmax(0, 1.35fr) minmax(300px, .8fr); gap: 16px; }
  .composer-panel { padding-left: 22px; padding-right: 22px; }
  .cover-editor { height: 270px; }
  .metric-strip { padding: 0 10px; }
  .metric { padding: 0 12px; }
}

@media (max-width: 880px) {
  .sidebar { display: none; }
  .mobile-brand { display: inline-flex; }
  .topbar { padding: 0 20px; }
  .topbar-context { display: none; }
  .page-wrap { padding: 28px 20px 48px; }
  .page-intro { align-items: flex-start; flex-direction: column; gap: 21px; }
  .intro-meta { width: 100%; flex: 0 0 auto; }
  .week-progress { max-width: 360px; }
  .intro-meta > .text-button { margin-top: 10px; }
  .metric-strip { grid-template-columns: repeat(3, 1fr); gap: 0; }
  .metric-note { grid-column: 1 / -1; min-height: 48px; padding: 12px 4px 0; border-top: 1px solid var(--line); border-right: 0; }
  .workspace-grid, .bottom-grid { grid-template-columns: 1fr; }
  .preview-column { display: grid; grid-template-columns: minmax(0, 1fr) minmax(235px, .8fr); gap: 16px; align-items: start; }
  .preview-panel { grid-row: span 2; }
  .cover-editor { height: 300px; }
}

@media (max-width: 620px) {
  .topbar { height: 64px; padding: 0 15px; }
  .topbar-actions { gap: 2px; }
  .top-divider { display: none; }
  .top-icon { display: none; }
  .primary-button { min-height: 32px; padding: 0 10px; }
  .primary-button span { display: none; }
  .primary-button svg { width: 17px; height: 17px; }
  .page-wrap { padding: 25px 14px 38px; }
  h1 { font-size: 29px; }
  .page-subtitle { font-size: 12px; }
  .metric-strip { padding: 6px 0; grid-template-columns: repeat(3, 1fr); }
  .metric { min-height: 54px; padding: 0 7px; display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: 3px; }
  .metric:first-child { padding-left: 9px; }
  .metric strong { font-size: 16px; }
  .metric-change { font-size: 9px; }
  .metric-note { min-height: 52px; padding: 10px 9px 4px; font-size: 10px; }
  .composer-panel { padding: 21px 15px 17px; }
  h2 { font-size: 17px; }
  .cover-editor { grid-template-columns: minmax(0, 1fr) 66px; height: 244px; gap: 6px; }
  .cover-thumb { height: 49px; }
  .cover-label { font-size: 9px; }
  .replace-cover { font-size: 8px; }
  .asset-toolbar { align-items: flex-start; flex-direction: column; gap: 9px; }
  .asset-actions { width: 100%; justify-content: flex-end; }
  .asset-disclaimer { margin-bottom: 20px; }
  .title-input { font-size: 13px; }
  .body-field textarea { min-height: 205px; font-size: 11px; }
  .composer-footer { align-items: flex-start; flex-direction: column; }
  .footer-actions { width: 100%; }
  .footer-actions .button { flex: 1; }
  .preview-column { display: flex; }
  .preview-panel { padding-left: 15px; padding-right: 15px; }
  .phone-frame { width: min(100%, 300px); }
  .inspiration-panel { padding-left: 15px; padding-right: 15px; }
  .calendar-panel, .task-panel { padding-left: 15px; padding-right: 15px; }
  .week-row { gap: 3px; }
  .day { height: 73px; }
  .day span { font-size: 8px; }
  .day strong { font-size: 14px; }
  .queue-note { flex-wrap: wrap; }
  .queue-separator { display: none; }
  .queue-note .muted { width: 100%; padding-left: 14px; }
  .modal { padding: 20px; }
  .schedule-fields { grid-template-columns: 1fr; }
}
