@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Poppins:wght@500;600;700;800&display=swap');

:root {
    --primary-color: #003893;
    --secondary-color: #DC3545;
    --accent-color: #0B5ED7;
    --bg-color: #F8FAFC;
    --header-color: #FFFFFF;
    --text-main: #1F2937;
    --text-muted: #64748B;
    --border-color: #E5E7EB;
    --shadow-sm: 0 8px 24px rgba(15, 23, 42, 0.08);
    --shadow-md: 0 16px 40px rgba(15, 23, 42, 0.12);
    --font-main: 'Inter', sans-serif;
    --font-heading: 'Poppins', sans-serif;
    --font-nepali: 'Noto Sans Devanagari', sans-serif;
    --border-radius: 16px;
    --transition-speed: 0.25s;
}

body {
    font-family: var(--font-main);
    color: var(--text-main);
    background-color: var(--bg-color);
    line-height: 1.7;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    color: var(--primary-color);
    letter-spacing: -0.01em;
}

p {
    margin-bottom: 0;
}

.nepali-text {
    font-family: var(--font-nepali);
}

/* Header Styles */
.top-bar {
    background: #061B43 !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    color: #CBD5E1 !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.88rem;
    position: relative;
    z-index: 1031;
}

.top-bar .info-item {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: #E2E8F0 !important;
}

.top-bar .info-item i {
    color: #60A5FA !important;
}

.main-header {
    position: relative;
    overflow: hidden;
    isolation: isolate;
    background: linear-gradient(135deg, #061B43 0%, #0A2F73 40%, #1E4FA8 80%, #0B5ED7 100%) !important;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    padding: 1.25rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
    min-height: 112px;
}

.main-header::before {
    content: '';
    position: absolute;
    inset: 0;
    background: 
        radial-gradient(circle at 15% 30%, rgba(56, 189, 248, 0.18) 0%, transparent 45%),
        radial-gradient(circle at 85% 70%, rgba(11, 94, 215, 0.25) 0%, transparent 50%),
        radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.05) 0%, transparent 60%);
    opacity: 0.9;
    z-index: -1;
    pointer-events: none;
}

.gov-text {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.gov-crest {
    font-size: 0.95rem;
    font-weight: 600;
    color: #93C5FD;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.header-meta {
    font-size: 1rem;
    color: #CBD5E1;
}

.header-agency {
    font-size: 1rem;
    color: #F8FAFC;
    font-weight: 600;
}

.header-institution {
    font-size: 1.05rem;
    color: #38BDF8;
    font-weight: 700;
    text-shadow: 0 2px 10px rgba(56, 189, 248, 0.3);
}

.header-title {
    font-size: clamp(1.35rem, 2.15vw, 1.95rem);
    color: #FFFFFF;
    font-weight: 800;
    line-height: 1.2;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.25);
}

.header-location {
    font-size: 0.9rem;
    color: #94A3B8;
}

.header-logo {
    max-height: 86px;
    width: auto;
    object-fit: contain;
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.25));
    transition: transform var(--transition-speed) ease;
}

.header-logo:hover {
    transform: scale(1.04);
}

