/* ============================================
   Robert Bell Vercel Test Site
   Theming System v1 - CSS Custom Properties
   ============================================ */

:root {
    --color-bg: #f8f9fa;
    --color-text: #333333;
    --color-heading: #1a5f7a;
    --color-accent: #1a5f7a;
    --color-link: #1a5f7a;
    --color-card-bg: #ffffff;
    --color-card-border: #e9ecef;
    --color-shadow: rgba(0, 0, 0, 0.1);
    --font-body: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-heading: var(--font-body);
    --font-size-base: 1rem;
    --line-height: 1.6;
    --radius: 6px;
    --transition-speed: 0.25s;
    --card-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    --card-shadow-hover: 0 10px 26px rgba(26, 95, 122, 0.18);
    --card-hover-scale: 1.015;
    --nav-bg: rgba(255, 255, 255, 0.15);
    /* Report page header – light mode */
    --header-bg: #f1f3f5;
    --header-text: #212529;
}

[data-theme="dark"] {
    --color-bg: #121212;
    --color-text: #e0e0e0;
    --color-heading: #7eb8d9;
    --color-accent: #7eb8d9;
    --color-link: #7eb8d9;
    --color-card-bg: #1e1e1e;
    --color-card-border: #333333;
    --color-shadow: rgba(0, 0, 0, 0.3);
    --card-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    --card-shadow-hover: 0 8px 22px rgba(126, 184, 217, 0.10), 0 3px 10px rgba(255, 255, 255, 0.04);
    --nav-bg: rgba(0, 0, 0, 0.25);
    /* Report page header – dark mode */
    --header-bg: #0d0d0d;
    --header-text: #ffffff;
}

.theme-professional {}
.theme-nature {
    --color-heading: #2e5a3c;
    --color-accent: #2e7d32;
    --color-link: #2e7d32;
    --card-shadow-hover: 0 10px 26px rgba(46, 125, 50, 0.18);
}
.theme-minimal {
    --color-heading: #2c3e50;
    --color-accent: #34495e;
    --color-link: #34495e;
    --card-shadow-hover: 0 8px 20px rgba(52, 73, 94, 0.15);
}
.theme-dark {
    --color-heading: #64b5f6;
    --color-accent: #42a5f5;
    --color-link: #42a5f5;
}
.theme-heritage {
    --color-heading: #5d4037;
    --color-accent: #6d4c41;
    --color-link: #6d4c41;
    --card-shadow-hover: 0 10px 26px rgba(109, 76, 65, 0.18);
}

body {
    font-family: var(--font-body);
    max-width: min(90%, 900px);
    margin-left: auto;
    margin-right: auto;
    padding: 0 16px;
    line-height: var(--line-height);
    background-color: var(--color-bg);
    color: var(--color-text);
    font-size: var(--font-size-base);
}

h1, h2, h3, h4 {
    font-family: var(--font-heading);
    color: var(--color-heading);
    line-height: 1.3;
}

a {
    color: var(--color-link);
    text-decoration: none;
}

.header-image-wrapper { position: relative; }
.header-image-wrapper img { width: 100%; border-radius: var(--radius); display: block; }

.overlay-nav { position: absolute; bottom: 0; left: 0; z-index: 10; }
.overlay-nav ul {
    background-color: var(--nav-bg);
    padding: 6px 12px;
    border-radius: 0 6px 0 0;
    margin: 0;
    list-style: none;
    display: flex;
    gap: 16px;
}
.overlay-nav a {
    color: white;
    font-weight: 600;
    padding: 4px 8px;
    border-bottom: 2px solid transparent;
}
.overlay-nav a.active {
    border-bottom: 2px solid white;
    padding-bottom: 3px;
}

.theme-toggle {
    position: absolute;
    top: 8px;
    right: 8px;
    background: transparent;
    border: none;
    color: white;
    font-size: 1.25rem;
    cursor: pointer;
    padding: 5px;
    border-radius: 50%;
}

