
/* ============================================
   ROTARY CLUB OF KIGALI COSMOPOLITAN
   Shared Styles — Used Across All Pages
   ============================================ */

/* --- CSS CUSTOM PROPERTIES --- */
:root {
    --primary-blue: #0061a2;
    --dark-blue: #003d6b;
    --deep-blue: #001f3f;
    --accent-gold: #f7a823;
    --warm-gold: #e8960c;
    --cranberry: #c4122f;
    --text-dark: #2c3e50;
    --text-medium: #555;
    --text-light: #777;
    --bg-light: #f8fafc;
    --bg-warm: #fffbf2;
    --white: #ffffff;
    --shadow-sm: 0 2px 8px rgba(0,0,0,0.06);
    --shadow-md: 0 4px 20px rgba(0,0,0,0.08);
    --shadow-lg: 0 10px 40px rgba(0,0,0,0.12);
    --shadow-xl: 0 20px 60px rgba(0,0,0,0.15);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --transition-fast: 0.2s ease;
    --transition-base: 0.3s ease;
    --transition-slow: 0.5s ease;
    --font-main: 'Poppins', -apple-system, BlinkMacSystemFont, sans-serif;
    --header-height: 100px;
    --header-height-scrolled: 70px;
}

/* --- RESET & BASE --- */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    overflow-x: hidden; /* Added strict lock */
    width: 100vw;       /* Added strict lock */
}

body {
    font-family: var(--font-main);
    color: var(--text-dark);
    background-color: var(--white);
    overflow-x: hidden;
    width: 100%;        /* Added strict lock */
    position: relative; /* Added strict lock */
    line-height: 1.7;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-base);
}

ul {
    list-style: none;
}

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

/* --- PAGE LOADING ANIMATION --- */
.page-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.page-loader.loaded {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.loader-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #e0e0e0;
    border-top-color: var(--accent-gold);
    border-right-color: var(--primary-blue);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ============================================
   PAGE HERO — SHARED (FIXED)
   ============================================ */
   .page-hero {
    position: relative;
    width: 100%;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: var(--dark-blue); /* fallback while image loads */
}

/* Background image — fills the entire hero */
.page-hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
    z-index: 1;
}

/* Dark overlay so text is readable */
.page-hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        180deg,
        rgba(0, 27, 61, 0.75) 0%,
        rgba(0, 27, 61, 0.60) 40%,
        rgba(0, 27, 61, 0.80) 100%
    );
    z-index: 2;
}

/* Decorative floating shapes */
.page-hero .shape {
    position: absolute;
    border-radius: 50%;
    opacity: 0.06;
    z-index: 3;
    pointer-events: none;
}

.page-hero .shape-1 {
    width: 400px;
    height: 400px;
    background: var(--accent-gold);
    top: -100px;
    right: -100px;
}

.page-hero .shape-2 {
    width: 250px;
    height: 250px;
    background: var(--primary-blue);
    bottom: -50px;
    left: -80px;
}

.page-hero .shape-3 {
    width: 150px;
    height: 150px;
    background: white;
    top: 40%;
    left: 15%;
}

/* Content — sits ON TOP of image + overlay */
.page-hero-content {
    position: relative;
    z-index: 10;
    text-align: center;
    color: white;
    max-width: 900px;
    padding: 120px 20px 60px;  /* top padding accounts for fixed header */
}

/* Badge pill */
.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: white;
    padding: 10px 24px;
    border-radius: 50px;
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    margin-bottom: 20px;
}

.hero-badge i {
    color: var(--accent-gold);
}

/* Main heading */
.page-hero-content h1 {
    font-size: 3.2rem;
    font-weight: 900;
    color: white;
    line-height: 1.15;
    margin-bottom: 15px;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
}

.page-hero-content h1 span {
    color: var(--accent-gold);
}

/* Subtitle */
.hero-subtitle {
    font-size: 1.1rem;
    font-weight: 300;
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.7;
    max-width: 700px;
    margin: 0 auto;
}

/* Breadcrumb */
.breadcrumb {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 0.82rem;
    color: rgba(255, 255, 255, 0.6);
}

.breadcrumb a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: color 0.3s ease;
}

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

.breadcrumb-separator {
    font-size: 0.6rem;
    color: rgba(255, 255, 255, 0.4);
}

