/* ================================================
   sqla-authz docs — Brand color overrides
   Only override what Zensical doesn't handle.
   ================================================ */

/* ----- Custom primary color (light mode) ----- */
:root > * {
  --md-primary-fg-color:        #7c3aed;
  --md-primary-fg-color--light: #8b5cf6;
  --md-primary-fg-color--dark:  #6d28d9;
}

/* ----- Custom primary color (dark mode) ----- */
[data-md-color-scheme="slate"] {
  --md-hue: 263;
  --md-primary-fg-color:        #8b5cf6;
  --md-primary-fg-color--light: #a78bfa;
  --md-primary-fg-color--dark:  #7c3aed;
}

/* ----- Hero section (landing page only) ----- */
.hero {
  text-align: center;
  padding: 3.5rem 1rem 2.5rem;
  margin: -0.6rem -0.6rem 0;
  background: radial-gradient(ellipse at 50% 0%, #f5f3ff 0%, transparent 70%);
}

[data-md-color-scheme="slate"] .hero {
  background: radial-gradient(ellipse at 50% 0%, rgba(139, 92, 246, .08) 0%, transparent 70%);
}

.hero-icon {
  width: 96px;
  height: 96px;
  border-radius: 20px;
  margin-bottom: 1.25rem;
  box-shadow:
    0 4px 6px -1px rgba(124, 58, 237, .1),
    0 10px 20px -2px rgba(124, 58, 237, .08);
  transition: transform .2s ease, box-shadow .2s ease;
}

.hero-icon:hover {
  transform: translateY(-2px);
  box-shadow:
    0 8px 12px -2px rgba(124, 58, 237, .15),
    0 16px 32px -4px rgba(124, 58, 237, .12);
}

.hero h1 {
  font-size: 2.8rem;
  font-weight: 700;
  line-height: 1.15;
  margin-bottom: 1rem;
  letter-spacing: -0.025em;
  background: linear-gradient(135deg, #7c3aed, #5b21b6);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero h1 .headerlink {
  display: none;
}

[data-md-color-scheme="slate"] .hero h1 {
  background: linear-gradient(135deg, #a78bfa, #8b5cf6);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero > p {
  font-size: 1.2rem;
  opacity: 0.75;
  max-width: 600px;
  margin: 0 auto 1.75rem;
  line-height: 1.6;
}

.hero-install {
  display: inline-block;
  text-align: center;
}

.hero-install .highlight {
  display: inline-block;
  min-width: 300px;
  margin-bottom: 0.5rem;
  border-radius: 8px;
  overflow: hidden;
}

.hero-install p {
  margin: 0;
}

/* Hide page title on landing page (shown in hero) */
.md-content__inner > h1:first-child {
  display: none;
}

/* ----- Cards: subtle hover polish ----- */
.md-typeset .grid.cards > ul > li,
.md-typeset .grid.cards > ol > li {
  border-radius: 12px;
  transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}

.md-typeset .grid.cards > ul > li:hover,
.md-typeset .grid.cards > ol > li:hover {
  border-color: var(--md-primary-fg-color--light);
  box-shadow: 0 4px 16px rgba(124, 58, 237, .08);
  transform: translateY(-2px);
}

[data-md-color-scheme="slate"] .md-typeset .grid.cards > ul > li:hover,
[data-md-color-scheme="slate"] .md-typeset .grid.cards > ol > li:hover {
  border-color: rgba(139, 92, 246, .25);
  box-shadow: 0 4px 16px rgba(139, 92, 246, .12);
}

/* ----- Quick links grid: 2x2 for 4 items ----- */
.md-typeset h2#quick-links ~ .grid.cards {
  grid-template-columns: repeat(2, 1fr) !important;
}

/* ----- Responsive ----- */
@media (max-width: 76.25em) {
  .hero h1 {
    font-size: 2.2rem;
  }
}

@media (max-width: 44.9375em) {
  .hero h1 {
    font-size: 1.8rem;
  }

  .hero > p {
    font-size: 1.05rem;
  }

  .hero-install .highlight {
    min-width: auto;
  }

  .md-typeset h2#quick-links ~ .grid.cards {
    grid-template-columns: 1fr !important;
  }
}
