/* ====================================================================
   Gayatri Computer Classes - Modern Design System
   Colors: Royal Blue (#2563EB, #1E40AF), Vibrant Orange (#EA580C), 
           Gold (#F59E0B, #FBBF24), Dark (#0F172A), Light (#F8FAFC)
   ==================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Noto+Sans+Gujarati:wght@400;600;700&display=swap');

:root {
    --primary: #2563EB;
    --primary-dark: #1E40AF;
    --primary-light: #EFF6FF;
    --secondary: #06B6D4;
    --accent: #EA580C;
    --accent-hover: #C2410C;
    --gold: #F59E0B;
    --gold-light: #FEF3C7;
    --dark: #0F172A;
    --dark-muted: #475569;
    --light: #F8FAFC;
    --white: #FFFFFF;
    --border-color: #E2E8F0;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --font-main: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-gu: 'Noto Sans Gujarati', 'Inter', sans-serif;
}

body {
    font-family: var(--font-main);
    background-color: var(--light);
    color: var(--dark);
    line-height: 1.6;
    overflow-x: hidden;
}

.font-gu {
    font-family: var(--font-gu);
}

/* Top Announcement Bar */
.top-bar {
    background-color: var(--dark);
    color: #94A3B8;
    font-size: 0.85rem;
    padding: 7px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.top-bar a {
    color: #CBD5E1;
    text-decoration: none;
    transition: color 0.2s;
}
.top-bar a:hover {
    color: var(--gold);
}

/* Navbar */
.navbar-custom {
    background-color: var(--white);
    box-shadow: var(--shadow-sm);
    padding: 14px 0;
    transition: all 0.3s ease;
}
.navbar-brand {
    font-weight: 700;
    font-size: 1.28rem;
    color: var(--primary) !important;
    display: flex;
    align-items: center;
    gap: 10px;
}
.navbar-brand .brand-logo-icon {
    width: 42px;
    height: 42px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: var(--white);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    box-shadow: 0 4px 10px rgba(37, 99, 235, 0.25);
}
.nav-link {
    font-weight: 500;
    color: #334155 !important;
    padding: 8px 14px !important;
    border-radius: var(--radius-sm);
    transition: all 0.2s;
}
.nav-link:hover, .nav-link.active {
    color: var(--primary) !important;
    background-color: var(--primary-light);
}

/* Buttons */
.btn-primary-custom {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: var(--white) !important;
    border: none;
    font-weight: 600;
    padding: 10px 22px;
    border-radius: var(--radius-md);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
    transition: all 0.25s ease;
}
.btn-primary-custom:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(37, 99, 235, 0.35);
}
.btn-accent-custom {
    background: linear-gradient(135deg, var(--accent), var(--accent-hover));
    color: var(--white) !important;
    border: none;
    font-weight: 600;
    padding: 10px 22px;
    border-radius: var(--radius-md);
    box-shadow: 0 4px 12px rgba(234, 88, 12, 0.25);
    transition: all 0.25s ease;
}
.btn-accent-custom:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(234, 88, 12, 0.35);
}
.btn-outline-custom {
    border: 2px solid var(--primary);
    color: var(--primary) !important;
    font-weight: 600;
    padding: 8px 20px;
    border-radius: var(--radius-md);
    transition: all 0.2s ease;
}
.btn-outline-custom:hover {
    background-color: var(--primary);
    color: var(--white) !important;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, #0f172a 0%, #1e3a8a 50%, #1e40af 100%);
    color: var(--white);
    padding: 80px 0 90px;
    position: relative;
    overflow: hidden;
}
.hero-section::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 40px;
    background: var(--light);
    clip-path: polygon(0 100%, 100% 100%, 100% 0);
}
.hero-badge {
    background: rgba(245, 158, 11, 0.15);
    color: var(--gold);
    border: 1px solid rgba(245, 158, 11, 0.3);
    padding: 6px 16px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.88rem;
    display: inline-block;
    margin-bottom: 18px;
}
.hero-title {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 20px;
}
.hero-subtitle {
    font-size: 1.15rem;
    color: #CBD5E1;
    margin-bottom: 30px;
    max-width: 620px;
}

/* Feature & Stat Cards */
.stat-box {
    background: var(--white);
    border-radius: var(--radius-md);
    padding: 24px 20px;
    text-align: center;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
    transition: transform 0.2s;
}
.stat-box:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}
.stat-icon {
    font-size: 2.2rem;
    color: var(--primary);
    margin-bottom: 10px;
}
.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: var(--dark);
    line-height: 1.1;
}
.stat-label {
    font-size: 0.9rem;
    color: var(--dark-muted);
    margin-top: 5px;
}

