:root {
  --ink: #151515;
  --muted: #66615a;
  --paper: #fbfaf6;
  --linen: #efeadf;
  --olive: #344238;
  --amber: #b46f32;
  --white: #ffffff;
  --line: rgba(21, 21, 21, 0.12);
  --shadow: 0 24px 70px rgba(21, 21, 21, 0.14);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 20;
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 32px clamp(24px, 5vw, 88px);
  color: var(--white);
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.58), rgba(0, 0, 0, 0));
}

.brand,
.main-nav {
  display: flex;
  align-items: center;
}

.brand {
  gap: 10px;
  font-size: 1.85rem;
  font-weight: 800;
  letter-spacing: 0;
}

.brand-mark {
  display: inline-grid;
  width: 76px;
  height: 76px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.52);
  border-radius: 50%;
  font-size: 1.38rem;
}

.main-nav {
  gap: clamp(12px, 2vw, 28px);
  font-size: 1.75rem;
  font-weight: 700;
}

.main-nav a {
  opacity: 0.9;
}

.nav-cta {
  padding: 18px 28px;
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 999px;
}

.hero {
  position: relative;
  min-height: 92vh;
  display: grid;
  align-items: center;
  overflow: hidden;
  padding: 112px clamp(20px, 6vw, 84px) 72px;
  color: var(--white);
}

.hero-image,
.hero-overlay {
  position: absolute;
  inset: 0;
}

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-overlay {
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.72) 0%, rgba(0, 0, 0, 0.44) 48%, rgba(0, 0, 0, 0.08) 100%),
    linear-gradient(0deg, rgba(0, 0, 0, 0.38), rgba(0, 0, 0, 0.05));
}

.hero-content {
  position: relative;
  max-width: 760px;
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--amber);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero .eyebrow {
  color: #f2bd83;
}

h1,
h2,
h3,
blockquote {
  font-family: "Playfair Display", Georgia, serif;
  line-height: 1.04;
  letter-spacing: 0;
}

h1 {
  max-width: 820px;
  margin: 0;
  font-size: clamp(3rem, 8vw, 6.8rem);
}

.hero-copy {
  max-width: 620px;
  margin: 24px 0 28px;
  color: rgba(255, 255, 255, 0.86);
  font-size: clamp(1rem, 1.5vw, 1.2rem);
}

.signup-form,
.panel-form {
  display: flex;
  width: min(100%, 560px);
  gap: 10px;
}

.signup-form input,
.panel-form input {
  min-width: 0;
  flex: 1;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 15px 18px;
  outline: none;
}

.signup-form button,
.panel-form button,
.filter-button {
  border: 0;
  cursor: pointer;
  transition: transform 0.18s ease, background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}

.signup-form button,
.panel-form button {
  border-radius: 999px;
  padding: 15px 22px;
  background: var(--amber);
  color: var(--white);
  font-weight: 800;
  white-space: nowrap;
}

.signup-form button:hover,
.panel-form button:hover,
.filter-button:hover {
  transform: translateY(-1px);
}

.form-note {
  min-height: 24px;
  margin: 10px 0 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.93rem;
}

.intro-band {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--line);
}

.intro-band div {
  background: var(--olive);
  color: var(--white);
  padding: 28px clamp(20px, 4vw, 54px);
}

.stat {
  display: block;
  margin-bottom: 8px;
  color: #f2bd83;
  font-family: "Playfair Display", Georgia, serif;
  font-size: clamp(1.9rem, 4vw, 3.2rem);
  font-weight: 800;
  line-height: 1;
}

.intro-band p {
  max-width: 280px;
  margin: 0;
  color: rgba(255, 255, 255, 0.78);
}

.section-shell {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 86px 0;
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
}

.section-heading h2,
.author-copy h2 {
  margin: 0;
  font-size: clamp(2.4rem, 5vw, 4.6rem);
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 24px;
}

.filter-button {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  padding: 10px 15px;
  font-weight: 800;
}

.filter-button.active {
  border-color: var(--olive);
  background: var(--olive);
  color: var(--white);
}

.post-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.post-card {
  min-height: 280px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  padding: 26px;
  box-shadow: 0 10px 26px rgba(21, 21, 21, 0.05);
}

.feature-post {
  grid-column: span 2;
  background: var(--linen);
}

.post-meta {
  margin: 0 0 18px;
  color: var(--amber);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.post-card h3 {
  margin: 0 0 18px;
  font-size: clamp(1.6rem, 2.6vw, 2.55rem);
}

.post-card p:not(.post-meta) {
  margin: 0 0 22px;
  color: var(--muted);
}

.post-card a {
  width: fit-content;
  color: var(--olive);
  font-weight: 800;
}

.post-card.is-hidden {
  display: none;
}

.empty-state {
  grid-column: 1 / -1;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  padding: 24px;
  color: var(--muted);
  font-weight: 700;
}

.empty-state.compact {
  padding: 16px;
  font-size: 0.95rem;
}

.quote-band {
  background: var(--ink);
  color: var(--white);
  padding: clamp(54px, 9vw, 110px) clamp(20px, 6vw, 84px);
}

.quote-band blockquote {
  max-width: 980px;
  margin: 0 auto;
  font-size: clamp(2.1rem, 5vw, 5rem);
  text-align: center;
}

.author-section {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
  gap: clamp(28px, 6vw, 76px);
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 86px 0;
}

.author-copy p:not(.eyebrow) {
  max-width: 720px;
  margin: 24px 0 0;
  color: var(--muted);
  font-size: 1.08rem;
}

.author-panel {
  align-self: start;
  border-radius: 8px;
  background: var(--olive);
  color: var(--white);
  padding: 30px;
  box-shadow: var(--shadow);
}

.author-panel h3 {
  margin: 0 0 12px;
  font-size: 2.2rem;
}

.author-panel p {
  color: rgba(255, 255, 255, 0.78);
}

.panel-form {
  flex-direction: column;
  margin-top: 22px;
}

.panel-form button {
  width: 100%;
}

.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-top: 1px solid var(--line);
  padding: 26px clamp(20px, 4vw, 56px);
  color: var(--muted);
}

