/* ============================================================
   House Price Checker — style.css
   Premium Property Data Dashboard
   Cormorant Garamond + Outfit • Navy & Gold
   ============================================================ */

/* --- Fonts --- */
@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,400;0,500;0,600;0,700;1,400;1,500&family=Outfit:wght@300;400;500;600;700&display=swap');

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

:root {
  /* Core palette - Navy & Gold */
  --clr-navy: #0a1628;
  --clr-navy-light: #142238;
  --clr-navy-dark: #050d18;
  --clr-gold: #d4a853;
  --clr-gold-light: #e8c87a;
  --clr-gold-dark: #b8923f;
  --clr-gold-soft: rgba(212, 168, 83, 0.1);
  --clr-white: #ffffff;
  --clr-cream: #f8f6f2;
  --clr-gray-50: #f9f9f9;
  --clr-gray-100: #f0f0f0;
  --clr-gray-200: #e2e2e2;
  --clr-gray-300: #c8c8c8;
  --clr-gray-400: #9a9a9a;
  --clr-gray-500: #6b6b6b;
  --clr-gray-600: #4a4a4a;
  --clr-gray-700: #333333;
  --clr-text: #1a1a1a;
  --clr-text-light: #5a5a5a;
  --clr-text-muted: #8a8a8a;

  /* Property type colours */
  --clr-detached: #2d5a4a;
  --clr-semi: #3d6b8c;
  --clr-terraced: #7c5c3d;
  --clr-flat: #5c4a7c;

  /* Trend colours */
  --clr-up: #2d8a5a;
  --clr-down: #c44536;
  --clr-stable: #5a7c8a;

  /* Layout */
  --max-w: 1200px;
  --radius: 6px;
  --radius-lg: 12px;
  --radius-sm: 4px;

  /* Shadows */
  --shadow-xs: 0 1px 2px rgba(10, 22, 40, 0.05);
  --shadow-sm: 0 2px 8px rgba(10, 22, 40, 0.08);
  --shadow-md: 0 4px 16px rgba(10, 22, 40, 0.1);
  --shadow-lg: 0 8px 32px rgba(10, 22, 40, 0.12);
  --shadow-xl: 0 16px 48px rgba(10, 22, 40, 0.15);

  /* Transitions */
  --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-fast: 0.15s cubic-bezier(0.4, 0, 0.2, 1);

  /* Fonts */
  --font-display: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
  --font-body: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
}

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

body {
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--clr-text);
  background: var(--clr-cream);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-weight: 400;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--clr-navy); text-decoration: none; transition: color var(--transition-fast); }
a:hover { color: var(--clr-gold-dark); }

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  color: var(--clr-navy);
  line-height: 1.2;
  font-weight: 600;
  letter-spacing: -0.01em;
}
h1 { font-size: clamp(2.25rem, 5vw, 3.5rem); font-weight: 700; }
h2 { font-size: clamp(1.75rem, 3.5vw, 2.5rem); margin-bottom: 1rem; }
h3 { font-size: clamp(1.25rem, 2vw, 1.5rem); margin-bottom: 0.75rem; }
h4 { font-size: 1.1rem; margin-bottom: 0.5rem; }

p + p { margin-top: 1rem; }

/* --- Utility --- */
.container { width: 100%; max-width: var(--max-w); margin: 0 auto; padding: 0 1.5rem; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }
.text-center { text-align: center; }
.text-navy { color: var(--clr-navy); }
.text-gold { color: var(--clr-gold); }
.text-muted { color: var(--clr-text-light); }

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.875rem 1.75rem;
  border: none;
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: var(--clr-gold);
  color: var(--clr-navy-dark);
}
.btn-primary:hover {
  background: var(--clr-gold-light);
  color: var(--clr-navy-dark);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(212, 168, 83, 0.35);
}

.btn-secondary {
  background: var(--clr-navy);
  color: var(--clr-white);
}
.btn-secondary:hover {
  background: var(--clr-navy-light);
  color: var(--clr-white);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn-outline {
  background: transparent;
  color: var(--clr-navy);
  border: 2px solid var(--clr-navy);
}
.btn-outline:hover {
  background: var(--clr-navy);
  color: var(--clr-white);
}

.btn-lg {
  padding: 1rem 2.5rem;
  font-size: 1.05rem;
}

.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
}

/* --- Header / Nav --- */
.site-header {
  background: var(--clr-navy);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-md);
}

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

.logo {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--clr-white);
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  letter-spacing: -0.02em;
}

.logo:hover {
  color: var(--clr-gold);
}

.logo-icon {
  width: 36px;
  height: 36px;
  background: var(--clr-gold);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--clr-navy-dark);
  font-weight: 700;
  font-size: 1rem;
}

.main-nav {
  display: flex;
  gap: 2rem;
  align-items: center;
}

.main-nav a {
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.9rem;
  font-weight: 500;
  font-family: var(--font-body);
  transition: color var(--transition-fast);
}

