/* ============================================
   LibertyX Bitcoin ATM — Ridgeville, SC
   Classic & Elegant Design System
   ============================================ */

/* --- CSS Custom Properties --- */
:root {
  --color-navy: #1a2744;
  --color-navy-light: #243352;
  --color-navy-dark: #111b30;
  --color-gold: #c8a45a;
  --color-gold-light: #d4b76e;
  --color-gold-dark: #b8933f;
  --color-cream: #f8f6f1;
  --color-warm-gray: #e8e4dd;
  --color-text: #2c2c2c;
  --color-text-light: #5a5a5a;
  --color-text-on-dark: #f0ece4;
  --color-white: #ffffff;

  --font-serif: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --font-sans: 'Lato', 'Segoe UI', system-ui, -apple-system, sans-serif;

  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 1.5rem;
  --space-lg: 2.5rem;
  --space-xl: 4rem;
  --space-2xl: 6rem;
  --space-3xl: 8rem;

  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 16px;

  --shadow-sm: 0 1px 3px rgba(26, 39, 68, 0.08);
  --shadow-md: 0 4px 16px rgba(26, 39, 68, 0.1);
  --shadow-lg: 0 8px 32px rgba(26, 39, 68, 0.12);
  --shadow-gold: 0 4px 20px rgba(200, 164, 90, 0.25);

  --transition-fast: 0.2s ease;
  --transition-base: 0.3s ease;
  --transition-slow: 0.5s ease;
}

/* --- Reset & Base --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.7;
  color: var(--color-text);
  background-color: var(--color-cream);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

ul, ol {
  list-style: none;
}

address {
  font-style: normal;
}

/* --- Typography --- */
h1, h2, h3, h4 {
  font-family: var(--font-serif);
  font-weight: 600;
  line-height: 1.25;
  color: var(--color-navy);
}

h1 { font-size: clamp(2.25rem, 5vw, 3.75rem); }
h2 { font-size: clamp(1.75rem, 3.5vw, 2.5rem); }
h3 { font-size: clamp(1.25rem, 2vw, 1.5rem); }
h4 { font-size: 1.125rem; }

p {
  color: var(--color-text-light);
}

/* --- Layout --- */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-md);
}

.section {
  padding: var(--space-3xl) 0;
}

/* --- Section Headers --- */
.section-header {
  text-align: center;
  max-width: 680px;
  margin: 0 auto var(--space-xl);
}

.section-eyebrow {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-gold);
  margin-bottom: var(--space-sm);
}

.section-title {
  margin-bottom: var(--space-sm);
}

.section-title--light {
  color: var(--color-white);
}

.section-title--gold {
  color: var(--color-gold);
}

.section-desc {
  font-size: 1.0625rem;
  line-height: 1.75;
  color: var(--color-text-light);
}

.section-desc--light {
  color: rgba(240, 236, 228, 0.75);
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-sans);
  font-size: 0.9375rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  padding: 0.875rem 1.75rem;
  border-radius: var(--radius-sm);
  transition: all var(--transition-base);
  white-space: nowrap;
}

.btn-gold {
  background: var(--color-gold);
  color: var(--color-navy-dark);
  border: 2px solid var(--color-gold);
}

.btn-gold:hover,
.btn-gold:focus-visible {
  background: var(--color-gold-light);
  border-color: var(--color-gold-light);
  transform: translateY(-2px);
  box-shadow: var(--shadow-gold);
}

.btn-outline-light {
  background: transparent;
  color: var(--color-white);
  border: 1.5px solid rgba(255, 255, 255, 0.5);
}

.btn-outline-light:hover,
.btn-outline-light:focus-visible {
  border-color: var(--color-white);
  background: rgba(255, 255, 255, 0.08);
  transform: translateY(-2px);
}

