/* Shared hub layout for Discovering Da Vinci secondary index pages */

.hub-page {
  position: relative;
  background:
    radial-gradient(circle at 10% 0%, rgba(205, 163, 73, 0.14), transparent 26%),
    radial-gradient(circle at 90% 12%, rgba(143, 106, 45, 0.12), transparent 30%),
    linear-gradient(180deg, #090b0e 0%, #0b0d11 40%, #090a0d 100%);
  color: var(--color-text-primary);
}

.hub-page::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.02), transparent 30%),
    repeating-linear-gradient(
      90deg,
      transparent 0,
      transparent 63px,
      rgba(255, 255, 255, 0.015) 64px
    );
  opacity: 0.35;
}

.hub-shell {
  position: relative;
  z-index: 1;
  max-width: 1320px;
  margin: 0 auto;
  padding: 1.9rem 1.25rem 4rem;
}

.hub-crumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin: 0 0 1.2rem;
  font-family: var(--font-ui);
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  color: var(--color-text-secondary);
}

.hub-crumb a {
  color: var(--color-accent-secondary);
  text-decoration: none;
}

.hub-crumb strong {
  color: var(--color-text-primary);
}

.hub-crumb a:hover,
.hub-crumb a:focus-visible {
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

.hub-hero {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(205, 163, 73, 0.28);
  border-radius: 24px;
  background:
    radial-gradient(circle at top right, rgba(205, 163, 73, 0.16), transparent 32%),
    linear-gradient(145deg, rgba(23, 28, 37, 0.98), rgba(12, 15, 20, 0.98));
  padding: clamp(1.3rem, 2vw, 2rem);
  box-shadow: 0 22px 50px rgba(0, 0, 0, 0.34);
  margin-bottom: 1.2rem;
}

.hub-hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(205, 163, 73, 0.56), transparent);
}

.hub-kicker {
  margin: 0;
  color: var(--color-accent-secondary);
  text-transform: uppercase;
  letter-spacing: 0.2em;
  font-size: 0.75rem;
  font-family: var(--font-ui);
}

.hub-title {
  margin: 0.35rem 0 0.7rem;
  font-size: clamp(2.1rem, 4vw, 4rem);
  line-height: 1.04;
  text-wrap: balance;
  max-width: 16ch;
}

.hub-lead {
  margin: 0;
  max-width: 72ch;
  color: var(--color-text-secondary);
  line-height: 1.72;
  font-size: 1.03rem;
}

.hub-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.58rem;
  margin-top: 1.15rem;
}

.hub-pill {
  border: 1px solid rgba(205, 163, 73, 0.24);
  border-radius: 999px;
  padding: 0.48rem 0.82rem;
  background: rgba(255, 255, 255, 0.035);
  font-family: var(--font-ui);
  font-size: 0.72rem;
  color: var(--color-text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.hub-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}

.hub-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 0.95rem;
}

.hub-header {
  margin-bottom: 1.4rem;
}

.hub-header .hub-title {
  margin-bottom: 0.5rem;
}

.hub-subtitle {
  color: var(--color-text-secondary);
  font-size: 0.98rem;
  line-height: 1.7;
  max-width: 80ch;
  margin: 0;
}

.hub-subtitle a {
  color: var(--color-accent-secondary);
  text-decoration: none;
}

.hub-subtitle a:hover,
.hub-subtitle a:focus-visible {
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

.hub-footer {
  margin-top: 2.2rem;
  padding-top: 1.2rem;
  border-top: 1px solid rgba(205, 163, 73, 0.14);
  font-family: var(--font-ui);
  font-size: 0.82rem;
  color: var(--color-text-tertiary);
}

.hub-footer a {
  color: var(--color-accent-secondary);
  text-decoration: none;
}

.hub-footer a:hover,
.hub-footer a:focus-visible {
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

.hub-card {
  position: relative;
  overflow: hidden;
  min-height: 100%;
  border: 1px solid rgba(205, 163, 73, 0.14);
  border-radius: 20px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.015)),
    linear-gradient(145deg, rgba(22, 27, 35, 0.98), rgba(15, 18, 24, 0.98));
  padding: 1.15rem;
  display: grid;
  gap: 0.62rem;
  color: var(--color-text-primary);
  text-decoration: none;
  box-shadow: 0 12px 26px rgba(0, 0, 0, 0.2);
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background 180ms ease,
    box-shadow 180ms ease;
}

