/* Elf 5 / Periscope — Custom overrides on top of Materialize CSS */

/* ── Fonts ────────────────────────────────────────────────────────── */
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* ── Skip to content ─────────────────────────────────────────────── */
.skip-to-content {
    position: absolute;
    left: -9999px;
    top: auto;
    width: 1px;
    height: 1px;
    overflow: hidden;
    z-index: 9999;
}
.skip-to-content:focus {
    position: fixed;
    top: 10px;
    left: 10px;
    width: auto;
    height: auto;
    padding: 12px 24px;
    background: #1565c0;
    color: #fff;
    font-weight: 600;
    border-radius: 4px;
    text-decoration: none;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

/* ── Focus indicators ────────────────────────────────────────────── */
a:focus-visible,
button:focus-visible,
.btn:focus-visible,
.btn-large:focus-visible,
.collapsible-header:focus-visible {
    outline: 2px solid #1565c0;
    outline-offset: 2px;
}

/* ── Card headings (h3 styled to preserve visual hierarchy) ──────── */
.card-content h3,
.card-panel h3,
.center-align h3,
h3[style*="margin-top"] {
    font-size: 1.2rem;
    font-weight: 600;
    margin: 0.5rem 0 0.8rem;
}

/* ── Navbar ───────────────────────────────────────────────────────── */
nav {
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.08);
}
nav .brand-logo img {
    height: 48px;
    margin-top: 8px;
    border-radius: 4px;
}
nav ul a {
    color: #546e7a;
    font-weight: 500;
    font-size: 0.95rem;
}
nav ul a:hover,
nav ul li.active a {
    color: #1565c0;
    background-color: transparent;
}
.sidenav li > a {
    color: #546e7a;
    font-weight: 500;
}
.sidenav li > a:hover {
    color: #1565c0;
}

