/**
 * Custom Styles
 * This file contains project-specific styles.
 * Bootstrap utilities are preferred; use custom CSS sparingly.
 */

/* ============================================
   CSS Custom Properties (Design Tokens)
   Modern shadcn-inspired design system
   ============================================ */

@import url("header.css");
@import url("footer.css");

:root {
  /* Colors - shadcn inspired palette */
  --custom-accent: #6366f1;
  --custom-accent-light: #818cf8;
  --custom-accent-dark: #4f46e5;

  /* Brand colors */
  --brand-color: #f04e23;
  --brand-color-rgb: 240 78 35;
  --brand-color-dark: #d74721;
  --brand-color-darker: #c33f1c;
  --brand-dark-color: #132a40;
  --brand-darker-color: #0e2032;
  --brand-darker-color-rgb: 14 32 50;
  --brand-border-dark-color: #1e334a;

  /* Neutral colors */
  --color-background: #fff;
  --color-foreground: #09090b;
  --color-muted: #f4f4f5;
  --color-muted-foreground: #71717a;
  --color-border: #e4e4e7;

  /* Animation durations */
  --animation-duration-fast: 200ms;
  --animation-duration-normal: 400ms;
  --animation-duration-slow: 600ms;

  /* Shadows - softer, more subtle */
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 5%);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 10%), 0 2px 4px -1px rgb(0 0 0 / 6%);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 10%), 0 4px 6px -2px rgb(0 0 0 / 5%);
  --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 10%), 0 10px 10px -5px rgb(0 0 0 / 4%);

  /* Spacing - Tailwind-like scale */
  --spacing-xs: 0.5rem; /* 8px */
  --spacing-sm: 0.75rem; /* 12px */
  --spacing-md: 1rem; /* 16px */
  --spacing-lg: 1.5rem; /* 24px */
  --spacing-xl: 2rem; /* 32px */
  --spacing-2xl: 3rem; /* 48px */
  --spacing-3xl: 4rem; /* 64px */
  --spacing-4xl: 6rem; /* 96px */

  /* Border radius */
  --radius-sm: 0.375rem; /* 6px */
  --radius-md: 0.5rem; /* 8px */
  --radius-lg: 0.75rem; /* 12px */
  --radius-xl: 1rem; /* 16px */
}

/* ============================================
   Global Styles
   ============================================ */

/* Smooth scrolling for anchor links */
html {
  scroll-behavior: smooth;
}

/* Ensure footer stays at bottom */
body {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  font-family: Inter, sans-serif;
}

main {
  flex: 1;
}

a {
  text-decoration: none;
}

.page-hero {
  position: relative;
  height: clamp(270px, 34vw, 440px);
  overflow: hidden;
  color: var(--bs-white);
  background: var(--brand-darker-color);
}

.page-hero__image,
.page-hero__overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.page-hero__image {
  object-fit: cover;
}

.page-hero__overlay {
  background: linear-gradient(
    90deg,
    rgb(var(--brand-darker-color-rgb) / 94%),
    rgb(var(--brand-darker-color-rgb) / 42%) 55%,
    rgb(var(--brand-darker-color-rgb) / 10%)
  );
}

.page-hero .container-md {
  height: 100%;
}

.page-hero__content {
  display: flex;
  width: min(470px, 90%);
  height: 100%;
  flex-direction: column;
  justify-content: center;
}

.page-hero h1 {
  margin: 0 0 0.7rem;
  font-size: 4rem;
  font-weight: 650;
  line-height: 100%;
  letter-spacing: -0.045em;
}

.page-hero p {
  margin: 0;
  color: rgb(255 255 255 / 82%);
  line-height: 150%;
}

.page-hero__line {
  display: none;
  width: 54px;
  height: 4px;
  background: var(--brand-color);
}

.page-cta {
  background: var(--bs-white);
}

.page-cta__panel {
  position: relative;
  overflow: hidden;
  display: flex;
  gap: 2rem;
  align-items: center;
  justify-content: space-between;
  padding: 44px;
  color: var(--bs-white);
  border-radius: var(--radius-md);
  background-color: var(--brand-dark-color);
  background-size:
    auto,
    24px 24px,
    24px 24px;
}

.page-cta__content {
  display: flex;
  gap: 1.25rem;
  align-items: center;
}

.inner-page-cta .page-cta__content {
  min-width: 0;
}

.page-cta__symbol {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 58px;
  color: var(--brand-dark-color);
  font-size: 1.75rem;
  background: var(--bs-white);
  border-radius: 50%;
}

.page-cta h2 {
  margin: 0 0 0.45rem;
  font-size: 2rem;
  line-height: 1.2;
  letter-spacing: 0.015em;
}

.page-cta p {
  margin: 0;
  color: rgb(255 255 255 / 68%);
  font-size: 0.875rem;
  line-height: 1.6;
}

