/* First35 Blog — matches privacy.html / terms.html look
   Layouts: B (side-by-side post header) + D (thumbnail listing) */

:root {
  --bg: #f4f3ee;
  --ink: #181818;
  --bodyText: #3b3b36;
  --muted: #85857f;
  --line: #e7e4dc;
  --orange: #ff6a1a;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Hiragino Sans", "Yu Gothic", "Meiryo", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { background: var(--bg); color: var(--ink); overflow-x: hidden; }

/* ─── Nav ─────────────────────────────────────── */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  background: rgba(244,243,238,.85);
  border-bottom: 1px solid rgba(0,0,0,.04);
  padding: 14px 0;
}
nav .inner {
  display: flex; align-items: center; justify-content: space-between;
  max-width: 1100px; margin: 0 auto; padding: 0 24px; gap: 16px;
}
nav .logo {
  display: flex; align-items: center; gap: 10px;
  font-size: 18px; font-weight: 900; letter-spacing: -.8px;
  color: var(--ink); text-decoration: none;
}
nav .logo img { width: 36px; height: 36px; border-radius: 10px; }
nav .nav-right { display: flex; align-items: center; gap: 12px; }

/* Language toggle pill */
.lang-toggle {
  display: inline-flex; align-items: center; gap: 2px;
  background: rgba(0,0,0,.05);
  border-radius: 999px;
  padding: 3px;
}
.lang-toggle a {
  font-size: 11px; font-weight: 800; letter-spacing: 1.2px;
  color: var(--muted); text-decoration: none;
  padding: 6px 12px; border-radius: 999px;
  transition: color .15s, background .15s;
}
.lang-toggle a:hover { color: var(--ink); }
.lang-toggle a.active { background: var(--ink); color: #fff; }

/* Orange "Try First35" CTA */
.try-cta {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 13px; font-weight: 850; letter-spacing: .2px;
  color: #fff; text-decoration: none;
  padding: 9px 16px; border-radius: 999px;
  background: var(--orange);
  box-shadow: 0 8px 18px rgba(255,106,26,.20);
  transition: transform .2s, box-shadow .2s;
}
.try-cta:hover { transform: translateY(-1px); box-shadow: 0 12px 24px rgba(255,106,26,.28); }
.try-cta .arrow { transition: transform .2s; }
.try-cta:hover .arrow { transform: translateX(3px); }

/* ─── Container / layout ──────────────────────── */
.container { max-width: 960px; margin: 0 auto; padding: 140px 24px 80px; }

/* ─── Post header (Layout B: side-by-side) ────── */
.post-header {
  display: grid;
  grid-template-columns: 1fr 240px;
  gap: 44px;
  align-items: start;
}
.post-header-text h1 {
  font-size: clamp(36px, 4.6vw, 48px);
  font-weight: 950;
  letter-spacing: -1.8px;
  line-height: 1.05;
  color: var(--ink);
}
.post-header-text .effective {
  margin-top: 14px;
  font-size: 13px; font-weight: 700;
  letter-spacing: .5px; text-transform: uppercase;
  color: var(--muted);
}
.post-header-text .intro {
  margin-top: 22px;
  font-size: 17px; line-height: 1.7;
  color: var(--bodyText);
}
.post-hero {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 20px;
  object-fit: cover;
  display: block;
}

/* ─── Post body (max 720px for reading) ───────── */
.post-body {
  max-width: 720px;
  margin: 56px auto 0;
}
.legal-article h2 {
  font-size: 24px; font-weight: 900;
  letter-spacing: -.4px; color: var(--ink);
  margin-top: 52px;
}
.legal-article h3 {
  font-size: 18px; font-weight: 900;
  letter-spacing: -.2px; color: var(--ink);
  margin-top: 32px;
}
.legal-article p {
  font-size: 17px; line-height: 1.75;
  color: var(--bodyText); margin-top: 16px;
  font-weight: 450;
}
.legal-article ul, .legal-article ol { margin-top: 14px; padding-left: 24px; }
.legal-article li {
  font-size: 17px; line-height: 1.75;
  color: var(--bodyText); padding: 4px 0;
  font-weight: 450;
}
.legal-article a {
  color: var(--ink); font-weight: 700;
  text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 3px;
}
.legal-article a:hover { color: var(--orange); }
.legal-article strong { font-weight: 800; color: var(--ink); }
.legal-article em { font-style: italic; }
.legal-article blockquote {
  margin: 24px 0; padding: 16px 20px;
  border-left: 3px solid var(--ink);
  background: rgba(0,0,0,.03);
  font-size: 17px; line-height: 1.7;
  color: var(--bodyText); font-style: italic;
}
.legal-article code {
  font-family: "SF Mono", "Menlo", "Roboto Mono", monospace;
  font-size: 14px; background: rgba(0,0,0,.06);
  padding: 2px 6px; border-radius: 4px;
}
.legal-article pre {
  margin: 20px 0; padding: 16px;
  background: #f0efe9; border: 1px solid var(--line);
  border-radius: 8px; overflow-x: auto;
  font-size: 13px; line-height: 1.5;
}
.legal-article pre code { background: transparent; padding: 0; }
.legal-article img {
  max-width: 100%; height: auto;
  border-radius: 8px; margin: 24px 0;
  display: block;
}
.legal-article hr { margin: 44px 0; border: 0; border-top: 1px solid var(--line); }
.legal-article table {
  margin: 24px 0; border-collapse: collapse; width: 100%; font-size: 15px;
}
.legal-article th, .legal-article td {
  padding: 10px 14px; text-align: left;
  border-bottom: 1px solid var(--line); color: var(--bodyText);
}
.legal-article th { font-weight: 900; color: var(--ink); border-bottom-width: 2px; }

/* ─── Divider before CTA ──────────────────────── */
.post-divider {
  max-width: 720px; margin: 60px auto 32px;
  border: 0; border-top: 1px solid var(--line);
}

/* ─── Enhanced Post CTA (App Store button) ────── */
.post-cta {
  max-width: 720px; margin: 8px auto 0;
  padding: 36px;
  background: #fff;
  border-radius: 20px;
  border: 1px solid var(--line);
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 32px;
  align-items: center;
}
.post-cta-text .cta-eyebrow {
  font-size: 11px; font-weight: 800; letter-spacing: 1.5px;
  color: var(--muted); text-transform: uppercase;
}
.post-cta-text h3 {
  margin-top: 8px;
  font-size: 22px; font-weight: 900; letter-spacing: -.4px; color: var(--ink);
}
.post-cta-text p {
  margin-top: 10px; font-size: 15px; line-height: 1.6; color: var(--bodyText);
}

/* Apple App Store button (official SVG badge) */
.app-store-btn {
  display: inline-block;
  text-decoration: none !important;
  transition: transform .2s, opacity .2s;
  line-height: 0;
}
.app-store-btn:hover { transform: translateY(-1px); opacity: .85; }
.app-store-btn img { height: 48px; width: auto; display: block; }

/* ─── Blog listing (Layout D: thumbnail cards) ──── */
.blog-listing h1 {
  font-size: clamp(40px, 5vw, 56px);
  font-weight: 950; letter-spacing: -2px;
  line-height: 1.05; color: var(--ink);
}
.blog-listing .intro {
  margin-top: 20px;
  font-size: 17px; line-height: 1.7;
  color: var(--bodyText); max-width: 640px;
}
.post-list {
  list-style: none; padding: 0;
  margin: 56px 0 0;
}
.post-list li {
  border-top: 1px solid var(--line);
  padding: 8px 0;
  border-radius: 16px;
  transition: box-shadow .25s, background .25s;
}
.post-list li:last-child { border-bottom: 1px solid var(--line); }
.post-list li:hover {
  box-shadow: 0 12px 32px rgba(0,0,0,.06), 0 4px 12px rgba(0,0,0,.04);
  background: #fff;
}
.post-list li.empty {
  color: var(--muted); padding: 40px 0;
  font-size: 15px; text-align: center;
  border-bottom: 1px solid var(--line);
}
.post-list a {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 36px;
  text-decoration: none;
  color: inherit;
  align-items: center;
  padding: 24px 20px;
  border-radius: 16px;
}
.thumb {
  width: 160px;
  aspect-ratio: 1 / 1;
  border-radius: 16px;
  object-fit: cover;
  background: var(--line);
  display: block;
}
.thumb-placeholder {
  background: linear-gradient(135deg, #ecebe4, #d8d7d0);
}
.post-list-text {
  min-width: 0;
}
.post-meta {
  font-size: 12px; font-weight: 800; letter-spacing: 1px;
  color: var(--muted); text-transform: uppercase;
}
.post-list-text h2 {
  margin-top: 8px;
  font-size: 24px; font-weight: 900; letter-spacing: -.5px;
  color: var(--ink); line-height: 1.2;
  transition: color .2s;
}
.post-list a:hover h2 { color: var(--orange); }
.post-excerpt {
  margin-top: 10px;
  font-size: 16px; line-height: 1.6;
  color: var(--bodyText); font-weight: 450;
}
.post-read-more {
  margin-top: 16px;
  font-size: 12px; font-weight: 800; letter-spacing: 1px;
  color: var(--orange); text-transform: uppercase;
}
.post-read-more .arrow {
  display: inline-block;
  transition: transform .2s;
}
.post-list a:hover .post-read-more .arrow { transform: translateX(4px); }

/* ─── Footer ──────────────────────────────────── */
footer {
  border-top: 1px solid var(--line);
  padding: 40px 0 60px;
  text-align: center;
}
footer p { font-size: 13px; color: var(--muted); margin: 0; }
footer a { color: var(--muted); text-decoration: none; font-weight: 700; }
footer a:hover { color: var(--ink); }
footer .links {
  display: inline-flex; gap: 20px;
  margin-top: 12px; flex-wrap: wrap;
  justify-content: center;
}

/* ─── Mobile ──────────────────────────────────── */
@media (max-width: 760px) {
  .container { padding-top: 100px; }
  nav .nav-right { gap: 8px; }
  .try-cta { padding: 8px 12px; font-size: 12px; }
  .lang-toggle a { padding: 5px 10px; font-size: 10px; }

  /* Post header: stack image above title on mobile */
  .post-header { grid-template-columns: 1fr; gap: 24px; }
  .post-hero { max-width: 280px; margin: 0 auto; }
  .post-header-text { order: 2; }
  .post-header .post-hero { order: 1; }

  .post-body { margin-top: 40px; }
  .legal-article h2 { margin-top: 40px; }

  /* CTA: stack button below text */
  .post-cta { grid-template-columns: 1fr; gap: 24px; padding: 28px; }
  .post-cta-action { justify-self: start; }
  .app-store-btn { min-width: 0; }

  /* Post list: thumb above text */
  .post-list a { grid-template-columns: 1fr; gap: 18px; }
  .thumb { max-width: 280px; }
}
