/* Altoryva palette: Forest, Ivory, Gold, Sage, Charcoal.
   Fonts (Playfair Display, Inter) are loaded via a Google Fonts link in the page head. */

:root {
  --color-forest: #0E3B2E;
  --color-ivory: #F8F6EE;
  --color-gold: #D4AF7C;
  --color-sage: #A7B89F;
  --color-charcoal: #1F1F1F;

  --color-bg: var(--color-ivory);
  --color-text: var(--color-charcoal);
  --color-text-secondary: #4F5A54;
  /* Gold fails contrast as text on ivory, so links and accents on light use forest. */
  --color-accent: var(--color-forest);
  --color-accent-dark: #082a20;
  --color-accent-light: var(--color-gold);
  --color-secondary: var(--color-sage);
  --color-border: #E3DFCF;
  --color-card: #FFFFFF;
  --max-width: 740px;
  --font-display: "Playfair Display", "New York", Georgia, serif;
  --font-body: Inter, -apple-system, system-ui, sans-serif;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

/* Navigation */
nav {
  position: sticky;
  top: 0;
  background: var(--color-forest);
  border-bottom: 1px solid rgba(212, 175, 124, 0.25);
  z-index: 100;
}

nav .nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
}

nav .logo {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.1rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--color-ivory);
  text-decoration: none;
}

nav .logo svg {
  width: 26px;
  height: 26px;
  flex-shrink: 0;
}

nav .nav-links {
  display: flex;
  gap: 1.5rem;
  list-style: none;
}

nav .nav-links a {
  text-decoration: none;
  color: rgba(248, 246, 238, 0.8);
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.2s;
}

nav .nav-links a:hover,
nav .nav-links a.active {
  color: var(--color-gold);
  text-decoration: none;
}

/* Main content */
main {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 3rem 1.5rem 5rem;
}

h1 {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  letter-spacing: -0.02em;
}

.subtitle {
  color: var(--color-text-secondary);
  font-size: 0.95rem;
  margin-bottom: 2.5rem;
}

h2 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 600;
  margin-top: 2.5rem;
  margin-bottom: 0.75rem;
  letter-spacing: -0.01em;
}

h3 {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
}

p {
  margin-bottom: 1rem;
  color: var(--color-text);
}

ul, ol {
  margin-bottom: 1rem;
  padding-left: 1.5rem;
}

li {
  margin-bottom: 0.35rem;
}

strong {
  font-weight: 600;
}

a {
  color: var(--color-accent);
  text-decoration: underline;
  text-decoration-color: var(--color-gold);
  text-underline-offset: 3px;
}

a:hover {
  text-decoration-thickness: 2px;
}

hr {
  border: none;
  border-top: 1px solid var(--color-border);
  margin: 2.5rem 0;
}

/* Info card */
.info-card {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: 12px;
  padding: 1.5rem;
  margin: 1.5rem 0;
}

.info-card h3 {
  margin-top: 0;
}

/* Table */
table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0;
  font-size: 0.9rem;
}

th, td {
  text-align: left;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--color-border);
}

th {
  font-weight: 600;
  color: var(--color-text-secondary);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Hero section for index */
.hero {
  text-align: center;
  padding: 3rem 0 2rem;
}

.hero h1 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.hero p {
  color: var(--color-text-secondary);
  font-size: 1.1rem;
  max-width: 500px;
  margin: 0 auto 2rem;
}

.page-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-top: 2rem;
}

.page-card {
  display: block;
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: 12px;
  padding: 1.5rem;
  text-decoration: none;
  transition: border-color 0.2s, transform 0.2s;
}

.page-card:hover {
  border-color: var(--color-accent);
  transform: translateY(-2px);
  text-decoration: none;
}

.page-card h3 {
  margin: 0 0 0.5rem;
  color: var(--color-text);
}

.page-card p {
  color: var(--color-text-secondary);
  font-size: 0.9rem;
  margin: 0;
}

