/* ================================================
   CITIZEN'S CHARTER – Professional Redesign
   Palette: Navy #002855 | Gold #ffd700
   ================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
    --navy:        #002855;
    --navy-dark:   #001c3d;
    --navy-light:  #003575;
    --gold:        #ffd700;
    --gold-dark:   #e6c200;
    --bg:          #f0f4f8;
    --card-bg:     #ffffff;
    --text-main:   #1a2332;
    --text-muted:  #5a6a7a;
    --border:      #e2e8f0;
    --shadow-sm:   0 1px 3px rgba(0,40,85,.08), 0 1px 2px rgba(0,0,0,.06);
    --shadow-md:   0 4px 6px rgba(0,40,85,.07), 0 2px 4px rgba(0,0,0,.06);
    --shadow-lg:   0 10px 20px rgba(0,40,85,.12), 0 4px 6px rgba(0,0,0,.05);
    --radius:      10px;
}

*, *::before, *::after { box-sizing: border-box; }

html, body {
    max-width: 100%;
    overflow-x: hidden;
    background: var(--bg);
    margin: 0;
    padding: 0;
    font-family: 'Inter', 'Segoe UI', Tahoma, Verdana, sans-serif;
    color: var(--text-main);
    line-height: 1.6;
}

/* ── HERO HEADER ─────────────────────────────── */
.page-hero {
    background: linear-gradient(135deg, var(--navy-dark) 0%, var(--navy) 60%, var(--navy-light) 100%);
    position: relative;
    overflow: hidden;
    padding: 64px 24px 56px;
    text-align: center;
}

.page-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/svg%3E");
    pointer-events: none;
}

.page-hero::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--gold), var(--gold-dark), var(--gold));
}

.breadcrumb {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: .78rem;
    color: rgba(255,255,255,.55);
    margin-bottom: 22px;
    position: relative;
    z-index: 1;
    text-transform: uppercase;
    letter-spacing: .5px;
}
.breadcrumb a             { color: rgba(255,255,255,.55); text-decoration: none; transition: color .2s; }
.breadcrumb a:hover       { color: var(--gold); }
.breadcrumb-sep          { color: rgba(255,255,255,.25); font-size: .72rem; }
.breadcrumb-current      { color: var(--gold); }

.hero-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 64px; height: 64px;
    background: rgba(255,215,0,.12);
    border: 1.5px solid rgba(255,215,0,.35);
    border-radius: 16px;
    margin: 0 auto 20px;
    position: relative;
    z-index: 1;
}
.hero-icon svg { width: 30px; height: 30px; fill: var(--gold); }

