/* Desk404, library calm (uiupdate.md) */

:root {
  --bg: #F4F1EC;
  --text: #2B2B2B;
  --accent: #2F5D50;
  --accent-hover: #244A40;
  --text-secondary: #6B6A66;
  --text-muted: #A3A098;
  --divider: #DEDAD3;
  --section-tint: #F7F5F1;
  --max-width: 45rem; /* ~720px */
  --section-spacing: 2.5rem; /* 40px */
  --font-heading: 'Inter', system-ui, -apple-system, sans-serif;
}

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

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  font-size: 1.0625rem; /* ~17px */
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
}

/* Page container: max-width ~720px, centered, padding */
.page-container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ----- Hero ----- */
.hero {
  padding: clamp(2rem, 5vw, 3rem) 0;
}

.hero-inner {
  margin: 0;
}

.hero h1 {
  margin: 0 0 0.5em;
  font-family: var(--font-heading);
  font-size: clamp(1.875rem, 4.5vw, 2.625rem); /* ~30–42px */
  font-weight: 600;
  line-height: 1.25;
  letter-spacing: -0.02em;
}

.hero-tagline {
  margin: 0 0 1.5rem;
  font-size: 1.125rem;
  line-height: 1.6;
  color: var(--text);
}

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1rem;
}

.hero-helper {
  margin: 1rem 0 0;
  font-size: 0.9375rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.hero-trust {
  margin: 0.5rem 0 0;
  font-size: 0.9375rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* Feature chips */
.feature-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2rem;
  list-style: none;
  padding: 0;
  margin-left: 0;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 0.875rem;
  font-size: 0.9375rem;
  color: var(--text-secondary);
  background: var(--section-tint);
  border: 1px solid var(--divider);
  border-radius: 999px;
}

.chip-icon {
  flex-shrink: 0;
  color: var(--accent);
}

/* ----- Sections: spacing rhythm, no thick dividers ----- */
main section {
  padding: var(--section-spacing) 0;
}

main section:first-of-type {
  padding-top: 1.5rem;
}

main section.how-it-works {
  padding-top: 1.5rem;
}

main section.recognition {
  background: var(--section-tint);
}

main section.what-it-is,
main section.how-it-works {
  background: var(--bg);
}

/* Subtle divider above conversion blocks */
.section-divider {
  height: 0;
  padding: 0;
  margin: 0;
  border: none;
  border-top: 1px solid var(--divider);
}

.card-section {
  padding: var(--section-spacing) 0;
  background: var(--bg);
}

section.conversion.card-section {
  padding-top: 1.25rem;
}

/* ----- Section typography ----- */
h2 {
  margin: 0 0 1rem;
  font-family: var(--font-heading);
  font-size: 1.375rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.4;
}

/* ----- Recognition ----- */
.recognition-list {
  margin: 0;
  padding-left: 1.25rem;
}

.recognition-list li {
  margin-bottom: 0.5rem;
  line-height: 1.6;
}

/* ----- What it is ----- */
.what-not {
  margin: 0 0 0.5rem;
  color: var(--text-secondary);
}

.what-yes {
  margin: 0 0 1.25rem;
  font-weight: 500;
}

.what-intro {
  margin: 0 0 1.25rem;
  font-weight: 500;
}

.what-use {
  margin: 1.25rem 0 0;
  color: var(--text-secondary);
  font-size: 0.9375rem;
}

.what-coming {
  margin: 1.25rem 0 0;
  font-size: 0.9375rem;
  color: var(--text-secondary);
  font-weight: 500;
}

.feature-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.feature-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
  line-height: 1.6;
}

.feature-list-icon {
  flex-shrink: 0;
  margin-top: 0.15rem;
  color: var(--accent);
}

.feature-list-icon svg {
  display: block;
}

/* ----- How it works ----- */
.steps-list {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: step;
}

.steps-list li {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1rem;
  counter-increment: step;
  line-height: 1.6;
}

.steps-list li:last-child {
  margin-bottom: 0;
}

.step-num {
  flex-shrink: 0;
  width: 1.75rem;
  height: 1.75rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--accent);
  background: var(--section-tint);
  border: 1px solid var(--divider);
  border-radius: 50%;
}

.step-text {
  padding-top: 0.1rem;
}

/* ----- Cards (conversion blocks) ----- */
.card {
  padding: 1.75rem;
  background: var(--section-tint);
  border: 1px solid var(--divider);
  border-radius: 14px;
}

.card h2 {
  margin-top: 0;
}

.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;
}

.conversion-anchor {
  position: absolute;
  pointer-events: none;
}

