/* CoHabby Comparison & Alternative Pages — Shared Stylesheet */
/* Extends the brand design system with comparison-specific components */

:root {
    --primary: #FF6B4A;
    --primary-light: #FF8A6A;
    --primary-dark: #E85A3A;
    --primary-subtle: rgba(255, 107, 74, 0.08);
    --secondary: #00A699;
    --secondary-subtle: rgba(0, 166, 153, 0.08);
    --gradient-hero: linear-gradient(135deg, #FF6B4A 0%, #FFB347 35%, #4ECDC4 65%, #00A699 100%);
    --text-primary: #222222;
    --text-secondary: #717171;
    --text-muted: #B0B0B0;
    --bg-white: #FFFFFF;
    --bg-subtle: #FAFAFA;
    --bg-cream: #FFF9F8;
    --border: #EEEEEE;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.1);
    --shadow-glow: 0 8px 30px rgba(255, 90, 95, 0.25);
    --green: #22C55E;
    --red: #EF4444;
    --amber: #F59E0B;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
    font-family: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: var(--text-primary);
    line-height: 1.7;
    background: var(--bg-white);
}

a { color: inherit; }

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 24px;
}

.container--wide {
    max-width: 1080px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ─── NAV ─── */
nav {
    padding: 16px 24px;
    background: rgba(255, 255, 255, 0.98);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.nav-logo img { width: 40px; height: 40px; border-radius: 10px; }

.nav-logo span {
    font-size: 22px;
    font-weight: 700;
    background: var(--gradient-hero);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 32px;
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    transition: color 0.2s;
}

.nav-links a:hover { color: var(--primary); }

.nav-cta {
    background: var(--primary);
    color: white !important;
    padding: 10px 20px;
    border-radius: 24px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.nav-cta:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-glow);
}

/* ─── HERO ─── */
.hero {
    padding: 64px 24px 48px;
    background: var(--bg-cream);
    border-bottom: 1px solid var(--border);
}

.hero .container { max-width: 800px; }

.breadcrumb {
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 16px;
}

.breadcrumb a {
    color: var(--text-secondary);
    text-decoration: none;
}

.breadcrumb a:hover { color: var(--primary); }

.hero h1 {
    font-size: clamp(30px, 4vw, 44px);
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 16px;
}

.hero .subtitle {
    font-size: 18px;
    color: var(--text-secondary);
    max-width: 680px;
    line-height: 1.7;
    margin-bottom: 24px;
}

.article-meta {
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 20px;
}

.hero .micro-intro {
    font-size: 16px;
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 24px;
}

.hero-cta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.trust-signal {
    font-size: 13px;
    color: var(--text-muted);
}

/* ─── BUTTONS ─── */
.btn-gradient {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--gradient-hero);
    color: white;
    padding: 14px 28px;
    border-radius: 28px;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
}

.btn-gradient:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-glow);
}

