:root {
    --ink: #11151a;
    --muted: #6d747c;
    --paper: #f4f2ed;
    --panel: #fff;
    --line: #dedbd3;
    --orange: #f4511e;
    --orange-dark: #d53d0d;
    --radius: 18px;
    font-family: Arial, Helvetica, sans-serif;
    color: var(--ink);
    background: var(--paper);
}
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; background: var(--paper); }
a { color: inherit; }
button, input { font: inherit; }
h1, h2, p { margin-top: 0; }
h1 { font-size: clamp(2rem, 4vw, 3.7rem); letter-spacing: -.045em; line-height: .98; margin-bottom: .75rem; }
h2 { letter-spacing: -.025em; }
.muted { color: var(--muted); }
.eyebrow { font-size: .72rem; letter-spacing: .23em; font-weight: 700; color: var(--muted); margin-bottom: .7rem; }
.topbar { height: 74px; padding: 0 clamp(20px, 4vw, 58px); display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; border-bottom: 1px solid var(--line); background: rgba(244,242,237,.94); position: sticky; top: 0; z-index: 20; backdrop-filter: blur(14px); }
.wordmark { text-decoration: none; display: flex; align-items: center; gap: 11px; font-weight: 800; letter-spacing: .08em; font-size: .78rem; }
.wordmark small { display: block; color: var(--muted); letter-spacing: .23em; font-size: .56rem; margin-top: 2px; }
.mini-mark, .brand-mark span { display: block; border-radius: 50%; background: var(--orange); border: 2px solid white; box-shadow: 0 0 0 1px var(--orange); }
.mini-mark { width: 13px; height: 13px; }
.topbar nav { display: flex; height: 100%; gap: 34px; }
.topbar nav a { display: grid; place-items: center; text-decoration: none; font-size: .87rem; color: var(--muted); border-bottom: 2px solid transparent; }
.topbar nav a.active { color: var(--ink); border-color: var(--orange); }
.topbar form { justify-self: end; }
.link-button { border: 0; background: none; color: var(--muted); cursor: pointer; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 22px; border-radius: 999px; border: 0; text-decoration: none; font-weight: 700; cursor: pointer; }
.button.primary { background: var(--orange); color: white; box-shadow: 0 7px 24px rgba(244,81,30,.22); }
.button.primary:hover { background: var(--orange-dark); }
.button.wide { width: 100%; }
.page-wrap { max-width: 1340px; margin: 0 auto; padding: 60px 28px 90px; }
.hero-row { display: flex; justify-content: space-between; align-items: end; gap: 30px; margin-bottom: 44px; }
.hero-row h1 { margin-bottom: 8px; }
.post-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 24px; }
.post-card { background: var(--panel); border-radius: var(--radius); overflow: hidden; border: 1px solid rgba(17,21,26,.06); box-shadow: 0 12px 36px rgba(35,31,24,.07); }
.post-card img { width: 100%; aspect-ratio: 4/5; object-fit: cover; display: block; }
.post-card-body { padding: 20px; }
.post-card-body h2 { font-size: 1.15rem; margin-bottom: 18px; }
.card-actions { display: flex; align-items: center; justify-content: space-between; font-size: .78rem; }
.card-actions a { color: var(--orange-dark); font-weight: 700; }
.status-chip { display: inline-flex; padding: 7px 11px; border-radius: 999px; color: #785f26; background: #fff4d5; font-size: .7rem; font-weight: 700; }
.empty-state { min-height: 410px; display: grid; place-items: center; align-content: center; text-align: center; background: var(--panel); border: 1px dashed #cbc6bb; border-radius: 24px; }
.brand-mark { width: 70px; height: 40px; border-top: 1px solid var(--ink); display: grid; place-items: start center; margin: 0 auto 22px; }
.brand-mark span { width: 17px; height: 17px; margin-top: -9px; }
.workspace { min-height: calc(100vh - 74px); display: grid; grid-template-columns: minmax(420px, .8fr) minmax(500px, 1.2fr); }
.editor-panel { padding: 46px clamp(28px, 5vw, 74px) 70px; background: var(--panel); }
.section-heading { display: flex; justify-content: space-between; align-items: start; gap: 20px; }
.section-heading h1 { font-size: clamp(2.1rem, 4vw, 3.2rem); }
.editor-form { margin-top: 30px; }
.stack, .editor-form { display: grid; gap: 18px; }
label { display: grid; gap: 8px; font-size: .76rem; font-weight: 700; letter-spacing: .04em; }
label small { color: var(--muted); font-weight: 400; }
input[type="email"], input[type="password"], input[type="text"], input:not([type]) { width: 100%; min-height: 48px; border: 1px solid var(--line); border-radius: 10px; padding: 0 14px; background: #fbfaf7; outline: none; }
input:focus { border-color: var(--orange); box-shadow: 0 0 0 3px rgba(244,81,30,.1); }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.upload-zone { min-height: 150px; place-items: center; align-content: center; text-align: center; border: 1px dashed #bfb9ae; border-radius: 15px; cursor: pointer; background: #faf9f6; transition: .2s ease; }
.upload-zone:hover, .upload-zone.dragging { border-color: var(--orange); background: #fff7f3; }
.upload-zone input { position: absolute; opacity: 0; pointer-events: none; }
.upload-zone strong { font-size: .95rem; }
.upload-icon { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--orange); color: white; font-size: 1.3rem; }
details { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 15px 0; }
summary { cursor: pointer; font-size: .8rem; font-weight: 700; }
.sliders { padding-top: 20px; }
input[type="range"] { accent-color: var(--orange); }
.preview-panel { padding: 34px; background: #171a1e; display: grid; align-content: start; justify-items: center; }
.preview-toolbar { width: min(100%, 540px); display: flex; justify-content: space-between; color: #aeb2b7; font-size: .72rem; letter-spacing: .06em; margin-bottom: 14px; }
#preview { display: block; width: min(100%, 540px); height: auto; background: #252a30; box-shadow: 0 24px 70px rgba(0,0,0,.38); }
.preview-hint { max-width: 540px; color: #8f949b; font-size: .72rem; line-height: 1.5; margin-top: 14px; }
.auth-shell { min-height: 100vh; display: grid; place-items: center; padding: 30px; background: radial-gradient(circle at 80% 10%, #e6ddcc 0, transparent 34%), var(--paper); }
.auth-card { width: min(100%, 470px); padding: clamp(30px, 6vw, 58px); border-radius: 24px; background: rgba(255,255,255,.94); box-shadow: 0 26px 80px rgba(53,45,32,.12); }
.auth-card h1 { text-align: center; }
.auth-card > .eyebrow, .auth-card > .muted { text-align: center; }
.notice { padding: 13px 15px; border-radius: 10px; margin: 18px 0; font-size: .84rem; line-height: 1.4; }
.notice.error { background: #ffebe7; color: #8e2715; }
.notice.success { background: #e8f6e9; color: #235f2b; }
.requirement-list { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; margin: 18px 0 24px; }
.requirement { display: flex; align-items: center; gap: 7px; color: var(--muted); font-size: .72rem; }
.requirement b { width: 18px; height: 18px; display: grid; place-items: center; border-radius: 50%; }
.requirement.ok b { color: #22652b; background: #e2f4e4; }
.requirement.bad b { color: #922b18; background: #fee8e3; }
@media (max-width: 900px) {
    .workspace { grid-template-columns: 1fr; }
    .preview-panel { order: -1; padding: 22px; }
    #preview { max-height: 56vh; width: auto; max-width: 100%; }
    .topbar { grid-template-columns: 1fr auto; }
    .topbar nav { display: none; }
}
@media (max-width: 600px) {
    .form-grid { grid-template-columns: 1fr; }
    .hero-row { align-items: stretch; flex-direction: column; }
    .hero-row .button { align-self: flex-start; }
    .editor-panel { padding: 34px 20px 60px; }
    .requirement-list { grid-template-columns: 1fr; }
}
