:root {
  --notice-shadow: 0 18px 55px color-mix(in srgb, var(--ink) 18%, transparent);
  font-family: var(--font);
  color-scheme: light dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; background: var(--bg); color: var(--ink); }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
.shell { width: min(1160px, 100%); margin: auto; padding: 20px; }
.topbar { display: flex; align-items: center; gap: 14px; margin-bottom: 18px; }
.brand { width: 42px; height: 42px; border-radius: 13px; background: linear-gradient(145deg, var(--ac), var(--chrome)); box-shadow: 0 8px 24px color-mix(in srgb, var(--ac) 35%, transparent); display: grid; place-items: center; color: var(--ac-on); font-weight: 700; }
.topbar h1 { font-size: 19px; margin: 0; }
.topbar p { margin: 3px 0 0; color: var(--muted); font-size: 13px; }
.grow { flex: 1; }
.icon-btn, .secondary, .primary, .danger { border: 1px solid var(--line); border-radius: 10px; padding: 9px 13px; background: var(--surface); color: var(--ink); font-weight: 700; text-decoration: none; }
.primary { background: var(--ac); border-color: var(--ac); color: var(--ac-on); }
.danger { color: var(--ac-on); background: var(--coral); border-color: var(--coral); }
.secondary:hover, .icon-btn:hover { border-color: var(--ac); }
.notice-nav { display: flex; gap: 8px; overflow: auto; padding: 2px 0 13px; }
.notice-nav button { white-space: nowrap; border: 1px solid var(--line); border-radius: 999px; padding: 7px 12px; background: var(--surface); color: var(--muted); }
.notice-nav button.active { background: var(--ac); border-color: var(--ac); color: var(--ac-on); }
.hero { min-height: 240px; border-radius: 22px; background: linear-gradient(120deg, var(--chrome), var(--ac-deep)); color: var(--ac-on); display: flex; align-items: end; padding: 28px; box-shadow: var(--notice-shadow); overflow: hidden; position: relative; margin-bottom: 18px; }
.hero::after { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at 80% 20%, color-mix(in srgb, var(--ac) 45%, transparent), transparent 42%); pointer-events: none; }
.hero-copy { position: relative; z-index: 1; max-width: 680px; }
.eyebrow, .pill { display: inline-flex; border-radius: 999px; padding: 4px 9px; font-size: 11px; font-weight: 700; letter-spacing: .05em; background: var(--ac); color: var(--ac-on); }
.hero h2 { font-size: clamp(25px, 4vw, 42px); line-height: 1.07; margin: 10px 0; }
.hero p { margin: 0; line-height: 1.55; color: var(--ac-on); opacity: .82; }
.section-head { display: flex; align-items: center; margin: 20px 0 10px; }
.section-head h2 { font-size: 15px; margin: 0; }
.section-head span { color: var(--muted); font-size: 12px; }
.feed { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.notice-card { border: 1px solid var(--line); background: var(--surface); color: var(--ink); text-align: left; border-radius: 16px; padding: 16px; min-height: 150px; position: relative; }
.notice-card:hover { border-color: var(--ac); transform: translateY(-1px); }
.notice-card.read { opacity: .72; }
.notice-card h3 { font-size: 16px; line-height: 1.35; margin: 12px 0 7px; }
.notice-card p { font-size: 13px; line-height: 1.5; color: var(--muted); margin: 0; }
.meta { display: flex; justify-content: space-between; gap: 10px; color: var(--muted); font-size: 11px; }
.required { position: absolute; right: 12px; bottom: 12px; color: var(--coral); font-size: 10px; font-weight: 700; }
.account { border: 1px solid var(--line); border-radius: 14px; background: var(--surface); padding: 12px 14px; display: flex; align-items: center; gap: 12px; margin: 15px 0; }
.account b { font-size: 13px; }
.account small { display: block; color: var(--muted); margin-top: 2px; }
.empty { border: 1px dashed var(--line); border-radius: 16px; padding: 30px; text-align: center; color: var(--muted); grid-column: 1/-1; }
.modal { position: fixed; inset: 0; background: color-mix(in srgb, var(--ink) 65%, transparent); display: grid; place-items: center; padding: 18px; z-index: 50; }
.modal[hidden] { display: none; }
.modal-card { width: min(720px, 100%); max-height: 88vh; overflow: auto; background: var(--surface); border-radius: 20px; padding: 22px; box-shadow: var(--notice-shadow); }
.modal-card h2 { margin: 10px 0; font-size: 25px; }
.modal-body { white-space: pre-wrap; line-height: 1.68; color: var(--ink); }
.modal-actions { display: flex; justify-content: flex-end; gap: 9px; margin-top: 20px; }
.oauth-card { width: min(430px, 100%); text-align: center; overflow: hidden; }
.oauth-card .eyebrow { margin: 0; }
.oauth-card h2 { margin-top: 13px; }
.oauth-copy { margin: 0; color: var(--muted); line-height: 1.55; }
.oauth-mark { width: 58px; height: 58px; margin: 0 auto 18px; border-radius: 18px; display: grid; place-items: center; background: color-mix(in srgb, var(--ac) 14%, var(--surface)); }
.oauth-mark span { width: 26px; height: 26px; border-radius: 50%; border: 3px solid color-mix(in srgb, var(--ac) 25%, transparent); border-top-color: var(--ac); animation: oauth-spin .8s linear infinite; }
.oauth-card .modal-actions { justify-content: center; }
@keyframes oauth-spin { to { transform: rotate(360deg); } }
.toast { position: fixed; left: 50%; bottom: 20px; transform: translate(-50%, 20px); opacity: 0; background: var(--chrome); color: var(--ac-on); border-radius: 10px; padding: 10px 14px; transition: .2s; z-index: 80; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.board-footer { display: flex; gap: 10px; justify-content: space-between; align-items: center; margin-top: 18px; color: var(--muted); font-size: 11px; }
.admin-grid { display: grid; grid-template-columns: minmax(330px, 430px) 1fr; gap: 18px; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 18px; }
.panel h2 { font-size: 16px; margin: 0 0 14px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 11px; }
.field { display: grid; gap: 5px; }
.field.full { grid-column: 1/-1; }
.field label { font-size: 11px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 700; }
.field input, .field select, .field textarea { width: 100%; border: 1px solid var(--line); background: var(--bg); color: var(--ink); border-radius: 10px; padding: 10px; outline: none; }
.field textarea { resize: vertical; min-height: 82px; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--ac); }
.checks { display: flex; flex-wrap: wrap; gap: 12px; font-size: 12px; color: var(--muted); }
.actions { display: flex; gap: 9px; align-items: center; margin-top: 14px; }
.status { font-size: 12px; color: var(--muted); }
.admin-list { display: grid; gap: 9px; }
.admin-row { border: 1px solid var(--line); border-radius: 13px; padding: 13px; }
.admin-row-head { display: flex; gap: 10px; align-items: flex-start; }
.admin-row h3 { font-size: 14px; margin: 0; flex: 1; }
.admin-row p { font-size: 12px; color: var(--muted); line-height: 1.45; margin: 7px 0; }
.row-actions { display: flex; gap: 7px; flex-wrap: wrap; }
.row-actions button { padding: 6px 9px; font-size: 11px; }
.pill.draft { background: var(--muted); }
.pill.published { background: var(--ac); }
.pill.archived { background: var(--chrome); }
.pill.scheduled { background: var(--amber); }
@media (max-width: 820px) {
  .shell { padding: 13px; }
  .admin-grid { grid-template-columns: 1fr; }
  .hero { min-height: 200px; padding: 20px; }
  .topbar { align-items: flex-start; }
  .board-footer { align-items: flex-start; flex-direction: column; }
  .form-grid { grid-template-columns: 1fr; }
  .field.full { grid-column: auto; }
}