/* Course Cards */
.course-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    height: 100%;
    transition: all 0.3s ease;
}
.course-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
    border-color: #BFDBFE;
}
.course-thumb-wrapper {
    position: relative;
    width: 100%;
    height: 200px;
    background: #E2E8F0;
    overflow: hidden;
}
.course-thumb-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}
.course-card:hover .course-thumb-wrapper img {
    transform: scale(1.05);
}
.badge-free {
    background-color: #10B981;
    color: var(--white);
    font-weight: 700;
    font-size: 0.78rem;
    padding: 4px 10px;
    border-radius: 4px;
}
.badge-paid {
    background-color: var(--accent);
    color: var(--white);
    font-weight: 700;
    font-size: 0.78rem;
    padding: 4px 10px;
    border-radius: 4px;
}
.badge-level {
    background: rgba(15, 23, 42, 0.75);
    color: var(--white);
    font-size: 0.75rem;
    padding: 3px 8px;
    border-radius: 4px;
}
.course-body {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}
.course-category {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}
.course-title {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 10px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.course-meta {
    display: flex;
    gap: 14px;
    font-size: 0.84rem;
    color: var(--dark-muted);
    margin-bottom: 15px;
}
.course-price-wrap {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-top: auto;
    padding-top: 15px;
    border-top: 1px solid var(--border-color);
}
.price-current {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--dark);
}
.price-original {
    font-size: 0.95rem;
    color: #94A3B8;
    text-decoration: line-through;
}

/* Subscription Plan Cards */
.plan-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    border: 2px solid var(--border-color);
    padding: 35px 25px;
    text-align: center;
    position: relative;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
}
.plan-card.featured {
    border-color: var(--primary);
    box-shadow: 0 10px 25px -5px rgba(37, 99, 235, 0.2);
    transform: scale(1.03);
}
.plan-badge {
    position: absolute;
    top: -14px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, var(--gold), #D97706);
    color: var(--white);
    font-weight: 700;
    font-size: 0.8rem;
    padding: 4px 18px;
    border-radius: 50px;
    box-shadow: 0 2px 6px rgba(245, 158, 11, 0.4);
}
.plan-name {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 10px;
}
.plan-price {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--primary);
    line-height: 1;
    margin: 15px 0 5px;
}
.plan-original-price {
    color: #94A3B8;
    text-decoration: line-through;
    font-size: 1.1rem;
    margin-bottom: 10px;
}
.plan-duration {
    font-size: 0.88rem;
    color: var(--dark-muted);
    margin-bottom: 25px;
}
.plan-features {
    text-align: left;
    margin: 20px 0 30px;
    padding: 0;
    list-style: none;
    flex-grow: 1;
}
.plan-features li {
    padding: 8px 0;
    font-size: 0.92rem;
    color: #334155;
    display: flex;
    align-items: flex-start;
    gap: 10px;
}
.plan-features li i {
    color: #10B981;
    margin-top: 3px;
    font-size: 1rem;
}

/* Floating WhatsApp Button */
.whatsapp-float {
    position: fixed;
    bottom: 25px;
    right: 25px;
    background-color: #25D366;
    color: var(--white);
    width: 60px;
    height: 60px;
    border-radius: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.4);
    z-index: 1000;
    transition: all 0.3s ease;
}
.whatsapp-float:hover {
    color: var(--white);
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.6);
}

/* Footer */
footer {
    background-color: var(--dark);
    color: #94A3B8;
    padding: 70px 0 25px;
    font-size: 0.92rem;
}
footer h5 {
    color: var(--white);
    font-weight: 700;
    margin-bottom: 20px;
    font-size: 1.1rem;
}
footer a {
    color: #CBD5E1;
    text-decoration: none;
    transition: color 0.2s;
}
footer a:hover {
    color: var(--gold);
}
footer ul {
    padding-left: 0;
    list-style: none;
}
footer ul li {
    margin-bottom: 10px;
}
.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    margin-top: 45px;
    padding-top: 25px;
    text-align: center;
    font-size: 0.85rem;
}

/* Security & Anti-Piracy Protection */
@media print {
    body, html, * {
        display: none !important;
        visibility: hidden !important;
    }
}