.card,
.card-with-image,
.card-horizontal,
.tool-item {
    background-color: var(--color-card-bg);
    border: 1px solid var(--color-card-border);
    border-radius: var(--radius);
    overflow: hidden;
    transition: transform var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
    box-shadow: var(--card-shadow);
}
.card:hover,
.card-with-image:hover,
.card-horizontal:hover,
.tool-item:hover {
    transform: translateY(-5px) scale(var(--card-hover-scale));
    box-shadow: var(--card-shadow-hover);
    cursor: pointer;
}
.card-content { padding: 16px; }
.card-with-image img {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
}
.card-horizontal {
    display: flex;
    gap: 16px;
    align-items: center;
    margin-bottom: 24px;
}
.card-horizontal img {
    width: 120px;
    height: 120px;
    object-fit: cover;
    border-radius: var(--radius);
    flex-shrink: 0;
    margin-left: 8px;
}
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    margin-top: 24px;
}

.tools-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    margin: 2rem auto;
    max-width: 900px;
}
@media (max-width: 640px) {
    .tools-grid { grid-template-columns: 1fr; gap: 1.5rem; }
}
.tool-item {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}
.tool-icon {
    width: 120px;
    height: 120px;
    margin-bottom: 1rem;
    flex-shrink: 0;
}
.tool-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 8px;
}
.simple-g-icon {
    background-color: var(--color-accent);
    color: white;
    border-radius: 50%;
    width: 120px;
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    font-weight: bold;
}

.container {
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 16px;
    padding-right: 16px;
}
main section { margin-bottom: 3rem; }
main section:last-child { margin-bottom: 2rem; }
.site-header { position: relative; }
footer {
    padding: 2rem 0;
    border-top: 1px solid var(--color-card-border);
    margin-top: 2rem;
}

.nav-toggle {
    position: absolute;
    top: 8px;
    right: 60px;
    background: transparent;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 8px;
    z-index: 20;
    display: none;
}
@media (max-width: 768px) {
    .nav-toggle {
        display: block;
        top: auto;
        bottom: 12px;
        left: 12px;
        right: auto;
        padding: 14px;
        font-size: 1.9rem;
    }
    .desktop-nav { display: none; }
}
.nav-toggle-icon {
    display: block;
    width: 26px;
    height: 2.5px;
    background: white;
    position: relative;
}
.nav-toggle-icon::before,
.nav-toggle-icon::after {
    content: '';
    position: absolute;
    width: 26px;
    height: 2.5px;
    background: white;
    left: 0;
}
.nav-toggle-icon::before { top: -8px; }
.nav-toggle-icon::after { top: 8px; }

.mobile-menu {
    position: fixed;
    top: 0;
    left: -100%;
    width: 280px;
    height: 100vh;
    background-color: var(--color-card-bg);
    box-shadow: 2px 0 15px rgba(0, 0, 0, 0.2);
    z-index: 100;
    transition: left 0.3s ease;
    padding: 20px;
    overflow-y: auto;
}
.mobile-menu.open { left: 0; }
.mobile-menu ul { list-style: none; padding: 0; margin: 40px 0 0 0; }
.mobile-menu li { margin-bottom: 16px; }
.mobile-menu a {
    color: var(--color-text);
    font-size: 1.1rem;
    font-weight: 600;
    text-decoration: none;
    display: block;
    padding: 8px 0;
}
.mobile-menu a:hover { color: var(--color-accent); }
.mobile-menu a.active {
    color: var(--color-accent);
    border-left: 4px solid var(--color-accent);
    padding-left: 12px;
    font-weight: 600;
}
.nav-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--color-text);
    cursor: pointer;
    float: right;
}

/* ============================================
   PUB REPORT PAGES – Simple header (stacked)
   Stronger selectors so this wins over any
   older embedded styles on individual pages.
   ============================================ */

header.report-header {
    background: var(--header-bg, #f1f3f5) !important;
    color: var(--header-text, #212529) !important;
    padding: 0.85rem 1.25rem !important;
    border-bottom: 1px solid var(--color-card-border, rgba(128, 128, 128, 0.2)) !important;
}

header.report-header .report-header-inner {
    max-width: 720px !important;
    margin: 0 auto !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    justify-content: flex-start !important;
    gap: 0.25rem !important;
}

header.report-header .report-header-title {
    font-size: 0.95rem !important;
    font-weight: 500 !important;
    opacity: 0.9 !important;
    margin: 0 !important;
    line-height: 1.3 !important;
    white-space: nowrap !important;
}

header.report-header a {
    color: inherit !important;
    text-decoration: none !important;
    font-size: 0.9rem !important;
    opacity: 0.85 !important;
    line-height: 1.3 !important;
}

header.report-header a:hover {
    opacity: 1 !important;
    text-decoration: underline !important;
}