/* Glassmorphism Navbar */
.main-navbar {
    background: linear-gradient(180deg, rgba(240, 249, 255, 0.85) 0%, rgba(224, 242, 254, 0.75) 100%) !important;
    backdrop-filter: blur(24px) saturate(190%) !important;
    -webkit-backdrop-filter: blur(24px) saturate(190%) !important;
    padding: 0.5rem 0 !important;
    box-shadow: 0 8px 32px 0 rgba(14, 165, 233, 0.15), 0 2px 8px 0 rgba(0, 0, 0, 0.04), inset 0 1px 1px 0 rgba(255, 255, 255, 0.95), inset 0 -1px 1px 0 rgba(186, 230, 253, 0.5) !important;
    border-top: 1px solid rgba(255, 255, 255, 0.85) !important;
    border-bottom: 1px solid rgba(186, 230, 253, 0.6) !important;
    position: sticky;
    top: 0;
    z-index: 1030;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.navbar-brand {
    color: #0F294A !important;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.nav-link {
    color: #0F294A !important;
    padding: 0.55rem 1.25rem !important;
    font-weight: 600 !important;
    font-size: 0.93rem;
    border-radius: 12px !important;
    margin: 0 4px !important;
    border: 1px solid transparent !important;
    text-shadow: none !important;
    -webkit-tap-highlight-color: transparent !important;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.nav-link:hover,
.nav-link:focus {
    background: rgba(255, 255, 255, 0.85) !important;
    color: #0284C7 !important;
    border-color: rgba(255, 255, 255, 1) !important;
    box-shadow: 0 4px 14px rgba(56, 189, 248, 0.25), inset 0 1px 0 rgba(255, 255, 255, 1) !important;
    transform: translateY(-1px);
}

.nav-link.active {
    background: linear-gradient(135deg, #0EA5E9 0%, #0284C7 100%) !important;
    color: #FFFFFF !important;
    font-weight: 700 !important;
    box-shadow: 0 4px 16px rgba(14, 165, 233, 0.4), inset 0 1px 1px 0 rgba(255, 255, 255, 0.4) !important;
    border: 1px solid rgba(255, 255, 255, 0.5) !important;
    transform: translateY(-1px);
}

.dropdown-menu {
    background: rgba(240, 249, 255, 0.94) !important;
    backdrop-filter: blur(25px) saturate(190%) !important;
    -webkit-backdrop-filter: blur(25px) saturate(190%) !important;
    border: 1px solid rgba(255, 255, 255, 0.9) !important;
    border-radius: 16px !important;
    padding: 0.5rem !important;
    box-shadow: 0 20px 40px rgba(14, 165, 233, 0.18), 0 4px 12px rgba(0, 0, 0, 0.05), inset 0 1px 1px rgba(255, 255, 255, 0.9) !important;
    margin-top: 0.5rem !important;
}

.dropdown-item {
    color: #0F294A !important;
    border-radius: 10px !important;
    padding: 0.65rem 1rem !important;
    font-weight: 600 !important;
    transition: all 0.2s ease !important;
}

.dropdown-item:hover,
.dropdown-item:focus {
    background: linear-gradient(135deg, #0EA5E9 0%, #0284C7 100%) !important;
    color: #FFFFFF !important;
    box-shadow: 0 4px 14px rgba(14, 165, 233, 0.35) !important;
    transform: translateX(2px);
}

.navbar-toggler {
    border: 1px solid rgba(186, 230, 253, 0.8);
    border-radius: 12px;
    padding: 0.4rem 0.6rem;
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(12px);
    box-shadow: 0 4px 12px rgba(14, 165, 233, 0.15);
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml;charset=utf8,%3Csvg viewBox='0 0 30 30' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath stroke='rgba(15, 41, 74, 1)' stroke-width='2.2' stroke-linecap='round' stroke-miterlimit='10' d='M4 7h22M4 15h22M4 23h22'/%3E%3C/svg%3E");
}

/* Mobile Glassmorphic Menu Collapse */
@media (max-width: 991.98px) {
    .main-navbar .navbar-collapse {
        background: rgba(240, 249, 255, 0.95) !important;
        backdrop-filter: blur(25px) saturate(190%) !important;
        -webkit-backdrop-filter: blur(25px) saturate(190%) !important;
        border: 1px solid rgba(255, 255, 255, 0.9) !important;
        border-radius: 18px !important;
        padding: 1rem !important;
        margin-top: 0.75rem !important;
        box-shadow: 0 16px 36px rgba(14, 165, 233, 0.2), inset 0 1px 1px 0 rgba(255, 255, 255, 0.9) !important;
    }
    
    .main-navbar .nav-link {
        margin: 4px 0 !important;
        padding: 0.7rem 1rem !important;
    }
}

/* Hero Section */
.hero-section {
    position: relative;
    overflow: hidden;
    background: #f5f8ff;
    color: #1E293B;
    isolation: isolate;
    border-bottom: 1px solid rgba(186, 230, 253, 0.5);
}

.hero-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 20% 20%, rgba(14, 165, 233, 0.08) 0 15%, transparent 20%),
        radial-gradient(circle at 80% 30%, rgba(2, 132, 199, 0.07) 0 18%, transparent 25%),
        radial-gradient(circle at 40% 80%, rgba(56, 189, 248, 0.06) 0 12%, transparent 18%);
    opacity: 0.9;
    z-index: -1;
}

.hero-content {
    position: relative;
    z-index: 1;
    padding: 4rem 0;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.6rem 0.95rem;
    background: rgba(14, 165, 233, 0.12);
    border: 1px solid rgba(14, 165, 233, 0.25);
    border-radius: 999px;
    font-size: 0.9rem;
    font-weight: 600;
    color: #0284C7;
    backdrop-filter: blur(8px);
    margin-bottom: 1.25rem;
}

.hero-title {
    font-size: clamp(2.1rem, 4vw, 3rem);
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 1rem;
    color: #0F294A;
    max-width: 700px;
}

.hero-subtitle {
    font-size: clamp(1rem, 1.4vw, 1.2rem);
    color: #475569;
    line-height: 1.75;
    max-width: 690px;
    margin-bottom: 1.6rem;
}

.hero-btn {
    border-radius: 10px;
    padding: 0.85rem 1.35rem;
    font-weight: 600;
    box-shadow: 0 10px 25px rgba(14, 165, 233, 0.2);
    transition: transform var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
}

.hero-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 14px 28px rgba(14, 165, 233, 0.28);
}

.hero-panel {
    background: rgba(255, 255, 255, 0.85);
    border: 1px solid rgba(186, 230, 253, 0.8);
    border-radius: 24px;
    padding: 1.75rem;
    backdrop-filter: blur(12px);
    box-shadow: 0 16px 40px rgba(14, 165, 233, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.hero-panel-title {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 1.1rem;
    color: #0F294A;
}

.hero-panel-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 0.85rem;
}

.hero-panel-list li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: #334155;
    font-weight: 600;
}

.hero-panel-list li i {
    color: #0284C7;
    font-size: 1.1rem;
}

.hero-highlight-item {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    color: #334155;
    font-weight: 600;
}

.hero-highlight-item i {
    color: #0284C7;
}

/* Sections */
.py-lg-6 {
    padding-top: 4.5rem !important;
    padding-bottom: 4.5rem !important;
}

.section-alt {
    background-color: #f5f8ff;
}

.section-header {
    max-width: 720px;
    margin: 0 auto 2rem;
    text-align: center;
}

.section-title {
    font-size: clamp(1.7rem, 2.3vw, 2.2rem);
    color: var(--primary-color);
    font-weight: 700;
    margin-bottom: 0.75rem;
}

.section-subtitle {
    color: var(--text-muted);
    line-height: 1.7;
    font-size: 1rem;
}

.statistics-section {
    background: #f8fbff;
    padding: 4rem 0;
}

.stats-card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: 18px;
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
    min-height: 100%;
    transition: transform var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
}

