:root {
  --ivory: #F7F3EA;
  --paper: #FFFDF8;
  --sand: #EEE7D8;
  --ink: #14201B;
  --ink-2: #4A564F;
  --ink-3: #7A847E;
  --emerald: #0E4A3A;
  --emerald-2: #13634D;
  --emerald-deep: #0A3329;
  --gold: #C9A13B;
  --gold-soft: #F3E3B5;
  --danger: #A63D2F;
  --radius: 16px;
  --shadow: 0 1px 2px rgba(20, 32, 27, .06), 0 12px 32px -12px rgba(20, 32, 27, .18);
  --serif: 'Fraunces', Georgia, 'Times New Roman', serif;
  --sans: 'Manrope', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--ivory); color: var(--ink); font: 16px/1.6 var(--sans); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--emerald-2); text-underline-offset: 3px; }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 600; line-height: 1.15; letter-spacing: -.01em; margin: 0 0 .5em; }
h1 { font-size: clamp(2rem, 4.4vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.3rem); }
h3, .h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }
code { background: var(--sand); padding: .1em .4em; border-radius: 6px; font-size: .9em; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; border-radius: 6px; }

.wrap { width: 100%; max-width: 1160px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 720px) { .wrap { padding: 0 28px; } }
.narrow { max-width: 820px; }
.center { text-align: center; }
.muted { color: var(--ink-2); }
.small { font-size: .875rem; }
.gold { color: var(--gold); font-style: italic; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 8px 14px; border-radius: 8px; z-index: 10; }
.skip:focus { left: 8px; }

.eyebrow { display: inline-block; font: 700 .75rem/1 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--emerald-2); margin-bottom: 14px; }
.lead { font-size: 1.15rem; color: var(--ink-2); max-width: 36em; }

