/* HairMatch AI — shared styles for guide/answer pages.
   Mirrors the design tokens used inline on the landing page. */

:root {
    --primary: #FF5C00;
    --primary-dark: #E04F00;
    --bg: #0A0A0B;
    --surface: #141416;
    --surface-2: #1B1B1E;
    --text: #F5F5F7;
    --text-secondary: #A1A1AA;
    --border: #26262A;
    --radius: 16px;
}
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
}
.container { max-width: 960px; margin: 0 auto; padding: 0 24px; }
.serif { font-family: 'Instrument Serif', Georgia, 'Times New Roman', serif; font-weight: 400; }
a { color: var(--primary); }

/* Nav — identical to the landing page */
nav {
    padding: 18px 0;
    border-bottom: 1px solid var(--border);
    background: rgba(10,10,11,0.85);
    backdrop-filter: blur(12px);
    position: sticky;
    top: 0;
    z-index: 100;
}
nav .container { display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.logo { display: inline-flex; align-items: center; gap: 10px; font-size: 19px; font-weight: 700; color: var(--text); text-decoration: none; }
.logo img { width: 30px; height: 30px; border-radius: 8px; }
.logo span { color: var(--primary); }
.nav-links { white-space: nowrap; }
.nav-links a {
    margin-left: 24px;
    text-decoration: none;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    transition: color 0.2s;
}
.nav-links a:hover { color: var(--primary); }

/* Article shell */
.article-wrap { max-width: 760px; margin: 0 auto; padding: 0 24px; }
article { padding: 44px 0 24px; }

.breadcrumb { font-size: 13px; color: var(--text-secondary); margin-bottom: 22px; }
.breadcrumb a { color: var(--text-secondary); text-decoration: none; }
.breadcrumb a:hover { color: var(--primary); }
.breadcrumb span { margin: 0 8px; opacity: 0.5; }

article h1 {
    font-family: 'Instrument Serif', Georgia, 'Times New Roman', serif;
    font-weight: 400;
    font-size: clamp(32px, 5.2vw, 46px);
    line-height: 1.13;
    letter-spacing: -0.01em;
    margin-bottom: 22px;
}
article h1 em { font-style: italic; color: var(--primary); }

/* The direct answer — first two sentences, visually distinct */
.answer {
    border-left: 3px solid var(--primary);
    background: rgba(255,92,0,0.06);
    border-radius: 0 12px 12px 0;
    padding: 18px 22px;
    font-size: 17.5px;
    margin-bottom: 30px;
}
.answer p + p { margin-top: 10px; }
.answer strong { color: var(--text); }

article h2 {
    font-family: 'Instrument Serif', Georgia, 'Times New Roman', serif;
    font-weight: 400;
    font-size: clamp(25px, 3.6vw, 31px);
    line-height: 1.25;
    margin: 46px 0 14px;
    scroll-margin-top: 80px;
}
article h3 {
    font-size: 18px;
    font-weight: 600;
    margin: 30px 0 10px;
    scroll-margin-top: 80px;
}
article h4 { font-size: 15px; font-weight: 600; margin: 20px 0 6px; color: var(--text); }
article p { margin-bottom: 16px; color: #DCDCE0; }
article ul, article ol { margin: 0 0 18px 22px; color: #DCDCE0; }
article li { margin-bottom: 8px; }
article li::marker { color: var(--primary); }
article strong { color: var(--text); font-weight: 600; }
hr { border: 0; border-top: 1px solid var(--border); margin: 44px 0; }

/* Table of contents */
.toc {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px 24px;
    margin-bottom: 34px;
}
.toc p { font-size: 12.5px; text-transform: uppercase; letter-spacing: 0.07em; color: var(--text-secondary); margin-bottom: 10px; font-weight: 600; }
.toc ul { list-style: none; margin: 0; column-gap: 26px; }
.toc li { margin-bottom: 6px; }
.toc a { color: #DCDCE0; text-decoration: none; font-size: 14.5px; }
.toc a:hover { color: var(--primary); }
@media (min-width: 620px) { .toc ul { columns: 2; } }

/* Cards / callouts */
.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 22px 24px;
    margin: 22px 0;
}
.card h3 { margin-top: 0; }
.card p:last-child, .card ul:last-child { margin-bottom: 0; }

.note {
    background: var(--surface);
    border: 1px solid var(--border);
    border-left: 3px solid var(--text-secondary);
    border-radius: 0 12px 12px 0;
    padding: 16px 20px;
    margin: 24px 0;
    font-size: 14.5px;
    color: var(--text-secondary);
}
.note strong { color: var(--text); }
.note p:last-child { margin-bottom: 0; }

/* Disclosure — who wrote this page */
.disclosure {
    background: rgba(255,92,0,0.06);
    border: 1px solid rgba(255,92,0,0.28);
    border-radius: var(--radius);
    padding: 18px 22px;
    margin: 26px 0;
    font-size: 14.5px;
    color: #DCDCE0;
}
.disclosure strong { color: var(--primary); }
.disclosure p:last-child { margin-bottom: 0; }

/* Face-shape / style blocks */
.shape-block { border-top: 2px solid var(--primary); padding-top: 6px; margin-top: 42px; }
.shape-block h2 { margin-top: 10px; }
.pill-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 16px; }
.pill {
    font-size: 12.5px;
    font-weight: 600;
    letter-spacing: 0.02em;
    padding: 5px 12px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: var(--surface-2);
    color: var(--text-secondary);
}
.pill.good { border-color: rgba(255,92,0,0.35); background: rgba(255,92,0,0.10); color: var(--primary); }

.two-col { display: grid; grid-template-columns: 1fr; gap: 16px; margin: 18px 0 6px; }
@media (min-width: 620px) { .two-col { grid-template-columns: 1fr 1fr; } }
.two-col .card { margin: 0; }

/* Tables — scroll horizontally on small screens */
.table-scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    margin: 24px 0 10px;
    background: var(--surface);
}
table { border-collapse: collapse; width: 100%; min-width: 620px; font-size: 14.5px; }
caption { caption-side: top; text-align: left; padding: 16px 18px 4px; font-size: 13px; color: var(--text-secondary); }
th, td { padding: 13px 16px; text-align: left; border-bottom: 1px solid var(--border); vertical-align: top; }
thead th {
    font-size: 12.5px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-secondary);
    font-weight: 600;
    background: var(--surface-2);
    white-space: nowrap;
}
tbody th { font-weight: 600; color: var(--text); white-space: nowrap; }
tbody tr:last-child th, tbody tr:last-child td { border-bottom: 0; }
tr.is-ours { background: rgba(255,92,0,0.07); }
tr.is-ours th { color: var(--primary); }
.table-source { font-size: 12.5px; color: var(--text-secondary); margin: 0 0 26px; }
.yes { color: var(--primary); font-weight: 600; }
.no { color: var(--text-secondary); }