/* --- Header --- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(26, 39, 68, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(200, 164, 90, 0.15);
  transition: background var(--transition-base);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.625rem;
}

.logo-text {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--color-white);
  letter-spacing: 0.02em;
}

.logo--light .logo-text {
  color: var(--color-white);
}

.main-nav ul {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
}

.main-nav a {
  font-size: 0.875rem;
  font-weight: 500;
  color: rgba(240, 236, 228, 0.8);
  letter-spacing: 0.03em;
  transition: color var(--transition-fast);
  position: relative;
}

.main-nav a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1.5px;
  background: var(--color-gold);
  transition: width var(--transition-base);
}

.main-nav a:hover {
  color: var(--color-gold);
}

.main-nav a::after {
  width: 100%;
}

.btn-nav {
  font-size: 0.875rem !important;
  font-weight: 600 !important;
  color: var(--color-navy-dark) !important;
  background: var(--color-gold);
  padding: 0.5rem 1.125rem;
  border-radius: var(--radius-sm);
  transition: all var(--transition-base) !important;
}

.btn-nav::after {
  display: none !important;
}

.btn-nav:hover {
  background: var(--color-gold-light) !important;
  color: var(--color-navy-dark) !important;
  transform: translateY(-1px);
}

/* Mobile nav toggle */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 4px;
}

.nav-toggle-line {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-white);
  border-radius: 2px;
  transition: all var(--transition-base);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-line:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-line:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-line:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* --- Hero --- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  background: var(--color-navy-dark);
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.35;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(17, 27, 48, 0.92) 0%,
    rgba(26, 39, 68, 0.85) 40%,
    rgba(26, 39, 68, 0.70) 100%
  );
}

.hero-content {
  position: relative;
  z-index: 1;
  padding-top: var(--space-2xl);
  padding-bottom: var(--space-2xl);
  max-width: 720px;
}

.hero-eyebrow {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--color-gold);
  margin-bottom: var(--space-md);
}

.hero-headline {
  color: var(--color-white);
  margin-bottom: var(--space-md);
  font-weight: 700;
}

.hero-sub {
  font-size: 1.125rem;
  line-height: 1.8;
  color: rgba(240, 236, 228, 0.8);
  margin-bottom: var(--space-lg);
  max-width: 580px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  margin-bottom: var(--space-xl);
}

.hero-trust {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-md);
}

.trust-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: rgba(240, 236, 228, 0.7);
}

/* --- How It Works --- */
.how-it-works {
  background: var(--color-white);
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-lg);
}

.step-card {
  text-align: center;
  padding: var(--space-lg) var(--space-md);
  position: relative;
}

.step-number {
  font-family: var(--font-serif);
  font-size: 4rem;
  font-weight: 700;
  color: rgba(200, 164, 90, 0.15);
  line-height: 1;
  margin-bottom: var(--space-sm);
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
}

.step-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto var(--space-md);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-cream);
  border-radius: var(--radius-md);
  position: relative;
  z-index: 1;
}

.step-card h3 {
  margin-bottom: var(--space-xs);
}

.step-card p {
  font-size: 0.9375rem;
  line-height: 1.7;
}

/* --- Why LibertyX --- */
.why-section {
  background: var(--color-navy);
  overflow: hidden;
}

.why-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-xl);
  align-items: center;
}

.why-content {
  max-width: 520px;
}

.why-features {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  margin-top: var(--space-lg);
}

.why-feature {
  display: flex;
  gap: var(--space-sm);
  align-items: flex-start;
}

.why-feature-icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(200, 164, 90, 0.12);
  border-radius: var(--radius-sm);
  margin-top: 2px;
}

.why-feature h4 {
  color: var(--color-white);
  font-size: 1rem;
  margin-bottom: 0.25rem;
}

.why-feature p {
  font-size: 0.9375rem;
  color: rgba(240, 236, 228, 0.65);
  line-height: 1.65;
}

.why-image {
  position: relative;
}

