/* ============================================
   TERMS OF SERVICE PAGE STYLES
   File: public/assets/css/pages/terms/index.css
   --------------------------------------------
   - Dark, cinematic layout (matches Privacy page)
   - Legal / policy typography focus
   - Fully responsive (mobile-first)
   - Sticky sidebar on desktop for smooth scrolling
   - Hero image dimensions documented for easy replacement
============================================ */

/* ---------- PAGE SHELL ---------- */

/**
 * Root wrapper for static legal pages.
 *
 * Applied to:
 * <section class="static-page static-page-legal">
 */
.static-page.static-page-legal {
  min-height: 100vh;
  color: #e5e7eb; /* slate-200 */
  background: radial-gradient(
      circle at top,
      rgba(245, 158, 11, 0.16),
      transparent 55%
    ),
    radial-gradient(circle at bottom, rgba(15, 23, 42, 0.97), #020617);
  /* Smooth anchor scrolling for sidebar links */
  scroll-behavior: smooth;
}

/**
 * Inner layout container: sidebar + main content.
 *
 * On mobile:
 * - Single column (flex column)
 * On desktop:
 * - Row layout: sidebar (left) + content (right)
 */
.static-page-inner,
.static-legal-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 2.5rem 1.25rem 3.5rem;
  display: flex;
  flex-direction: column;
  gap: 2.25rem;
  box-sizing: border-box;
}

/* ============================================
   HERO
============================================ */

/**
 * Generic hero container.
 */
.static-hero {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid rgba(148, 163, 184, 0.26);
}

/**
 * Legal hero variant.
 *
 * Warm amber accent to visually separate it from the
 * Privacy page hero while keeping the same cinematic style.
 */
.static-hero--legal {
  background: radial-gradient(
      circle at top left,
      rgba(120, 53, 15, 0.6),
      transparent 55%
    ),
    radial-gradient(circle at bottom right, rgba(15, 23, 42, 0.95), #020617);
  box-shadow: 0 22px 60px rgba(15, 23, 42, 0.9);
}

/**
 * Hero media wrapper (contains the hero image).
 */
.static-hero-media {
  position: relative;
  max-height: 480px; /* recommended max hero height on large screens */
}

/**
 * HERO IMAGE ELEMENT
 * --------------------------------------------
 * Recommended source image sizes:
 * - Desktop: 1440 x 480 px
 * - Tablet : 1024 x 380 px
 * - Mobile :  768 x 320 px (crop from center)
 */
.static-hero-img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
}

/**
 * Dark gradient overlay over the hero image.
 * Fades the image into the page background.
 */
.static-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(2, 6, 23, 0.35),
    rgba(2, 6, 23, 0.98)
  );
  display: flex;
  align-items: flex-end;
}

/**
 * Hero content container.
 * Constrains text width for better readability.
 */
.static-hero-inner {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 3.25rem 1.25rem 2.75rem;
}

/**
 * Legal-specific hero content tweak.
 * Slightly narrower for a “document” feel.
 */
.static-hero-inner--legal {
  max-width: 960px;
}

/**
 * Small pill above main title ("Legal").
 */
.static-hero-kicker {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.8rem;
  border-radius: 999px;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(245, 158, 11, 0.9); /* amber accent */
  color: #fed7aa; /* warm highlight */
  margin-bottom: 0.8rem;
}

/**
 * Main hero title ("Terms & Conditions").
 */
.static-hero-title {
  font-family: Poppins, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  font-size: 1.9rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 0.55rem;
}

/**
 * Hero subtitle paragraph.
 */
.static-hero-subtitle {
  font-size: 0.95rem;
  line-height: 1.7;
  color: #e5e7eb;
  max-width: 40rem;
}

/* ============================================
   LAYOUT: SIDEBAR + MAIN CONTENT
============================================ */

/**
 * Sidebar column:
 * - "On this page" navigation
 * - "Last updated" block
 *
 * On mobile, we show the main content first (order set below),
 * then the sidebar. On desktop, they sit side-by-side and the
 * sidebar becomes sticky, similar to the Privacy page behavior.
 */
.static-legal-sidebar {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  order: 2; /* sidebar under content on small screens */
}

/**
 * Main legal document container.
 */
.static-legal-main {
  flex: 1 1 auto;
  background: rgba(15, 23, 42, 0.96);
  border-radius: 1.1rem;
  border: 1px solid rgba(148, 163, 184, 0.55);
  box-shadow: 0 22px 55px rgba(0, 0, 0, 0.85);
  padding: 1.5rem 1.25rem 1.9rem;
  order: 1; /* main content above sidebar on small screens */
}

/**
 * Individual legal section.
 */
.static-legal-section {
  margin-bottom: 1.8rem;
  padding-bottom: 1.1rem;
  border-bottom: 1px solid rgba(30, 64, 175, 0.26);
}

/**
 * Remove bottom border for last section block.
 */
.static-legal-section:last-of-type {
  margin-bottom: 0;
  border-bottom: none;
}

/**
 * Contact section modifier, gives a small spacing bump.
 */
.static-legal-section--contact {
  margin-top: 0.8rem;
}

/* ============================================
   SIDEBAR NAVIGATION
============================================ */

/**
 * Sidebar navigation card.
 * Becomes sticky on desktop via .static-legal-sidebar.
 */
.static-legal-nav {
  background: rgba(15, 23, 42, 0.96);
  border-radius: 0.9rem;
  border: 1px solid rgba(148, 163, 184, 0.5);
  padding: 1rem 1rem 1.1rem;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.75);
}

/**
 * "On this page" label above sidebar list.
 */
.static-legal-nav-title {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: #9ca3af;
  margin-bottom: 0.6rem;
}