.no-select {
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

/* ====================================================================
   Comprehensive Mobile & Tablet Responsiveness System
   Breakpoints:
   - Large / Tablet (< 992px)
   - Medium / Mobile Landscape (< 768px)
   - Small / Mobile Phones (< 576px)
   - Extra Small (< 400px)
   ==================================================================== */

@media (max-width: 991.98px) {
    /* Navbar Mobile Styles */
    .navbar-custom {
        padding: 10px 0;
    }
    .navbar-brand {
        font-size: 1.12rem;
        gap: 10px;
    }
    .navbar-brand .brand-logo-icon {
        width: 38px;
        height: 38px;
        font-size: 1.15rem;
    }
    .navbar-collapse {
        background: var(--white);
        margin-top: 14px;
        padding: 16px 18px;
        border-radius: 14px;
        box-shadow: 0 12px 28px rgba(15, 23, 42, 0.12);
        border: 1px solid var(--border-color);
    }
    .navbar-nav .nav-item {
        border-bottom: 1px solid #F1F5F9;
    }
    .navbar-nav .nav-item:last-child {
        border-bottom: none;
    }
    .navbar-nav .nav-link {
        padding: 11px 14px !important;
        font-size: 0.98rem;
    }
    .nav-auth-buttons {
        flex-wrap: wrap;
        width: 100%;
        margin-top: 14px;
        padding-top: 14px;
        border-top: 1px solid var(--border-color);
        gap: 10px;
    }
    .nav-auth-buttons .btn {
        flex: 1 1 calc(50% - 10px);
        min-width: 120px;
        padding: 10px 14px;
        font-size: 0.92rem;
        text-align: center;
        justify-content: center;
    }

    /* Plan Cards on Tablet */
    .plan-card.featured {
        transform: none;
        margin-top: 10px;
    }

    /* Course detail sticky sidebar fallback */
    .course-details-sidebar .sticky-top {
        position: static !important;
        margin-top: 20px;
    }
}

@media (max-width: 767.98px) {
    /* Typography scaling */
    h1, .h1 { font-size: 1.85rem; }
    h2, .h2 { font-size: 1.55rem; }
    h3, .h3 { font-size: 1.3rem; }

    /* Hero Section */
    .hero-section {
        padding: 48px 0 60px;
        text-align: center;
    }
    .hero-section::after {
        height: 25px;
    }
    .hero-badge {
        font-size: 0.8rem;
        padding: 5px 14px;
        margin-bottom: 14px;
    }
    .hero-title {
        font-size: 2.1rem;
        line-height: 1.25;
        margin-bottom: 14px;
    }
    .hero-subtitle {
        font-size: 1rem;
        margin: 0 auto 24px;
        line-height: 1.6;
    }
    .hero-section .d-flex.flex-wrap {
        justify-content: center;
        gap: 10px !important;
    }
    .hero-section .btn-lg {
        width: 100%;
        font-size: 1rem;
        padding: 12px 18px;
    }

    /* Stats Section */
    .stat-box {
        padding: 18px 12px;
    }
    .stat-icon {
        font-size: 1.8rem;
        margin-bottom: 6px;
    }
    .stat-number {
        font-size: 1.65rem;
    }
    .stat-label {
        font-size: 0.82rem;
    }

    /* Course Cards */
    .course-thumb-wrapper {
        height: 180px;
    }
    .course-body {
        padding: 16px;
    }
    .course-title {
        font-size: 1.05rem;
    }

    /* Plan Cards */
    .plan-card {
        padding: 26px 18px;
        margin-bottom: 20px;
    }
    .plan-price {
        font-size: 2.2rem;
    }

    /* Tables & Responsive overflow */
    .table-responsive {
        -webkit-overflow-scrolling: touch;
        margin-bottom: 15px;
    }

    /* Forms & Inputs */
    .form-control, .form-select {
        font-size: 0.95rem;
        padding: 9px 12px;
    }
    .btn {
        touch-action: manipulation;
    }

    /* Breadcrumbs */
    .breadcrumb {
        font-size: 0.85rem;
    }

    /* Footer */
    footer {
        padding: 50px 0 25px;
        text-align: center;
    }
    footer .d-flex.gap-3 {
        justify-content: center;
    }
    footer ul li {
        margin-bottom: 8px;
    }
}

@media (max-width: 575.98px) {
    /* Brand logo on small mobile */
    .navbar-brand {
        font-size: 0.98rem;
        gap: 8px;
    }
    .navbar-brand .brand-logo-icon {
        width: 34px;
        height: 34px;
        font-size: 1rem;
        border-radius: 8px;
    }
    .navbar-brand small {
        font-size: 0.65rem !important;
    }

    /* Hero title on smaller screens */
    .hero-title {
        font-size: 1.72rem;
    }
    .hero-badge {
        font-size: 0.74rem;
        padding: 4px 10px;
    }

    /* Buttons in navbar */
    .nav-auth-buttons .btn {
        flex: 1 1 100%;
        width: 100%;
    }

    /* Floating WhatsApp Button */
    .whatsapp-float {
        bottom: 16px;
        right: 16px;
        width: 48px;
        height: 48px;
        font-size: 24px;
        box-shadow: 0 4px 12px rgba(37, 211, 102, 0.45);
    }

    /* Course detail list items */
    .accordion-button {
        padding: 12px 14px;
        font-size: 0.92rem;
    }
    .list-group-item {
        padding: 12px 14px !important;
    }
}

@media (max-width: 380px) {
    .navbar-brand {
        font-size: 0.9rem;
    }
    .navbar-brand .brand-logo-icon {
        width: 30px;
        height: 30px;
        font-size: 0.9rem;
    }
    .hero-title {
        font-size: 1.5rem;
    }
    .stat-number {
        font-size: 1.4rem;
    }
}

/* ====================================================================
   PWA Installation & Mobile Bottom Navigation Bar (as per m1.jpg & m2.png)
   ==================================================================== */

/* Header Install App Button (Positioned next to title as in m2.png) */
.btn-install-app {
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
    color: #1e40af;
    border: 1.5px solid #93c5fd;
    font-size: 0.78rem;
    font-weight: 700;
    padding: 5px 12px;
    border-radius: 50px;
    box-shadow: 0 2px 5px rgba(37, 99, 235, 0.12);
    transition: all 0.25s ease;
    white-space: nowrap;
    text-decoration: none;
    line-height: 1.2;
    cursor: pointer;
}

.btn-install-app:hover, .btn-install-app:focus {
    background: linear-gradient(135deg, #2563eb, #1e40af);
    color: #ffffff !important;
    border-color: #2563eb;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.28);
}

.btn-install-app .install-icon {
    font-size: 0.86rem;
    color: #2563eb;
    transition: color 0.2s;
}

.btn-install-app:hover .install-icon {
    color: #ffffff;
}

.btn-install-app.is-installed {
    background: #ecfdf5 !important;
    border-color: #a7f3d0 !important;
    color: #065f46 !important;
    box-shadow: 0 1px 3px rgba(16, 185, 129, 0.15);
    cursor: pointer;
}

.btn-install-app.is-installed:hover {
    background: #d1fae5 !important;
    border-color: #6ee7b7 !important;
    color: #047857 !important;
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(16, 185, 129, 0.25);
}

.btn-install-app.can-install {
    animation: pwaPulse 2.5s infinite ease-in-out;
}

@keyframes pwaPulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.45);
    }
    50% {
        box-shadow: 0 0 0 7px rgba(37, 99, 235, 0);
    }
}