/* ── Hero ─────────────────────────────────────────────────────────── */
.hero-section {
    background: linear-gradient(135deg, #1565c0 0%, #7b1fa2 100%);
    padding: 100px 0 80px;
    color: #fff;
}
.hero-section h1 {
    font-size: 2.8rem;
    font-weight: 700;
    margin-bottom: 1rem;
}
.hero-section p.lead {
    font-size: 1.15rem;
    line-height: 1.7;
    opacity: 0.92;
    max-width: 640px;
}
.hero-section .btn-large {
    margin-top: 1.5rem;
    margin-right: 0.75rem;
    text-transform: none;
    font-weight: 600;
    border-radius: 6px;
}

/* ── Page headers (inner pages) ───────────────────────────────────── */
.page-header-section {
    background: linear-gradient(135deg, #1565c0 0%, #7b1fa2 100%);
    padding: 80px 0 50px;
    color: #fff;
}
.page-header-section h1 {
    font-size: 2.4rem;
    font-weight: 700;
}
.page-header-section p {
    font-size: 1.1rem;
    opacity: 0.92;
    max-width: 640px;
}

/* ── Section spacing ──────────────────────────────────────────────── */
.section {
    padding: 60px 0;
}
.section-title {
    font-size: 1.8rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
}

/* ── Cards ────────────────────────────────────────────────────────── */
.card .card-content .card-title {
    font-weight: 600;
    font-size: 1.2rem;
}
.card i.material-icons.medium {
    color: #1565c0;
}

/* ── Comparison table ─────────────────────────────────────────────── */
.table-scroll-wrapper {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}
table.comparison-table {
    border-collapse: collapse;
    min-width: 700px;
}
table.comparison-table thead {
    background-color: #f5f5f5;
}
table.comparison-table th,
table.comparison-table td {
    padding: 12px 16px;
    font-size: 0.95rem;
}
table.comparison-table td:first-child,
table.comparison-table th:first-child {
    font-weight: 600;
    position: sticky;
    left: 0;
    background-color: #fff;
    z-index: 1;
}
table.comparison-table thead th:first-child {
    background-color: #f5f5f5;
}

/* ── Code blocks ──────────────────────────────────────────────────── */
pre.code-block {
    background-color: #263238;
    color: #eeffff;
    padding: 20px 24px;
    border-radius: 8px;
    overflow-x: auto;
    font-family: 'Fira Code', 'Consolas', 'Monaco', monospace;
    font-size: 0.9rem;
    line-height: 1.6;
    margin: 1rem 0 1.5rem;
}
code.inline {
    background-color: #f5f5f5;
    padding: 2px 8px;
    border-radius: 4px;
    font-family: 'Fira Code', 'Consolas', 'Monaco', monospace;
    font-size: 0.88em;
    color: #c62828;
}

/* ── ASCII diagram ────────────────────────────────────────────────── */
pre.diagram {
    background-color: #fafafa;
    border: 1px solid #e0e0e0;
    padding: 20px 24px;
    border-radius: 8px;
    overflow-x: auto;
    font-family: 'Fira Code', 'Consolas', 'Monaco', monospace;
    font-size: 0.85rem;
    line-height: 1.5;
    color: #37474f;
    margin: 1rem 0 1.5rem;
}

/* ── Rollout timeline ─────────────────────────────────────────────── */
.timeline-badge {
    display: inline-block;
    padding: 4px 14px;
    border-radius: 16px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.badge-now {
    background-color: #e8f5e9;
    color: #2e7d32;
}
.badge-next {
    background-color: #e3f2fd;
    color: #1565c0;
}
.badge-future {
    background-color: #f3e5f5;
    color: #7b1fa2;
}

/* ── FAQ collapsible ──────────────────────────────────────────────── */
.collapsible.faq-list {
    border: none;
    box-shadow: none;
}
.collapsible.faq-list li {
    margin-bottom: 8px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
}
.collapsible.faq-list .collapsible-header {
    font-weight: 600;
    border-bottom: none;
    padding: 16px 20px;
    background-color: #fafafa;
}
.collapsible.faq-list .collapsible-body {
    padding: 0 20px 16px;
}
.collapsible.faq-list .collapsible-body p {
    margin: 0;
    color: #616161;
    line-height: 1.6;
}

/* ── Footer ───────────────────────────────────────────────────────── */
.page-footer {
    background-color: #263238;
}
.page-footer h5 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
}
.page-footer li {
    margin-bottom: 6px;
}
.page-footer a {
    color: #b0bec5;
}
.page-footer a:hover {
    color: #fff;
}
.footer-copyright {
    background-color: #1c252a;
}

/* ── Legal pages ──────────────────────────────────────────────────── */
.legal-content h3 {
    margin-top: 2rem;
    font-size: 1.3rem;
    font-weight: 600;
}
.legal-content p,
.legal-content li {
    line-height: 1.8;
    color: #616161;
}
.legal-content ul {
    padding-left: 1.5rem;
}
.legal-content ul li {
    list-style-type: disc;
    margin-bottom: 0.5rem;
}

/* ── Getting started steps ────────────────────────────────────────── */
.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: #1565c0;
    color: #fff;
    font-weight: 700;
    font-size: 1rem;
    margin-right: 12px;
    flex-shrink: 0;
}

/* ── Equal-height card rows (auto – applies to every row with cards) */
.row:has(> [class*="col"] > .card),
.row:has(> [class*="col"] > .card-panel) {
    display: flex;
    flex-wrap: wrap;
}
.row:has(> [class*="col"] > .card) > [class*="col"],
.row:has(> [class*="col"] > .card-panel) > [class*="col"] {
    display: flex;
}
.row:has(> [class*="col"] > .card) > [class*="col"] > .card,
.row:has(> [class*="col"] > .card-panel) > [class*="col"] > .card-panel {
    width: 100%;
    display: flex;
    flex-direction: column;
}
.card-panel .badge-group {
    margin-top: auto;
    padding-top: 12px;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}
.badge-group .timeline-badge {
    margin-right: 0;
}

/* ── Utility ──────────────────────────────────────────────────────── */
.text-muted {
    color: #9e9e9e;
}
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }

/* ── Responsive ───────────────────────────────────────────────────── */
@media only screen and (max-width: 600px) {
    .hero-section {
        padding: 70px 0 50px;
    }
    .hero-section h1 {
        font-size: 2rem;
    }
    .hero-section .btn-large {
        display: block;
        margin-right: 0;
        margin-bottom: 0.75rem;
    }
    .page-header-section {
        padding: 60px 0 30px;
    }
    .page-header-section h1 {
        font-size: 1.8rem;
    }
    pre.code-block,
    pre.diagram {
        font-size: 0.78rem;
        padding: 14px 16px;
    }
    .timeline-badge {
        padding: 3px 10px;
        font-size: 0.7rem;
    }
}