.page-cta p a {
  color: var(--bs-white);
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.page-cta a:focus-visible {
  outline: 3px solid var(--bs-white);
  outline-offset: 4px;
}

.inner-page-cta .btn-brand-solid {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  flex: 0 0 auto;
  width: auto;
  max-width: 100%;
  padding: 0.8rem 1.25rem;
  font-size: 1rem;
  line-height: 1.25;
  white-space: nowrap;
}

.inner-page-cta .btn-brand-solid i {
  flex: 0 0 auto;
  font-size: 1.2em;
  line-height: 1;
}

/* Utility spacing classes */
.py-6 {
  padding-top: 5rem !important;
  padding-bottom: 5rem !important;
}

.section-subtitle {
  color: var(--brand-color);
  font-size: 0.6875rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 600;
}

.btn-brand-solid {
  background-color: var(--brand-color);
  border: 1px solid var(--brand-color);
  color: var(--bs-white);
}

.btn-brand-solid:hover,
.btn-brand-solid:focus-visible {
  background-color: var(--brand-color-dark);
  border: 1px solid var(--brand-color-dark);
  color: var(--bs-white);
}

.btn-brand-solid:focus-visible,
.btn-brand-outline:focus-visible {
  outline: 3px solid rgb(var(--brand-color-rgb) / 25%);
  outline-offset: 0;
}

.btn-brand-solid:active {
  background-color: var(--brand-color-darker) !important;
  border: 1px solid var(--brand-color-darker) !important;
  color: var(--bs-white) !important;
}

.btn-brand-outline {
  color: var(--brand-color);
  border: 1px solid var(--brand-color);
}

.btn-brand-outline:hover,
.btn-brand-outline:active,
.btn-brand-outline:focus-visible {
  background-color: var(--brand-color) !important;
  border-color: var(--brand-color) !important;
  color: var(--bs-white) !important;
}

/* ============================================
   Error pages
   ============================================ */

.error-section {
  min-height: 70dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.error-page-code {
  color: var(--brand-dark-color);
  font-size: 220px;
  font-weight: 300;
  line-height: 0.8;
  margin-bottom: 1.25rem;
}

.error-page-title {
  margin-bottom: 0.5rem;
  color: var(--brand-dark-color);
  font-size: 2rem;
}

.error-page-message {
  max-width: 34rem;
  margin: 0 auto 1.25rem;
  color: var(--color-muted-foreground);
}

@media (width <= 576px) {
  .error-page-code {
    font-size: 5rem;
    line-height: 1;
  }

  .error-page-title {
    font-size: 1.5rem;
  }
}

/* ============================================
   Motion Animation States
   Elements using data-animate start hidden
   and are revealed by animations.js
   ============================================ */
[data-animate] {
  opacity: 0;
}

/* ============================================
   Responsive Design
   ============================================ */
@media (width < 992px) {
  .page-hero__overlay {
    background: linear-gradient(
      90deg,
      rgb(var(--brand-darker-color-rgb) / 94%),
      rgb(var(--brand-darker-color-rgb) / 52%)
    );
  }

  .page-hero h1 {
    font-size: 3.25rem;
  }

  .py-6 {
    padding-top: 3rem !important;
    padding-bottom: 3rem !important;
  }
}

@media (width < 1200px) {
  .inner-page-cta .page-cta__panel {
    display: block;
    padding: 2.75rem;
    text-align: center;
  }

  .inner-page-cta .page-cta__content {
    flex-direction: column;
    align-items: center;
    max-width: 760px;
    margin-inline: auto;
  }

  .inner-page-cta .page-cta__symbol {
    flex: 0 0 4.5rem;
    width: 4.5rem;
    height: 4.5rem;
    font-size: 2rem;
  }

  .inner-page-cta h2 {
    font-size: 2rem;
  }

  .inner-page-cta p {
    font-size: 1.25rem;
  }

  .inner-page-cta .btn-brand-solid {
    width: fit-content;
    min-width: 260px;
    margin: 2rem auto 0;
  }
}

@media (width < 768px) {
  .container-md {
    padding-inline: calc(var(--bs-gutter-x) * 1);
  }

  .inner-page-cta .page-cta__panel {
    padding: 2rem;
  }

  .inner-page-cta p {
    font-size: 1.05rem;
  }
}

@media (width < 576px) {
  .container-md {
    padding-inline: 1rem;
  }

  .page-hero h1 {
    font-size: 2.625rem;
  }

  .page-hero__content {
    width: 100%;
  }

  .inner-page-cta h2 {
    font-size: 1.625rem;
  }

  .inner-page-cta .page-cta__panel {
    padding: 1.5rem;
  }

  .inner-page-cta .btn-brand-solid {
    width: fit-content;
    min-width: 0;
    max-width: 100%;
    padding: 0.75rem 1rem;
    font-size: 0.95rem;
    margin: 1.75rem auto 0;
  }
}

@media (width <= 375px) {
  .container-md {
    padding-inline: 0.875rem;
  }

  .page-hero {
    height: clamp(250px, 72vw, 270px);
  }

  .page-hero h1 {
    font-size: 2.25rem;
  }

  .page-hero p {
    font-size: 0.9375rem;
  }

  .inner-page-cta .page-cta__content {
    gap: 1rem;
  }

  .inner-page-cta .page-cta__symbol {
    width: 3rem;
    height: 3rem;
    flex-basis: 3rem;
    font-size: 1.5rem;
  }

  .inner-page-cta .btn-brand-solid {
    width: fit-content;
    max-width: 100%;
    font-size: 0.9rem;
  }
}

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

  html {
    scroll-behavior: auto;
  }

  /* Ensure data-animate elements are visible when motion is reduced */
  [data-animate] {
    opacity: 1;
  }
}

/* ============================================
   Print Styles
   ============================================ */
@media print {
  .navbar,
  footer {
    display: none;
  }

  body {
    color: black;
    background: white;
  }

  .card {
    border: 1px solid var(--bs-border-color) !important;
    box-shadow: none !important;
  }
}

/* Match the expanded FAQ chevron to its question text. */
.accordion-button:not(.collapsed)::after {
  background-image: none;
  background-color: currentcolor;
  mask: var(--bs-accordion-btn-icon) center / contain no-repeat;
}