.hub-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: linear-gradient(180deg, rgba(205, 163, 73, 0.88), rgba(205, 163, 73, 0));
  opacity: 0.7;
}

.hub-card:hover,
.hub-card:focus-visible {
  transform: translateY(-3px);
  border-color: rgba(205, 163, 73, 0.34);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.hub-card--featured {
  border-color: rgba(205, 163, 73, 0.28);
  background:
    radial-gradient(circle at top right, rgba(205, 163, 73, 0.18), transparent 36%),
    linear-gradient(145deg, rgba(34, 29, 17, 0.9), rgba(18, 20, 25, 0.98));
}

.hub-card--featured:hover,
.hub-card--featured:focus-visible {
  border-color: rgba(205, 163, 73, 0.52);
}

.hub-card__kicker {
  font-family: var(--font-ui);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-accent-secondary);
}

.hub-card__title {
  font-family: var(--font-display);
  font-size: 1.2rem;
  color: var(--color-text-primary);
  font-weight: 600;
  line-height: 1.2;
}

.hub-card__meta {
  font-family: var(--font-ui);
  font-size: 0.88rem;
  color: var(--color-text-secondary);
  line-height: 1.6;
}

.hub-card h2,
.hub-card h3 {
  margin: 0;
  font-size: 1.15rem;
  line-height: 1.2;
}

.hub-card p {
  margin: 0;
  color: var(--color-text-secondary);
  font-size: 0.96rem;
  line-height: 1.62;
}

.hub-card ul,
.hub-card ol {
  margin: 0;
  padding-left: 1.1rem;
  display: grid;
  gap: 0.42rem;
}

.hub-card li {
  color: var(--color-text-secondary);
  font-size: 0.92rem;
  line-height: 1.58;
}

.hub-card a {
  color: var(--color-accent-secondary);
  text-decoration: none;
}

.hub-card a:hover,
.hub-card a:focus-visible {
  text-decoration: underline;
  text-underline-offset: 0.16em;
}

.hub-section {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(205, 163, 73, 0.12);
  border-radius: 22px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(255, 255, 255, 0.01)),
    linear-gradient(145deg, rgba(16, 20, 26, 0.97), rgba(11, 14, 18, 0.98));
  padding: 1.25rem 1.3rem;
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.22);
}

.hub-section::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: linear-gradient(180deg, rgba(205, 163, 73, 0.78), rgba(205, 163, 73, 0));
}

.hub-section > * + * {
  margin-top: 0.95rem;
}

.hub-section > * + h2 {
  margin-top: 1.5rem;
}

.hub-section > h2:first-child {
  margin-top: 0;
}

.hub-section h2 {
  margin: 0;
  font-size: 1.15rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: #f0ddb1;
}

.hub-section h3 {
  margin: 0;
  font-size: 1rem;
  color: var(--color-text-primary);
}

.hub-section p {
  margin: 0;
  color: var(--color-text-secondary);
  line-height: 1.72;
  font-size: 1rem;
}

.hub-section a {
  color: var(--color-accent-secondary);
  text-decoration: none;
}

.hub-section a:hover,
.hub-section a:focus-visible {
  text-decoration: underline;
  text-underline-offset: 0.16em;
}

.hub-section ul,
.hub-section ol {
  margin: 0;
  padding-left: 1.15rem;
  display: grid;
  gap: 0.52rem;
}

.hub-section li {
  color: var(--color-text-secondary);
  line-height: 1.65;
}

.hub-list {
  margin: 0;
  padding-left: 1.1rem;
  display: grid;
  gap: 0.46rem;
}

.hub-list li {
  color: var(--color-text-secondary);
  line-height: 1.62;
}