/* ── RESPONSIVE HERO ── */
@media (max-width: 768px) {
    .page-hero {
        min-height: 520px;
    }

    .page-hero-content {
        padding: 100px 15px 40px;
    }

    .page-hero-content h1 {
        font-size: 2.2rem;
    }

    .hero-subtitle {
        font-size: 0.95rem;
    }
}

@media (max-width: 480px) {
    .page-hero {
        min-height: 480px;
    }

    .page-hero-content h1 {
        font-size: 1.8rem;
    }

    .hero-badge {
        font-size: 0.72rem;
        padding: 8px 18px;
    }
}
/* --- TOP BAR / TICKER --- */
.top-bar {
    background: linear-gradient(135deg, var(--deep-blue) 0%, var(--dark-blue) 100%);
    color: white;
    padding: 0 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 17px;
    height: 42px;
    overflow: hidden;
    position: relative;
}

.ticker-wrap {
    flex: 1;
    overflow: hidden;
    height: 100%;
    display: flex;
    align-items: center;
    margin-right: 20px;
    position: relative;
}

.ticker-wrap::before,
.ticker-wrap::after {
    content: '';
    position: absolute;
    top: 0;
    width: 60px;
    height: 100%;
    z-index: 2;
    pointer-events: none;
}

.ticker-wrap::before {
    left: 0;
    background: linear-gradient(to right, var(--deep-blue), transparent);
}

.ticker-wrap::after {
    right: 0;
    background: linear-gradient(to left, var(--dark-blue), transparent);
}

.ticker-content {
    display: flex;
    white-space: nowrap;
    animation: ticker-scroll 25s linear infinite;
    will-change: transform;
}

.ticker-content span {
    padding: 0 50px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 400;
    letter-spacing: 0.3px;
}

.ticker-content span i {
    color: var(--accent-gold);
    font-size: 11px;
}

@keyframes ticker-scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

.social-icons-top {
    display: flex;
    gap: 5px;
    flex-shrink: 0;
}

.social-icons-top a {
    color: rgba(255,255,255,0.7);
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 13px;
    transition: var(--transition-fast);
}

.social-icons-top a:hover {
    color: white;
    background: rgba(255,255,255,0.1);
    transform: translateY(-1px);
}

/* --- HEADER / NAVIGATION --- */
header {
    background-color: var(--white);
    height: var(--header-height);
    padding: 0 5%;
    position: sticky;
    top: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: all var(--transition-base);
    box-shadow: none;
}

header.scrolled {
    height: var(--header-height-scrolled);
    box-shadow: var(--shadow-md);
    background: rgba(255,255,255,0.97);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.logo img {
    height: 150px;
    width: auto;
    display: block;
    transition: height var(--transition-base);
}

header.scrolled .logo img {
    height: 60px;
}

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

.nav-links > li > a {
    color: var(--dark-blue);
    font-weight: 600;
    font-size: 13.5px;
    text-transform: uppercase;
    padding: 10px 16px;
    position: relative;
    letter-spacing: 0.5px;
    border-radius: var(--radius-sm);
    transition: var(--transition-fast);
}

.nav-links > li > a:hover {
    color: var(--primary-blue);
    background: rgba(0, 97, 162, 0.05);
}

.nav-links > li > a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 3px;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(90deg, var(--accent-gold), var(--warm-gold));
    transition: width var(--transition-base);
    border-radius: 3px;
}

.nav-links > li > a:hover::after,
.nav-links > li > a.active::after {
    width: 60%;
}

/* ===============================
   DESKTOP DROPDOWN (Global)
=============================== */
.dropdown {
    position: relative;
}

.dropdown-content {
    display: none;
    position: absolute;
    top: calc(100% + 5px);
    left: 50%;
    transform: translateX(-50%);
    background-color: var(--white);
    min-width: 230px;
    box-shadow: var(--shadow-lg);
    border-radius: var(--radius-sm);
    padding: 8px 0;
    z-index: 1002;
    border-top: 3px solid var(--accent-gold);
    opacity: 0;
    visibility: hidden;
    transform: translateX(-50%) translateY(10px);
    transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s ease;
}

.dropdown:hover .dropdown-content {
    display: block;
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.dropdown-content li a {
    padding: 11px 22px;
    color: var(--text-dark);
    font-size: 13.5px;
    font-weight: 500;
    text-transform: none;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition-fast);
}