.main-nav a:hover {
  color: var(--clr-gold);
  text-decoration: none;
}

.main-nav .btn-primary {
  font-size: 0.85rem;
  padding: 0.6rem 1.25rem;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--clr-white);
  margin: 5px 0;
  transition: var(--transition);
}

/* --- Hero --- */
.hero {
  background: var(--clr-navy);
  padding: 5rem 0 4.5rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background:
    radial-gradient(ellipse 50% 40% at 20% 20%, rgba(212, 168, 83, 0.15) 0%, transparent 50%),
    radial-gradient(ellipse 40% 50% at 80% 80%, rgba(212, 168, 83, 0.08) 0%, transparent 50%);
  pointer-events: none;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, 
    var(--clr-detached) 0%, 
    var(--clr-semi) 25%, 
    var(--clr-gold) 50%, 
    var(--clr-terraced) 75%, 
    var(--clr-flat) 100%
  );
}

.hero .container {
  position: relative;
  z-index: 1;
}

.hero h1 {
  color: var(--clr-white);
  margin-bottom: 1rem;
  font-weight: 700;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.hero p {
  font-size: 1.15rem;
  color: rgba(255, 255, 255, 0.65);
  max-width: 560px;
  margin: 0 auto 2.5rem;
  line-height: 1.6;
  font-weight: 300;
}

/* --- Search Box --- */
.search-box {
  max-width: 580px;
  margin: 0 auto;
  display: flex;
  gap: 0.75rem;
  background: var(--clr-white);
  border-radius: var(--radius-lg);
  padding: 0.6rem;
  box-shadow: var(--shadow-xl);
}

.search-box input {
  flex: 1;
  border: 2px solid var(--clr-gray-200);
  border-radius: var(--radius);
  padding: 1rem 1.25rem;
  font-size: 1rem;
  font-family: var(--font-body);
  outline: none;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
  background: var(--clr-gray-50);
}

.search-box input:focus {
  border-color: var(--clr-gold);
  box-shadow: 0 0 0 4px rgba(212, 168, 83, 0.15);
}

.search-box .btn {
  white-space: nowrap;
}

.search-hint {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
  margin-top: 1rem;
}

/* --- Sections --- */
.section {
  padding: 4.5rem 0;
}

.section-alt {
  background: var(--clr-white);
}

.section-navy {
  background: var(--clr-navy);
  color: var(--clr-white);
}

.section-navy h2 {
  color: var(--clr-white);
}

/* --- How It Works --- */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin-top: 2.5rem;
}

.step-card {
  background: var(--clr-white);
  padding: 2.25rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  text-align: center;
  border: 1px solid var(--clr-gray-100);
  transition: all var(--transition);
  position: relative;
}

.step-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 3px;
  background: var(--clr-gold);
  border-radius: 0 0 var(--radius-sm) var(--radius-sm);
}

.step-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
  border-color: var(--clr-gold-soft);
}

.step-number {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--clr-gold-soft);
  color: var(--clr-gold-dark);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 1.25rem;
  font-family: var(--font-body);
}

.step-card h3 {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.step-card p {
  font-size: 0.95rem;
  color: var(--clr-text-light);
}

/* --- Stats Banner --- */
.stats-banner {
  background: var(--clr-navy);
  color: var(--clr-white);
  padding: 3.5rem 0;
  position: relative;
  overflow: hidden;
}

.stats-banner::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--clr-gold), transparent);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 2.5rem;
}

.stat-item h3 {
  font-size: 2.5rem;
  color: var(--clr-gold);
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1;
  margin-bottom: 0.5rem;
}

.stat-item p {
  font-size: 0.85rem;
  opacity: 0.7;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 500;
}

/* --- Price Cards --- */
.price-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.price-card {
  background: var(--clr-white);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--clr-gray-100);
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
}

.price-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
}

.price-card.detached::before { background: var(--clr-detached); }
.price-card.semi::before { background: var(--clr-semi); }
.price-card.terraced::before { background: var(--clr-terraced); }
.price-card.flat::before { background: var(--clr-flat); }

.price-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

.price-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.35rem 0.75rem;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 1rem;
}

.price-badge.detached { background: rgba(45, 90, 74, 0.1); color: var(--clr-detached); }
.price-badge.semi { background: rgba(61, 107, 140, 0.1); color: var(--clr-semi); }
.price-badge.terraced { background: rgba(124, 92, 61, 0.1); color: var(--clr-terraced); }
.price-badge.flat { background: rgba(92, 74, 124, 0.1); color: var(--clr-flat); }

.price-value {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  color: var(--clr-navy);
  margin-bottom: 0.25rem;
}

.price-label {
  font-size: 0.9rem;
  color: var(--clr-text-light);
}

.price-trend {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.8rem;
  font-weight: 600;
  margin-top: 0.75rem;
  padding: 0.25rem 0.5rem;
  border-radius: var(--radius-sm);
}