/* Screenshots */
figure.shot { margin: 26px 0; text-align: center; }
figure.shot img {
    display: block;
    width: 100%;
    max-width: 300px;
    height: auto;
    margin: 0 auto;
    border-radius: 20px;
    border: 1px solid var(--border);
}
figure.shot figcaption { font-size: 13px; color: var(--text-secondary); margin-top: 12px; }
figure.shot.wide img { max-width: 340px; }

/* Prompt block */
.prompt-block {
    background: #0F0F11;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px 22px;
    margin: 20px 0;
    font-family: ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, monospace;
    font-size: 13.5px;
    line-height: 1.62;
    color: #DCDCE0;
    white-space: pre-wrap;
    overflow-x: auto;
}

/* App mention / CTA */
.app-mention {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    margin: 30px 0;
    display: flex;
    gap: 18px;
    align-items: flex-start;
}
.app-mention img { width: 56px; height: 56px; border-radius: 13px; flex-shrink: 0; }
.app-mention h3 { margin: 0 0 6px; font-size: 17px; }
.app-mention p { font-size: 14.5px; margin-bottom: 12px; }
.app-mention .cta-button { font-size: 14.5px; padding: 11px 20px; }
.cta-button {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    background: var(--primary);
    color: #fff;
    padding: 14px 26px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 15.5px;
    transition: background 0.2s, transform 0.15s;
}
.cta-button:hover { background: var(--primary-dark); transform: translateY(-1px); }
.cta-button svg { width: 18px; height: 18px; }
@media (max-width: 520px) {
    .app-mention { flex-direction: column; gap: 14px; }
}

/* Related pages */
.related { border-top: 1px solid var(--border); padding: 34px 0 10px; }
.related h2 { font-family: 'Instrument Serif', Georgia, serif; font-weight: 400; font-size: 26px; margin-bottom: 16px; }
.related ul { list-style: none; margin: 0; }
.related li { margin-bottom: 11px; }
.related a { text-decoration: none; font-weight: 500; }
.related a:hover { text-decoration: underline; }
.related .desc { display: block; color: var(--text-secondary); font-size: 14px; font-weight: 400; }

/* Updated stamp */
.updated {
    font-size: 13px;
    color: var(--text-secondary);
    border-top: 1px solid var(--border);
    padding-top: 18px;
    margin-top: 34px;
}

/* Footer */
footer { border-top: 1px solid var(--border); padding: 36px 0; text-align: center; margin-top: 20px; }
.footer-links { margin-bottom: 14px; }
.footer-links a {
    margin: 0 14px;
    text-decoration: none;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    transition: color 0.2s;
}
.footer-links a:hover { color: var(--primary); }
.copyright { font-size: 13px; color: var(--text-secondary); }

@media (max-width: 640px) {
    .logo { font-size: 16.5px; gap: 8px; }
    .logo img { width: 26px; height: 26px; }
    .nav-links a { margin-left: 13px; font-size: 13px; }
    article { padding: 30px 0 20px; }
    .answer { font-size: 16.5px; padding: 16px 18px; }
    .footer-links a { margin: 0 9px; font-size: 13px; }
}
