/* ========================================
   Coastal Dune Labs — Global Stylesheet
   Clean minimal: white space, sharp type, quiet confidence
   ======================================== */

@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;1,9..40,400&family=DM+Serif+Display&display=swap');

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

:root {
  --text-primary: #1a1a1a;
  --text-secondary: #5c5c5c;
  --text-tertiary: #8a8a8a;
  --bg: #ffffff;
  --bg-subtle: #f8f8f7;
  --border: #e5e5e3;
  --accent: #2c5f4a;
  --accent-light: #e8f0ec;
  --font-body: 'DM Sans', -apple-system, sans-serif;
  --font-display: 'DM Serif Display', Georgia, serif;
  --max-width: 720px;
  --max-width-wide: 960px;
}

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  color: var(--text-primary);
  background: var(--bg);
  line-height: 1.7;
  font-weight: 400;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: opacity 0.15s;
}
a:hover { opacity: 0.7; }

/* --- Layout --- */
.site-header {
  padding: 1.5rem 2rem;
  border-bottom: 1px solid var(--border);
}

.header-inner {
  max-width: var(--max-width-wide);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1rem;
  letter-spacing: -0.01em;
  color: var(--text-primary);
  text-decoration: none;
}
.logo:hover { opacity: 1; }

.header-nav {
  display: flex;
  gap: 1.75rem;
  list-style: none;
}
.header-nav a {
  font-size: 0.875rem;
  color: var(--text-secondary);
  font-weight: 400;
}
.header-nav a:hover { color: var(--text-primary); opacity: 1; }

.main {
  flex: 1;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 4rem 2rem;
  width: 100%;
}

.main--wide {
  max-width: var(--max-width-wide);
}

.site-footer {
  border-top: 1px solid var(--border);
  padding: 2rem;
  text-align: center;
}

.footer-inner {
  max-width: var(--max-width-wide);
  margin: 0 auto;
  font-size: 0.8125rem;
  color: var(--text-tertiary);
}
.footer-inner a { color: var(--text-tertiary); }
.footer-inner a:hover { color: var(--text-primary); }

.footer-links {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  list-style: none;
  margin-bottom: 0.75rem;
}

/* --- Typography --- */
h1 {
  font-family: var(--font-display);
  font-size: 2.5rem;
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-bottom: 1rem;
}

h2 {
  font-family: var(--font-body);
  font-size: 1.125rem;
  font-weight: 600;
  line-height: 1.4;
  margin-top: 2.5rem;
  margin-bottom: 0.75rem;
}

h3 {
  font-size: 0.9375rem;
  font-weight: 600;
  margin-top: 2rem;
  margin-bottom: 0.5rem;
}

p { margin-bottom: 1rem; }

.lead {
  font-size: 1.125rem;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 560px;
}

/* --- Homepage Hero Banner --- */
.hero-banner {
  position: relative;
  min-height: 420px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: url('/assets/hero-bg.jpg') center 40% / cover no-repeat;
  overflow: hidden;
}

.hero-banner__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0.82) 0%,
    rgba(255, 255, 255, 0.70) 50%,
    rgba(255, 255, 255, 0.88) 100%
  );
}

.hero-banner__content {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 5rem 2rem;
  max-width: 600px;
}

.hero-banner__content h1 {
  font-family: var(--font-display);
  font-size: 2.75rem;
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-bottom: 1.25rem;
  color: var(--text-primary);
}

.hero-banner__content .lead {
  max-width: 480px;
  margin: 0 auto;
  color: var(--text-secondary);
}

.section-label {
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-tertiary);
  margin-bottom: 1.5rem;
}

/* --- App Cards --- */
.app-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  max-width: 520px;
  margin: 0 auto;
}

.app-card {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2rem;
  transition: border-color 0.2s, box-shadow 0.2s;
  text-decoration: none;
  color: inherit;
  display: block;
}
.app-card:hover {
  border-color: var(--accent);
  box-shadow: 0 2px 12px rgba(0,0,0,0.04);
  opacity: 1;
}

.app-card__icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--accent-light);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  font-size: 1.25rem;
}

.app-card__name {
  font-weight: 600;
  font-size: 1rem;
  margin-bottom: 0.375rem;
}

.app-card__desc {
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 1rem;
}

.app-card__badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--accent);
  background: var(--accent-light);
  padding: 0.25rem 0.75rem;
  border-radius: 100px;
}

/* --- Legal Pages --- */
.legal-header {
  margin-bottom: 3rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border);
}

.legal-header .breadcrumb {
  font-size: 0.8125rem;
  color: var(--text-tertiary);
  margin-bottom: 1rem;
}

.legal-header h1 {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

.legal-header .meta {
  font-size: 0.875rem;
  color: var(--text-tertiary);
}

.legal-content h2 {
  margin-top: 3rem;
}

.legal-content h2:first-child {
  margin-top: 0;
}

.legal-content p,
.legal-content li {
  font-size: 0.9375rem;
  color: var(--text-secondary);
}

.legal-content ul,
.legal-content ol {
  padding-left: 1.25rem;
  margin-bottom: 1rem;
}

.legal-content li {
  margin-bottom: 0.5rem;
  line-height: 1.7;
}

/* --- Support Page --- */
.support-card {
  background: var(--bg-subtle);
  border-radius: 12px;
  padding: 2.5rem;
  margin-top: 2rem;
  text-align: center;
}

.support-card p {
  color: var(--text-secondary);
  font-size: 0.9375rem;
}

.btn {
  display: inline-block;
  padding: 0.75rem 1.75rem;
  background: var(--accent);
  color: #fff;
  border-radius: 8px;
  font-weight: 500;
  font-size: 0.9375rem;
  margin-top: 1rem;
  transition: background 0.15s;
}
.btn:hover {
  background: #234d3b;
  opacity: 1;
  color: #fff;
}

/* --- Responsive --- */
@media (max-width: 640px) {
  .site-header { padding: 1.25rem 1.25rem; }
  .main { padding: 2.5rem 1.25rem; }

  .hero-banner { min-height: 320px; }
  .hero-banner__content { padding: 3rem 1.25rem; }
  .hero-banner__content h1 { font-size: 2rem; }

  h1 { font-size: 1.875rem; }
  .legal-header h1 { font-size: 1.625rem; }

  .header-nav { gap: 1.25rem; }
  .header-nav a { font-size: 0.8125rem; }

  .footer-links { flex-wrap: wrap; gap: 1rem; }
}