/**
 * Sidebar list reset.
 */
.static-legal-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

/**
 * Space between sidebar items.
 */
.static-legal-nav li + li {
  margin-top: 0.25rem;
}

/**
 * Sidebar nav links (anchors to sections).
 */
.static-legal-nav a {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.82rem;
  line-height: 1.5;
  color: #cbd5e1;
  text-decoration: none;
  padding: 0.25rem 0.15rem;
  border-radius: 0.45rem;
  transition: background-color 0.15s ease, color 0.15s ease,
    transform 0.12s ease, padding-left 0.12s ease;
}

/**
 * Small bullet icon before each sidebar link.
 */
.static-legal-nav a::before {
  content: "•";
  font-size: 0.85rem;
  color: #facc15; /* warm bullet */
  transform: translateY(-0.03rem);
}

.static-legal-nav a:hover,
.static-legal-nav a:focus-visible {
  background-color: rgba(15, 23, 42, 0.9);
  color: #f9fafb;
  padding-left: 0.3rem;
  transform: translateX(1px);
}

/**
 * "Last updated" block below the navigation.
 */
.static-legal-update {
  padding: 0.7rem 0.9rem;
  border-radius: 0.75rem;
  border: 1px dashed rgba(148, 163, 184, 0.7);
  background: radial-gradient(
    circle at top left,
    rgba(30, 64, 175, 0.22),
    rgba(15, 23, 42, 0.98)
  );
  font-size: 0.78rem;
  line-height: 1.7;
}

.static-legal-update-label {
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: #9ca3af;
  margin-bottom: 0.25rem;
}

.static-legal-update-date {
  font-size: 0.88rem;
  font-weight: 500;
  color: #e5e7eb;
}

/* ============================================
   TYPOGRAPHY (HEADINGS / TEXT / LISTS)
============================================ */

/**
 * Section titles (H2).
 */
.static-legal-section h2 {
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 0.5rem;
}

/**
 * Sub-headings (H3).
 */
.static-legal-section h3 {
  font-size: 0.95rem;
  font-weight: 500;
  margin-top: 0.9rem;
  margin-bottom: 0.35rem;
}

/**
 * Body copy paragraphs.
 */
.static-legal-section p {
  font-size: 0.9rem;
  line-height: 1.8;
  color: #e5e7eb;
  margin-bottom: 0.75rem;
}

/**
 * Unordered and ordered lists inside sections.
 */
.static-legal-section ul,
.static-legal-section ol {
  margin: 0.4rem 0 0.9rem 0;
  padding-left: 1.05rem;
}

.static-legal-section ul {
  list-style: disc;
}

.static-legal-section ol {
  list-style: decimal;
}

/**
 * Optional compact custom bullet style
 * (ready if you want tighter lists later).
 */
.static-legal-section ul.static-legal-list-compact {
  list-style: none;
  padding-left: 0;
}

.static-legal-section ul.static-legal-list-compact li {
  position: relative;
  padding-left: 1.25rem;
  margin-bottom: 0.45rem;
  font-size: 0.9rem;
  line-height: 1.7;
}

.static-legal-section ul.static-legal-list-compact li::before {
  content: "";
  position: absolute;
  left: 0.35rem;
  top: 0.55rem;
  width: 0.33rem;
  height: 0.33rem;
  border-radius: 999px;
  background: linear-gradient(135deg, #f5b200, #f97316);
}

/**
 * Strong emphasis inside text.
 */
.static-legal-section strong {
  font-weight: 600;
}

/* ============================================
   LINKS (GLOBAL FOR LEGAL PAGE)
============================================ */

.static-page-legal a {
  color: #93c5fd; /* blue-300 */
  text-decoration: none;
}

.static-page-legal a:hover {
  text-decoration: underline;
}

/* ============================================
   RESPONSIVE BREAKPOINTS
============================================ */

/* ≥ 640px (small tablets) */
@media (min-width: 640px) {
  .static-hero-inner {
    padding: 3.9rem 1.6rem 3rem;
  }

  .static-hero-title {
    font-size: 2.1rem;
  }

  .static-hero-subtitle {
    font-size: 1rem;
  }

  .static-legal-main {
    padding: 1.7rem 1.5rem 2rem;
  }
}

/* ≥ 768px (tablets / small laptops) */
@media (min-width: 768px) {
  .static-hero-inner {
    padding-left: 0;
    padding-right: 0;
  }

  .static-page-inner,
  .static-legal-inner {
    padding-top: 3rem;
    padding-bottom: 4rem;
  }

  .static-hero-title {
    font-size: 2.3rem;
  }

  .static-legal-section p {
    font-size: 0.92rem;
  }
}

/* ≥ 1024px (desktops) */
@media (min-width: 1024px) {
  /* Switch to side-by-side layout */
  .static-page-inner,
  .static-legal-inner {
    flex-direction: row;
    align-items: flex-start;
    gap: 2.5rem;
    padding-left: 0;
    padding-right: 0;
  }

  /* Sticky sidebar similar to Privacy page scrolling behavior */
  .static-legal-sidebar {
    position: sticky;
    top: 96px; /* sits below main site header */
    max-width: 260px;
    order: 0;
  }

  .static-legal-main {
    order: 1;
  }

  .static-hero-title {
    font-size: 2.5rem;
  }

  .static-hero-subtitle {
    font-size: 1.03rem;
  }
}

/* ≥ 1280px (large desktops) */
@media (min-width: 1280px) {
  .static-hero-inner {
    max-width: 1120px;
  }

  .static-page-inner,
  .static-legal-inner {
    max-width: 1160px;
  }
}