.site-footer div {
  display: flex;
  gap: 18px;
  font-weight: 800;
}

.plain-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border-bottom: 1px solid var(--line);
  padding: 26px clamp(20px, 5vw, 72px);
  background: var(--paper);
  color: var(--ink);
}

.plain-brand {
  color: var(--ink);
}

.plain-brand .brand-mark {
  border-color: rgba(21, 21, 21, 0.25);
}

.plain-nav {
  display: flex;
  gap: 22px;
  color: var(--muted);
  font-weight: 800;
}

.article-body,
.admin-body {
  min-height: 100vh;
}

.article-shell {
  width: min(860px, calc(100% - 40px));
  margin: 0 auto;
  padding: clamp(54px, 8vw, 96px) 0;
}

.article-shell h1 {
  color: var(--ink);
  font-size: clamp(3rem, 7vw, 6rem);
}

.article-meta {
  margin: 22px 0 46px;
  color: var(--muted);
  font-weight: 800;
}

.article-content {
  color: #2b2925;
  font-size: clamp(1.08rem, 2vw, 1.24rem);
}

.article-content p {
  margin: 0 0 24px;
}

.back-link {
  display: inline-flex;
  margin-top: 26px;
  color: var(--olive);
  font-weight: 800;
}

.admin-shell {
  width: min(1280px, calc(100% - 40px));
  margin: 0 auto;
  padding: 48px 0 72px;
}

.admin-login {
  width: min(620px, 100%);
  margin: 8vh auto 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  padding: clamp(28px, 5vw, 48px);
  box-shadow: var(--shadow);
}

.admin-login h1,
.admin-topbar h1 {
  margin: 0 0 24px;
  color: var(--ink);
  font-size: clamp(2.4rem, 5vw, 4.4rem);
}

.admin-form,
.editor-panel {
  display: grid;
  gap: 12px;
}

.admin-form label,
.editor-panel label {
  color: var(--muted);
  font-weight: 800;
}

.admin-form input,
.editor-panel input,
.editor-panel select,
.editor-panel textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  color: var(--ink);
  padding: 13px 14px;
  outline: none;
}

.editor-panel textarea {
  resize: vertical;
}

.admin-form button,
.editor-panel button,
.admin-actions button,
.admin-actions a,
.admin-item button,
.side-heading a {
  border: 0;
  border-radius: 999px;
  background: var(--olive);
  color: var(--white);
  padding: 12px 18px;
  cursor: pointer;
  font-weight: 800;
}

.admin-note {
  min-height: 24px;
  margin: 6px 0 0;
  color: var(--muted);
}

.admin-topbar,
.admin-actions,
.editor-actions,
.side-heading {
  display: flex;
  align-items: center;
}

.admin-topbar {
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 24px;
}

.admin-actions,
.editor-actions {
  gap: 10px;
}

.admin-actions button,
.admin-actions a,
.secondary-button,
.admin-item button,
.side-heading a {
  background: var(--linen);
  color: var(--ink);
}

.admin-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(330px, 0.8fr);
  gap: 22px;
}

.editor-panel,
.admin-side section {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  padding: 24px;
}

.check-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.check-row input {
  width: auto;
}

.admin-side {
  display: grid;
  align-content: start;
  gap: 18px;
}

.side-heading {
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.side-heading h2 {
  margin: 0;
  font-family: Inter, system-ui, sans-serif;
  font-size: 1.1rem;
}

.admin-list {
  display: grid;
  gap: 10px;
}

.admin-item {
  display: grid;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
}

.admin-item span {
  color: var(--muted);
  font-size: 0.92rem;
}

.admin-item div {
  display: flex;
  gap: 8px;
}

.admin-item button {
  padding: 8px 12px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 860px) {
  .site-header {
    position: absolute;
    align-items: flex-start;
  }

  .main-nav {
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 12px 18px;
    font-size: 1.08rem;
  }

  .hero {
    min-height: 88vh;
    padding-top: 138px;
  }

  .signup-form,
  .intro-band,
  .post-grid,
  .author-section,
  .admin-layout {
    grid-template-columns: 1fr;
  }

  .signup-form {
    display: grid;
  }

  .feature-post {
    grid-column: auto;
  }

  .intro-band {
    display: grid;
  }

  .author-section {
    display: grid;
  }

  .admin-topbar,
  .plain-header {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 560px) {
  .site-header {
    padding: 18px 16px;
  }

  .brand {
    font-size: 1.15rem;
  }

  .brand-mark {
    width: 50px;
    height: 50px;
    font-size: 1rem;
  }

  .brand span:last-child {
    display: none;
  }

  .main-nav {
    font-size: 0.96rem;
  }

  .nav-cta {
    padding: 9px 12px;
  }

  h1 {
    font-size: 3rem;
  }

  .post-card,
  .author-panel {
    padding: 22px;
  }

  .site-footer {
    align-items: flex-start;
    flex-direction: column;
  }
}
