:root {
  --bg: #f4f2ed;
  --text: #1a1a1a;
  --text-muted: #6b6b6b;
  --accent: #2c5282;
  --accent-soft: rgba(44, 82, 130, 0.15);
  --border: rgba(0, 0, 0, 0.08);
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --logo: "Caveat", "Segoe Script", cursive;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
}

body {
  margin: 0;
  min-height: 100dvh;
  font-family: var(--font);
  font-weight: 400;
  color: var(--text);
  background: var(--bg);
  line-height: 1.5;
}

#pattern {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

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

a:hover {
  opacity: 0.65;
}

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

.page {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-rows: auto 1fr auto;
  min-height: 100dvh;
  padding: 1.75rem 2rem 2rem;
  opacity: 0;
  transition: opacity 3.5s var(--ease);
}

body.is-text-ready .page {
  opacity: 1;
}

.site-header {
  display: flex;
  align-items: flex-start;
}

.logo {
  display: inline-flex;
  color: var(--text);
  text-decoration: none;
}

.logo-text {
  font-family: var(--logo);
  font-size: 2.5rem;
  font-weight: 500;
  line-height: 1;
  letter-spacing: 0.01em;
}

@media (prefers-reduced-motion: reduce) {
  .page {
    transition: none;
  }
}

.hero {
  min-height: 12rem;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 2rem;
  padding-top: 1rem;
}

.footer-left {
  max-width: 28rem;
}

.tagline {
  margin: 0 0 0.5rem;
  font-size: 0.95rem;
}

.label {
  font-weight: 500;
}

.description {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.9rem;
  max-width: 26rem;
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem 1.75rem;
  justify-content: flex-end;
  font-size: 0.95rem;
}

.panel {
  position: fixed;
  inset: 0;
  z-index: 10;
  background: var(--bg);
  overflow-y: auto;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s var(--ease);
}

.panel.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.panel-content {
  max-width: 42rem;
  margin: 0 auto;
  padding: 3rem 2rem 4rem;
}

.panel-header {
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
}

.panel-meta {
  margin: 0 0 0.75rem;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.panel-header h2 {
  margin: 0;
  font-size: 1.75rem;
  font-weight: 500;
  letter-spacing: -0.02em;
}

.panel-body {
  font-size: 1rem;
  color: var(--text);
}

.panel-body p {
  margin: 0 0 1.25rem;
}

.panel-body a {
  text-decoration: underline;
  text-underline-offset: 2px;
}

.placeholder:empty {
  display: none;
}

.back-link {
  display: inline-block;
  margin-top: 2.5rem;
  font-size: 0.95rem;
}

@media (max-width: 720px) {
  .page {
    padding: 1.25rem 1.25rem 1.5rem;
  }

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

  .footer-nav {
    justify-content: flex-start;
  }
}