.image-frame {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.image-frame img {
  width: 100%;
  height: 400px;
  object-fit: cover;
  display: block;
}

.image-accent {
  position: absolute;
  bottom: -20px;
  right: -20px;
  width: 120px;
  height: 120px;
  background: var(--color-gold);
  border-radius: var(--radius-md);
  z-index: -1;
  opacity: 0.3;
}

/* --- Fees --- */
.fees-section {
  background: var(--color-cream);
}

.fees-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-md);
  margin-bottom: var(--space-lg);
}

.fee-card {
  background: var(--color-white);
  padding: var(--space-lg);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(26, 39, 68, 0.06);
  transition: all var(--transition-base);
}

.fee-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(200, 164, 90, 0.2);
}

.fee-card-header {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(200, 164, 90, 0.1);
  border-radius: var(--radius-sm);
  margin-bottom: var(--space-md);
}

.fee-card h3 {
  margin-bottom: var(--space-xs);
}

.fee-card p {
  font-size: 0.9375rem;
  line-height: 1.7;
}

.fees-note {
  text-align: center;
  font-size: 0.875rem;
  color: var(--color-text-light);
  font-style: italic;
}

/* --- Location --- */
.location-section {
  background: var(--color-white);
}

.location-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-xl);
  align-items: start;
}

.location-info {
  max-width: 480px;
}

.location-address {
  margin: var(--space-md) 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.address-line {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-family: var(--font-serif);
  font-size: 1.125rem;
  color: var(--color-navy);
}

.location-contact {
  margin-bottom: var(--space-lg);
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.contact-item a {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  color: var(--color-navy);
  font-weight: 600;
  transition: color var(--transition-fast);
}

.contact-item a:hover {
  color: var(--color-gold);
}

.location-hours {
  margin-bottom: var(--space-lg);
  padding: var(--space-md);
  background: var(--color-cream);
  border-radius: var(--radius-md);
  border-left: 3px solid var(--color-gold);
}

.location-hours h4 {
  font-size: 1rem;
  margin-bottom: 0.375rem;
  color: var(--color-navy);
}

.location-hours p {
  font-size: 0.9375rem;
}

.location-map {
  margin-top: var(--space-md);
}

.location-map-wrap {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  min-height: 400px;
}

.map-placeholder {
  width: 100%;
  height: 100%;
  min-height: 400px;
}

.map-placeholder iframe {
  width: 100%;
  height: 100%;
  min-height: 400px;
  display: block;
}

/* --- FAQ --- */
.faq-section {
  background: var(--color-cream);
}

.faq-list {
  max-width: 760px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
}

.faq-item {
  border-bottom: 1px solid rgba(26, 39, 68, 0.1);
}

.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
  padding: var(--space-md) 0;
  text-align: left;
  font-family: var(--font-serif);
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--color-navy);
  transition: color var(--transition-fast);
}

.faq-question:hover {
  color: var(--color-gold);
}

.faq-toggle {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-gold);
  transition: transform var(--transition-base);
}

.faq-question[aria-expanded="true"] .faq-toggle {
  transform: rotate(45deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height var(--transition-base), padding var(--transition-base);
}

.faq-answer p {
  padding-bottom: var(--space-md);
  font-size: 0.9375rem;
  line-height: 1.75;
  color: var(--color-text-light);
}

.faq-item.active .faq-answer {
  max-height: 300px;
}

/* --- CTA --- */
.cta-section {
  background: var(--color-navy-dark);
  padding: var(--space-3xl) 0;
}

.cta-box {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-xl);
}

.cta-content {
  flex: 1;
  max-width: 600px;
}

.section-eyebrow--dark {
  color: var(--color-gold-light);
}

.cta-text {
  font-size: 1.0625rem;
  line-height: 1.8;
  color: rgba(240, 236, 228, 0.7);
  margin-bottom: var(--space-lg);
}

.cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
}

.cta-decoration {
  flex-shrink: 0;
  opacity: 0.4;
}

/* --- Footer --- */
.site-footer {
  background: var(--color-navy-dark);
  border-top: 1px solid rgba(200, 164, 90, 0.15);
  padding: var(--space-xl) 0 var(--space-lg);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1.5fr;
  gap: var(--space-xl);
  margin-bottom: var(--space-xl);
}

