/* ========================================
   EmComm Life - Unified Dark Theme
   Shared across all site pages
   ======================================== */

/* CSS Custom Properties */
:root {
    --bg-primary: #0d1117;
    --bg-secondary: #161b22;
    --bg-card: #21262d;
    --bg-card-hover: #292e36;
    --border-color: #30363d;
    --border-light: #3a424d;
    --text-primary: #e6edf3;
    --text-secondary: #8b949e;
    --text-muted: #6e7681;

    /* Brand / accent */
    --accent-blue: #58a6ff;
    --accent-cyan: #39c5cf;
    --accent-green: #3fb950;
    --accent-yellow: #d29922;
    --accent-orange: #db6d28;
    --accent-red: #f85149;
    --accent-purple: #a371f7;

    /* Status */
    --good: #238636;
    --fair: #9e6a03;
    --poor: #da3633;

    /* Fonts */
    --font-display: 'Oswald', sans-serif;
    --font-body: 'Epilogue', 'Segoe UI', sans-serif;
    --font-mono: 'JetBrains Mono', monospace;

    /* Nav */
    --nav-height: 56px;
}

/* Reset */
*, *::before, *::after { box-sizing: border-box; }

body {
    margin: 0;
    padding: 0;
    font-family: var(--font-body);
    background: var(--bg-primary);
    color: var(--text-primary);
    min-height: 100vh;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a { color: var(--accent-blue); text-decoration: none; }
a:hover { color: var(--accent-cyan); text-decoration: underline; }

img { max-width: 100%; height: auto; }

/* ========== NAVIGATION ========== */
.site-nav {
    position: sticky;
    top: 0;
    z-index: 9999;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    height: var(--nav-height);
    display: flex;
    align-items: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

.site-nav .nav-inner {
    max-width: 1600px;
    width: 100%;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.site-nav .nav-brand {
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--accent-cyan);
    letter-spacing: 1px;
    text-transform: uppercase;
    white-space: nowrap;
    text-decoration: none;
}
.site-nav .nav-brand:hover { color: #fff; text-decoration: none; }

.site-nav .nav-links {
    display: flex;
    gap: 4px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.site-nav .nav-links a {
    display: block;
    padding: 8px 16px;
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
    border-radius: 6px;
    transition: all 0.2s;
    text-decoration: none;
}

.site-nav .nav-links a:hover {
    color: var(--text-primary);
    background: var(--bg-card);
    text-decoration: none;
}

.site-nav .nav-links a.active {
    color: var(--accent-cyan);
    background: rgba(57, 197, 207, 0.1);
}

/* Hamburger for mobile */
.site-nav .nav-toggle {
    display: none;
    background: none;
    border: none;
    padding: 8px;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
}
.site-nav .nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text-secondary);
    border-radius: 2px;
    transition: 0.3s;
}

@media (max-width: 768px) {
    .site-nav .nav-toggle { display: flex; }
    .site-nav .nav-links {
        display: none;
        position: absolute;
        top: var(--nav-height);
        left: 0; right: 0;
        flex-direction: column;
        background: var(--bg-secondary);
        border-bottom: 1px solid var(--border-color);
        padding: 8px;
        box-shadow: 0 4px 12px rgba(0,0,0,0.5);
    }
    .site-nav .nav-links.open { display: flex; }
    .site-nav .nav-links a { padding: 12px 16px; }
}

/* ========== PAGE CONTENT WRAPPER ========== */
.site-content {
    max-width: 1600px;
    margin: 0 auto;
    padding: 30px 20px;
}

/* ========== SECTION HEADERS ========== */
.section-title {
    font-family: var(--font-display);
    font-size: 2rem;
    font-weight: 600;
    color: var(--text-primary);
    text-align: center;
    margin-bottom: 8px;
}

.section-subtitle {
    font-size: 0.95rem;
    color: var(--text-secondary);
    text-align: center;
    margin-bottom: 30px;
}

/* ========== CARD GRID ========== */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.site-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    overflow: hidden;
    transition: transform 0.2s, border-color 0.2s;
}
.site-card:hover {
    transform: translateY(-2px);
    border-color: var(--border-light);
}

.site-card .card-img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: contain;
    background: var(--bg-secondary);
    padding: 20px;
}