/* Footer */
footer {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 2rem 1.5rem;
  border-top: 1px solid var(--color-border);
  text-align: center;
  color: var(--color-text-secondary);
  font-size: 0.85rem;
}

/* ================================================
   MARKETING PAGE STYLES
   ================================================ */

/* Marketing main — full-width, no max-width cap */
.marketing-main {
  max-width: none;
  padding: 0;
}

/* Hero */
.marketing-hero {
  background: var(--color-forest);
  color: var(--color-ivory);
  padding: 5.5rem 1.5rem 5rem;
  text-align: center;
}

.hero-mark {
  width: 72px;
  height: 72px;
  margin: 0 auto 1.5rem;
  display: block;
}

.marketing-hero-inner {
  max-width: 680px;
  margin: 0 auto;
}

.hero-badge {
  display: inline-block;
  background: rgba(212, 175, 124, 0.12);
  color: var(--color-gold);
  border: 1px solid rgba(212, 175, 124, 0.4);
  border-radius: 100px;
  padding: 0.3rem 1rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
}

.marketing-headline {
  font-family: var(--font-display);
  font-size: 3.25rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin-bottom: 1.25rem;
  color: var(--color-ivory);
}

.marketing-tagline {
  font-size: 1.35rem;
  color: var(--color-gold);
  margin: 0 auto 1rem;
  font-weight: 500;
}

.marketing-subheadline {
  font-size: 1.1rem;
  color: rgba(248, 246, 238, 0.82);
  line-height: 1.7;
  max-width: 560px;
  margin: 0 auto 2.5rem;
}

/* App Store Button */
.hero-cta {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.app-store-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  background: var(--color-gold);
  color: var(--color-forest);
  border-radius: 12px;
  padding: 0.75rem 1.5rem;
  text-decoration: none;
  transition: opacity 0.2s, transform 0.2s;
  min-width: 180px;
}

.app-store-btn:hover {
  opacity: 0.85;
  transform: translateY(-2px);
  text-decoration: none;
}

.app-store-btn--large {
  padding: 1rem 2rem;
  border-radius: 14px;
}

.app-store-icon {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.app-store-text {
  display: flex;
  flex-direction: column;
  text-align: left;
}

.app-store-label {
  font-size: 0.7rem;
  font-weight: 400;
  opacity: 0.8;
  line-height: 1;
}

.app-store-name {
  font-size: 1.1rem;
  font-weight: 700;
  line-height: 1.2;
}

.app-store-btn--large .app-store-name {
  font-size: 1.25rem;
}

/* Section shared styles */
.screenshots-section,
.features-section,
.steps-section,
.download-section,
.privacy-section,
.legal-links-section {
  padding: 5rem 1.5rem;
}

.screenshots-section,
.features-section,
.steps-section {
  max-width: 1100px;
  margin: 0 auto;
}

.section-title {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  text-align: center;
  margin-bottom: 0.75rem;
  margin-top: 0;
}

/* How it works */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  list-style: none;
  padding: 0;
  margin: 0;
}

.step {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: 16px;
  padding: 2rem 1.75rem;
  text-align: center;
  margin: 0;
}

.step-number {
  display: block;
  font-family: var(--font-display);
  font-size: 2.5rem;
  line-height: 1;
  color: var(--color-gold);
  margin-bottom: 0.75rem;
}

.step h3 {
  margin: 0 0 0.5rem;
  font-size: 1.3rem;
}

.step p {
  margin: 0;
  color: var(--color-text-secondary);
  font-size: 0.95rem;
}

.section-subtitle {
  text-align: center;
  color: var(--color-text-secondary);
  font-size: 1.05rem;
  max-width: 520px;
  margin: 0 auto 3rem;
}

/* Screenshots grid */
.screenshots-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  max-width: 900px;
  margin: 0 auto;
}

.phone-mockup {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: 28px;
  padding: 0.5rem;
  overflow: hidden;
  box-shadow: 0 4px 24px rgba(31, 31, 31, 0.06);
  transition: transform 0.2s, box-shadow 0.2s;
}