/* Header */
.site-header { background: var(--ivory); border-bottom: 1px solid var(--sand); position: sticky; top: 0; z-index: 5; backdrop-filter: saturate(1.2) blur(6px); background: rgba(247, 243, 234, .92); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--emerald); text-decoration: none; font: 600 1.05rem/1.1 var(--serif); }
.brand em { font-style: normal; color: var(--ink-2); font-weight: 400; }
.logo-mark { width: 36px; height: 36px; flex: none; color: var(--gold); background: var(--emerald); border-radius: 50%; }
.nav { display: flex; gap: 4px; }
.nav a { color: var(--ink); text-decoration: none; font-weight: 600; font-size: .92rem; padding: 8px 12px; border-radius: 999px; }
.nav a:hover { background: var(--sand); }
@media (max-width: 640px) {
  .brand span { font-size: .95rem; }
  .brand em { display: block; font-size: .8rem; }
  .nav a { padding: 6px 8px; font-size: .82rem; }
  .nav a:first-child { display: none; }
}
.demo-bar { background: var(--gold-soft); color: var(--ink); text-align: center; font-size: .85rem; padding: 8px 16px; border-bottom: 1px solid #E5CF8F; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; background: var(--emerald); color: #fff; border: 0; border-radius: 999px; padding: 12px 22px; font: 700 .95rem/1.2 var(--sans); text-decoration: none; cursor: pointer; transition: background .15s, transform .15s, box-shadow .15s; box-shadow: 0 6px 16px -8px rgba(14, 74, 58, .7); }
.btn:hover { background: var(--emerald-2); transform: translateY(-1px); }
.btn:active { transform: none; }
.btn-lg { padding: 16px 28px; font-size: 1rem; }
.btn-sm { padding: 8px 16px; font-size: .85rem; }
.btn-block { width: 100%; }
.btn-ghost { background: transparent; color: var(--emerald); box-shadow: inset 0 0 0 1.5px var(--emerald); }
.btn-ghost:hover { background: var(--emerald); color: #fff; }
.btn-demo { background: var(--ink); }
.link-btn { background: none; border: 0; padding: 0; color: var(--emerald-2); font: 600 .82rem var(--sans); cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }

/* Hero */
.hero { padding: 56px 0 72px; overflow: hidden; background:
  radial-gradient(900px 400px at 85% 20%, rgba(201, 161, 59, .16), transparent 60%),
  radial-gradient(700px 500px at 10% 100%, rgba(14, 74, 58, .08), transparent 60%); }
.hero-grid { display: grid; gap: 48px; align-items: center; }
@media (min-width: 900px) { .hero-grid { grid-template-columns: 1.1fr .9fr; } .hero { padding: 88px 0 104px; } }
.hero h1 { max-width: 13em; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin: 28px 0 24px; }
.hero-points { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px 22px; color: var(--ink-2); font-weight: 600; font-size: .92rem; }
.hero-points li { display: flex; align-items: center; gap: 6px; }
.ico { width: 18px; height: 18px; color: var(--emerald-2); flex: none; }
.hero-art { position: relative; justify-self: center; width: min(420px, 86vw); }
.book-stack { position: relative; aspect-ratio: 826 / 1169; }
.book { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border-radius: 6px; box-shadow: 0 30px 60px -24px rgba(10, 51, 41, .55), 0 2px 6px rgba(0, 0, 0, .12); }
.book-back { transform: rotate(7deg) translate(14%, 2%) scale(.92); opacity: .95; }
.book-front { transform: rotate(-3deg); }
.hero-badge { position: absolute; left: -6%; bottom: 8%; background: var(--emerald); color: #fff; border-radius: 14px; padding: 14px 18px; display: flex; align-items: center; gap: 10px; box-shadow: var(--shadow); }
.hero-badge strong { font: 700 1.9rem/1 var(--serif); color: var(--gold-soft); }
.hero-badge span { font-size: .8rem; line-height: 1.25; opacity: .9; }

/* Sections */
.section { padding: 64px 0; }
.section-tint { background: var(--paper); border-block: 1px solid var(--sand); }
.section-dark { background: var(--emerald-deep); color: #E8EFEA; }
.section-dark h2, .section-dark h3 { color: #fff; }
.section-head { margin-bottom: 32px; }
.section-head p { margin: 0; }

.grid { display: grid; gap: 24px; }
.products-grid { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.card { background: var(--paper); border: 1px solid var(--sand); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.product-card { display: grid; grid-template-columns: 132px 1fr; transition: transform .2s; }
.product-card:hover { transform: translateY(-3px); }
.card-cover { background: var(--sand); padding: 18px 0 18px 18px; }
.card-cover img { border-radius: 4px; box-shadow: 0 8px 18px -8px rgba(0, 0, 0, .4); }
.card-body { padding: 20px; display: flex; flex-direction: column; }
.card-body .eyebrow { margin-bottom: 8px; }
.card-body h3 { font-size: 1.15rem; margin-bottom: 6px; }
.card-body h3 a { color: var(--ink); text-decoration: none; }
.card-body p { font-size: .9rem; }
.card-foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.price { font: 700 1.35rem/1 var(--serif); color: var(--emerald); }
.price-lg { font-size: 2.2rem; }

.steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }
.steps li { border: 1px solid rgba(243, 227, 181, .2); border-radius: var(--radius); padding: 26px; background: rgba(255, 255, 255, .03); }
.steps p { margin: 0; opacity: .85; }
.step-n { display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; background: var(--gold); color: var(--emerald-deep); font: 700 1.05rem var(--serif); margin-bottom: 14px; }

.faq details { border-bottom: 1px solid var(--sand); padding: 4px 0; }
.faq summary { cursor: pointer; list-style: none; font-weight: 700; padding: 16px 32px 16px 0; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; position: absolute; right: 4px; top: 12px; font: 400 1.5rem/1 var(--serif); color: var(--emerald-2); transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { color: var(--ink-2); margin: 0 0 16px; }

/* Product */
.product { padding-top: 40px; }
.product-grid { display: grid; gap: 40px; align-items: start; }
@media (min-width: 900px) { .product-grid { grid-template-columns: .95fr 1.05fr; gap: 64px; } .gallery { position: sticky; top: 92px; } }
.gallery-main { background: var(--sand); border-radius: var(--radius); padding: clamp(18px, 5vw, 44px); }
.gallery-main img { margin: 0 auto; max-height: 620px; width: auto; border-radius: 4px; box-shadow: 0 24px 48px -20px rgba(10, 51, 41, .5); }
.gallery-thumbs { display: flex; gap: 10px; margin: 14px 0 8px; justify-content: center; }
.thumb { width: 64px; padding: 4px; border: 2px solid transparent; border-radius: 10px; background: var(--paper); cursor: pointer; }
.thumb.is-active { border-color: var(--emerald); }
.thumb img { border-radius: 4px; }
.buy h1 { font-size: clamp(1.9rem, 3.6vw, 2.8rem); }
.editions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 24px 0; }
.edition { display: grid; gap: 2px; padding: 14px 16px; border-radius: 12px; border: 1.5px solid var(--sand); background: var(--paper); text-decoration: none; color: var(--ink); transition: border-color .15s; }
.edition:hover { border-color: var(--emerald-2); }
.edition.is-active { border-color: var(--emerald); box-shadow: inset 0 0 0 1px var(--emerald); background: #F1F6F2; }
.edition-name { font-weight: 700; font-size: .92rem; }
.edition-price { font: 700 1.2rem var(--serif); color: var(--emerald); }
.edition-note { font-size: .8rem; color: var(--ink-3); }
.checklist, .xlist { list-style: none; padding: 0; margin: 0 0 24px; display: grid; gap: 10px; }
.checklist li { display: flex; gap: 10px; align-items: flex-start; }
.checklist .ico { margin-top: 3px; background: #E1EEE6; border-radius: 50%; padding: 2px; width: 20px; height: 20px; }
.xlist li { padding-left: 30px; position: relative; color: var(--ink-2); }
.xlist li::before { content: '×'; position: absolute; left: 6px; top: -2px; color: var(--danger); font: 700 1.2rem var(--sans); }
.buy-box { background: var(--paper); border: 1px solid var(--sand); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); display: grid; gap: 14px; scroll-margin-top: 90px; }
.buy-price { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.or { display: flex; align-items: center; gap: 12px; color: var(--ink-3); font-size: .8rem; text-transform: uppercase; letter-spacing: .1em; }
.or::before, .or::after { content: ''; height: 1px; background: var(--sand); flex: 1; }
#paypal-buttons { min-height: 52px; }
#paypal-buttons.is-busy { opacity: .5; pointer-events: none; }
.demo-form { display: grid; gap: 8px; padding-top: 6px; }
.pay-badges { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
.pay-badges span { font-size: .72rem; font-weight: 700; color: var(--ink-2); border: 1px solid var(--sand); border-radius: 6px; padding: 3px 8px; background: #fff; }
label { font-weight: 600; font-size: .9rem; }
input[type=email], input[type=text], input[name=q] { width: 100%; font: 1rem var(--sans); padding: 13px 14px; border-radius: 10px; border: 1.5px solid #D9CFBB; background: #fff; color: var(--ink); }
input:focus { outline: none; border-color: var(--emerald); box-shadow: 0 0 0 3px rgba(19, 99, 77, .15); }
.notice { background: var(--gold-soft); border-radius: 10px; padding: 12px 14px; margin: 0; font-size: .92rem; }
.notice-error { background: #F7E1DC; color: #6E2117; }

.contents { list-style: none; padding: 0; margin: 0 0 20px; display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.contents li { background: var(--ivory); border: 1px solid var(--sand); border-radius: 12px; padding: 14px 16px; font-weight: 600; display: flex; gap: 12px; align-items: center; }
.contents-n { font: 700 .85rem var(--serif); color: var(--gold); }
.license-grid { display: grid; gap: 24px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); margin: 24px 0 8px; }

/* Order */
.order-card { background: var(--paper); border: 1px solid var(--sand); border-radius: 20px; padding: clamp(24px, 5vw, 44px); box-shadow: var(--shadow); }
.order-head h1 { font-size: clamp(1.7rem, 3.4vw, 2.4rem); }
.order-ok { width: 56px; height: 56px; border-radius: 50%; background: var(--emerald); display: grid; place-items: center; margin-bottom: 16px; }
.order-ok .ico { color: #fff; width: 30px; height: 30px; }
.downloads { display: grid; gap: 12px; margin: 24px 0 12px; }
.download { display: flex; align-items: center; gap: 16px; padding: 18px 20px; border-radius: 14px; background: var(--emerald); color: #fff; text-decoration: none; transition: background .15s, transform .15s; }
.download:hover { background: var(--emerald-2); transform: translateY(-1px); }
.download small { display: block; opacity: .75; font-size: .82rem; }
.download-ico { width: 44px; height: 44px; border-radius: 50%; background: rgba(255, 255, 255, .14); display: grid; place-items: center; flex: none; }
.download-ico svg { width: 22px; height: 22px; }
.receipt { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px; margin: 24px 0 16px; padding: 18px 0 0; border-top: 1px solid var(--sand); }
.receipt dt { font-size: .75rem; text-transform: uppercase; letter-spacing: .1em; color: var(--ink-3); }
.receipt dd { margin: 2px 0 0; font-weight: 700; word-break: break-word; }
.stack { display: grid; gap: 10px; margin-top: 20px; }
.spinner { width: 44px; height: 44px; border-radius: 50%; border: 4px solid var(--sand); border-top-color: var(--emerald); margin: 0 auto 20px; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Legal */
.prose h2 { font-size: 1.35rem; margin-top: 1.8em; }
.prose p, .prose li { color: var(--ink-2); }
.prose ul { padding-left: 20px; }

/* Admin */
.admin-head, .admin-orders-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap; }
.admin-orders-head { margin-top: 36px; }
.search { display: flex; gap: 8px; }
.search input { padding: 8px 12px; min-width: 220px; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 14px; margin: 20px 0 32px; }
.stat { background: var(--paper); border: 1px solid var(--sand); border-radius: 14px; padding: 18px; }
.stat span { display: block; font-size: .8rem; color: var(--ink-3); text-transform: uppercase; letter-spacing: .08em; }
.stat strong { font: 700 1.8rem/1.3 var(--serif); color: var(--emerald); }
.table-scroll { overflow-x: auto; border: 1px solid var(--sand); border-radius: 14px; background: var(--paper); }
.table { width: 100%; border-collapse: collapse; font-size: .86rem; background: var(--paper); }
.table th, .table td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--sand); vertical-align: top; white-space: nowrap; }
.table th { font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-3); }
.actions { display: flex; gap: 10px; }
.pill { display: inline-block; font-size: .72rem; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: var(--sand); color: var(--ink-2); }
.pill-ok { background: #DDEFE4; color: #165A3F; }
.pill-bad { background: #F7E1DC; color: #8A2B1E; }

/* Footer */
.site-footer { background: var(--emerald-deep); color: #C9D6CF; padding: 56px 0 28px; margin-top: 40px; }
.page-home .site-footer { margin-top: 0; }
.footer-grid { display: grid; gap: 32px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.site-footer h4 { font: 700 .75rem var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--gold-soft); }
.site-footer a { display: block; color: #E8EFEA; text-decoration: none; margin-bottom: 8px; font-size: .92rem; }
.site-footer a:hover { text-decoration: underline; }
.site-footer .muted { color: #9FB2A8; margin-top: 12px; }
.brand-light, .brand-light em { color: #fff !important; }
.footer-fine { border-top: 1px solid rgba(255, 255, 255, .1); margin-top: 36px; padding-top: 20px; font-size: .8rem; color: #8FA399; }
.footer-fine p { margin: 0 0 6px; }
.site-footer a.brand { display: inline-flex; margin-bottom: 0; }
.products-grid { grid-template-columns: repeat(auto-fill, minmax(300px, 420px)); }

/* ---------- Blog ---------- */
.blog-hero { padding: 56px 0 8px; background: radial-gradient(800px 320px at 90% 0%, rgba(201, 161, 59, .14), transparent 60%); }
.blog-hero h1 { max-width: 14em; }
.blog-list { padding-top: 32px; }
.posts-grid { grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); }
.post-card { background: var(--paper); border: 1px solid var(--sand); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); display: flex; flex-direction: column; transition: transform .2s; }
.post-card:hover { transform: translateY(-3px); }
.post-card-img { display: block; aspect-ratio: 1200 / 630; background: var(--emerald); overflow: hidden; }
.post-card-img img { width: 100%; height: 100%; object-fit: cover; }
.post-card-ph { display: grid; place-items: center; height: 100%; font: 700 2.4rem var(--serif); color: var(--gold); }
.post-card-body { padding: 20px 22px 24px; display: flex; flex-direction: column; flex: 1; }
.post-card-body h2, .post-card-body h3 { margin-bottom: 8px; }
.post-card-body h3 { font-size: 1.2rem; }
.post-card-body h2 a, .post-card-body h3 a { color: var(--ink); text-decoration: none; }
.post-card-body h2 a:hover, .post-card-body h3 a:hover { color: var(--emerald-2); }
.post-card-body p.muted { font-size: .93rem; }
.post-meta { font-size: .8rem; font-weight: 600; letter-spacing: .04em; color: var(--ink-3); margin-bottom: 8px; }
.read-more { margin-top: auto; font-weight: 700; font-size: .9rem; text-decoration: none; }
.post-card-big { margin-bottom: 24px; }
@media (min-width: 860px) {
  .post-card-big { flex-direction: row; }
  .post-card-big { align-items: stretch; }
  .post-card-big .post-card-img { flex: 1.25; aspect-ratio: 1200 / 630; align-self: center; }
  .post-card-big .post-card-body { flex: 1; padding: 36px; justify-content: center; }
  .post-card-big h2 { font-size: 2rem; }
}
.pager { display: flex; justify-content: space-between; align-items: center; margin-top: 36px; }
.section-head-row { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }

.post { padding: 40px 0 24px; }
.post-head, .post-body, .post-foot { max-width: 760px; }
.back-link { display: inline-block; font-weight: 700; font-size: .9rem; text-decoration: none; margin-bottom: 20px; }
.post-head h1 { font-size: clamp(2rem, 4.2vw, 3rem); }
.post-cover { max-width: 1000px; margin: 28px auto 8px; }
.post-cover img { width: 100%; border-radius: var(--radius); box-shadow: var(--shadow); }
.post-body { font-size: 1.08rem; line-height: 1.75; padding-top: 24px; padding-bottom: 8px; }
.prose h2 { font-size: 1.6rem; margin: 1.8em 0 .5em; }
.prose h3 { font-size: 1.25rem; margin: 1.5em 0 .4em; }
.prose h4 { font-size: 1.05rem; margin: 1.4em 0 .4em; }
.prose p, .prose li { color: var(--ink); }
.post-body.prose p, .post-body.prose li { color: #26332D; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1.2em; }
.prose li { margin-bottom: .4em; }
.prose blockquote { margin: 1.4em 0; padding: 16px 20px; background: var(--paper); border-left: 4px solid var(--gold); border-radius: 0 12px 12px 0; }
.prose blockquote p { margin: 0 0 .6em; font-size: .98rem; color: var(--ink-2); }
.prose blockquote p:last-child { margin: 0; }
.prose figure { margin: 1.6em 0; }
.prose figure img, .prose p img { border-radius: 12px; }
.prose figcaption { font-size: .85rem; color: var(--ink-3); text-align: center; margin-top: 8px; }
.prose pre { background: var(--ink); color: #EDEFEA; padding: 16px; border-radius: 12px; overflow-x: auto; font-size: .88rem; }
.prose pre code { background: none; padding: 0; }
.prose hr { border: 0; border-top: 1px solid var(--sand); margin: 2em 0; }
.prose .btn { text-decoration: none; color: #fff; }
.post-cta { display: flex; gap: 22px; align-items: center; background: var(--emerald-deep); color: #E8EFEA; border-radius: 20px; padding: 26px; margin: 40px 0 16px; }
.post-cta img { width: 110px; border-radius: 4px; flex: none; box-shadow: 0 10px 24px -10px rgba(0, 0, 0, .6); }
.post-cta h3 { color: #fff; }
.post-cta .muted { color: #B9CBC1; font-size: .93rem; }
.post-cta .btn { background: var(--gold); color: var(--emerald-deep); }
.post-cta .btn:hover { background: #E0BC57; }
@media (max-width: 560px) { .post-cta { flex-direction: column; align-items: flex-start; } .post-cta img { width: 90px; } }
.preview-bar { background: var(--ink); color: #fff; text-align: center; padding: 10px 16px; font-size: .9rem; }
.preview-bar a { color: var(--gold-soft); }

/* ---------- Admin ---------- */
.admin-nav { display: flex; gap: 6px; margin-bottom: 24px; border-bottom: 1px solid var(--sand); padding-bottom: 12px; flex-wrap: wrap; }
.admin-nav a { text-decoration: none; color: var(--ink-2); font-weight: 700; font-size: .92rem; padding: 8px 14px; border-radius: 999px; }
.admin-nav a.is-active { background: var(--emerald); color: #fff; }
.admin-nav a:last-child { margin-left: auto; }
.admin-title { font-size: clamp(1.8rem, 3vw, 2.4rem); }
.head-links { display: flex; gap: 14px; align-items: center; }
.wrap-cell { white-space: normal !important; min-width: 260px; }
.link-danger { color: var(--danger); }
.pill-gold { background: var(--gold-soft); color: #6B5210; }
.editor { display: grid; gap: 24px; align-items: start; }
@media (min-width: 980px) { .editor { grid-template-columns: 1fr 320px; } .editor-side { position: sticky; top: 90px; } }
.editor-main, .side-card { display: grid; gap: 8px; }
.side-card { background: var(--paper); border: 1px solid var(--sand); border-radius: 14px; padding: 18px; margin-bottom: 16px; }
.side-card label:not(:first-child) { margin-top: 8px; }
.input-title { font: 600 1.4rem var(--serif) !important; }
.editor textarea, .editor select, .editor input[type=date] { width: 100%; font: .98rem/1.6 var(--sans); padding: 12px 14px; border-radius: 10px; border: 1.5px solid #D9CFBB; background: #fff; color: var(--ink); }
.editor textarea:focus, .editor select:focus, .editor input:focus { outline: none; border-color: var(--emerald); box-shadow: 0 0 0 3px rgba(19, 99, 77, .15); }
#f-body { font: .98rem/1.7 ui-monospace, 'SF Mono', Menlo, Consolas, monospace; min-height: 460px; resize: vertical; }
.tabs { display: flex; gap: 4px; margin-top: 10px; }
.tab { background: none; border: 0; padding: 8px 14px; border-radius: 8px 8px 0 0; font: 700 .88rem var(--sans); color: var(--ink-3); cursor: pointer; }
.tab.is-active { background: var(--paper); color: var(--emerald); box-shadow: inset 0 -2px 0 var(--emerald); }
.toolbar { display: flex; flex-wrap: wrap; gap: 4px; padding: 6px; background: var(--paper); border: 1px solid var(--sand); border-radius: 10px; }
.toolbar button, .toolbar-upload { background: #fff; border: 1px solid var(--sand); border-radius: 7px; padding: 6px 10px; font: 600 .82rem var(--sans); color: var(--ink); cursor: pointer; }
.toolbar button:hover, .toolbar-upload:hover { border-color: var(--emerald-2); color: var(--emerald); }
.toolbar[hidden] { display: none; }
.editor-preview { background: #fff; border: 1.5px solid #D9CFBB; border-radius: 10px; padding: 24px 28px; min-height: 460px; }
.md-help { font-size: .85rem; color: var(--ink-2); }
.md-help summary { cursor: pointer; font-weight: 600; }
.md-help code { font-size: .8rem; }
.hint { font-size: .8rem; color: var(--ink-3); margin: 0; }
.cover-pick { aspect-ratio: 1200 / 630; background: var(--ivory); border: 1.5px dashed #D9CFBB; border-radius: 10px; display: grid; place-items: center; overflow: hidden; }
.cover-pick img { width: 100%; height: 100%; object-fit: cover; }
.row-btns { display: flex; gap: 12px; align-items: center; }
.row-btns label.btn { margin: 0; cursor: pointer; }
.slug-row { display: flex; align-items: center; gap: 4px; }
.slug-row input { padding: 9px 10px !important; font-size: .9rem !important; }
.editor input[type=text] { width: 100%; font: 1rem var(--sans); padding: 12px 14px; border-radius: 10px; border: 1.5px solid #D9CFBB; background: #fff; }