.dropdown-content li a::before {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent-gold);
    opacity: 0;
    transition: opacity var(--transition-fast);
    flex-shrink: 0;
}

.dropdown-content li a:hover {
    background-color: var(--bg-light);
    color: var(--primary-blue);
    padding-left: 28px;
}

.dropdown-content li a:hover::before {
    opacity: 1;
}

/* Hamburger */
.hamburger {
    display: none;
    color: var(--primary-blue);
    font-size: 24px;
    cursor: pointer;
    width: 44px;
    height: 44px;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    transition: var(--transition-fast);
}

.hamburger:hover {
    background: rgba(0, 97, 162, 0.05);
}

/* --- FOOTER --- */
footer {
    background: linear-gradient(160deg, var(--deep-blue) 0%, var(--dark-blue) 60%, #00507a 100%);
    color: white;
    padding: 70px 8% 0;
    position: relative;
}

footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--accent-gold), var(--primary-blue), var(--cranberry), var(--accent-gold));
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 50px;
    padding-bottom: 50px;
}

.footer-item h3 {
    color: var(--accent-gold);
    margin-bottom: 20px;
    font-size: 1.1rem;
    position: relative;
    padding-bottom: 12px;
}

.footer-item h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 2px;
    background: var(--accent-gold);
    border-radius: 2px;
}

.footer-item p {
    color: rgba(255,255,255,0.75);
    font-size: 0.9rem;
    line-height: 1.8;
    margin-bottom: 8px;
}

.footer-item p i {
    color: var(--accent-gold);
    width: 20px;
    margin-right: 8px;
}

.footer-item ul li {
    margin-bottom: 10px;
}

.footer-item ul li a {
    color: rgba(255,255,255,0.75);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition-fast);
}

.footer-item ul li a::before {
    content: '›';
    color: var(--accent-gold);
    font-size: 1.2rem;
    font-weight: bold;
    transition: transform var(--transition-fast);
}

.footer-item ul li a:hover {
    color: white;
    transform: translateX(5px);
}

.footer-item ul li a:hover::before {
    transform: translateX(3px);
}

.footer-socials {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.footer-socials a {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: 1.5px solid rgba(255,255,255,0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: rgba(255,255,255,0.8);
    transition: var(--transition-base);
}

.footer-socials a:hover {
    background: var(--accent-gold);
    border-color: var(--accent-gold);
    color: white;
    transform: translateY(-3px);
}

.footer-bottom {
    text-align: center;
    border-top: 1px solid rgba(255,255,255,0.1);
    padding: 25px 0;
    color: rgba(255,255,255,0.5);
    font-size: 0.85rem;
}

.footer-bottom a {
    color: var(--accent-gold);
}

.footer-bottom a:hover {
    color: var(--warm-gold);
    text-decoration: underline;
}

/* ======================== SUBTLE ADMIN ACCESS ======================== */

.admin-access-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    color: rgba(255, 255, 255, 0.15);
    font-size: 14px;
    text-decoration: none;
    transition: all 0.4s ease;
    position: relative;
    cursor: pointer;
}

/* Very subtle — barely visible until hover */
.admin-access-link:hover {
    color: rgba(255, 255, 255, 0.6);
    background: rgba(255, 255, 255, 0.08);
    transform: scale(1.1);
}

.admin-access-link:active {
    transform: scale(0.95);
}

/* Tooltip on hover */
.admin-access-link::after {
    content: 'Portal';
    position: absolute;
    bottom: calc(100% + 6px);
    left: 50%;
    transform: translateX(-50%) translateY(4px);
    background: rgba(0, 0, 0, 0.8);
    color: #fff;
    font-size: 10px;
    font-family: 'Inter', sans-serif;
    padding: 3px 8px;
    border-radius: 4px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
    letter-spacing: 0.5px;
}

.admin-access-link:hover::after {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* If footer bottom is flex, ensure alignment */
.footer-bottom .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* ======================== ALTERNATIVE: Fixed corner position ======================== */


.admin-access-fixed {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.03);
    color: rgba(0, 0, 0, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    text-decoration: none;
    transition: all 0.5s ease;
    z-index: 10;
    cursor: pointer;
    border: 1px solid transparent;
}

.admin-access-fixed:hover {
    background: rgba(0, 0, 0, 0.06);
    color: rgba(0, 0, 0, 0.3);
    border-color: rgba(0, 0, 0, 0.08);
}



/* --- BACK TO TOP BUTTON --- */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary-blue), var(--dark-blue));
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    cursor: pointer;
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all var(--transition-base);
    box-shadow: var(--shadow-md);
    border: none;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
    background: linear-gradient(135deg, var(--accent-gold), var(--warm-gold));
}

