/* The private studio: the same nocturnal palette, with practical controls. */
.admin-shell {
  --ink: #e4dbca; --paper: #0e0e0d; --acid: #c5a773;
  --line: #363129; --muted: #aba496; --panel: #171613;
  --serif: 'Cormorant Garamond', Georgia, serif;
  background: var(--paper); color: var(--ink); color-scheme: dark;
  font-size: 15px; line-height: 1.6;
}
.admin-shell [hidden] { display: none !important; }
.admin-shell .grain { opacity: .025; }
.admin-shell a { color: inherit; text-underline-offset: 4px; }
.admin-shell :focus-visible { outline: 2px solid var(--acid); outline-offset: 4px; }
.studio-header { min-height: 82px; padding: 1rem 5vw; display: flex; align-items: center; justify-content: space-between; gap: 1rem; border-bottom: 1px solid var(--line); }
.studio-header .brand { font-family: 'Cinzel', Georgia, serif; font-weight: 400; letter-spacing: .12em; }
.studio-header .brand-mark { color: var(--acid); }
.studio-wordmark { color: var(--muted); font: .65rem var(--mono); letter-spacing: .05em; margin-left: .8rem; }
.view-site { font-size: .78rem; text-decoration: none; padding: .6rem 0; white-space: nowrap; }
.studio-nav-wrap { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 0 5vw; border-bottom: 1px solid var(--line); background: #13120f; }
.studio-nav { display: flex; gap: 2rem; }
.studio-nav a { display: block; padding: 1.1rem 0; text-decoration: none; font-size: .82rem; border-bottom: 2px solid transparent; color: var(--muted); }
.studio-nav a[aria-current] { color: var(--acid); border-color: var(--acid); }
.studio-nav-wrap .link-button { min-height: 44px; font: .75rem var(--sans); color: var(--muted); }
.admin-shell .studio { max-width: 1360px; margin: auto; padding: 2.5rem 5vw 6rem; min-height: calc(100svh - 144px); }
.admin-shell .kicker { color: var(--acid); font-size: .63rem; letter-spacing: .17em; }
.admin-shell .studio-heading { align-items: center; padding: 1rem 0 2.2rem; gap: 1.5rem; }
.admin-shell .studio-heading h1, .admin-shell .form-heading h1 { font: 400 clamp(3.2rem, 5vw, 5rem)/1.05 var(--serif); letter-spacing: -.03em; margin: .6rem 0; }
.admin-shell .studio-heading p:last-child, .admin-shell .form-heading > p:not(.kicker) { color: var(--muted); font-size: .86rem; max-width: 600px; margin-bottom: 0; }
.admin-shell .primary-button, .admin-shell .secondary-button { display: inline-flex; align-items: center; justify-content: center; min-height: 46px; padding: .8rem 1.15rem; border: 1px solid var(--acid); background: var(--acid); color: #17130d; border-radius: 4px; text-decoration: none; font: 600 .78rem/1.4 var(--sans); text-transform: none; letter-spacing: 0; cursor: pointer; white-space: normal; text-align: center; }
.admin-shell .primary-button:hover { background: #dcc294; border-color: #dcc294; color: #17130d; }
.admin-shell .secondary-button { background: transparent; color: var(--ink); border-color: #625541; }
.admin-shell .secondary-button:hover { border-color: var(--acid); background: #c5a77310; }
.studio-stats { display: grid; grid-template-columns: repeat(3, 1fr) 1.6fr; border: 1px solid var(--line); background: var(--panel); margin: 1.7rem 0; border-radius: 6px; }
.studio-stats > div, .studio-stats > a { padding: 1.25rem 1.5rem; border-right: 1px solid var(--line); }
.studio-stats > div > span { font: 400 2.4rem/1 var(--serif); color: var(--acid); }
.studio-stats p { margin: .4rem 0 0; color: var(--muted); font-size: .75rem; }
.studio-stats > a { border: 0; display: flex; align-items: center; gap: 1rem; text-decoration: none; font-size: .83rem; }
.studio-stats > a:hover { background: #c5a7730c; }
.stat-symbol { font-size: 2rem; color: var(--acid); }
.studio-stats small { display: block; color: var(--muted); font-size: .68rem; margin-top: .35rem; }
.security-nudge { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; padding: 1rem 1.25rem; border-left: 2px solid var(--acid); background: #211d16; font-size: .78rem; color: #c3b9a6; }
.security-nudge strong { color: var(--ink); }
.security-nudge a { flex-shrink: 0; color: var(--acid); }
.archive-tools { display: flex; align-items: end; justify-content: space-between; gap: 1.5rem; margin-top: 2rem; }
.search-field { display: grid; gap: .5rem; width: min(100%, 380px); color: var(--muted); font-size: .73rem; }
.admin-shell input:not([type='checkbox']):not([type='hidden']), .admin-shell select, .admin-shell textarea { width: 100%; min-width: 0; min-height: 46px; padding: .7rem .85rem; border: 1px solid #554b3c; border-radius: 4px; background: #10100e; color: var(--ink); font: 400 1rem/1.5 var(--sans); box-shadow: none; }
.admin-shell input::placeholder, .admin-shell textarea::placeholder { color: #898376; opacity: 1; }
.admin-shell input:focus, .admin-shell select:focus, .admin-shell textarea:focus { border-color: var(--acid); box-shadow: 0 0 0 2px #c5a77322; outline: 2px solid transparent; }
.status-filters { display: flex; padding: 4px; border: 1px solid var(--line); border-radius: 4px; gap: 3px; }
.status-filters button { min-height: 38px; border: 0; border-radius: 3px; background: transparent; color: var(--muted); padding: .5rem .9rem; font: .75rem var(--sans); cursor: pointer; }
.status-filters button[aria-pressed='true'] { background: #342c20; color: #e2c795; }
.results-count { margin: 1.4rem 0 .7rem; font: .64rem/1.7 var(--mono); color: var(--muted); }
.studio-work-list { border-top: 1px solid var(--line); }
.studio-work-row { display: grid; grid-template-columns: minmax(0, 1fr) 115px 195px; align-items: center; gap: 1.5rem; padding: 1.2rem .5rem; border-bottom: 1px solid var(--line); }
.studio-work-row:hover { background: #c5a77305; }
.work-identity { display: flex; align-items: center; gap: 1.1rem; min-width: 0; }
.work-identity > div { min-width: 0; }
.work-identity h2 { font: 500 1.7rem/1.15 var(--serif); margin: .2rem 0; overflow-wrap: anywhere; }
.work-identity h2 a { text-decoration: none; }
.work-identity p, .work-identity small { font: .6rem/1.6 var(--mono); color: var(--muted); margin: 0; }
.work-identity p { text-transform: uppercase; letter-spacing: .06em; }
.work-identity small { color: var(--acid); }
.admin-shell .table-swatch { height: 64px; width: 64px; display: grid; place-items: center; border-radius: 3px; font-size: 1.5rem; color: #eadbb9; box-shadow: inset 0 0 35px #0008; }
.admin-shell .status { width: fit-content; padding: .3rem .65rem; font: .63rem/1.5 var(--sans); text-transform: none; border: 1px solid #494237; }
.admin-shell .status.live { background: #222d23; color: #b9d3b4; border-color: #3d513a; }
.admin-shell .status.draft { background: #28241e; color: #c2b5a0; }
.work-row-actions { display: flex; align-items: center; gap: 1rem; font-size: .7rem; }
.work-row-actions > a:last-child { white-space: nowrap; text-decoration: none; color: var(--muted); }
.admin-shell .empty-state { border: 0; padding: 3.5rem 1rem; }
.admin-shell .empty-state h2 { font: 2.5rem var(--serif); margin: 0; }
.admin-shell .empty-state p { font: .9rem/1.7 var(--sans); color: var(--muted); margin: 1rem auto 1.5rem; max-width: 470px; }
.account-summary { display: flex; gap: 1rem; align-items: center; margin: 1.6rem 0; }
.account-avatar { width: 50px; height: 50px; display: grid; place-items: center; background: #262015; color: var(--acid); border: 1px solid var(--line); border-radius: 50%; font-size: 1.4rem; }
.account-summary p { margin: .1rem 0 0; color: var(--muted); font-size: .72rem; }
.account-summary > .status { margin-left: auto; }
.settings-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; align-items: start; }
.settings-card, .recovery-result { padding: 2rem; border: 1px solid var(--line); border-radius: 6px; background: var(--panel); min-width: 0; scroll-margin-top: 1rem; }
.settings-card h2, .recovery-result h2 { font: 500 2.3rem/1.15 var(--serif); margin: .5rem 0 1rem; }
.settings-card > p:not(.kicker), .recovery-result p { color: var(--muted); font-size: .82rem; line-height: 1.8; }
.security-form { margin-top: 1.5rem; }
.admin-shell .security-form label, .recovery-result label { display: block; margin: 0 0 .5rem; font: 500 .78rem/1.5 var(--sans); letter-spacing: 0; text-transform: none; }
.security-form > input:not([type='hidden']) { margin-bottom: 1.3rem; }
.password-field { margin-bottom: 1.3rem; }
.password-input { position: relative; }
.admin-shell .password-input input { padding-right: 4.5rem; }
.password-input button { position: absolute; right: 4px; top: 4px; bottom: 4px; min-width: 55px; border: 0; border-radius: 3px; background: #28241d; color: #d6bd93; cursor: pointer; font: .72rem var(--sans); }
.admin-shell .field-help, .admin-shell .work-form small { color: var(--muted); font: .75rem/1.7 var(--sans); opacity: 1; text-transform: none; letter-spacing: 0; }
.security-form .primary-button, .security-form .secondary-button { margin-top: .6rem; }
.studio-help { border-top: 1px solid var(--line); padding-top: 1.2rem; margin-top: 1.5rem; font-size: .78rem; color: var(--muted); }
.studio-help summary { cursor: pointer; color: var(--ink); padding-block: .3rem; }
.studio-help p { margin-bottom: 0; }
.recovery-result { border-color: var(--acid); margin-bottom: 1.5rem; background: #242017; }
.recovery-copy { display: flex; gap: .7rem; }
.admin-shell .recovery-copy input { font-family: var(--mono); font-size: .9rem; }
.recovery-copy button { flex-shrink: 0; }
.admin-shell .login-wrap { min-height: calc(100svh - 82px); padding: 3rem 1rem; background: radial-gradient(ellipse at 50% 25%, #3925174d, transparent 65%); }
.admin-shell .login-card { background: var(--panel); border: 1px solid var(--line); border-radius: 6px; padding: 2.5rem; max-width: 500px; box-shadow: 0 20px 80px #0004; margin: 0; }
.login-seal { display: block; color: var(--acid); font-size: 2.3rem; margin-bottom: 1.2rem; }
.admin-shell .login-card h1 { font: 500 clamp(2.8rem, 6vw, 3.7rem)/1.05 var(--serif); letter-spacing: -.03em; margin: .7rem 0 1rem; }
.login-intro { color: var(--muted); font-size: .83rem; margin-bottom: 2rem; }
.admin-shell .login-card .primary-button { margin-top: .5rem; }
.forgot-link { display: block; text-align: center; font-size: .8rem; margin-top: 1.5rem; }
.login-card > .back { display: inline-block; margin-bottom: 1.3rem; }
.admin-shell .form-page > .back { margin-bottom: 1.7rem; }
.admin-shell .form-heading { padding-bottom: 1.5rem; }
.form-heading .field-help { display: block; margin-top: .7rem; }
.editor-steps { display: flex; gap: 2rem; margin-bottom: 1.5rem; font: .7rem var(--mono); }
.editor-steps a { padding-block: .7rem; text-decoration: none; }
.admin-shell .work-form { border-color: var(--line); }
.admin-shell .form-section { padding: 2.5rem 0; scroll-margin-top: 1rem; }
.admin-shell .form-section h2 { font-size: 2.2rem; }
.admin-shell .form-section > div:first-child > span { color: var(--acid); }
.admin-shell .form-section > div:first-child > p { color: var(--muted); }
.admin-shell .work-form label { font: 500 .8rem/1.5 var(--sans); text-transform: none; letter-spacing: 0; margin-bottom: .6rem; }
.admin-shell input[type='file'] { font-size: .85rem; padding: 1rem; border-style: dashed; }
.admin-shell input::file-selector-button { color: var(--ink); background: #30291f; border: 1px solid #625541; border-radius: 3px; padding: .6rem; margin-right: .8rem; cursor: pointer; }
.admin-shell .check input { accent-color: var(--acid); flex-shrink: 0; }
.publish-options .field-help { margin: 0; }
.admin-shell .publish-options .primary-button { margin-top: 1rem; }
.editor-cancel { font-size: .75rem; padding: .5rem 0; }
.admin-shell .danger-zone { margin-top: 3rem; background: #261818; border-color: #69413b; border-radius: 5px; }
.admin-shell .danger-zone h2, .admin-shell .danger-zone button { color: #efb2a7; }
.admin-shell .danger-zone button { border-color: #98655a; min-height: 44px; border-radius: 3px; }
.admin-shell .danger-zone p { color: #c6a59c; }
.admin-shell .flash-stack { position: static; width: auto; max-width: 1220px; margin: 1.2rem 5vw 0; }
.admin-shell .flash { background: #252219; color: var(--ink); border: 1px solid #5e5138; border-left: 3px solid var(--acid); border-radius: 4px; font: .83rem/1.6 var(--sans); box-shadow: none; }
.admin-shell .flash-error { background: #301b19; border-color: #98655a; }
@media (min-width: 1450px) { .admin-shell .flash-stack { margin-inline: auto; } }
@media (max-width: 850px) {
  .studio-stats { grid-template-columns: repeat(3, 1fr); }
  .studio-stats > div:nth-child(3) { border-right: 0; }
  .studio-stats > a { grid-column: 1 / -1; border-top: 1px solid var(--line); padding-block: .8rem; }
  .settings-grid { grid-template-columns: 1fr; }
  .studio-work-row { grid-template-columns: minmax(0, 1fr) auto; gap: 1rem; }
  .work-row-actions { grid-column: 1 / -1; justify-content: flex-end; }
}
@media (max-width: 600px) {
  .studio-header { min-height: 72px; padding-inline: 5vw; }
  .studio-header .brand { font-size: .76rem; letter-spacing: .05em; }
  .studio-wordmark { display: none; }
  .studio-nav-wrap { gap: .6rem; }
  .studio-nav { gap: 1.1rem; }
  .studio-nav a { font-size: .73rem; }
  .studio-nav-wrap .link-button { font-size: .67rem; }
  .admin-shell .studio { padding-top: 1.5rem; }
  .admin-shell .studio-heading { display: block; }
  .admin-shell .studio-heading .primary-button, .admin-shell .studio-heading > .secondary-button { margin-top: 1.3rem; }
  .studio-stats > div { padding: 1rem .8rem; }
  .studio-stats p { font-size: .66rem; }
  .studio-stats > a { padding-inline: 1rem; }
  .security-nudge { display: block; }
  .security-nudge a { display: inline-block; margin-top: .6rem; padding-block: .25rem; }
  .archive-tools { flex-direction: column; align-items: stretch; gap: 1rem; }
  .search-field { width: 100%; }
  .status-filters { width: fit-content; }
  .status-filters button { padding-inline: .8rem; }
  .studio-work-row { padding-block: 1.1rem; column-gap: .6rem; }
  .admin-shell .table-swatch { width: 44px; height: 52px; }
  .work-identity { gap: .7rem; }
  .work-identity h2 { font-size: 1.5rem; }
  .work-identity p { font-size: .53rem; }
  .admin-shell .status { font-size: .59rem; padding-inline: .5rem; }
  .work-row-actions { justify-content: flex-start; padding-left: 55px; }
  .settings-card, .recovery-result { padding: 1.4rem; }
  .admin-shell .login-card { padding: 1.8rem 1.4rem; }
  .admin-shell .login-wrap { padding-block: 2rem; }
  .recovery-copy { flex-direction: column; }
  .editor-steps { gap: 1rem; font-size: .61rem; flex-wrap: wrap; }
  .admin-shell .form-section { grid-template-columns: 1fr; gap: 1.5rem; }
  .admin-shell .field-grid { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