.hub-table-wrap {
  overflow-x: auto;
  border: 1px solid rgba(205, 163, 73, 0.12);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.02);
}

.hub-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 560px;
}

.hub-table th,
.hub-table td {
  border-bottom: 1px solid rgba(205, 163, 73, 0.1);
  text-align: left;
  padding: 0.8rem 0.9rem;
  font-size: 0.9rem;
  vertical-align: top;
}

.hub-table th {
  background: rgba(255, 255, 255, 0.03);
  color: var(--color-text-primary);
  font-family: var(--font-ui);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.hub-table td {
  color: var(--color-text-secondary);
}

.hub-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.72rem;
  margin-top: 1.25rem;
  padding: 0.8rem;
  border: 1px solid rgba(205, 163, 73, 0.16);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.02)),
    linear-gradient(145deg, rgba(17, 21, 27, 0.98), rgba(12, 15, 20, 0.98));
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.22);
}

.hub-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border: 1px solid rgba(205, 163, 73, 0.18);
  background: rgba(255, 255, 255, 0.03);
  color: var(--color-text-primary);
  border-radius: 12px;
  text-decoration: none;
  font-family: var(--font-ui);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.72rem;
  padding: 0.74rem 1rem;
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    background 160ms ease,
    box-shadow 160ms ease;
  appearance: none;
  cursor: pointer;
}

.hub-actions > .hub-btn:first-child {
  background: linear-gradient(135deg, rgba(205, 163, 73, 0.24), rgba(205, 163, 73, 0.1));
  border-color: rgba(205, 163, 73, 0.34);
  color: #faebc7;
}

.hub-btn:hover,
.hub-btn:focus-visible {
  transform: translateY(-1px);
  border-color: rgba(205, 163, 73, 0.42);
  background: rgba(205, 163, 73, 0.12);
  box-shadow: 0 12px 20px rgba(0, 0, 0, 0.18);
}

.hub-btn:focus-visible,
.hub-card:focus-visible {
  outline: 2px solid rgba(227, 192, 108, 0.9);
  outline-offset: 2px;
}

@media (max-width: 900px) {
  .hub-shell {
    padding: 1.25rem 0.88rem 2.6rem;
  }

  .hub-hero,
  .hub-section {
    border-radius: 18px;
  }
}

@media (max-width: 640px) {
  .hub-title {
    max-width: none;
  }

  .hub-grid {
    grid-template-columns: 1fr;
  }

  .hub-actions > * {
    width: 100%;
  }
}

[data-theme="light"] .hub-page {
  background:
    radial-gradient(circle at 10% 0%, rgba(139, 105, 20, 0.1), transparent 26%),
    radial-gradient(circle at 90% 12%, rgba(171, 136, 81, 0.08), transparent 30%),
    linear-gradient(180deg, #f7f2e8 0%, #f4ecde 40%, #efe6d6 100%);
}

[data-theme="light"] .hub-page::before {
  opacity: 0.18;
}

[data-theme="light"] .hub-hero {
  border-color: rgba(139, 105, 20, 0.18);
  background:
    radial-gradient(circle at top right, rgba(139, 105, 20, 0.12), transparent 32%),
    linear-gradient(145deg, rgba(255, 251, 243, 0.98), rgba(247, 240, 227, 0.98));
  box-shadow: 0 14px 28px rgba(66, 47, 12, 0.08);
}

[data-theme="light"] .hub-pill {
  border-color: rgba(139, 105, 20, 0.18);
  background: rgba(139, 105, 20, 0.04);
}

[data-theme="light"] .hub-footer {
  border-top-color: rgba(139, 105, 20, 0.16);
}

[data-theme="light"] .hub-card {
  border-color: rgba(139, 105, 20, 0.14);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(255, 255, 255, 0.96)),
    linear-gradient(145deg, rgba(255, 251, 243, 0.98), rgba(247, 240, 227, 0.98));
  box-shadow: 0 10px 22px rgba(66, 47, 12, 0.08);
}

