/* Roy Education Custom Design System */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;500;600;700;800&display=swap');

:root {
    --roy-navy: #0A2540;
    --roy-blue: #1A56DB;
    --roy-blue-hover: #1447B8;
    --roy-crimson: #E11D48;
    --roy-amber: #F59E0B;
    --roy-light: #F8FAFC;
    --roy-dark: #0F172A;
    --roy-gradient: linear-gradient(135deg, #0A2540 0%, #1A56DB 100%);
    --roy-gradient-accent: linear-gradient(135deg, #E11D48 0%, #F59E0B 100%);
    --roy-font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
    --roy-font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

body {
    font-family: var(--roy-font-body);
    background-color: var(--roy-light);
    color: #334155;
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6, .font-heading {
    font-family: var(--roy-font-heading);
    font-weight: 700;
}

/* Top Announcement & Contact Bar */
.top-contact-bar {
    background: #0A2540;
    color: #CBD5E1;
    font-size: 0.85rem;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.top-contact-bar a {
    color: #F8FAFC;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.top-contact-bar a:hover {
    color: #F59E0B;
}

.ticker-wrapper {
    background: #0F172A;
    color: #F8FAFC;
    font-size: 0.85rem;
    padding: 8px 0;
    border-bottom: 3px solid #E11D48;
}

/* Premium Navbar */
.navbar-roy {
    background: #FFFFFF;
    box-shadow: 0 4px 25px rgba(10, 37, 64, 0.08);
    padding: 10px 0;
    transition: all 0.3s ease;
}

.navbar-roy .navbar-brand {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
    padding: 2px 0;
}

.navbar-roy .navbar-brand img {
    height: 48px;
    width: auto;
    max-width: 250px;
    object-fit: contain;
    filter: drop-shadow(0 2px 8px rgba(10, 37, 64, 0.12));
    transition: transform 0.2s ease;
}

.navbar-roy .navbar-brand img:hover {
    transform: scale(1.02);
}

.brand-text-container {
    display: flex;
    flex-direction: column;
    line-height: 1.15;
}

.brand-title {
    font-family: var(--roy-font-heading);
    font-weight: 900;
    font-size: 1.35rem;
    color: #0A2540 !important;
    letter-spacing: -0.5px;
}

.brand-subtitle {
    font-size: 0.7rem;
    font-weight: 700;
    color: #DC2626 !important;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.navbar-roy .nav-link {
    display: inline-flex !important;
    align-items: center !important;
    gap: 6px !important;
    white-space: nowrap !important;
    font-family: var(--roy-font-heading);
    font-weight: 600;
    font-size: 0.9rem;
    color: #1E293B !important;
    padding: 8px 12px !important;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.navbar-roy .nav-link i {
    font-size: 0.95rem;
    display: inline-block !important;
    margin: 0 !important;
}

.navbar-roy .nav-link:hover,
.navbar-roy .nav-link.active {
    color: var(--roy-blue) !important;
    background: rgba(26, 86, 219, 0.08);
}

.dropdown-menu-roy {
    border: 0;
    box-shadow: 0 12px 30px rgba(10, 37, 64, 0.15);
    border-radius: 12px;
    padding: 10px;
}

.dropdown-menu-roy .dropdown-item {
    font-weight: 500;
    padding: 10px 14px;
    border-radius: 8px;
    color: #334155;
    transition: all 0.2s ease;
}

.dropdown-menu-roy .dropdown-item:hover {
    background: #F1F5F9;
    color: var(--roy-blue);
    transform: translateX(3px);
}

.btn-roy-primary {
    background: var(--roy-gradient);
    color: #FFFFFF;
    font-weight: 600;
    border: none;
    box-shadow: 0 4px 14px rgba(26, 86, 219, 0.35);
    transition: all 0.3s ease;
}

.btn-roy-primary:hover {
    background: linear-gradient(135deg, #1A56DB 0%, #0A2540 100%);
    color: #FFFFFF;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(26, 86, 219, 0.45);
}

.btn-roy-accent {
    background: var(--roy-gradient-accent);
    color: #FFFFFF;
    font-weight: 600;
    border: none;
    box-shadow: 0 4px 14px rgba(225, 29, 72, 0.35);
    transition: all 0.3s ease;
}

.btn-roy-accent:hover {
    color: #FFFFFF;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(225, 29, 72, 0.45);
}

/* Hero Carousel / Section */
.hero-section {
    background: var(--roy-navy);
    background-image: radial-gradient(circle at 10% 20%, rgba(26, 86, 219, 0.3) 0%, transparent 40%),
                      radial-gradient(circle at 90% 80%, rgba(225, 29, 72, 0.2) 0%, transparent 40%);
    color: #FFFFFF;
    padding: 80px 0;
    position: relative;
    overflow: hidden;
}

.hero-card {
    background: rgba(255, 255, 255, 0.07);
    backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 24px;
    padding: 40px;
}

/* Feature Cards & Glassmorphism */
.glass-card {
    background: #FFFFFF;
    border: 1px solid #E2E8F0;
    border-radius: 16px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.03);
}

.glass-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 32px rgba(10, 37, 64, 0.12);
    border-color: #CBD5E1;
}

/* Exam Badge */
.badge-exam {
    background: rgba(26, 86, 219, 0.1);
    color: var(--roy-blue);
    font-weight: 600;
    border-radius: 30px;
    padding: 6px 14px;
}

/* Floating Action Elements (WhatsApp & Chatbot) */
.whatsapp-float {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 60px;
    height: 60px;
    background-color: #25D366;
    color: #FFF;
    border-radius: 50px;
    text-align: center;
    font-size: 32px;
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    text-decoration: none;
}

.whatsapp-float:hover {
    color: #FFF;
    transform: scale(1.1);
    box-shadow: 0 8px 25px rgba(37, 211, 102, 0.6);
}

.ai-chat-btn {
    position: fixed;
    bottom: 96px;
    right: 24px;
    width: 60px;
    height: 60px;
    background: var(--roy-gradient);
    color: #FFF;
    border-radius: 50px;
    border: none;
    box-shadow: 0 6px 20px rgba(26, 86, 219, 0.4);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.ai-chat-btn:hover {
    transform: scale(1.1);
}

/* AI Chat Window Modal Widget */
.chat-window {
    position: fixed;
    bottom: 168px;
    right: 24px;
    width: 360px;
    max-width: 90vw;
    height: 480px;
    background: #FFFFFF;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(10, 37, 64, 0.25);
    z-index: 9998;
    display: none;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid #E2E8F0;
}

.chat-header {
    background: var(--roy-navy);
    color: #FFF;
    padding: 16px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-body {
    flex: 1;
    padding: 16px;
    overflow-y: auto;
    background: #F8FAFC;
}

.chat-msg {
    margin-bottom: 12px;
    max-width: 85%;
    padding: 10px 14px;
    border-radius: 14px;
    font-size: 0.9rem;
}

.chat-msg.bot {
    background: #FFFFFF;
    border: 1px solid #E2E8F0;
    color: #1E293B;
    align-self: flex-start;
}

.chat-msg.user {
    background: var(--roy-blue);
    color: #FFFFFF;
    margin-left: auto;
    align-self: flex-end;
}

.chat-footer {
    padding: 12px;
    background: #FFFFFF;
    border-top: 1px solid #E2E8F0;
}

/* Admin Panel Sidebar */
.admin-wrapper {
    display: flex;
    min-height: 100vh;
}

.admin-sidebar {
    width: 260px;
    background: var(--roy-navy);
    color: #94A3B8;
    flex-shrink: 0;
}

.admin-sidebar .nav-link {
    color: #CBD5E1;
    font-weight: 500;
    padding: 12px 20px;
    border-radius: 8px;
    margin: 4px 12px;
    transition: all 0.2s ease;
}

.admin-sidebar .nav-link:hover,
.admin-sidebar .nav-link.active {
    background: rgba(255, 255, 255, 0.1);
    color: #FFFFFF;
}

.admin-content {
    flex: 1;
    background: #F1F5F9;
    padding: 30px;
}

/* Footer */
footer {
    background: var(--roy-navy);
    color: #94A3B8;
    padding-top: 60px;
    padding-bottom: 30px;
}

footer h5 {
    color: #FFFFFF;
}

footer a {
    color: #CBD5E1;
    text-decoration: none;
    transition: color 0.2s ease;
}

footer a:hover {
    color: #FFFFFF;
}

/* Custom Gradients & Utilities */
.bg-gradient-navy,
.card.bg-gradient-navy {
    background: linear-gradient(135deg, #0A2540 0%, #1E3A8A 50%, #0F172A 100%) !important;
    color: #FFFFFF !important;
}

.bg-gradient-crimson,
.card.bg-gradient-crimson {
    background: linear-gradient(135deg, #E11D48 0%, #BE123C 50%, #881337 100%) !important;
    color: #FFFFFF !important;
}

.bg-gradient-dark {
    background: linear-gradient(180deg, rgba(15, 23, 42, 0) 0%, rgba(15, 23, 42, 0.95) 100%) !important;
}

.text-light-50 {
    color: rgba(248, 250, 252, 0.85) !important;
}

.backdrop-blur {
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.service-card-hover {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.service-card-hover:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 32px rgba(10, 37, 64, 0.12) !important;
}

.video-card-hover {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.video-card-hover:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 32px rgba(10, 37, 64, 0.2) !important;
}

.max-w-700 {
    max-width: 700px;
}

.max-w-800 {
    max-width: 800px;
}

.max-w-900 {
    max-width: 900px;
}

.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Service Detail Tab Styling */
.nav-pills .nav-link {
    color: #334155;
    background: #F1F5F9;
    border: 1px solid #E2E8F0;
    transition: all 0.2s ease;
}

.nav-pills .nav-link.active {
    background: var(--roy-blue) !important;
    color: #FFFFFF !important;
    border-color: var(--roy-blue) !important;
    box-shadow: 0 4px 12px rgba(26, 86, 219, 0.25);
}

/* ==========================================================================
   Admin Panel Modern Sidebar & Interactive Layout
   ========================================================================== */
.admin-wrapper {
    display: flex;
    min-height: 100vh;
    background-color: #F8FAFC;
    overflow-x: hidden;
}

.admin-sidebar {
    width: 280px;
    min-width: 280px;
    background: linear-gradient(180deg, #0A2540 0%, #0D1E36 50%, #081628 100%);
    color: #E2E8F0;
    display: flex;
    flex-direction: column;
    z-index: 1040;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 4px 0 25px rgba(0, 0, 0, 0.15);
    border-right: 1px solid rgba(255, 255, 255, 0.06);
}

.admin-sidebar-header {
    padding: 20px 24px;
    background: rgba(255, 255, 255, 0.03);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.admin-sidebar-menu {
    flex: 1;
    overflow-y: auto;
    padding: 18px 16px;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}

.admin-sidebar-menu::-webkit-scrollbar {
    width: 5px;
}

.admin-sidebar-menu::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
}

.admin-menu-section {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #94A3B8;
    margin-top: 20px;
    margin-bottom: 8px;
    padding-left: 12px;
}

.admin-menu-section:first-child {
    margin-top: 4px;
}

.admin-nav-item {
    margin-bottom: 4px;
}

.admin-nav-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
    color: #CBD5E1;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9rem;
    border-radius: 12px;
    transition: all 0.22s ease-in-out;
    position: relative;
}

.admin-nav-link .nav-icon {
    width: 22px;
    font-size: 1.05rem;
    margin-right: 12px;
    text-align: center;
    transition: transform 0.2s ease;
}

.admin-nav-link:hover {
    color: #FFFFFF;
    background: rgba(255, 255, 255, 0.08);
    transform: translateX(3px);
}

.admin-nav-link:hover .nav-icon {
    transform: scale(1.15);
}

.admin-nav-link.active {
    color: #FFFFFF !important;
    background: linear-gradient(135deg, #1A56DB 0%, #3B82F6 100%) !important;
    box-shadow: 0 4px 16px rgba(26, 86, 219, 0.4);
    font-weight: 600;
}

.admin-nav-link.active::before {
    content: '';
    position: absolute;
    left: -16px;
    top: 50%;
    transform: translateY(-50%);
    width: 5px;
    height: 24px;
    background: #F59E0B;
    border-radius: 0 4px 4px 0;
}

.admin-sidebar-footer {
    padding: 16px;
    background: rgba(0, 0, 0, 0.2);
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.admin-content-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow-x: hidden;
}

.admin-topbar {
    background: #FFFFFF;
    border-bottom: 1px solid #E2E8F0;
    padding: 14px 28px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
    position: sticky;
    top: 0;
    z-index: 1020;
}

.admin-main-body {
    flex: 1;
    padding: 28px;
}

@media (max-width: 991.98px) {
    .admin-sidebar {
        position: fixed;
        top: 0;
        bottom: 0;
        left: -280px;
    }

    .admin-sidebar.show {
        left: 0;
    }

    .navbar-roy .navbar-brand img {
        height: 38px;
        max-width: 190px;
    }
}

@media (max-width: 575.98px) {
    .top-contact-bar {
        font-size: 0.78rem;
    }
    .top-contact-bar a {
        font-size: 0.78rem;
    }
    .ticker-wrapper {
        font-size: 0.78rem;
    }
}