/* Google Fonts: Poppins, Inter & Playfair Display */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Poppins:wght@600;700;800&family=Playfair+Display:wght@700;800&display=swap');

:root {
    --primary-green: #033201;
    --dark-green-split: #012419;
    /* Deep Forest Green */
    --accent-teal: #14b8a6;
    /* Vibrant Teal */
    --dark-bg: #012216;
    /* Darker Forest */
    --gold-accent: #c8a94a;
    /* Metallic Gold */
    --gold-hover: #b3943a;
    --text-light: #f8fafc;
    --glass-bg: rgba(255, 255, 255, 0.85);
    --glass-border: rgba(255, 255, 255, 0.18);
    --glow-teal: 0 0 15px rgba(20, 184, 166, 0.4);
    --glow-gold: 0 0 15px rgba(200, 169, 74, 0.4);
    --card-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    --soft-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.07);
    --font-main: 'Outfit', sans-serif;
    --font-heading: 'Poppins', sans-serif;
}

body {
    background-color: #fcfcfc;
    color: #334155;
    font-family: var(--font-main);
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
.navbar-brand {
    font-family: var(--font-heading);
    font-weight: 700;
}

.text-gold {
    color: var(--gold-accent);
}

/* Navbar */
.navbar {
    background: var(--dark-bg);
    padding: 1.2rem 0;
    transition: all 0.3s ease;
    z-index: 1030;
}

.navbar .nav-link {
    color: rgba(255, 255, 255, 0.8) !important;
    font-weight: 500;
}

.navbar .nav-link:hover {
    color: var(--gold-accent) !important;
}

.brand-text {
    color: white;
    font-size: 1.5rem;
    letter-spacing: 1px;
}

/* Buttons */
.btn-gold {
    background-color: var(--gold-accent);
    color: white;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
}

.btn-gold:hover {
    background-color: var(--gold-hover);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(200, 169, 74, 0.4);
}

.btn-outline-gold {
    border: 2px solid var(--gold-accent);
    color: var(--gold-accent);
    font-weight: 600;
}

.btn-outline-gold:hover {
    background: var(--gold-accent);
    color: white;
}

/* Sections */
.hero-section {
    background: linear-gradient(135deg, var(--dark-bg) 0%, var(--primary-green) 100%);
    color: white;
    padding: 100px 0;
    position: relative;
    overflow: hidden;
}

.hero-section::after {
    content: '';
    position: absolute;
    bottom: -100px;
    left: -10%;
    width: 120%;
    height: 200px;
    background: #fcfcfc;
    border-radius: 100%;
}

/* Cards */
.modern-card {
    background: white;
    border-radius: 16px;
    border: none;
    padding: 2.5rem;
    box-shadow: var(--soft-shadow);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    height: 100%;
}

.modern-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--card-shadow);
}

.icon-box {
    width: 60px;
    height: 60px;
    background: rgba(20, 184, 166, 0.1);
    /* Teal tinted bg */
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: var(--accent-teal);
    margin-bottom: 1.5rem;
}

/* Countdown */
.countdown-container {
    display: flex;
    gap: 1.5rem;
    margin-top: 3rem;
}

.countdown-item {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 1.5rem;
    border-radius: 12px;
    min-width: 90px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.countdown-value {
    font-size: 2rem;
    font-weight: 800;
    display: block;
}

.countdown-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    opacity: 0.8;
}

/* Footer */
.footer {
    background: var(--dark-bg);
}

/* Accordion Customization */
.accordion-item {
    border: none;
    margin-bottom: 1rem;
    border-radius: 12px !important;
    overflow: hidden;
    box-shadow: var(--soft-shadow);
}

.accordion-button:not(.collapsed) {
    background-color: rgba(20, 184, 166, 0.05);
    color: var(--accent-teal);
}

.accordion-button:focus {
    box-shadow: none;
    border-color: rgba(0, 0, 0, .125);
}

/* Leaderboard */
.leaderboard-table {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--card-shadow);
}

.leaderboard-table thead {
    background: var(--primary-green);
    color: white;
}

.leaderboard-table th,
.leaderboard-table td {
    padding: 1.2rem;
    vertical-align: middle;
}

.rank-badge {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
}

.rank-1 {
    background: gold;
    color: #856404;
}

.rank-2 {
    background: #e2e2e2;
    color: #495057;
}

.rank-3 {
    background: #cd7f32;
    color: white;
}

/* Admin Layout & Sidebar */
.admin-layout {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    background: var(--dark-bg);
    color: white;
    width: 260px;
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    z-index: 1000;
    overflow-x: hidden;
    transition: transform 0.3s ease;
    visibility: visible;
}

.main-content {
    margin-left: 260px;
    padding: 40px;
    background: #f8fafc;
    min-height: 100vh;
    width: calc(100% - 260px);
}

.sidebar-nav .nav-link {
    color: rgba(255, 255, 255, 0.7);
    padding: 12px 20px;
    border-radius: 8px;
    margin: 4px 15px;
    transition: all 0.2s;
    display: flex;
    align-items: center;
}

.sidebar-nav .nav-link:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--accent-teal);
}

.sidebar-nav .nav-link.active {
    background: rgba(255, 255, 255, 0.1);
    color: var(--gold-accent);
    font-weight: 600;
}

.sidebar-brand {
    padding: 30px 20px;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 20px;
}

.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
}

/* Responsive Admin */
/* Sponsors & Inquiries */
.sponsor-logo {
    max-height: 60px;
    filter: grayscale(1);
    opacity: 0.6;
    transition: all 0.3s ease;
}