.site-card .card-body {
    padding: 20px;
}

.site-card .card-title {
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.site-card .card-text {
    font-size: 0.88rem;
    color: var(--text-secondary);
    margin-bottom: 16px;
    line-height: 1.5;
}

.site-card .card-links {
    font-size: 0.82rem;
    color: var(--text-muted);
    margin-bottom: 16px;
    line-height: 1.8;
}

.site-card .card-btn {
    display: inline-block;
    padding: 8px 20px;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--accent-cyan);
    border: 1px solid var(--accent-cyan);
    border-radius: 6px;
    transition: all 0.2s;
    text-decoration: none;
}
.site-card .card-btn:hover {
    background: rgba(57, 197, 207, 0.15);
    text-decoration: none;
}

/* ========== HERO / LANDING ========== */
.hero {
    position: relative;
    width: 100%;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
}
.hero img {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    object-fit: cover;
    opacity: 0.35;
}
.hero-overlay {
    position: relative;
    z-index: 1;
    text-align: center;
    padding: 60px 20px;
}
.hero-title {
    font-family: var(--font-display);
    font-size: 3rem;
    font-weight: 700;
    color: #fff;
    text-shadow: 0 2px 10px rgba(0,0,0,0.6);
    margin-bottom: 12px;
}
.hero-subtitle {
    font-size: 1.2rem;
    color: rgba(255,255,255,0.8);
    font-style: italic;
}

/* ========== FEATURE CARDS (Home) ========== */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.feature-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 30px 20px;
    text-align: center;
    transition: transform 0.2s, border-color 0.2s;
}
.feature-card:hover {
    transform: translateY(-3px);
    border-color: var(--accent-cyan);
}

.feature-card .feature-icon {
    font-size: 2.5rem;
    margin-bottom: 16px;
}

.feature-card .feature-title {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--text-primary);
}

.feature-card .feature-text {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* ========== QUOTE BANNER ========== */
.quote-banner {
    text-align: center;
    padding: 40px 20px;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    margin: 0 -20px 40px;
    background: var(--bg-secondary);
}
.quote-banner p {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-style: italic;
    color: var(--accent-cyan);
    opacity: 0.9;
}

/* ========== IFRAME CONTAINER ========== */
.iframe-container {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 30px;
}
.iframe-container iframe {
    width: 100%;
    border: none;
    display: block;
}

/* ========== IMAGE GRID (for proppy maps, etc.) ========== */
.image-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
    margin-bottom: 40px;
}

.image-grid-item {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    overflow: hidden;
    transition: border-color 0.2s;
}
.image-grid-item:hover { border-color: var(--accent-cyan); }

.image-grid-item a {
    display: block;
    padding: 12px;
}
.image-grid-item img {
    width: 100%;
    border-radius: 6px;
}
.image-grid-item .img-label {
    text-align: center;
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 1.05rem;
    padding: 10px 0 4px;
    color: var(--text-primary);
}

/* ========== 2-COL IMAGE ROW ========== */
.image-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 30px;
}
@media (max-width: 768px) {
    .image-row { grid-template-columns: 1fr; }
}
.image-row .img-panel {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 16px;
    text-align: center;
}
.image-row .img-panel img {
    max-width: 100%;
    border-radius: 6px;
}

/* ========== FOOTER ========== */
.site-footer {
    text-align: center;
    padding: 20px;
    border-top: 1px solid var(--border-color);
    color: var(--text-muted);
    font-size: 0.8rem;
    margin-top: 40px;
}

/* ========== UTILITIES ========== */
.text-center { text-align: center; }
.mt-1 { margin-top: 10px; }
.mt-2 { margin-top: 20px; }
.mt-3 { margin-top: 30px; }
.mb-1 { margin-bottom: 10px; }
.mb-2 { margin-bottom: 20px; }
.mb-3 { margin-bottom: 30px; }
