/* SnapKnow — Natural-history museum / specimen-label aesthetic */
/* Palette: deep terracotta #7a2e1e, burnt amber #c2611f, warm sand #f7efe3, warm grey #e0dcd6, ink #1a1a1a */

*,*::before,*::after{box-sizing:border-box;margin:0}
html{font-size:18px;scroll-behavior:smooth;-webkit-text-size-adjust:100%}
body{font-family:'DM Sans',system-ui,sans-serif;color:#1a1a1a;background:#f7efe3;line-height:1.65}

/* Top bar */
.topbar{display:flex;justify-content:space-between;align-items:center;padding:.45rem 1.5rem;background:#7a2e1e;color:#f0d9c4;font-size:.72rem;letter-spacing:.03em}
.topbar a{color:#e9b98c;text-decoration:none}
.topbar a:hover{text-decoration:underline}

/* Header */
.site-header{display:flex;align-items:center;padding:.8rem 1.5rem;background:#f7efe3;border-bottom:1px solid #e0dcd6;position:sticky;top:0;z-index:90}
.logo{display:flex;align-items:center;gap:.4rem;text-decoration:none;color:#7a2e1e;font-size:1.15rem;font-weight:600}
.logo svg{color:#c2611f}
.logo b{font-weight:700}
.site-header nav{margin-left:auto;display:flex;gap:1.6rem}
.site-header nav a{text-decoration:none;color:#444;font-size:.78rem;font-weight:500;letter-spacing:.02em}
.site-header nav a:hover{color:#7a2e1e}
.btn-hero{margin-left:1.6rem;padding:.5rem 1.1rem;border-radius:6px;background:#c2611f;color:#fff;text-decoration:none;font-size:.78rem;font-weight:600;border:none;cursor:pointer;transition:background .2s}
.btn-hero:hover{background:#7a2e1e}

/* Hero */
.hero{padding:4rem 1.5rem 3rem;max-width:960px;margin:0 auto}
.kicker{font-family:'DM Mono',monospace;font-size:.72rem;text-transform:uppercase;letter-spacing:.14em;color:#c2611f;margin-bottom:.5rem}
.hero h1{font-size:clamp(2.4rem,6vw,4rem);font-weight:700;line-height:1.05;color:#7a2e1e;margin-bottom:1rem}
.hero .sub{max-width:540px;color:#444;font-size:1rem;margin-bottom:1.2rem}
.badges{list-style:none;display:flex;gap:.6rem;padding:0;margin-bottom:2rem}
.badges li{padding:.25rem .7rem;border:1.5px solid #c2611f;border-radius:20px;font-size:.68rem;color:#c2611f;font-weight:600;letter-spacing:.03em}

/* Snap card (upload area) */
.snap-card{background:#fff;border:1.5px solid #d4d0c8;border-radius:10px;overflow:hidden;max-width:560px;box-shadow:0 2px 12px rgba(122,46,30,.07)}
.snap-card-head{display:flex;align-items:center;gap:.5rem;padding:.55rem .9rem;background:#7a2e1e;color:#f0d9c4}
.dots{display:flex;gap:5px}
.dots i{width:10px;height:10px;border-radius:50%}
.dots i:nth-child(1){background:#e57373}
.dots i:nth-child(2){background:#ffb74d}
.dots i:nth-child(3){background:#81c784}
.snap-title{font-family:'DM Mono',monospace;font-size:.68rem;letter-spacing:.12em;margin-left:.4rem}

.upload-zone{padding:1.5rem;min-height:200px;display:flex;align-items:center;justify-content:center;cursor:pointer;border-bottom:1px dashed #d4d0c8;transition:background .2s}
.upload-zone:hover{background:#f5f2eb}
.upload-prompt{text-align:center;color:#888}
.upload-prompt svg{color:#c2611f;margin-bottom:.5rem}
.upload-prompt p{font-size:.88rem;font-weight:500;color:#555;margin-top:.3rem}
.upload-hint{font-size:.68rem;color:#aaa}
.preview-img{max-width:100%;max-height:300px;border-radius:6px;object-fit:contain}
.preview-img[hidden]{display:none}

.hint-row{padding:.5rem .9rem}
.hint-row input{width:100%;border:1px solid #d4d0c8;border-radius:5px;padding:.4rem .6rem;font-size:.82rem;font-family:inherit;background:#f7efe3}
.hint-row input:focus{outline:none;border-color:#c2611f}

.snap-actions{display:flex;justify-content:space-between;align-items:center;padding:.5rem .9rem .7rem}
.char-count{font-size:.68rem;color:#aaa}
.btn-snap{padding:.5rem 1.4rem;border-radius:6px;background:#c2611f;color:#fff;font-size:.82rem;font-weight:600;border:none;cursor:pointer;transition:background .2s,filter .2s}
.btn-snap:hover:not(:disabled){background:#7a2e1e}
.btn-snap:disabled{opacity:.4;cursor:not-allowed}

.snap-examples{padding:.3rem .9rem .7rem;font-size:.72rem;color:#888}
.example-btn{background:none;border:none;text-decoration:underline;color:#c2611f;cursor:pointer;font-size:.72rem;font-family:inherit}

/* Result card */
.result-card{max-width:560px;margin:1.5rem auto 0;background:#fff;border:1.5px solid #d4d0c8;border-radius:10px;overflow:hidden;box-shadow:0 2px 12px rgba(122,46,30,.07)}
.result-card[hidden]{display:none}
.result-head{display:flex;align-items:baseline;gap:.6rem;padding:.9rem;background:#7a2e1e;color:#fff}
.result-badge{font-family:'DM Mono',monospace;font-size:.62rem;letter-spacing:.12em;color:#e9b98c}
.result-label{font-size:1.25rem;font-weight:700}
.result-meta{display:flex;gap:.6rem;padding:.5rem .9rem;align-items:center;background:#f5f2eb;border-bottom:1px solid #e0dcd6}
.result-category{font-size:.75rem;font-weight:600;color:#c2611f;background:#fbe8d4;padding:.15rem .5rem;border-radius:12px}
.confidence-badge{font-size:.68rem;font-weight:600;padding:.15rem .5rem;border-radius:12px}
.confidence-badge.high{background:#c8e6c9;color:#2e7d32}
.confidence-badge.medium{background:#fff3e0;color:#e65100}
.confidence-badge.low{background:#ffcdd2;color:#c62828}
.result-scientific{padding:.3rem .9rem;font-style:italic;font-size:.78rem;color:#888}
.result-scientific:empty{display:none}
.result-summary{padding:.4rem .9rem .6rem;font-size:.88rem;color:#333;line-height:1.6}

.result-section{padding:.3rem .9rem .6rem;border-top:1px dashed #e0dcd6}
.result-section h5{font-family:'DM Mono',monospace;font-size:.65rem;text-transform:uppercase;letter-spacing:.1em;color:#c2611f;margin-bottom:.3rem;margin-top:.4rem}
.result-section ul{list-style:none;padding:0}
.result-section li{position:relative;padding-left:1rem;font-size:.82rem;color:#444;margin-bottom:.25rem}
.result-section li::before{content:"·";position:absolute;left:0;color:#c2611f;font-weight:700}
.result-section p{font-size:.82rem;color:#444}
.safety-section p{font-weight:600}

.result-footer{display:flex;align-items:center;gap:1rem;padding:.7rem .9rem;border-top:1px solid #e0dcd6;background:#f7efe3}
.btn-new{background:none;border:1.5px solid #c2611f;color:#c2611f;padding:.35rem .9rem;border-radius:5px;font-size:.75rem;font-weight:600;cursor:pointer;transition:background .15s}
.btn-new:hover{background:#fbe8d4}
.result-footer small{font-size:.62rem;color:#aaa;flex:1}

/* How / Steps */
.how{padding:4rem 1.5rem;max-width:960px;margin:0 auto}
.how h2{font-size:clamp(1.4rem,3vw,1.8rem);color:#7a2e1e;margin-bottom:2rem}
.steps{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:1.2rem}
.step{background:#fff;border:1px solid #e0dcd6;border-radius:8px;padding:1.2rem}
.step-num{font-family:'DM Mono',monospace;font-size:.72rem;color:#c2611f;font-weight:600}
.step h3{font-size:1rem;color:#7a2e1e;margin:.4rem 0 .3rem}
.step p{font-size:.82rem;color:#555}

/* What it IDs grid */
.what{padding:4rem 1.5rem;max-width:960px;margin:0 auto}
.what h2{font-size:clamp(1.4rem,3vw,1.8rem);color:#7a2e1e;margin-bottom:2rem}
.grid-cards{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:1rem}
.id-card{background:#fff;border:1px solid #e0dcd6;border-radius:8px;padding:1rem}
.id-card h3{font-size:.88rem;color:#7a2e1e;margin-bottom:.3rem}
.id-card p{font-size:.78rem;color:#666}

/* Why */
.why{padding:4rem 1.5rem;max-width:700px;margin:0 auto}
.why h2{font-size:clamp(1.4rem,3vw,1.8rem);color:#7a2e1e;margin-bottom:1rem}
.why-body{font-size:.92rem;color:#444;line-height:1.7}

/* Plans */
.plans{padding:4rem 1.5rem;max-width:960px;margin:0 auto}
.plans h2{font-size:clamp(1.4rem,3vw,1.8rem);color:#7a2e1e;margin-bottom:2rem}
.plan-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(230px,1fr));gap:1.2rem;align-items:start}
.plan-card{background:#fff;border:1px solid #e0dcd6;border-radius:10px;padding:1.4rem;position:relative}
.plan-card.featured{border-color:#c2611f;border-width:2px}
.plan-badge{position:absolute;top:-.65rem;left:1rem;background:#c2611f;color:#fff;font-size:.6rem;font-weight:600;padding:.2rem .6rem;border-radius:8px;letter-spacing:.04em}
.plan-card h3{font-size:1rem;color:#7a2e1e;font-weight:700}
.price{font-size:1.8rem;font-weight:700;color:#7a2e1e;margin:.3rem 0}
.price small{font-size:.7rem;font-weight:400;color:#888}
.plan-desc{font-size:.78rem;color:#888;margin-bottom:.8rem}
.plan-card ul{list-style:none;padding:0;margin-bottom:1rem}
.plan-card li{font-size:.78rem;color:#555;padding:.2rem 0 .2rem 1rem;position:relative}
.plan-card li::before{content:"✓";position:absolute;left:0;color:#c2611f;font-weight:700;font-size:.72rem}
.tier-btn{display:inline-block;padding:.5rem 1.2rem;border-radius:6px;font-size:.78rem;font-weight:600;text-decoration:none;border:1.5px solid #c2611f;cursor:pointer;transition:background .2s,filter .2s;font-family:inherit}
.tier-btn.ghost{background:transparent;color:#c2611f}
.tier-btn.ghost:hover{background:#fbe8d4}
.tier-btn.solid{background:#c2611f;color:#fff;border-color:#c2611f}
.tier-btn.solid:hover{filter:brightness(1.15)}
.tier-btn:disabled{opacity:.45;cursor:not-allowed}

/* About */
.about{padding:4rem 1.5rem;max-width:700px;margin:0 auto}
.about h2{font-size:clamp(1.4rem,3vw,1.8rem);color:#7a2e1e;margin-bottom:1rem}
.about-body{font-size:.88rem;color:#444;line-height:1.7;margin-bottom:1.5rem}
.sig{border-top:1px dashed #d4d0c8;padding-top:.8rem;font-size:.78rem;color:#888}
.sig b{display:block;color:#7a2e1e;font-size:.92rem;margin-bottom:.1rem}

/* FAQ */
.faq{padding:4rem 1.5rem;max-width:700px;margin:0 auto}
.faq h2{font-size:clamp(1.4rem,3vw,1.8rem);color:#7a2e1e;margin-bottom:1.5rem}
details{border-bottom:1px solid #e0dcd6;padding:.7rem 0}
summary{cursor:pointer;font-weight:600;font-size:.88rem;color:#7a2e1e;list-style:none}
summary::-webkit-details-marker{display:none}
summary::before{content:"+ ";color:#c2611f;font-family:'DM Mono',monospace;margin-right:.3rem}
details[open] summary::before{content:"− "}
details p{font-size:.82rem;color:#555;margin-top:.4rem;line-height:1.6}

/* Newsletter */
.newsletter{padding:3rem 1.5rem;max-width:500px;margin:0 auto;text-align:center}
.newsletter h2{font-size:1.3rem;color:#7a2e1e;margin-bottom:.4rem}
.newsletter p{font-size:.82rem;color:#888;margin-bottom:1rem}
.newsletter form{display:flex;gap:.5rem}
.newsletter input{flex:1;padding:.5rem .7rem;border:1.5px solid #d4d0c8;border-radius:5px;font-size:.82rem;font-family:inherit;background:#fff}
.newsletter input:focus{outline:none;border-color:#c2611f}
.newsletter button{padding:.5rem 1rem;border:none;border-radius:5px;background:#c2611f;color:#fff;font-size:.78rem;font-weight:600;cursor:pointer;font-family:inherit}
.newsletter button:hover{background:#7a2e1e}

/* Footer */
.site-footer{padding:3rem 1.5rem 2rem;border-top:1px solid #e0dcd6;display:flex;flex-wrap:wrap;gap:2rem;max-width:960px;margin:0 auto}
.footer-brand{display:flex;align-items:center;gap:.4rem;font-size:.92rem;color:#7a2e1e;font-weight:600;flex-basis:100%}
.footer-brand svg{color:#c2611f}
.footer-brand b{font-weight:700}
.footer-brand small{margin-left:.5rem;font-size:.68rem;color:#aaa;font-weight:400}
.footer-links{display:flex;gap:3rem;flex-wrap:wrap}
.footer-links div{display:flex;flex-direction:column;gap:.3rem}
.footer-links h4{font-size:.65rem;text-transform:uppercase;letter-spacing:.1em;color:#aaa;margin-bottom:.2rem}
.footer-links a{font-size:.78rem;color:#555;text-decoration:none}
.footer-links a:hover{color:#7a2e1e}
.copyright{flex-basis:100%;font-size:.62rem;color:#bbb;margin-top:1rem}

/* Modal */
.modal-overlay{position:fixed;inset:0;background:rgba(0,0,0,.45);display:flex;align-items:center;justify-content:center;z-index:200}
.modal-overlay[hidden]{display:none}
.modal{background:#fff;border-radius:10px;padding:1.5rem;max-width:380px;width:90%;position:relative}
.modal-close{position:absolute;top:.5rem;right:.7rem;background:none;border:none;font-size:1.3rem;cursor:pointer;color:#888}
.modal h3{font-size:1rem;color:#7a2e1e;margin-bottom:.3rem}
.modal p{font-size:.82rem;color:#888;margin-bottom:.8rem}
.modal form{display:flex;gap:.4rem}
.modal input{flex:1;padding:.45rem .6rem;border:1.5px solid #d4d0c8;border-radius:5px;font-size:.82rem;font-family:inherit}
.modal button[type=submit]{padding:.45rem .9rem;border:none;border-radius:5px;background:#c2611f;color:#fff;font-size:.78rem;font-weight:600;cursor:pointer;font-family:inherit}
.modal-note{font-size:.72rem;color:#888;margin-top:.5rem;min-height:1.2rem}

/* Loading state */
.btn-snap.loading{pointer-events:none;opacity:.6}
.btn-snap.loading::after{content:" ⏳"}

/* Legal docs */
.doc{max-width:700px;margin:0 auto;padding:3rem 1.5rem}
.doc .back{display:inline-block;margin-bottom:1.5rem;color:#c2611f;text-decoration:none;font-size:.82rem}
.doc .back:hover{text-decoration:underline}
.doc h1{font-size:1.8rem;color:#7a2e1e;margin-bottom:.3rem}
.doc .meta{font-size:.75rem;color:#aaa;margin-bottom:1.5rem}
.doc h2{font-size:1.05rem;color:#7a2e1e;margin:1.5rem 0 .4rem}
.doc p,.doc li{font-size:.85rem;color:#444;line-height:1.65}
.doc ul{padding-left:1.2rem;margin:.4rem 0}
.doc li{margin-bottom:.3rem}
.doc a{color:#c2611f}

/* Responsive */
@media(max-width:700px){
  .site-header nav{display:none}
  .btn-hero{margin-left:auto}
  .hero{padding:2.5rem 1rem 2rem}
  .snap-card{max-width:100%}
  .result-card{max-width:100%}
  .steps,.grid-cards,.plan-grid{grid-template-columns:1fr}
  .footer-links{gap:1.5rem}
}