.price-trend.up { background: rgba(45, 138, 90, 0.1); color: var(--clr-up); }
.price-trend.down { background: rgba(196, 69, 54, 0.1); color: var(--clr-down); }
.price-trend.stable { background: rgba(90, 124, 138, 0.1); color: var(--clr-stable); }

/* --- Location Grid --- */
.location-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1rem;
  margin-top: 2rem;
}

.location-card {
  background: var(--clr-white);
  border: 1px solid var(--clr-gray-200);
  border-radius: var(--radius);
  padding: 1.25rem;
  text-decoration: none;
  transition: all var(--transition);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.location-card:hover {
  border-color: var(--clr-gold);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.location-card h4 {
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--clr-navy);
  margin: 0;
}

.location-card span {
  font-size: 1.25rem;
}

/* --- Feature Cards --- */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.feature-card {
  background: var(--clr-white);
  padding: 1.75rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--clr-gray-100);
  transition: all var(--transition);
}

.feature-card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--clr-gold-soft);
}

.feature-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius);
  background: var(--clr-gold-soft);
  color: var(--clr-gold-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.feature-card h3 {
  font-size: 1.1rem;
  font-weight: 600;
}

.feature-card p {
  font-size: 0.9rem;
  color: var(--clr-text-light);
  margin-top: 0.35rem;
}

/* --- Guide Cards --- */
.guides-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.guide-card {
  background: var(--clr-white);
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--clr-gray-100);
  transition: all var(--transition);
  text-decoration: none;
}

.guide-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
  border-color: var(--clr-gold-soft);
}

.guide-card-content {
  padding: 1.5rem;
}

.guide-card h3 {
  font-size: 1.15rem;
  color: var(--clr-navy);
  margin-bottom: 0.5rem;
}

.guide-card p {
  font-size: 0.9rem;
  color: var(--clr-text-light);
  margin: 0;
}

.guide-card-meta {
  font-size: 0.8rem;
  color: var(--clr-text-muted);
  margin-top: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* --- Network / Cross-links --- */
.network-banner {
  background: var(--clr-navy-light);
  border-top: 1px solid var(--clr-gray-700);
  padding: 2.5rem 0;
  text-align: center;
}

.network-banner h3 {
  font-family: var(--font-body);
  font-size: 0.75rem;
  color: var(--clr-gray-400);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 1.25rem;
}

.network-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
}

.network-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1.25rem;
  border: 1px solid var(--clr-gray-600);
  border-radius: var(--radius);
  background: transparent;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--clr-gray-300);
  font-family: var(--font-body);
  transition: all var(--transition);
}

.network-link:hover {
  border-color: var(--clr-gold);
  color: var(--clr-gold);
  text-decoration: none;
  background: rgba(212, 168, 83, 0.05);
}

/* --- Footer --- */
.site-footer {
  background: var(--clr-navy-dark);
  color: var(--clr-gray-400);
  padding: 3.5rem 0 1.5rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 2rem;
  margin-bottom: 2.5rem;
}

.footer-col h4 {
  color: var(--clr-white);
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.footer-col ul {
  list-style: none;
}

.footer-col li {
  margin-bottom: 0.6rem;
}

.footer-col a {
  color: var(--clr-gray-500);
  font-size: 0.875rem;
  font-family: var(--font-body);
  transition: color var(--transition-fast);
}

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

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
  gap: 1rem;
}

.footer-bottom a {
  color: var(--clr-gray-500);
}

/* --- Animations --- */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.animate-in {
  animation: fadeInUp 0.6s ease forwards;
}

.delay-1 { animation-delay: 0.1s; }
.delay-2 { animation-delay: 0.2s; }
.delay-3 { animation-delay: 0.3s; }
.delay-4 { animation-delay: 0.4s; }

/* --- Responsive --- */
@media (max-width: 768px) {
  .main-nav {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background: var(--clr-navy);
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--clr-gray-700);
    box-shadow: var(--shadow-lg);
    gap: 0.5rem;
  }

  .main-nav.open {
    display: flex;
  }

  .main-nav a {
    padding: 0.75rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .nav-toggle {
    display: block;
  }

  .search-box {
    flex-direction: column;
  }

  .search-box .btn {
    width: 100%;
    justify-content: center;
  }

  .hero {
    padding: 3.5rem 0 3rem;
  }

  .section {
    padding: 3rem 0;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }

  .stat-item h3 {
    font-size: 2rem;
  }

  .location-grid {
    grid-template-columns: repeat(2, 1fr);
  }

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

@media (max-width: 480px) {
  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }

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

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

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

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

/* Print */
@media print {
  .site-header,
  .site-footer,
  .network-banner,
  .search-box,
  .nav-toggle,
  .btn {
    display: none !important;
  }

  body {
    font-size: 12pt;
    color: #000;
    background: #fff;
  }
}