.phone-mockup:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(14, 59, 46, 0.15);
}

.phone-mockup img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 20px;
  aspect-ratio: 9 / 19.5;
  object-fit: cover;
}

/* Features grid */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.feature-card {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: 16px;
  padding: 1.75rem;
  transition: border-color 0.2s, transform 0.2s;
}

.feature-card:hover {
  border-color: var(--color-accent);
  transform: translateY(-2px);
}

.feature-icon {
  color: var(--color-accent);
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
}

.feature-card h3 {
  margin-top: 0;
  margin-bottom: 0.5rem;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--color-text);
}

.feature-card p {
  font-size: 0.9rem;
  color: var(--color-text-secondary);
  margin: 0;
  line-height: 1.6;
}

/* Privacy section */
.privacy-section {
  background: var(--color-sage);
  color: var(--color-charcoal);
}

.privacy-card {
  max-width: 740px;
  margin: 0 auto;
  display: flex;
  align-items: flex-start;
  gap: 2rem;
}

.privacy-icon {
  color: var(--color-accent);
  flex-shrink: 0;
  padding-top: 0.25rem;
}

.privacy-text h2 {
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-top: 0;
  margin-bottom: 0.75rem;
}

.privacy-text p {
  color: var(--color-charcoal);
  margin: 0;
  line-height: 1.7;
}

/* Download CTA section */
.download-section {
  text-align: center;
  background: var(--color-forest);
}

.download-section h2 {
  font-size: 2rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-top: 0;
  margin-bottom: 0.75rem;
  color: var(--color-ivory);
}

.download-section p {
  color: rgba(248, 246, 238, 0.82);
  font-size: 1.05rem;
  max-width: 440px;
  margin: 0 auto 2.5rem;
}

/* Legal links section */
.legal-links-section {
  padding: 2rem 1.5rem 3rem;
  text-align: center;
  border-top: 1px solid var(--color-border);
}

.legal-nav {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.legal-nav a {
  font-size: 0.875rem;
  color: var(--color-text-secondary);
  text-decoration: none;
  transition: color 0.2s;
}

.legal-nav a:hover {
  color: var(--color-forest);
  text-decoration: underline;
}

/* ================================================
   RESPONSIVE
   ================================================ */

@media (max-width: 900px) {
  .screenshots-grid {
    grid-template-columns: repeat(2, 1fr);
    max-width: 600px;
  }

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

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

  .marketing-headline {
    font-size: 2.5rem;
  }
}

@media (max-width: 600px) {
  .hero h1 {
    font-size: 1.75rem;
  }

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

  nav .nav-links {
    gap: 1rem;
  }

  h1 {
    font-size: 1.5rem;
  }

  .marketing-headline {
    font-size: 2rem;
  }

  .marketing-subheadline {
    font-size: 1rem;
  }

  .screenshots-grid {
    grid-template-columns: 1fr;
    max-width: 300px;
    margin: 0 auto;
  }

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

  .privacy-card {
    flex-direction: column;
    gap: 1rem;
  }

  .section-title {
    font-size: 1.6rem;
  }

  .download-section h2 {
    font-size: 1.6rem;
  }
}

/* =====================================================================
   Blog & Post styles.
   Reuses existing coral/cream brand tokens — no new design tokens.
   ===================================================================== */

.blog-section {
  max-width: 1100px;
  margin: 3rem auto;
  padding: 0 1.5rem;
}

.blog-section-header {
  text-align: center;
  margin-bottom: 2rem;
}

.post-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem;
  margin-top: 1rem;
}