.page-hero h1 {
    color: #fff;
    margin: 0 0 12px;
    font-size: clamp(1.7rem, 4vw, 2.6rem);
    font-weight: 800;
    letter-spacing: .5px;
    position: relative;
    z-index: 1;
}
.page-hero .hero-subtitle {
    color: rgba(255,255,255,.68);
    font-size: .98rem;
    max-width: 540px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

/* ── MAIN CONTENT ────────────────────────────── */
.charter-main {
    max-width: 1160px;
    margin: 48px auto 80px;
    padding: 0 24px;
    box-sizing: border-box;
}

.charter-layout {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr; /* 1.15fr for PDF (Left), 0.85fr for Offices (Right) */
    gap: 32px;
    align-items: start;
}

/* ── PANEL CARDS ─────────────────────────────── */
.panel-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.panel-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 20px 24px;
    border-bottom: 1px solid var(--border);
    background: linear-gradient(to right, rgba(0,40,85,.04), transparent);
}
.panel-header-icon {
    width: 38px; height: 38px;
    background: rgba(0,40,85,.08);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.panel-header-icon svg { width: 18px; height: 18px; fill: var(--navy); }
.panel-header-text h3 {
    margin: 0 0 2px;
    font-size: .95rem;
    font-weight: 700;
    color: var(--navy);
    text-transform: uppercase;
    letter-spacing: .4px;
}
.panel-header-text p {
    margin: 0;
    font-size: .78rem;
    color: var(--text-muted);
}

/* ── OFFICE LIST ─────────────────────────────── */
.office-list {
    padding: 16px 20px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.office-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 13px 16px;
    background: #f8fafc;
    border: 1px solid var(--border);
    border-radius: 8px;
    text-decoration: none;
    color: var(--navy);
    font-size: .9rem;
    font-weight: 500;
    transition: background .2s, border-color .2s, transform .2s, box-shadow .2s;
    position: relative;
    overflow: hidden;
}
.office-item::before {
    content: '';
    position: absolute;
    left: 0; top: 0; bottom: 0;
    width: 3px;
    background: var(--gold);
    transform: scaleY(0);
    transition: transform .2s ease;
    border-radius: 0 2px 2px 0;
}
.office-item:hover {
    background: rgba(0,40,85,.05);
    border-color: rgba(0,40,85,.2);
    transform: translateX(4px);
    box-shadow: var(--shadow-sm);
}
.office-item:hover::before { transform: scaleY(1); }

.office-item-icon {
    width: 32px; height: 32px;
    background: rgba(0,40,85,.07);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background .2s;
}
.office-item:hover .office-item-icon { background: rgba(0,40,85,.13); }
.office-item-icon svg { width: 15px; height: 15px; fill: var(--navy); }

.office-item-label { flex: 1; word-break: break-word; }

.office-item-arrow {
    flex-shrink: 0;
    opacity: 0;
    transition: opacity .2s, transform .2s;
    transform: translateX(-4px);
}
.office-item:hover .office-item-arrow { opacity: 1; transform: translateX(0); }
.office-item-arrow svg { width: 14px; height: 14px; fill: var(--navy); display: block; }

.office-empty {
    padding: 40px 20px;
    text-align: center;
    color: var(--text-muted);
    font-size: .88rem;
}
.office-count-badge {
    margin-left: auto;
    background: rgba(0,40,85,.08);
    color: var(--navy);
    font-size: .72rem;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 12px;
}

/* ── PDF PANEL (MOBILE-OPTIMIZED) ─────────────── */
.pdf-wrapper {
    padding: 0;
    width: 100%;
}

.pdf-viewer {
    background: #fff;
    border-radius: 0 0 var(--radius) var(--radius);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.pdf-frame {
    width: 100%;
    height: 70vh;
    min-height: 500px;
    border: 0;
    display: block;
    background: #f0f4f8;
}

/* Download bar below iframe */
.pdf-download-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 20px;
    border-top: 1px solid var(--border);
    background: #f8fafc;
    gap: 12px;
    flex-wrap: wrap;
}
.pdf-download-bar span {
    font-size: .82rem;
    color: var(--text-muted);
}
.pdf-download-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--navy);
    color: #fff;
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: .82rem;
    font-weight: 600;
    transition: background .2s;
}
.pdf-download-btn:hover { background: var(--navy-light); }
.pdf-download-btn svg { width: 14px; height: 14px; fill: #fff; }

/* ── EMPTY PDF CARD ──────────────────────────── */
.pdf-empty {
    padding: 60px 24px;
    text-align: center;
}
.pdf-empty-icon {
    width: 64px; height: 64px;
    background: rgba(0,40,85,.05);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
}
.pdf-empty-icon svg { width: 30px; height: 30px; fill: #b0bec5; }
.pdf-empty-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-main);
    margin-bottom: 6px;
}
.pdf-empty-desc { font-size: .85rem; color: var(--text-muted); margin: 0; }

/* ── NAVIGATION LINKS ────────────────────────── */
.nav-links {
    list-style: none;
    display: flex;
    gap: 25px;
    margin: 0;
    padding: 0;
    align-items: center;
}

.nav-links li {
    position: relative;
}

.nav-links a {
    text-decoration: none;
    color: white;
    font-weight: 500;
    font-size: 14px;
    transition: 0.3s ease;
}

.nav-links a:hover {
    color: #f0ec00;
}

/* ── DROPDOWN DESIGN ─────────────────────────── */
.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%; 
    left: 0;
    background: white;
    list-style: none;
    padding: 5px 0;
    margin: 0;
    min-width: 220px;
    border-radius: 4px;
    box-shadow: 0 5px 12px rgba(0,0,0,0.2);
}

.dropdown-menu li a {
    display: block;
    padding: 10px 15px;
    color: #002855;
    font-size: 13px;
}

.dropdown-menu li a:hover {
    background: #f1f1f1;
    color: #002855;
}

.dropdown:hover .dropdown-menu {
    display: block;
}

.dropdown > a::after {
    content: " ▼";
    font-size: 10px;
    margin-left: 5px;
}

/* ── DATE & TIME ─────────────────────────────── */
.datetime-container {
    text-align: center;
    background-color: #002855;
    color: #ffd700;
    padding: 10px 0;
    font-weight: 500;
    font-size: 16px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

/* ── RESPONSIVE & MOBILE BREAKPOINTS ─────────── */
@media (max-width: 900px) {
    .charter-layout {
        grid-template-columns: 1fr;
    }
    .handbook-panel { order: -1; }
    .charter-main   { margin-top: 24px; padding: 0 16px; }
    .page-hero      { padding: 40px 16px 32px; }
}

@media (max-width: 600px) {
    .pdf-frame {
        height: 60vh;
        min-height: 400px;
    }

    .pdf-download-bar {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
        gap: 10px;
        padding: 12px 16px;
    }

    .pdf-download-btn {
        justify-content: center;
        width: 100%;
        padding: 10px 16px;
    }
}