/* ==========================================================================
   Exam Master - Modern Light Theme Design System
   ========================================================================== */

:root {
    --primary: #4f46e5;
    --primary-hover: #4338ca;
    --primary-light: #e0e7ff;
    --secondary: #0ea5e9;
    --accent: #f59e0b;
    --accent-hover: #d97706;
    --success: #10b981;
    --danger: #ef4444;
    --bg-main: #f8fafc;
    --bg-card: rgba(255, 255, 255, 0.9);
    --text-main: #0f172a;
    --text-muted: #64748b;
    --border-color: #e2e8f0;
}

body {
    font-family: 'Plus Jakarta Sans', sans-serif;
    background-color: var(--bg-main);
    color: var(--text-main);
    overflow-x: hidden;
    scroll-behavior: smooth;
}

/* Background particle backdrop styling */
#tsparticles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: radial-gradient(circle at 50% 0%, #ffffff 0%, #f1f5f9 100%);
}

/* Glassmorphism card effects */
.glass-card {
    background: var(--bg-card);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.8);
    box-shadow: 0 4px 25px rgba(0, 0, 0, 0.03);
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.glass-card:hover:not(.no-hover) {
    transform: translateY(-6px);
    background: #ffffff;
    box-shadow: 0 20px 40px rgba(79, 70, 229, 0.08);
    border-color: rgba(79, 70, 229, 0.2);
}

/* Category Filter Pills */
.category-pill {
    padding: 0.6rem 1.4rem;
    border-radius: 9999px;
    font-weight: 700;
    font-size: 0.875rem;
    background: #ffffff;
    color: var(--text-muted);
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
    cursor: pointer;
    white-space: nowrap;
}

.category-pill:hover {
    color: var(--primary);
    border-color: var(--primary-light);
    background: var(--primary-light);
}

.category-pill.active {
    background: var(--primary);
    color: #ffffff;
    border-color: var(--primary);
    box-shadow: 0 8px 20px rgba(79, 70, 229, 0.25);
}

/* Shine effect on buttons */
.btn-shine {
    position: relative;
    overflow: hidden;
}

.btn-shine::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(120deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: all 0.8s;
}

.btn-shine:hover::before {
    left: 100%;
}

/* Animated gradient text */
.animated-gradient-text {
    background: linear-gradient(to right, #4f46e5, #0ea5e9, #8b5cf6, #4f46e5);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradient-flow 6s linear infinite;
}

@keyframes gradient-flow {
    0% { background-position: 200% center; }
    100% { background-position: 0% center; }
}

/* Reveal scroll animation */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s cubic-bezier(0.165, 0.84, 0.44, 1), transform 0.8s cubic-bezier(0.165, 0.84, 0.44, 1);
}

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

/* Entrance animation */
@keyframes bounce-in-from-top {
    0% { opacity: 0; transform: translateY(-100px) scale(0.6); }
    60% { opacity: 1; transform: translateY(15px) scale(1.03); }
    100% { opacity: 1; transform: translateY(0) scale(1); }
}

.fab-bounce-in {
    opacity: 0;
    animation: bounce-in-from-top 1s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

/* Loader spinner */
.loader {
    border: 3px solid #f3f3f3;
    border-top: 3px solid var(--primary);
    border-radius: 50%;
    width: 36px;
    height: 36px;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Card Image aspect ratio crops */
.card-img-container {
    position: relative;
    width: 100%;
    padding-top: 56.25%; /* 16:9 ratio */
    overflow: hidden;
    border-radius: 1.25rem;
    background-color: #f1f5f9;
}

.card-img-container img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.glass-card:hover .card-img-container img {
    transform: scale(1.05);
}

/* Carousel dots navigation styling */
.banner-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: rgba(0, 0, 0, 0.2);
    transition: all 0.3s;
    cursor: pointer;
}

.banner-dot.active {
    width: 28px;
    border-radius: 14px;
    background-color: var(--primary);
}

/* Modal overlay styling */
.modal-overlay {
    background-color: rgba(15, 23, 42, 0.5);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    transition: all 0.3s ease;
}

/* Option card selector in purchase modal */
.option-select-card {
    border: 2px solid var(--border-color);
    border-radius: 1.25rem;
    padding: 1.25rem;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #ffffff;
}

.option-select-card:hover {
    border-color: var(--primary-light);
    background: #fafafa;
}

.option-select-card.selected {
    border-color: var(--primary);
    background: var(--primary-light);
    box-shadow: 0 4px 15px rgba(79, 70, 229, 0.15);
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #f1f5f9;
}
::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Custom Header Glow Effects with modern subtle transitions */
.part-english {
    font-family: 'Outfit', sans-serif;
    font-weight: 900;
    letter-spacing: -0.04em;
    background: linear-gradient(135deg, #0f172a 0%, #312e81 25%, #4f46e5 50%, #312e81 75%, #0f172a 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientShift 5s linear infinite;
    cursor: default;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    display: inline-block;
    filter: drop-shadow(0 2px 5px rgba(79, 70, 229, 0.1));
}

.part-english:hover {
    transform: translateY(-2px) scale(1.02);
    filter: drop-shadow(0 8px 20px rgba(79, 70, 229, 0.35));
}

.part-hindi {
    font-family: 'Kalam', cursive;
    font-weight: 700;
    background: linear-gradient(135deg, #ea580c 0%, #f97316 25%, #f59e0b 50%, #f97316 75%, #ea580c 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientShift 5s linear infinite;
    cursor: default;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    display: inline-block;
    padding-right: 12px; /* Prevent italic cursive clipping of Devnagari characters */
    filter: drop-shadow(0 2px 5px rgba(234, 88, 12, 0.1));
}

.part-hindi:hover {
    transform: translateY(-2px) scale(1.02);
    filter: drop-shadow(0 8px 20px rgba(234, 88, 12, 0.35));
}

/* Double word spacing for Hindi text elements */
.double-word-spacing {
    word-spacing: 0.35em;
}

/* Premium gradient styling for Exam Master Notes subtitle */
.premium-notes-text {
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-weight: 500;
    background: linear-gradient(to right, #ea580c, #f59e0b, #d97706);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: 0.05em;
    word-spacing: 0.35em;
    display: inline-block;
}

/* =========================================================
   COURIER LABEL - Print-only styles for A4 dispatch labels
   ========================================================= */
@media print {
    body * { visibility: hidden !important; }
    #courierLabelPrintArea, #courierLabelPrintArea * { visibility: visible !important; }
    #courierLabelPrintArea {
        position: fixed !important;
        top: 0 !important; left: 0 !important;
        width: 100% !important; height: 100% !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        background: white !important;
        z-index: 99999 !important;
    }
}

.courier-label-card {
    width: 148mm;
    min-height: 105mm;
    border: 2.5px solid #1e3a8a;
    border-radius: 10px;
    font-family: 'Plus Jakarta Sans', sans-serif;
    background: #fff;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(30,58,138,0.15);
}

.courier-label-header {
    background: linear-gradient(135deg, #1e3a8a 0%, #3b82f6 100%);
    color: white;
    padding: 8px 14px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.courier-label-body {
    padding: 10px 14px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.courier-addr-box {
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    padding: 8px 10px;
    background: #f8fafc;
}

.courier-addr-box.to {
    border-color: #3b82f6;
    background: #eff6ff;
}

.courier-label-footer {
    background: #f8fafc;
    border-top: 1.5px dashed #cbd5e1;
    padding: 6px 14px;
    font-size: 9px;
    color: #64748b;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
