/* Rockhound — whatisthatrock.com
   Mobile-first, no external fonts, system stack for performance. */

:root {
  --orange: #f97316;
  --orange-dark: #c2410c;
  --orange-soft: #ffedd5;
  --teal: #0f766e;
  --teal-dark: #115e59;
  --teal-soft: #ccfbf1;
  --ink: #1c1917;
  --ink-soft: #44403c;
  --muted: #78716c;
  --paper: #ffffff;
  --paper-warm: #fffaf5;
  --line: #e7e5e4;
  --radius: 14px;
  --shadow: 0 4px 24px rgba(28, 25, 23, 0.08);
  --maxw: 1080px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

a { color: var(--teal); }
a:hover { color: var(--teal-dark); }

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }

.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--ink); color: #fff; padding: 10px 16px; z-index: 100;
}
.skip-link:focus { left: 0; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.nav {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; padding: 12px 20px; max-width: var(--maxw); margin: 0 auto;
}
.brand {
  display: flex; align-items: center; gap: 10px;
  font-weight: 700; font-size: 1.05rem; color: var(--ink); text-decoration: none;
}
.brand img { width: 36px; height: 36px; border-radius: 9px; }
.nav-toggle {
  display: inline-flex; flex-direction: column; gap: 5px;
  background: none; border: 0; padding: 8px; cursor: pointer;
}
.nav-toggle span { width: 22px; height: 2px; background: var(--ink); transition: transform 0.2s; }
.nav-links {
  display: none; list-style: none;
  position: absolute; top: 100%; left: 0; right: 0;
  background: var(--paper); border-bottom: 1px solid var(--line);
  padding: 8px 20px 16px;
}
.nav-links.open { display: block; }
.nav-links li { margin: 4px 0; }
.nav-links a {
  display: block; padding: 8px 4px;
  color: var(--ink-soft); text-decoration: none; font-weight: 500;
}
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--orange-dark); }
.nav-cta {
  background: var(--orange); color: #fff !important;
  padding: 9px 18px !important; border-radius: 999px;
  font-weight: 600; text-align: center;
}
.nav-cta:hover { background: var(--orange-dark); }