.btn-outline {
    display: inline-flex;
    align-items: center;
    color: var(--primary-dark);
    text-decoration: none;
    border: 1px solid rgba(255, 107, 74, 0.5);
    border-radius: 28px;
    padding: 12px 20px;
    font-size: 15px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-outline:hover {
    background: rgba(255, 107, 74, 0.08);
    transform: translateY(-2px);
}

/* ─── ARTICLE ─── */
.article-body {
    padding: 56px 0;
}

.article-body h2 {
    font-size: clamp(24px, 3.2vw, 32px);
    font-weight: 700;
    margin-top: 56px;
    margin-bottom: 16px;
    line-height: 1.3;
}

.article-body h2:first-child { margin-top: 0; }

.article-body h3 {
    font-size: 20px;
    font-weight: 700;
    margin-top: 32px;
    margin-bottom: 10px;
    line-height: 1.3;
}

.article-body p {
    font-size: 17px;
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 18px;
}

.article-body a {
    color: var(--primary);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.article-body a:hover { color: var(--primary-dark); }

.article-body ul, .article-body ol {
    padding-left: 24px;
    margin-bottom: 18px;
    color: var(--text-secondary);
}

.article-body li {
    margin-bottom: 8px;
    font-size: 17px;
    line-height: 1.7;
}

/* ─── VERDICT BOX ─── */
.verdict-box {
    background: var(--bg-subtle);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 32px;
    margin: 32px 0;
}

.verdict-box h2, .verdict-box h3 {
    margin-top: 0;
    margin-bottom: 20px;
}

.verdict-columns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}

.verdict-col h4 {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.verdict-col ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.verdict-col li {
    font-size: 15px;
    color: var(--text-secondary);
    padding: 6px 0;
    padding-left: 24px;
    position: relative;
    line-height: 1.6;
}

.verdict-col li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 12px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.verdict-col.choose li::before { background: var(--green); }
.verdict-col.stick li::before { background: var(--text-muted); }

/* ─── COMPARISON TABLE ─── */
.comparison-table-wrap {
    margin: 32px 0;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.comparison-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    border: 1px solid var(--border);
    border-radius: 16px;
    overflow: hidden;
    font-size: 15px;
}

.comparison-table thead th {
    background: var(--bg-subtle);
    font-weight: 700;
    padding: 16px 20px;
    text-align: left;
    border-bottom: 2px solid var(--border);
    white-space: nowrap;
}

.comparison-table thead th:first-child { width: 35%; }

.comparison-table thead th.highlight {
    background: var(--primary-subtle);
    color: var(--primary-dark);
}

.comparison-table tbody td {
    padding: 14px 20px;
    border-bottom: 1px solid var(--border);
    vertical-align: top;
    color: var(--text-secondary);
}

.comparison-table tbody tr:last-child td { border-bottom: none; }

.comparison-table tbody td:first-child {
    font-weight: 600;
    color: var(--text-primary);
}

.comparison-table .check { color: var(--green); font-weight: 700; }
.comparison-table .cross { color: var(--red); font-weight: 700; }
.comparison-table .mixed { color: var(--amber); font-weight: 700; }

/* ─── STAT BLOCKS ─── */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin: 32px 0;
}

.stat-card {
    background: var(--bg-cream);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 24px;
    text-align: center;
}

.stat-card .stat-number {
    font-size: 36px;
    font-weight: 800;
    background: var(--gradient-hero);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.2;
    margin-bottom: 6px;
}

.stat-card .stat-label {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* ─── PULL QUOTES ─── */
.pull-quote {
    background: var(--bg-subtle);
    border-left: 4px solid var(--primary);
    border-radius: 0 12px 12px 0;
    padding: 24px 28px;
    margin: 28px 0;
}

.pull-quote blockquote {
    font-size: 16px;
    font-style: italic;
    color: var(--text-primary);
    line-height: 1.7;
    margin-bottom: 8px;
}

.pull-quote cite {
    font-size: 13px;
    color: var(--text-muted);
    font-style: normal;
}

/* ─── ENTITY BLOCK (About CoHabby) ─── */
.entity-block {
    background: var(--bg-cream);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 28px 32px;
    margin: 32px 0;
}

.entity-block h3 {
    margin-top: 0;
    margin-bottom: 12px;
    font-size: 18px;
}

.entity-block p {
    font-size: 15px;
    margin-bottom: 12px;
}

.entity-block p:last-child { margin-bottom: 0; }

/* ─── FAQ ACCORDION ─── */
.faq-section { margin: 56px 0; }

.faq-item {
    border-bottom: 1px solid var(--border);
}

.faq-question {
    width: 100%;
    background: none;
    border: none;
    padding: 20px 0;
    font-family: inherit;
    font-size: 17px;
    font-weight: 600;
    color: var(--text-primary);
    text-align: left;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    line-height: 1.4;
}

.faq-question::after {
    content: '+';
    font-size: 24px;
    font-weight: 300;
    color: var(--text-muted);
    flex-shrink: 0;
    transition: transform 0.3s ease;
}

.faq-item.open .faq-question::after {
    content: '\2212';
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.faq-answer-inner {
    padding: 0 0 20px;
    font-size: 16px;
    color: var(--text-secondary);
    line-height: 1.8;
}

.faq-answer-inner a {
    color: var(--primary);
    text-decoration: underline;
    text-underline-offset: 2px;
}

/* ─── CTA SECTION ─── */
.cta-section {
    padding: 0 24px 64px;
}

.cta-box {
    max-width: 800px;
    margin: 0 auto;
    background: var(--bg-cream);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 48px 40px;
    text-align: center;
}

.cta-box h2 {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 12px;
}

.cta-box p {
    font-size: 16px;
    color: var(--text-secondary);
    margin-bottom: 24px;
}

.cta-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
}

/* ─── PLATFORM REVIEW CARDS (for roundup pages) ─── */
.platform-review {
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 32px;
    margin: 28px 0;
}

.platform-review.featured {
    border-color: var(--primary);
    border-width: 2px;
    position: relative;
}

.platform-review.featured::before {
    content: 'Our Pick';
    position: absolute;
    top: -12px;
    left: 24px;
    background: var(--primary);
    color: white;
    font-size: 12px;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.platform-review h3 {
    font-size: 22px;
    margin-top: 0;
    margin-bottom: 8px;
}

.platform-review .platform-meta {
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 16px;
}

.platform-review p { margin-bottom: 12px; }

.platform-pros-cons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 16px;
}

.platform-pros h4 { color: var(--green); }
.platform-cons h4 { color: var(--red); }

.platform-pros h4, .platform-cons h4 {
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.platform-pros ul, .platform-cons ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.platform-pros li, .platform-cons li {
    font-size: 14px;
    color: var(--text-secondary);
    padding: 4px 0;
    padding-left: 20px;
    position: relative;
}

.platform-pros li::before {
    content: '+';
    position: absolute;
    left: 0;
    color: var(--green);
    font-weight: 700;
}

.platform-cons li::before {
    content: '\2212';
    position: absolute;
    left: 0;
    color: var(--red);
    font-weight: 700;
}

/* ─── RANKINGS TABLE ─── */
.rankings-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    border: 1px solid var(--border);
    border-radius: 16px;
    overflow: hidden;
    margin: 28px 0;
    font-size: 15px;
}

.rankings-table thead th {
    background: var(--bg-subtle);
    font-weight: 700;
    padding: 14px 18px;
    text-align: left;
    border-bottom: 2px solid var(--border);
}

.rankings-table tbody td {
    padding: 14px 18px;
    border-bottom: 1px solid var(--border);
    color: var(--text-secondary);
}

.rankings-table tbody tr:last-child td { border-bottom: none; }

.rankings-table .rank {
    font-weight: 800;
    color: var(--primary);
    font-size: 18px;
}

.rankings-table .platform-name {
    font-weight: 600;
    color: var(--text-primary);
}

/* ─── INTERNAL LINKS ─── */
.related-links {
    background: var(--bg-subtle);
    border-radius: 16px;
    padding: 24px 28px;
    margin: 32px 0;
}

.related-links h3 {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 12px;
    margin-top: 0;
}

.related-links ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 8px 20px;
}

.related-links li a {
    font-size: 15px;
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
}

.related-links li a:hover { text-decoration: underline; }

/* ─── FOOTER ─── */
footer {
    background: var(--text-primary);
    color: white;
    padding: 48px 24px;
    margin-top: 0;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 24px;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.footer-brand img { width: 32px; height: 32px; border-radius: 8px; }
.footer-brand span { font-size: 18px; font-weight: 700; }

.footer-links {
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.2s;
}

.footer-links a:hover { color: white; }

.footer-copyright {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.4);
}

/* ─── RESPONSIVE ─── */
@media (max-width: 768px) {
    .nav-links a:not(.nav-cta) { display: none; }

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

    .comparison-table { font-size: 14px; }
    .comparison-table thead th,
    .comparison-table tbody td { padding: 10px 12px; }

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

    .platform-pros-cons { grid-template-columns: 1fr; }

    .cta-box { padding: 28px 20px; }

    .footer-container { flex-direction: column; text-align: center; }
    .footer-links { justify-content: center; }
}

@media (max-width: 480px) {
    .stats-grid { grid-template-columns: 1fr; }
    .hero h1 { font-size: 26px; }
}

/* ─── FAQ ACCORDION SCRIPT (inject via page) ─── */
/* Script handles toggling .open class on .faq-item and animating max-height */
