/* Publisher-platform demo. Brand colours arrive as CSS variables from base.html. */
body { font-family: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif; color: #1f2933; background: #fff; }
h1, h2, h3, .display-font { font-family: "Fraunces", Georgia, serif; letter-spacing: -0.01em; }
a { color: var(--brand); }
a:hover { color: var(--brand-dark); }

/* Demo bar */
.demo-bar { background: #14161a; color: #cfd4da; font-size: 0.82rem; position: sticky; top: 0; z-index: 1030; }
.demo-pill { background: #ffcc33; color: #14161a; font-weight: 700; border-radius: 4px; padding: 1px 7px; font-size: 0.72rem; letter-spacing: .06em; }
.demo-views { display: flex; flex-wrap: wrap; gap: 2px; }
.demo-views a { color: #cfd4da; text-decoration: none; padding: 5px 10px; border-radius: 6px; white-space: nowrap; }
.demo-views a:hover { background: #262a31; color: #fff; }
.demo-views a.active { background: #2d333c; color: #fff; }
.demo-views a.demo-cta { background: #ffcc33; color: #14161a; font-weight: 600; }
.demo-views a.demo-cta-soft { color: #ffdd77; }

/* Brand buttons */
.btn-brand { background: var(--brand); color: var(--on-brand); border: 0; }
.btn-brand:hover, .btn-brand:focus { background: var(--brand-dark); color: #fff; }
.btn-accent { background: var(--accent); color: var(--on-accent); border: 0; }
.btn-accent:hover { filter: brightness(0.92); color: var(--on-accent); }
.btn-outline-brand { border: 1px solid var(--brand); color: var(--brand); }
.btn-outline-brand:hover { background: var(--brand); color: var(--on-brand); }
.text-brand { color: var(--brand) !important; }
.text-accent { color: var(--accent) !important; }
.bg-brand-light { background: var(--brand-light); }
.bg-accent-light { background: var(--accent-light); }

/* Logo mark */
.logo-mark { flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center; width: 38px; height: 38px; border-radius: 9px;
  background: var(--brand); color: var(--on-brand); font-family: "Fraunces", Georgia, serif; font-weight: 700; font-size: 1.05rem; }
.logo-mark.sm { width: 30px; height: 30px; font-size: .85rem; border-radius: 7px; }
.logo-name { font-family: "Fraunces", Georgia, serif; font-weight: 700; font-size: 1.2rem; color: #111; }

/* Press site */
.press-nav { border-bottom: 1px solid #eceff2; }
.press-nav .nav-link { color: #333; font-weight: 500; }
.press-nav .nav-link:hover, .press-nav .nav-link.active { color: var(--brand); }
.hero { background: linear-gradient(160deg, var(--brand-light) 0%, #fff 70%); padding: 72px 0 56px; }
.hero h1 { font-size: clamp(2.1rem, 4.6vw, 3.4rem); font-weight: 700; color: #111; }
.hero .lead { color: #4a5563; }
.hero-covers { position: relative; height: 340px; }
.hero-covers img { position: absolute; width: 170px; border-radius: 4px; box-shadow: 0 18px 40px rgba(0,0,0,.18); }
.hero-covers img:nth-child(1) { left: 6%; top: 40px; transform: rotate(-6deg); }
.hero-covers img:nth-child(2) { left: 32%; top: 0; z-index: 2; }
.hero-covers img:nth-child(3) { left: 58%; top: 50px; transform: rotate(5deg); }
.section { padding: 64px 0; }
.eyebrow { text-transform: uppercase; letter-spacing: .12em; font-size: .75rem; font-weight: 700; color: var(--accent); }
.step-num { width: 34px; height: 34px; border-radius: 50%; background: var(--accent); color: var(--on-accent);
  display: inline-flex; align-items: center; justify-content: center; font-weight: 700; }
.pkg-card { border: 1px solid #e6e9ed; border-radius: 14px; padding: 26px; height: 100%; background: #fff; transition: box-shadow .15s; }
.pkg-card:hover { box-shadow: 0 10px 30px rgba(15, 30, 50, .08); }
.pkg-card .price { font-family: "Fraunces", Georgia, serif; font-size: 2rem; font-weight: 700; color: var(--brand); }
.book-cover { width: 100%; border-radius: 4px; box-shadow: 0 8px 22px rgba(0,0,0,.15); aspect-ratio: 2/3; object-fit: cover; }
.book-card { text-decoration: none; color: inherit; display: block; }
.book-card:hover .book-cover { transform: translateY(-3px); transition: transform .15s; }
.press-footer { background: #111418; color: #aeb6bf; padding: 40px 0; font-size: .9rem; }
.press-footer a { color: #d7dce1; }
.cta-band { background: var(--brand); color: var(--on-brand); border-radius: 18px; padding: 44px; }

/* App shell (portal + admin) */
.app-shell { display: flex; min-height: calc(100vh - 38px); background: #f5f6f8; }
.app-side { width: 236px; flex-shrink: 0; background: #fff; border-right: 1px solid #e6e9ed; padding: 18px 12px; }
.app-side .side-brand { display: flex; align-items: center; gap: 10px; padding: 4px 8px 18px; }
.app-side .side-brand span { font-family: "Fraunces", Georgia, serif; font-weight: 700; line-height: 1.1; }
.app-side .side-label { font-size: .7rem; text-transform: uppercase; letter-spacing: .1em; color: #8a94a0; padding: 14px 10px 6px; }
.app-side a.side-link { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 8px; color: #3b4450; text-decoration: none; font-size: .92rem; }
.app-side a.side-link:hover { background: #f1f3f5; }
.app-side a.side-link.active { background: var(--brand-light); color: var(--brand); font-weight: 600; }
.app-main { flex: 1; min-width: 0; padding: 28px 32px 60px; }
.app-main h1 { font-size: 1.7rem; font-weight: 700; margin-bottom: .2rem; }
.page-sub { color: #6b7684; margin-bottom: 1.5rem; }
.card-soft { background: #fff; border: 1px solid #e6e9ed; border-radius: 12px; }
.card-soft .card-head { padding: 14px 18px; border-bottom: 1px solid #eef0f2; font-weight: 600; display: flex; align-items: center; justify-content: space-between; }
.card-soft .card-body-p { padding: 16px 18px; }
.kpi { background: #fff; border: 1px solid #e6e9ed; border-radius: 12px; padding: 16px 18px; height: 100%; }
.kpi .kpi-label { font-size: .78rem; color: #6b7684; text-transform: uppercase; letter-spacing: .06em; }
.kpi .kpi-value { font-size: 1.65rem; font-weight: 700; font-family: "Fraunces", Georgia, serif; }
.kpi .kpi-note { font-size: .8rem; color: #6b7684; }
.table-app { font-size: .9rem; margin: 0; }
.table-app th { font-size: .74rem; text-transform: uppercase; letter-spacing: .05em; color: #6b7684; font-weight: 600; background: #fafbfc; }
.table-app td, .table-app th { padding: .6rem .9rem; vertical-align: middle; }
.chip { display: inline-block; font-size: .74rem; font-weight: 600; border-radius: 999px; padding: 2px 9px; background: #eef0f3; color: #3b4450; white-space: nowrap; }
.chip-green { background: #e3f4e8; color: #1c6b35; }
.chip-amber { background: #fff2d6; color: #8a5a00; }
.chip-red { background: #fde4e1; color: #a2281a; }
.chip-blue { background: #e3edfb; color: #1c4f96; }
.chip-brand { background: var(--brand-light); color: var(--brand); }
.owner { font-size: .75rem; color: #6b7684; }
.bar-row { display: flex; align-items: flex-end; gap: 14px; height: 180px; padding-top: 10px; }
.bar-col { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; }
.bar-stack { width: 100%; max-width: 46px; display: flex; flex-direction: column-reverse; border-radius: 6px 6px 0 0; overflow: hidden; }
.bar-cost { background: #d7dde4; }
.bar-margin { background: var(--brand); }
.bar-royal { background: var(--accent); }
.bar-label { font-size: .75rem; color: #6b7684; margin-top: 6px; }
.legend-dot { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }
.board { display: grid; grid-template-columns: repeat(6, minmax(190px, 1fr)); gap: 12px; overflow-x: auto; padding-bottom: 8px; }
.board-col { background: #eceff3; border-radius: 12px; padding: 10px; min-height: 300px; }
.board-col h6 { font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; color: #56606c; margin: 4px 4px 10px; display: flex; justify-content: space-between; }
.board-card { background: #fff; border-radius: 10px; padding: 10px; margin-bottom: 10px; display: flex; gap: 10px; text-decoration: none; color: inherit; border: 1px solid #e3e6ea; }
.board-card:hover { border-color: var(--brand); }
.board-card img { width: 42px; height: 63px; border-radius: 3px; object-fit: cover; }
.progress-stages { display: flex; gap: 4px; }
.progress-stages .ps { flex: 1; text-align: center; font-size: .72rem; color: #8a94a0; }
.progress-stages .ps .dot { height: 6px; border-radius: 3px; background: #e2e6ea; margin-bottom: 6px; }
.progress-stages .ps.done .dot { background: var(--brand); }
.progress-stages .ps.now .dot { background: var(--accent); }
.progress-stages .ps.now { color: #222; font-weight: 600; }
.task { display: flex; gap: 10px; padding: 10px 0; border-bottom: 1px solid #f0f2f4; }
.task:last-child { border-bottom: 0; }
.task i { font-size: 1.1rem; }
.msg { padding: 10px 12px; border-radius: 10px; margin-bottom: 10px; font-size: .92rem; }
.msg.them { background: var(--brand-light); }
.msg.me { background: #f1f3f5; }
.studio-out { background: #fafbfc; border: 1px dashed #d5dbe1; border-radius: 10px; padding: 14px 16px; }
.sample-tag { font-size: .7rem; background: #fff6d6; color: #7a5a00; border-radius: 4px; padding: 1px 6px; font-weight: 600; letter-spacing: .03em; }
.swatch { width: 44px; height: 44px; border-radius: 10px; border: 1px solid #dfe3e8; padding: 0; cursor: pointer; }
.brand-preview { border: 1px solid #e6e9ed; border-radius: 14px; overflow: hidden; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .85rem; }
.help-callout { background: #fffbea; border: 1px solid #f3e3a2; border-radius: 10px; padding: 12px 14px; font-size: .88rem; color: #5b4a10; }

@media (max-width: 991px) {
  .app-shell { flex-direction: column; }
  .app-side { width: 100%; border-right: 0; border-bottom: 1px solid #e6e9ed; display: flex; flex-wrap: wrap; gap: 4px; padding: 10px; }
  .app-side .side-brand, .app-side .side-label { display: none; }
  .app-side a.side-link { padding: 6px 10px; font-size: .85rem; }
  .app-main { padding: 20px 16px 48px; }
  .hero-covers { height: 260px; }
  .hero-covers img { width: 130px; }
  .board { grid-template-columns: repeat(6, 220px); }
}

/* Platform marketing page (fixed palette, independent of the demo brand) */
body.platform { --brand: #16213a; --brand-dark: #0d1526; --brand-light: #eef1f7; --on-brand: #fff;
  --accent: #f0b429; --accent-light: #fff4d6; --on-accent: #1b1500; }
.plat-nav { background: #0f1729; position: sticky; top: 0; z-index: 1030; }
.plat-nav a { color: #d6dcea; text-decoration: none; }
.plat-nav a:hover { color: #fff; }
.plat-nav .logo-mark { background: var(--accent); color: #1b1500; }
.plat-name { color: #fff; font-family: "Fraunces", Georgia, serif; font-weight: 700; font-size: 1.1rem; }
.plat-hero { background: radial-gradient(1200px 500px at 80% 0%, #24365e 0%, #0f1729 60%); color: #fff; padding: 80px 0 90px; }
.plat-hero h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); font-weight: 700; line-height: 1.08; }
.plat-hero .lead { color: #c9d2e4; }
.plat-eyebrow { color: var(--accent); text-transform: uppercase; letter-spacing: .12em; font-size: .78rem; font-weight: 700; }
.plat-report { background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.14); border-radius: 18px; padding: 24px; box-shadow: 0 30px 60px rgba(0,0,0,.35); }
.plat-approve { display: flex; justify-content: space-between; align-items: center; gap: 12px; background: rgba(255,255,255,.06); border-radius: 12px; padding: 12px 14px; margin-top: 10px; }
.plat-card { background: #fff; border: 1px solid #e6e9ed; border-radius: 16px; padding: 28px; }
.plat-list { list-style: none; padding: 0; margin: 0 0 1rem; }
.plat-list li { padding: 6px 0 6px 28px; position: relative; }
.plat-list li::before { content: "\F26E"; font-family: "bootstrap-icons"; position: absolute; left: 0; top: 5px; color: #c98a06; font-size: 1.1rem; }
.bg-soft { background: #f5f6f9; }
.plat-price { font-family: "Fraunces", Georgia, serif; font-size: 3rem; font-weight: 700; line-height: 1; }
.plat-founding { background: #16213a; color: #fff; border-color: #16213a; }
.plat-founding .plat-price { color: var(--accent); }
.plat-dark { background: #0f1729; color: #fff; }
.text-accent-dark { color: #b07800 !important; }
body.platform .eyebrow { color: #b07800; }
body.platform .btn-accent { color: #1b1500; }