/* Conversion toggle (hidden when only waitlist — single purpose) */
.conversion-toggle {
  display: none;
}

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

.toggle-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  background: var(--bg);
  border: 1px solid var(--divider);
  border-radius: 8px;
  padding: 3px;
}

.toggle-label {
  flex: 1;
  min-width: 0;
  display: inline-block;
  padding: 0.5rem 1rem;
  font-size: 0.9375rem;
  font-weight: 500;
  text-align: center;
  cursor: pointer;
  border-radius: 6px;
  color: var(--text-secondary);
  transition: color 0.15s ease, background 0.15s ease;
}

.toggle-label:hover {
  color: var(--text);
}

.conversion-radio:focus-visible + .toggle-buttons .toggle-label,
.toggle-label:focus-within {
  outline: none;
}

#tab_join:checked ~ .toggle-buttons .toggle-label[for="tab_join"],
#tab_reserve:checked ~ .toggle-buttons .toggle-label[for="tab_reserve"] {
  background: var(--section-tint);
  color: var(--text);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}

.conversion-panel {
  margin-top: 0;
}

.conversion-panel[hidden] {
  display: none !important;
}

.panel-desc {
  margin: 0 0 1rem;
  color: var(--text);
}

.panel-helper {
  margin: 1rem 0 0;
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.card-helper {
  margin: 0 0 1.25rem;
  font-size: 0.9375rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* ----- Buttons ----- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.75rem; /* 44px */
  padding: 0.6rem 1.25rem;
  font-size: 1rem;
  font-weight: 500;
  text-decoration: none;
  text-align: center;
  border: 1px solid transparent;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.btn:focus {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.btn-primary:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
}

.btn-secondary {
  background: transparent;
  color: var(--accent);
  border-color: var(--accent);
}

.btn-secondary:hover {
  background: var(--accent);
  color: #fff;
}

/* ----- Forms ----- */
.join-form,
.reserve-form {
  margin-top: 1rem;
}

.join-form label,
.reserve-form label {
  display: block;
  margin-bottom: 0.35rem;
  font-weight: 500;
  font-size: 0.9375rem;
}

.join-form input[type="email"],
.reserve-form input[type="email"] {
  display: block;
  width: 100%;
  max-width: 20rem;
  min-height: 2.75rem;
  margin-bottom: 1rem;
  padding: 0.5rem 0.75rem;
  font-size: 1rem;
  border: 1px solid var(--divider);
  border-radius: 6px;
  background: var(--bg);
  color: var(--text);
}

.join-form input:focus,
.reserve-form input:focus {
  outline: 2px solid var(--accent);
  outline-offset: 0;
  border-color: var(--accent);
}

.success-message {
  margin: 1rem 0 0;
  color: var(--accent);
  font-weight: 500;
}

.error-message {
  margin: 0.75rem 0 0;
  color: var(--text);
  font-weight: 500;
  font-size: 0.9375rem;
}

/* ----- Footer ----- */
.site-footer {
  padding: 2.5rem 0;
  border-top: 1px solid var(--divider);
  background: var(--section-tint);
  color: var(--text-secondary);
  font-size: 0.9375rem;
  line-height: 1.6;
}

.site-footer p {
  margin: 0 0 0.5rem;
}

.site-footer p:last-child {
  margin-bottom: 0;
}

.footer-contact a {
  color: var(--accent);
  text-decoration: none;
}

.footer-contact a:hover {
  text-decoration: underline;
}

.footer-contact a:focus {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.footer-links {
  color: var(--text-muted);
}

.footer-links a {
  color: var(--accent);
  text-decoration: none;
}

.footer-links a:hover {
  text-decoration: underline;
}

.footer-links a:focus {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.footer-privacy {
  margin-top: 0.75rem;
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* ----- Legal pages ----- */
.legal-content .legal-meta {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-top: -0.25rem;
  margin-bottom: 1.25rem;
}

.legal-content h2 {
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
  font-size: 1.125rem;
  font-weight: 600;
}

.legal-content ul {
  margin: 0.5rem 0 1rem;
  padding-left: 1.25rem;
}

.legal-content li {
  margin-bottom: 0.25rem;
  line-height: 1.6;
}

.legal-content p {
  margin: 0 0 0.75rem;
  line-height: 1.6;
}

/* ----- Mobile ----- */
@media (max-width: 480px) {
  .hero-ctas {
    flex-direction: column;
  }

  .hero-ctas .btn {
    width: 100%;
  }

  .card-section .btn {
    width: 100%;
  }

  .page-container {
    padding: 0 1.25rem;
  }

  .card {
    padding: 1.25rem;
  }
}
