*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background: var(--bg);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(1100px 560px at 50% -12%, rgba(212, 165, 116, 0.16), transparent 62%),
    radial-gradient(800px 420px at 100% 20%, rgba(198, 123, 92, 0.05), transparent 60%);
}

img {
  display: block;
  max-width: 100%;
}

[hidden] {
  display: none !important;
}

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

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

h1,
h2,
h3,
h4 {
  margin: 0;
  font-family: var(--font-serif);
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: 0.01em;
}

p {
  margin: 0;
}

ul,
ol {
  margin: 0;
  padding: 0;
}

main {
  min-height: 60vh;
}

.container {
  width: min(var(--container), calc(100% - 48px));
  margin-inline: auto;
}

.skip-link {
  position: fixed;
  top: -60px;
  left: 16px;
  z-index: 100;
  padding: 10px 16px;
  color: #fff;
  background: var(--accent);
  border-radius: var(--radius-sm);
  transition: top 0.2s var(--ease);
}

.skip-link:focus {
  top: 12px;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(250, 248, 245, 0.88);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.brand-mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  color: #fff;
  background: linear-gradient(145deg, var(--accent-2), var(--accent));
  border-radius: 12px;
  font-family: var(--font-serif);
  font-size: 20px;
  box-shadow: 0 4px 12px rgba(198, 123, 92, 0.24);
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}

.brand-text strong {
  font-family: var(--font-serif);
  font-size: 17px;
  letter-spacing: 0.04em;
}

.brand-text small {
  color: var(--faint);
  font-size: 11px;
  letter-spacing: 0.12em;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: none;
}

.site-nav::-webkit-scrollbar {
  display: none;
}

.site-nav a,
.nav-random {
  flex-shrink: 0;
  padding: 8px 13px;
  color: var(--ink-soft);
  background: transparent;
  border: 0;
  border-radius: var(--radius-pill);
  font-size: 14px;
  white-space: nowrap;
  transition: color 0.2s var(--ease), background 0.2s var(--ease);
}

.site-nav a:hover,
.nav-random:hover {
  color: var(--accent-dark);
  background: var(--accent-soft);
}

.site-nav a.is-active {
  color: var(--accent-dark);
  background: rgba(198, 123, 92, 0.12);
}

.nav-random {
  margin-left: 4px;
  color: var(--accent-dark);
  border: 1px solid rgba(198, 123, 92, 0.28);
}

/* Footer */
.site-footer {
  margin-top: 24px;
  padding: 40px 0 44px;
  background: #f3ede5;
  border-top: 1px solid var(--line);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
}

.footer-brand strong {
  font-family: var(--font-serif);
  font-size: 18px;
}

.footer-brand p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  color: var(--muted);
  font-size: 13px;
}

.footer-links a:hover {
  color: var(--accent-dark);
}

.footer-source {
  flex-basis: 100%;
  padding-top: 16px;
  color: var(--faint);
  border-top: 1px solid var(--line);
  font-size: 12px;
}

.footer-source a {
  color: var(--muted);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Shared section heading */
.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.section-head h2 {
  font-size: clamp(22px, 3vw, 28px);
}

.section-head > a,
.section-head .link-btn {
  color: var(--muted);
  font-size: 13px;
}

.section-head > a:hover,
.section-head .link-btn:hover {
  color: var(--accent-dark);
}

.hero {
  padding: 76px 0 40px;
  text-align: center;
}

.hero-inner {
  max-width: 780px;
}

.eyebrow {
  margin-bottom: 12px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.22em;
}

.hero h1 {
  font-size: clamp(34px, 5.4vw, 56px);
  font-weight: 700;
  letter-spacing: 0.02em;
}

.hero-lead {
  max-width: 620px;
  margin: 18px auto 0;
  color: var(--ink-soft);
  font-size: 16px;
}

.hero-poem {
  margin-top: 18px;
  color: var(--faint);
  font-family: var(--font-serif);
  font-size: 14px;
  letter-spacing: 0.3em;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 22px 0 6px;
  color: var(--faint);
  font-size: 13px;
}

.breadcrumb a:hover {
  color: var(--accent-dark);
}
