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

:root {
  --bg-page: #f9fafb;
  --bg-card: #ffffff;
  --bg-topbar: #e5e7eb;
  --border-subtle: #e5e7eb;
  --text-main: #111827;
  --text-muted: #6b7280;
  --accent: #2563eb;
  --accent-dark: #1d4ed8;
}

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

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

a:hover {
  text-decoration: underline;
}

.page-container {
  max-width: 900px;
  margin: 0 auto;
  padding: 2rem 1.5rem 3rem;
}

@media (min-width: 960px) {
  .page-container {
    padding: 3rem 2rem 4rem;
  }
}

/* Top bar for variant pages */
.topbar {
  background-color: var(--bg-topbar);
  border-bottom: 1px solid #d1d5db;
  padding: 0.75rem 1rem;
  text-align: center;
  font-size: 0.95rem;
}

/* Hub (index) page */
.intro-header h1 {
  font-size: 2rem;
  margin: 0 0 0.75rem;
}

.intro-header p {
  margin: 0;
  max-width: 46rem;
  color: var(--text-muted);
}

.variants-grid {
  margin-top: 2.25rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1.5rem;
}

.variant-card {
  background-color: var(--bg-card);
  border-radius: 0.9rem;
  padding: 1.5rem 1.4rem;
  border: 1px solid var(--border-subtle);
  box-shadow: 0 14px 35px rgba(15, 23, 42, 0.06);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.variant-card h2 {
  font-size: 1.15rem;
  margin: 0 0 0.5rem;
}

.variant-card p {
  margin: 0;
  color: var(--text-muted);
}

.card-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 1.1rem;
  padding: 0.55rem 1.15rem;
  border-radius: 999px;
  background-color: var(--accent);
  color: #ffffff;
  font-size: 0.9rem;
  font-weight: 500;
  text-decoration: none;
  transition: background-color 0.16s ease, transform 0.16s ease, box-shadow 0.16s ease;
  box-shadow: 0 10px 20px rgba(37, 99, 235, 0.28);
}

.card-link:hover {
  background-color: var(--accent-dark);
  transform: translateY(-1px);
  text-decoration: none;
}

.card-link:active {
  transform: translateY(0);
  box-shadow: 0 6px 12px rgba(37, 99, 235, 0.25);
}

/* Variant inner pages */
.page-header h1 {
  margin: 0 0 0.75rem;
  font-size: 1.8rem;
}

.lead {
  margin: 0;
  color: var(--text-muted);
  max-width: 44rem;
}

.hero {
  margin-top: 2rem;
  margin-bottom: 2.25rem;
  background-color: var(--bg-card);
  border-radius: 0.9rem;
  border: 1px solid var(--border-subtle);
  padding: 1.75rem 1.5rem 1.7rem;
  box-shadow: 0 14px 40px rgba(15, 23, 42, 0.05);
}

.hero h2 {
  margin: 0 0 0.75rem;
  font-size: 1.4rem;
}

.hero p {
  margin: 0 0 1.2rem;
  color: var(--text-muted);
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.55rem 1.4rem;
  border-radius: 999px;
  border: none;
  background-color: var(--accent);
  color: #ffffff;
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.16s ease, transform 0.16s ease, box-shadow 0.16s ease;
  box-shadow: 0 10px 20px rgba(37, 99, 235, 0.28);
}

.btn-primary:hover {
  background-color: var(--accent-dark);
  transform: translateY(-1px);
}

.btn-primary:active {
  transform: translateY(0);
  box-shadow: 0 6px 12px rgba(37, 99, 235, 0.25);
}

.content-section {
  margin-top: 2.5rem;
  display: grid;
  gap: 1.8rem;
}

.content-block h3 {
  margin: 0 0 0.4rem;
  font-size: 1.1rem;
}

.content-block p {
  margin: 0;
  color: var(--text-muted);
}

.site-footer,
.page-footer {
  margin-top: 2.5rem;
  border-top: 1px solid var(--border-subtle);
  padding-top: 1.5rem;
}

.hint,
.page-footer p {
  margin: 0;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.logout-wrapper {
  margin-top: 1.75rem;
  text-align: center;
}

.logout-link {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.logout-link:hover {
  color: var(--text-main);
}