.stats-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.stat-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 54px;
    height: 54px;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(0, 56, 147, 0.12), rgba(11, 94, 215, 0.18));
    color: var(--primary-color);
    font-size: 1.45rem;
    margin-bottom: 1rem;
}

.counter-value {
    font-size: 2rem;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 0.35rem;
}

.stat-label {
    color: var(--text-muted);
    font-size: 1rem;
    margin: 0;
}

.about-card,
.process-card,
.notice-card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
    height: 100%;
    transition: transform var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
}

.about-card:hover,
.process-card:hover,
.notice-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.list-check {
    list-style: none;
    padding: 0;
    margin: 1.25rem 0 0;
}

.list-check li {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    margin-bottom: 0.75rem;
    color: var(--text-main);
}

.list-check li i {
    color: var(--primary-color);
    font-size: 1rem;
    margin-top: 0.2rem;
}

.step-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: var(--primary-color);
    color: #ffffff;
    font-weight: 700;
    margin-bottom: 1rem;
}

.date-badge {
    background-color: #f1f5f9;
    color: var(--primary-color);
    padding: 8px 12px;
    border-radius: 12px;
    font-weight: 600;
    text-align: center;
    min-width: 60px;
}

.download-list .btn {
    width: 100%;
    justify-content: flex-start;
    padding: 1rem 1.1rem;
    border-radius: 14px;
    border-color: var(--border-color);
    color: var(--primary-color);
    background: #ffffff;
    box-shadow: 0 3px 12px rgba(15, 23, 42, 0.06);
}

.download-list .btn:hover {
    background: var(--bg-color);
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

.accordion-item {
    border: 1px solid var(--border-color);
    border-radius: 16px;
    overflow: hidden;
    margin-bottom: 0.75rem;
}

.accordion-button {
    font-weight: 600;
    color: var(--primary-color);
    box-shadow: none !important;
}

.accordion-button:not(.collapsed) {
    background: rgba(0, 56, 147, 0.06);
    color: var(--primary-color);
}

/* Buttons */
.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-primary:hover,
.btn-primary:focus {
    background-color: var(--accent-color);
    border-color: var(--accent-color);
}

.btn-secondary-custom {
    background-color: var(--secondary-color);
    color: #ffffff;
    border: none;
}

.btn-secondary-custom:hover,
.btn-secondary-custom:focus {
    background-color: #b52a3b;
    border-color: #b52a3b;
    color: #ffffff;
}

.btn-outline-primary {
    color: var(--primary-color);
    border-color: var(--border-color);
}

.btn-outline-primary:hover {
    background-color: var(--primary-color);
    color: #ffffff;
    border-color: var(--primary-color);
}

/* Multi-step form wizard */
.wizard-progress {
    display: flex;
    justify-content: space-between;
    margin-bottom: 30px;
    position: relative;
}

.wizard-progress::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 3px;
    background-color: #e9ecef;
    z-index: 1;
}