.sponsor-logo:hover {
    filter: grayscale(0);
    opacity: 1;
}

.border-primary-green {
    border-color: var(--primary-green) !important;
}

.bg-primary-green {
    background-color: var(--primary-green) !important;
}

.text-primary-green {
    color: var(--primary-green) !important;
}

.btn-primary-green {
    background-color: #013220 !important;
    color: #ffffff !important;
    border: none !important;
    padding: 12px 24px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-primary-green:hover {
    background-color: #012216 !important;
    color: #ffffff !important;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(1, 50, 32, 0.4);
}

.btn-outline-primary-green {
    border-color: var(--primary-green);
    color: var(--primary-green);
}

.btn-outline-primary-green:hover {
    background-color: var(--primary-green);
    color: #fff;
}

.badge-pending {
    background-color: #fce7cf;
    color: #a35d05;
}

.badge-contacted {
    background-color: #d1fae5;
    color: #065f46;
}

@media (max-width: 991px) {
    .sidebar {
        transform: translateX(-100%);
        visibility: hidden;
        z-index: 1050;
    }

    .sidebar.open {
        transform: translateX(0);
        visibility: visible;
    }

    .main-content {
        margin-left: 0;
        width: 100%;
        padding-top: 80px;
        /* Space for mobile nav */
    }

    .sidebar-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100vw;
        height: 100vh;
        background: rgba(0, 0, 0, 0.5);
        z-index: 1045;
        display: none;
        backdrop-filter: blur(4px);
    }

    .sidebar-overlay.show {
        display: block;
    }

    .admin-header {
        margin-top: 20px;
    }

    .sidebar-toggle {
        display: block !important;
    }
}

.admin-mobile-nav {
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.sidebar-toggle {
    display: none;
}

/* Islamic Tech Pattern Background */
.bg-arabesque {
    background-color: #ffffff;
    position: relative;
    overflow: hidden;
}

.bg-arabesque::before,
.bg-arabesque::after {
    content: '';
    position: absolute;
    width: 400px;
    height: 400px;
    background-image: url('https://www.transparenttextures.com/patterns/arabesque.png');
    opacity: 0.03;
    z-index: 0;
}

.bg-arabesque::before {
    top: -100px;
    left: -100px;
    transform: rotate(45deg);
}

.bg-arabesque::after {
    bottom: -100px;
    right: -100px;
    transform: rotate(-135deg);
}

/* Glassmorphism Card */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    box-shadow: var(--soft-shadow);
    padding: 3rem;
    position: relative;
    z-index: 1;
}

/* Glow Buttons */
.btn-glow-teal {
    background-color: var(--accent-teal);
    color: white;
    border: none;
    box-shadow: var(--glow-teal);
    transition: all 0.3s ease;
}

.btn-glow-teal:hover {
    background-color: #0d9488;
    box-shadow: 0 0 20px rgba(20, 184, 166, 0.6);
    transform: translateY(-2px);
    color: white;
}

.social-proof-badge {
    display: inline-flex;
    align-items: center;
    background: rgba(20, 184, 166, 0.1);
    color: var(--accent-teal);
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.social-proof-badge i {
    margin-right: 0.5rem;
}

/* Responsive Adjustments */
@media (max-width: 991px) {
    .glass-card {
        padding: 2rem;
    }
}

@media (max-width: 768px) {
    .glass-card {
        padding: 2rem 1.5rem;
    }

    .hero-section {
        padding: 60px 0;
    }

    .hero-section h1 {
        font-size: 2.2rem;
    }

    .display-4 {
        font-size: 2rem;
    }

    .countdown-container {
        gap: 0.5rem;
    }

    .countdown-item {
        padding: 1rem;
        min-width: 70px;
    }
}

/* Purpose Section & Animations */
.purpose-section {
    background-color: #f8fafc;
    position: relative;
}

.purpose-section .lead {
    line-height: 1.8;
}

.icon-highlight {
    transition: transform 0.3s ease;
}

.icon-highlight:hover {
    transform: translateY(-5px);
}

.fade-in-up {
    animation: fadeInUp 0.8s ease-out forwards;
    opacity: 0;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Purpose Split Layout (V2) */
.purpose-split {
    background-color: var(--dark-green-split);
    position: relative;
    overflow: hidden;
}

.purpose-split .bg-arabesque {
    background-color: transparent !important;
}

.purpose-split .bg-arabesque::before,
.purpose-split .bg-arabesque::after {
    opacity: 0.05;
}

.font-serif {
    font-family: 'Playfair Display', serif;
}

.text-white-80 {
    color: rgba(255, 255, 255, 0.8) !important;
}

.text-accent-teal {
    color: var(--accent-teal) !important;
}

.purpose-list {
    padding-left: 0;
    list-style: none;
}

.purpose-list li {
    display: flex;
    align-items: center;
    margin-bottom: 1.25rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.9);
}

.purpose-list li i {
    color: var(--accent-teal);
    font-size: 1.25rem;
    margin-right: 1rem;
}

.gold-glow-img {
    border-radius: 24px;
    box-shadow: 0 0 40px rgba(200, 169, 74, 0.25);
    transition: all 0.5s ease;
    z-index: 2;
    position: relative;
}

.gold-glow-img:hover {
    box-shadow: 0 0 60px rgba(200, 169, 74, 0.4);
    transform: scale(1.02);
}

.glow-bg-shape {
    position: absolute;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(200, 169, 74, 0.15) 0%, rgba(200, 169, 74, 0) 70%);
    z-index: 1;
    right: 5%;
    top: 20%;
}