.post-card {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 1.5rem;
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: 16px;
  color: inherit;
  text-decoration: none;
  transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.post-card:hover,
.post-card:focus-visible {
  transform: translateY(-2px);
  border-color: var(--color-accent);
  box-shadow: 0 8px 24px rgba(14, 59, 46, 0.12);
  outline: none;
}

.post-card-title {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 600;
  line-height: 1.3;
  color: var(--color-text);
  margin: 0;
}

.post-card-description {
  font-size: 0.95rem;
  color: var(--color-text-secondary);
  line-height: 1.55;
  margin: 0;
}

.post-card-meta {
  font-size: 0.825rem;
  color: var(--color-text-secondary);
  margin-top: auto;
  padding-top: 0.25rem;
}

.blog-section-footer {
  text-align: center;
  margin-top: 2rem;
}

.view-all-link {
  display: inline-block;
  font-weight: 700;
  color: var(--color-accent);
  text-decoration: none;
  padding: 0.5rem 1rem;
  border-radius: 999px;
  border: 2px solid var(--color-accent);
  transition: background 0.15s ease, color 0.15s ease;
}

.view-all-link:hover {
  background: var(--color-forest);
  color: var(--color-ivory);
}

/* --- Individual post page --- */

.post-main {
  max-width: var(--max-width);
  margin: 2rem auto;
  padding: 0 1.5rem;
}

.post-header {
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--color-border);
}

.post-kicker {
  font-size: 0.9rem;
  margin: 0 0 1rem;
}

.post-kicker a {
  color: var(--color-accent);
  text-decoration: none;
  font-weight: 600;
}

.post-kicker a:hover {
  text-decoration: underline;
}

.post-title {
  font-family: var(--font-display);
  font-size: 2.25rem;
  line-height: 1.2;
  margin: 0 0 0.75rem;
  color: var(--color-text);
}

.post-subtitle {
  font-size: 1.15rem;
  color: var(--color-text-secondary);
  line-height: 1.5;
  margin: 0 0 1rem;
}

.post-meta {
  font-size: 0.9rem;
  color: var(--color-text-secondary);
}

.post-meta-sep {
  margin: 0 0.5rem;
}

.post-body {
  line-height: 1.75;
  font-size: 1.05rem;
}

.post-body h2 {
  font-family: var(--font-display);
  font-size: 1.6rem;
  margin: 2.25rem 0 1rem;
  color: var(--color-text);
}

.post-body h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  margin: 1.75rem 0 0.75rem;
  color: var(--color-text);
}

.post-body p {
  margin: 0 0 1.2rem;
}

.post-body ul,
.post-body ol {
  margin: 0 0 1.2rem 1.5rem;
}

.post-body li {
  margin-bottom: 0.5rem;
}

.post-body a {
  color: var(--color-accent);
}

.post-body strong {
  color: var(--color-text);
}

.post-body blockquote {
  border-left: 3px solid var(--color-accent);
  padding-left: 1rem;
  margin: 1.5rem 0;
  color: var(--color-text-secondary);
  font-style: italic;
}

.post-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
  font-size: 0.95rem;
}

.post-body th,
.post-body td {
  text-align: left;
  padding: 0.6rem 0.75rem;
  border-bottom: 1px solid var(--color-border);
}

.post-body th {
  background: var(--color-bg);
  font-weight: 700;
}

.post-footer {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--color-border);
}

.post-cta {
  text-align: center;
  padding: 2rem;
  background: var(--color-card);
  border-radius: 16px;
  border: 1px solid var(--color-border);
}

.post-cta h2 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  margin: 0 0 0.75rem;
}

.post-cta p {
  color: var(--color-text-secondary);
  margin: 0 0 1.5rem;
}

/* --- Footer tagline --- */

.footer-tagline {
  font-size: 0.85rem;
  opacity: 0.75;
  margin-top: 0.25rem;
}

@media (max-width: 600px) {
  .post-title {
    font-size: 1.75rem;
  }
  .post-body {
    font-size: 1rem;
  }
  .post-body h2 {
    font-size: 1.35rem;
  }
  .post-body table {
    font-size: 0.85rem;
  }
  .post-body th,
  .post-body td {
    padding: 0.45rem 0.5rem;
  }
}