[data-theme="light"] .hub-card--featured {
  background:
    radial-gradient(circle at top right, rgba(139, 105, 20, 0.12), transparent 36%),
    linear-gradient(145deg, rgba(255, 249, 237, 0.98), rgba(249, 241, 226, 0.98));
}

[data-theme="light"] .hub-section {
  border-color: rgba(139, 105, 20, 0.12);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0.92)),
    linear-gradient(145deg, rgba(251, 246, 236, 0.98), rgba(245, 237, 223, 0.98));
  box-shadow: 0 12px 24px rgba(66, 47, 12, 0.06);
}

[data-theme="light"] .hub-section h2 {
  color: #7a5a12;
}

[data-theme="light"] .hub-table-wrap {
  border-color: rgba(139, 105, 20, 0.12);
  background: rgba(255, 255, 255, 0.65);
}

[data-theme="light"] .hub-table th,
[data-theme="light"] .hub-table td {
  border-bottom-color: rgba(139, 105, 20, 0.1);
}

[data-theme="light"] .hub-table th {
  background: rgba(139, 105, 20, 0.06);
}

[data-theme="light"] .hub-actions {
  border-color: rgba(139, 105, 20, 0.14);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.84), rgba(255, 255, 255, 0.94)),
    linear-gradient(145deg, rgba(251, 246, 236, 0.98), rgba(244, 235, 221, 0.98));
  box-shadow: 0 16px 30px rgba(66, 47, 12, 0.08);
}

[data-theme="light"] .hub-btn {
  border-color: rgba(139, 105, 20, 0.16);
  background: rgba(139, 105, 20, 0.05);
  color: var(--color-text-primary);
}

[data-theme="light"] .hub-actions > .hub-btn:first-child {
  background: linear-gradient(135deg, rgba(139, 105, 20, 0.16), rgba(139, 105, 20, 0.08));
  color: #503b0d;
}

[data-theme="light"] .hub-btn:hover,
[data-theme="light"] .hub-btn:focus-visible {
  background: rgba(139, 105, 20, 0.12);
}

/* Quote Explorer */
.quote-card { border: 1px solid #1e1e1e; border-radius: 10px; background: #0f0f0f; padding: 1.2rem 1.4rem 1rem; display: flex; flex-direction: column; transition: border-color 200ms; }
.quote-card:hover { border-color: rgba(212, 175, 55, 0.25); }
.quote-text { font-family: var(--font-body); font-size: 1.04rem; line-height: 1.76; font-style: italic; color: var(--color-text-primary); flex: 1; margin: 0 0 1rem; }
.quote-source { font-family: var(--font-ui); font-size: 0.71rem; color: var(--color-accent-primary); letter-spacing: 0.08em; text-transform: uppercase; }
.quote-filters { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 1.6rem 0 1.2rem; }
.quote-filter-btn { border: 1px solid #333; background: transparent; color: #888; border-radius: 999px; padding: 0.35rem 1rem; font-family: var(--font-ui); font-size: 0.76rem; letter-spacing: 0.06em; cursor: pointer; transition: border-color 150ms, color 150ms; }
.quote-filter-btn:hover { border-color: #555; color: #bbb; }
.quote-filter-btn.active { border-color: var(--color-accent-primary); color: var(--color-accent-primary); }

/* Geographic Map */
.map-shell { display: grid; grid-template-columns: 1fr 360px; gap: 0; border: 1px solid #1a1a1a; border-radius: 10px; overflow: hidden; min-height: 520px; }
.map-marker { cursor: pointer; transition: transform 150ms; }
.map-marker:hover { transform: scale(1.3); }
.map-panel { background: #0e0e0e; border-left: 1px solid #1a1a1a; padding: 1.5rem; overflow-y: auto; }
.map-panel__title { font-family: var(--font-display); color: var(--color-text-primary); font-size: 1.25rem; margin-bottom: 0.25rem; }
.map-panel__dates { font-family: var(--font-ui); font-size: 0.72rem; color: var(--color-accent-primary); letter-spacing: 0.1em; text-transform: uppercase; margin-bottom: 1rem; }