.footer-brand {
  max-width: 280px;
}

.footer-tagline {
  font-size: 0.9375rem;
  color: rgba(240, 236, 228, 0.55);
  margin-top: var(--space-sm);
  line-height: 1.7;
}

.footer-links h4,
.footer-contact h4 {
  font-size: 0.875rem;
  font-family: var(--font-sans);
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-gold);
  margin-bottom: var(--space-sm);
}

.footer-links ul {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.footer-links a {
  font-size: 0.9375rem;
  color: rgba(240, 236, 228, 0.6);
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: var(--color-gold);
}

.footer-contact address {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
}

.footer-contact p {
  font-size: 0.9375rem;
  color: rgba(240, 236, 228, 0.6);
}

.footer-contact a {
  color: rgba(240, 236, 228, 0.6);
  transition: color var(--transition-fast);
}

.footer-contact a:hover {
  color: var(--color-gold);
}

.footer-bottom {
  border-top: 1px solid rgba(240, 236, 228, 0.08);
  padding-top: var(--space-md);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  align-items: center;
  text-align: center;
}

.footer-bottom p {
  font-size: 0.8125rem;
  color: rgba(240, 236, 228, 0.35);
}

.footer-disclaimer {
  font-size: 0.75rem !important;
  color: rgba(240, 236, 228, 0.25) !important;
  max-width: 600px;
}

/* --- Scroll Reveal --- */
.reveal {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal[data-reveal-delay="1"] { transition-delay: 0.1s; }
.reveal[data-reveal-delay="2"] { transition-delay: 0.2s; }
.reveal[data-reveal-delay="3"] { transition-delay: 0.3s; }

@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(24px);
  }

  .reveal.visible {
    opacity: 1;
    transform: translateY(0);
  }
}

/* --- Responsive --- */
@media (max-width: 1024px) {
  .why-grid,
  .location-grid {
    grid-template-columns: 1fr;
  }

  .why-image {
    order: -1;
  }

  .cta-box {
    flex-direction: column;
    text-align: center;
  }

  .cta-decoration {
    display: none;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  :root {
    --space-3xl: 5rem;
  }

  .nav-toggle {
    display: flex;
    z-index: 1001;
  }

  .main-nav {
    position: fixed;
    top: 0;
    right: 0;
    width: min(320px, 85vw);
    height: 100vh;
    height: 100dvh;
    background: var(--color-navy-dark);
    padding: 100px var(--space-lg) var(--space-lg);
    transform: translateX(100%);
    transition: transform var(--transition-base);
    box-shadow: -8px 0 32px rgba(0, 0, 0, 0.3);
  }

  .main-nav.open {
    transform: translateX(0);
  }

  .main-nav ul {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-sm);
  }

  .main-nav a {
    font-size: 1.0625rem;
    color: rgba(240, 236, 228, 0.8);
  }

  .btn-nav {
    margin-top: var(--space-sm);
  }

  .hero-content {
    padding-top: var(--space-xl);
  }

  .hero-actions {
    flex-direction: column;
  }

  .hero-actions .btn {
    justify-content: center;
  }

  .steps-grid,
  .fees-grid {
    grid-template-columns: 1fr;
    gap: var(--space-md);
  }

  .step-card {
    padding: var(--space-md);
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: var(--space-lg);
  }

  .footer-bottom {
    flex-direction: column;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 var(--space-sm);
  }

  .section {
    padding: var(--space-2xl) 0;
  }

  .hero-trust {
    flex-direction: column;
    gap: var(--space-xs);
  }
}

/* --- Focus styles --- */
:focus-visible {
  outline: 2px solid var(--color-gold);
  outline-offset: 2px;
}

/* --- Mobile nav overlay --- */
.nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 999;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-base);
}

.nav-overlay.active {
  opacity: 1;
  pointer-events: all;
}