.step-indicator {
    width: 40px;
    height: 40px;
    background-color: #e9ecef;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: var(--text-muted);
    position: relative;
    z-index: 2;
    transition: all var(--transition-speed);
}

.step-indicator.active {
    background-color: var(--primary-color);
    color: #ffffff;
}

.step-indicator.completed {
    background-color: #28a745;
    color: #ffffff;
}

.step-label {
    position: absolute;
    top: 45px;
    font-size: 0.8rem;
    width: max-content;
    text-align: center;
    color: var(--text-muted);
}

.wizard-step {
    display: none;
    animation: fadeIn 0.5s;
}

.wizard-step.active {
    display: block;
}

/* Timeline */
.timeline {
    position: relative;
    padding-left: 30px;
    list-style: none;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 10px;
    top: 0;
    bottom: 0;
    width: 2px;
    background-color: #e9ecef;
}

.timeline-item {
    position: relative;
    margin-bottom: 25px;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -26px;
    top: 5px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background-color: #e9ecef;
    border: 2px solid #ffffff;
    z-index: 2;
}

.timeline-item.completed::before {
    background-color: #28a745;
}

.timeline-item.active::before {
    background-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 56, 147, 0.2);
}

/* Footer */
.footer {
    background-color: #001d4a;
    color: rgba(255, 255, 255, 0.8);
    padding: 50px 0 20px;
}

.footer h5 {
    color: #ffffff;
    margin-bottom: 20px;
    font-weight: 600;
}

.footer-links {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color var(--transition-speed);
}

.footer-links a:hover {
    color: #ffffff;
    text-decoration: underline;
}

.bottom-bar {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 20px;
    margin-top: 30px;
    text-align: center;
    font-size: 0.9rem;
}

/* Back to top */
#backToTop {
    display: none;
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 99;
    border: none;
    outline: none;
    background-color: var(--secondary-color);
    color: white;
    cursor: pointer;
    padding: 10px 15px;
    border-radius: 5px;
    font-size: 18px;
    transition: background-color var(--transition-speed);
}

#backToTop:hover {
    background-color: #b01030;
}

/* Utilities & Animations */
.fade-in-scroll {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in-scroll.is-visible {
    opacity: 1;
    transform: translateY(0);
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Accessibility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

a:focus, button:focus, input:focus, select:focus, textarea:focus {
    outline: 2px solid var(--accent-color);
    outline-offset: 2px;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent-color);
}

/* Responsive Design */
@media (max-width: 767.8px) {
    .top-bar {
        font-size: 0.8rem;
    }

    .main-header {
        padding: 1rem 0;
        min-height: auto;
    }

    .header-title {
        font-size: 1.25rem;
    }

    .hero-content {
        padding: 3.5rem 0;
    }

    .hero-btn {
        width: 100%;
        justify-content: center;
    }

    .hero-panel {
        margin-top: 1.25rem;
    }

    .navbar-nav {
        padding-top: 0.5rem;
    }

    .nav-link {
        padding: 0.8rem 1rem !important;
        border-bottom: 0;
        border-left: 3px solid transparent;
    }

    .nav-link:hover,
    .nav-link:focus,
    .nav-link.active {
        border-left-color: rgba(255, 255, 255, 0.75);
        border-bottom-color: transparent;
    }
}

@media (min-width: 992px) {
    .hero-content {
        padding: 6rem 0;
    }
}

/* Print styles */
@media print {
    .navbar, .footer, .top-bar, .hero-section, .btn, #backToTop {
        display: none !important;
    }

    body {
        color: #000;
        background: #fff;
    }
}

/* Header Links Outline & Focus Reset */
.main-header a,
.main-header a:focus,
.main-header a:active,
.main-header a:hover,
.main-header a:focus-visible,
.main-header img,
.main-header img:focus,
.main-header img:active {
    outline: none !important;
    box-shadow: none !important;
    border: none !important;
    -webkit-tap-highlight-color: transparent !important;
}