/* Mobile Bottom Navigation Bar (as per m1.jpg) */
.mobile-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: #0f172a;
    background: linear-gradient(180deg, #131c31 0%, #0a0f1d 100%);
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    justify-content: space-around;
    align-items: center;
    z-index: 1040;
    padding-bottom: env(safe-area-inset-bottom, 0px);
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.4);
}

.bottom-nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #94a3b8;
    padding: 6px 0;
    transition: all 0.2s ease;
    font-family: var(--font-main);
    position: relative;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.bottom-nav-item .nav-icon {
    font-size: 1.25rem;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 2px;
    transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), color 0.2s ease;
}

.bottom-nav-item .nav-label {
    font-size: 0.68rem;
    font-weight: 500;
    letter-spacing: 0.2px;
    transition: color 0.2s ease;
    line-height: 1;
}

.bottom-nav-item:hover {
    color: #e2e8f0;
}

.bottom-nav-item.active {
    color: #ffffff;
}

.bottom-nav-item.active .nav-icon {
    color: #60a5fa;
    transform: translateY(-2px) scale(1.12);
}

.bottom-nav-item.active .nav-label {
    color: #ffffff;
    font-weight: 700;
}

.bottom-nav-item.active::after {
    content: '';
    position: absolute;
    bottom: 2px;
    width: 18px;
    height: 3px;
    background: #60a5fa;
    border-radius: 2px;
    box-shadow: 0 0 8px rgba(96, 165, 250, 0.8);
}

/* Mobile responsive padding & spacing */
@media (max-width: 767.98px) {
    body {
        padding-bottom: 68px !important;
    }

    .whatsapp-float {
        bottom: 76px !important;
        right: 16px !important;
    }

    .brand-main-title {
        font-size: 1.05rem;
        line-height: 1.15;
        font-weight: 700;
    }

    .brand-sub-title {
        font-size: 0.65rem !important;
        margin-top: 1px;
    }

    .btn-install-app {
        font-size: 0.74rem;
        padding: 4px 10px;
    }

    .dashboard-main {
        padding-bottom: 70px;
    }
}

@media (max-width: 460px) {
    .navbar-brand {
        font-size: 0.95rem;
        gap: 6px;
    }
    .brand-main-title {
        font-size: 0.92rem;
    }
    .navbar-brand .brand-logo-icon {
        width: 32px;
        height: 32px;
        font-size: 0.95rem;
    }
    .btn-install-app {
        padding: 4px 8px;
        font-size: 0.7rem;
    }
}

@media (max-width: 370px) {
    .btn-install-app .install-text {
        display: none;
    }
    .btn-install-app {
        padding: 6px 9px;
        border-radius: 50%;
    }
    .btn-install-app .install-icon {
        margin: 0 !important;
    }
}