@media (min-width: 800px) {
  .nav-toggle { display: none; }
  .nav-links {
    display: flex; position: static; border: 0; padding: 0;
    align-items: center; gap: 6px; background: transparent;
  }
  .nav-links li { margin: 0; }
  .nav-links a { padding: 8px 12px; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; text-decoration: none; font-weight: 700;
  border-radius: 999px; padding: 14px 28px; font-size: 1.05rem;
  transition: background 0.15s, transform 0.15s;
}
.btn:active { transform: scale(0.98); }
.btn-primary { background: var(--orange); color: #fff; }
.btn-primary:hover { background: var(--orange-dark); color: #fff; }
.btn-ghost { background: transparent; color: var(--teal); border: 2px solid var(--teal); }
.btn-ghost:hover { background: var(--teal-soft); }
.btn-appstore {
  display: inline-flex; align-items: center; gap: 10px;
  background: var(--ink); color: #fff;
}
.btn-appstore:hover { background: #000; color: #fff; }
.btn-appstore svg { flex: none; }
.btn-note { font-size: 0.85rem; color: var(--muted); margin-top: 8px; }

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(160deg, var(--paper-warm) 0%, var(--orange-soft) 100%);
  padding: 56px 0 40px;
}
.hero .container {
  display: grid; gap: 36px; align-items: center;
}
.hero h1 { font-size: clamp(2rem, 5.5vw, 3.1rem); line-height: 1.15; letter-spacing: -0.02em; }
.hero h1 em { font-style: normal; color: var(--orange-dark); }
.hero .lede { font-size: 1.15rem; color: var(--ink-soft); margin: 18px 0 26px; max-width: 34em; }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.hero-shot { margin: 0 auto; width: min(300px, 70vw); }
.hero-shot img { border-radius: 28px; box-shadow: var(--shadow); }
@media (min-width: 800px) {
  .hero .container { grid-template-columns: 1.2fr 0.8fr; }
  .hero { padding: 80px 0 64px; }
}

/* ---------- Sections ---------- */
.section { padding: 56px 0; }
.section-alt { background: var(--paper-warm); }
.section h2 {
  font-size: clamp(1.5rem, 3.5vw, 2.1rem);
  letter-spacing: -0.01em; margin-bottom: 10px;
}
.section .section-sub { color: var(--muted); max-width: 42em; margin-bottom: 32px; }
.center { text-align: center; }
.center .section-sub { margin-left: auto; margin-right: auto; }

/* Social proof strip */
.proof {
  display: flex; flex-wrap: wrap; justify-content: center;
  gap: 24px 48px; padding: 28px 20px;
  border-bottom: 1px solid var(--line);
}
.proof-item { text-align: center; }
.proof-item strong { display: block; font-size: 1.5rem; color: var(--orange-dark); }
.proof-item span { color: var(--muted); font-size: 0.9rem; }
.stars { color: var(--orange); letter-spacing: 2px; }

/* Feature cards */
.grid { display: grid; gap: 20px; }
@media (min-width: 640px) { .grid-2 { grid-template-columns: 1fr 1fr; } }
@media (min-width: 900px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } }
.card {
  background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 26px;
}
.card .icon {
  width: 44px; height: 44px; border-radius: 12px;
  display: grid; place-items: center; font-size: 1.4rem;
  background: var(--orange-soft); margin-bottom: 14px;
}
.card h3 { font-size: 1.12rem; margin-bottom: 6px; }
.card p { color: var(--ink-soft); font-size: 0.97rem; }

/* Screenshots rail */
.shots {
  display: grid; grid-auto-flow: column; grid-auto-columns: min(240px, 62vw);
  gap: 18px; overflow-x: auto; padding: 8px 20px 20px;
  scroll-snap-type: x mandatory; max-width: var(--maxw); margin: 0 auto;
}
.shots figure { scroll-snap-align: center; }
.shots img { border-radius: 22px; box-shadow: var(--shadow); }
.shots figcaption { text-align: center; font-size: 0.88rem; color: var(--muted); margin-top: 10px; }

/* How it works */
.steps { counter-reset: step; display: grid; gap: 22px; }
@media (min-width: 800px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.step { position: relative; padding: 24px 24px 24px 24px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); }
.step::before {
  counter-increment: step; content: counter(step);
  display: inline-grid; place-items: center;
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--teal); color: #fff; font-weight: 700; margin-bottom: 12px;
}
.step h3 { font-size: 1.08rem; margin-bottom: 6px; }
.step p { color: var(--ink-soft); font-size: 0.97rem; }

/* Testimonials */
.quote {
  background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 26px; height: 100%;
}
.quote blockquote { font-size: 1rem; color: var(--ink-soft); }
.quote cite { display: block; margin-top: 14px; font-style: normal; font-weight: 600; }
.quote .stars { display: block; margin-bottom: 10px; }

/* FAQ */
.faq { max-width: 760px; margin: 0 auto; }
.faq details {
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 0 20px; margin-bottom: 12px; background: var(--paper);
}
.faq summary {
  cursor: pointer; font-weight: 600; padding: 16px 0;
  list-style: none; position: relative; padding-right: 28px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 4px; top: 50%;
  transform: translateY(-50%); font-size: 1.3rem; color: var(--orange);
}
.faq details[open] summary::after { content: "–"; }
.faq details p { padding: 0 0 18px; color: var(--ink-soft); }

/* Final CTA band */
.cta-band {
  background: linear-gradient(135deg, var(--teal) 0%, var(--teal-dark) 100%);
  color: #fff; text-align: center; padding: 64px 20px;
}
.cta-band h2 { font-size: clamp(1.6rem, 4vw, 2.3rem); margin-bottom: 12px; }
.cta-band p { opacity: 0.9; max-width: 38em; margin: 0 auto 28px; }
.cta-band .btn-primary { background: var(--orange); }
.cta-band .btn-note { color: rgba(255,255,255,0.75); }

/* ---------- Article / guide pages ---------- */
.article { max-width: 760px; margin: 0 auto; padding: 40px 20px 64px; }
.article header h1 { font-size: clamp(1.8rem, 4.5vw, 2.5rem); line-height: 1.2; margin-bottom: 10px; }
.article .byline { color: var(--muted); font-size: 0.9rem; margin-bottom: 28px; }
.article h2 { font-size: 1.5rem; margin: 40px 0 14px; }
.article h3 { font-size: 1.18rem; margin: 28px 0 10px; }
.article p, .article li { color: var(--ink-soft); }
.article p { margin: 0 0 16px; }
.article ul, .article ol { margin: 0 0 16px 24px; }
.article li { margin-bottom: 6px; }
.article figure { margin: 28px auto; max-width: 300px; }
.article figure img { border-radius: 22px; box-shadow: var(--shadow); }
.article figcaption { text-align: center; font-size: 0.85rem; color: var(--muted); margin-top: 10px; }
.article table { width: 100%; border-collapse: collapse; margin: 0 0 20px; font-size: 0.95rem; }
.article th, .article td { border: 1px solid var(--line); padding: 10px 12px; text-align: left; }
.article th { background: var(--paper-warm); }
.table-wrap { overflow-x: auto; }
.breadcrumb { font-size: 0.85rem; color: var(--muted); margin-bottom: 20px; }
.breadcrumb ol { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin: 0; }
.breadcrumb li + li::before { content: "›"; margin-right: 6px; color: var(--line); }
.breadcrumb a { color: var(--muted); }

/* In-article CTA box */
.app-callout {
  display: flex; gap: 16px; align-items: center;
  background: var(--orange-soft); border: 1px solid #fed7aa;
  border-radius: var(--radius); padding: 20px; margin: 32px 0;
}
.app-callout img { width: 64px; height: 64px; border-radius: 14px; flex: none; }
.app-callout p { margin: 0 0 10px; font-size: 0.95rem; }
.app-callout strong { color: var(--ink); }
.app-callout .btn { padding: 10px 20px; font-size: 0.95rem; }

/* Related guides */
.related { border-top: 1px solid var(--line); margin-top: 48px; padding-top: 28px; }
.related h2 { margin-top: 0; }
.related ul { list-style: none; margin: 0; }
.related li { margin-bottom: 10px; }

/* ---------- Pricing ---------- */
.plans { display: grid; gap: 20px; max-width: 900px; margin: 0 auto; }
@media (min-width: 800px) { .plans { grid-template-columns: 1fr 1fr 1fr; } }
.plan {
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 30px 26px; background: var(--paper); text-align: center;
}
.plan.featured { border: 2px solid var(--orange); position: relative; }
.plan .flag {
  position: absolute; top: -13px; left: 50%; transform: translateX(-50%);
  background: var(--orange); color: #fff; font-size: 0.78rem; font-weight: 700;
  padding: 3px 14px; border-radius: 999px; white-space: nowrap;
}
.plan h3 { font-size: 1.15rem; }
.plan .price { font-size: 2.2rem; font-weight: 800; margin: 10px 0 2px; }
.plan .per { color: var(--muted); font-size: 0.9rem; margin-bottom: 18px; }
.plan ul { list-style: none; text-align: left; margin: 0 0 22px; }
.plan li { padding: 6px 0 6px 26px; position: relative; color: var(--ink-soft); font-size: 0.95rem; }
.plan li::before { content: "✓"; position: absolute; left: 0; color: var(--teal); font-weight: 700; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--ink); color: #d6d3d1;
  padding: 48px 0 32px; font-size: 0.92rem;
}
.site-footer a { color: #d6d3d1; text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.footer-grid { display: grid; gap: 32px; }
@media (min-width: 800px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; } }
.footer-brand { display: flex; align-items: center; gap: 10px; font-weight: 700; color: #fff; margin-bottom: 12px; }
.footer-brand img { width: 32px; height: 32px; border-radius: 8px; }
.site-footer h3 { color: #fff; font-size: 0.95rem; margin-bottom: 12px; }
.site-footer ul { list-style: none; }
.site-footer li { margin-bottom: 8px; }
.footer-legal {
  border-top: 1px solid #44403c; margin-top: 36px; padding-top: 20px;
  display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between;
  color: #a8a29e; font-size: 0.85rem;
}

/* Forms (contact) */
.form { max-width: 560px; }
.form label { display: block; font-weight: 600; margin: 18px 0 6px; }
.form input, .form textarea {
  width: 100%; padding: 12px 14px; border: 1px solid var(--line);
  border-radius: 10px; font: inherit; background: var(--paper);
}
.form input:focus, .form textarea:focus { outline: 2px solid var(--teal); border-color: var(--teal); }

/* Utility */
.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