/* --- SCROLL REVEAL ANIMATIONS --- */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

.reveal-left {
    opacity: 0;
    transform: translateX(-40px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal-left.revealed {
    opacity: 1;
    transform: translateX(0);
}

.reveal-right {
    opacity: 0;
    transform: translateX(40px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal-right.revealed {
    opacity: 1;
    transform: translateX(0);
}

.reveal-scale {
    opacity: 0;
    transform: scale(0.9);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal-scale.revealed {
    opacity: 1;
    transform: scale(1);
}

/* Stagger delays */
.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }
.delay-3 { transition-delay: 0.3s; }
.delay-4 { transition-delay: 0.4s; }
.delay-5 { transition-delay: 0.5s; }

/* --- UTILITY CLASSES --- */
.section-label {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--accent-gold);
    margin-bottom: 15px;
}

.section-label::before {
    content: '';
    width: 30px;
    height: 2px;
    background: var(--accent-gold);
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--dark-blue);
    line-height: 1.2;
    margin-bottom: 20px;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--text-light);
    max-width: 650px;
    line-height: 1.8;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 32px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all var(--transition-base);
    border: 2px solid transparent;
    text-transform: none;
    letter-spacing: 0.3px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent-gold), var(--warm-gold));
    color: white;
    border-color: var(--accent-gold);
    box-shadow: 0 4px 15px rgba(247, 168, 35, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(247, 168, 35, 0.4);
    background: linear-gradient(135deg, var(--warm-gold), #d4850a);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--primary-blue);
    color: var(--primary-blue);
}

.btn-outline:hover {
    background: var(--primary-blue);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 97, 162, 0.3);
}

.btn-white {
    background: white;
    color: var(--dark-blue);
    border-color: white;
    font-weight: 600;
}

.btn-white:hover {
    background: var(--accent-gold);
    border-color: var(--accent-gold);
    color: white;
    transform: translateY(-2px);
}

/* --- RESPONSIVE: MOBILE --- */
@media (max-width: 900px) {
    .top-bar {
        font-size: 12px;
        height: 38px;
        padding: 0 4%;
    }

    header {
        padding: 0 4%;
        height: 75px;
    }

    header.scrolled {
        height: 65px;
    }

    .logo img {
        height: 100px;
    }

    header.scrolled .logo img {
        height: 50px;
    }

    .hamburger {
        display: flex;
    }

    .nav-links {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: var(--white);
        padding: 15px 0;
        border-top: 3px solid var(--accent-gold);
        box-shadow: var(--shadow-lg);
        max-height: 80vh;
        overflow-y: auto;
    }

    .nav-links.active {
        display: flex;
    }

    .nav-links > li > a {
        padding: 14px 25px;
        font-size: 14px;
        width: 100%;
    }

    .nav-links > li > a::after {
        display: none;
    }

   /* MOBILE DROPDOWN FIX */
   .dropdown-content,
   .dropdown:hover .dropdown-content {
       position: static !important;
       transform: none !important;
       box-shadow: none !important;
       border-top: none !important;
       border-left: 3px solid var(--accent-gold);
       margin-left: 20px; 
       padding-left: 10px;
       min-width: 100%;
       border-radius: 0;
       display: none !important; /* Kills the fake mobile hover */
       opacity: 1;
       visibility: visible;
   }

   /* Only open via the Javascript 'open' class */
   .dropdown.open .dropdown-content {
       display: block !important;
   }

   /* Fix the spacing of the sub-links on mobile */
   .dropdown-content li a {
       padding: 10px 15px;
       font-size: 13.5px;
   }
    .dropdown.open .dropdown-content {
        display: block;
        transform: none;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 35px;
    }

    .section-title {
        font-size: 1.8rem;
    }

    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 44px;
        height: 44px;
        font-size: 18px;
    }
}

@media (max-width: 480px) {
    .social-icons-top {
        display: none;
    }

    .ticker-content span {
        padding: 0 30px;
        font-size: 12px;
    }
}