/* ==========================================================================
   LEARNENDO - Premium Design System (Streaming-style Digital Products Portal)
   ========================================================================== */

/* Variables & Theme Setup */
:root {
    --bg-dark: #06050b;
    --bg-card: #12101e;
    --bg-hover: #191629;
    --bg-glass: rgba(10, 8, 22, 0.75);
    
    --accent-purple: #8b5cf6;
    --accent-purple-glow: rgba(139, 92, 246, 0.5);
    --accent-magenta: #d946ef;
    --accent-magenta-glow: rgba(217, 70, 239, 0.4);
    --accent-cyan: #06b6d4;
    --accent-cyan-glow: rgba(6, 182, 212, 0.4);
    
    --text-main: #f3f4f6;
    --text-muted: #9ca3af;
    --text-glow: #ffffff;
    
    --border-glass: rgba(255, 255, 255, 0.08);
    --border-neon: rgba(139, 92, 246, 0.2);
    
    --font-main: 'Outfit', sans-serif;
    
    --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-elastic: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    
    --shadow-glow: 0 0 15px var(--accent-purple-glow);
    --shadow-card: 0 10px 30px rgba(0, 0, 0, 0.5);
}

/* Base Reset & Globals */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
    user-select: none;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    font-family: var(--font-main);
    overflow-x: hidden;
    min-height: 100vh;
    line-height: 1.5;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}
::-webkit-scrollbar-track {
    background: var(--bg-dark);
}
::-webkit-scrollbar-thumb {
    background: #27243c;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--accent-purple);
    box-shadow: 0 0 5px var(--accent-purple-glow);
}

/* Background canvas and floating neon blobs */
#bg-particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -2;
    pointer-events: none;
}

.bg-blobs-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -3;
    pointer-events: none;
    overflow: hidden;
}

.neon-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(140px);
    opacity: 0.15;
    animation: floatBlob 25s infinite alternate ease-in-out;
}

.blob-1 {
    width: 450px;
    height: 450px;
    background: var(--accent-purple);
    top: -10%;
    left: -10%;
    animation-duration: 20s;
}

.blob-2 {
    width: 500px;
    height: 500px;
    background: var(--accent-cyan);
    bottom: -15%;
    right: -10%;
    animation-duration: 28s;
    animation-delay: -5s;
}

.blob-3 {
    width: 350px;
    height: 350px;
    background: var(--accent-magenta);
    top: 40%;
    left: 60%;
    animation-duration: 24s;
    animation-delay: -10s;
}

@keyframes floatBlob {
    0% { transform: translate(0, 0) scale(1) rotate(0deg); }
    50% { transform: translate(60px, 40px) scale(1.15) rotate(180deg); }
    100% { transform: translate(-30px, -50px) scale(0.9) rotate(360deg); }
}

/* Typography elements */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    letter-spacing: -0.02em;
    color: #fff;
}

a {
    color: inherit;
    text-decoration: none;
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    outline: none;
    background: none;
    transition: var(--transition-smooth);
}

/* Input Fields */
input[type="text"], input[type="password"], select {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-glass);
    border-radius: 6px;
    padding: 10px 14px;
    color: #fff;
    font-family: inherit;
    font-size: 0.95rem;
    transition: var(--transition-smooth);
}
input[type="text"]:focus, input[type="password"]:focus, select:focus {
    border-color: var(--accent-purple);
    box-shadow: 0 0 8px var(--accent-purple-glow);
    outline: none;
}

/* Buttons System */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 6px;
    font-size: 0.95rem;
    font-weight: 600;
    transition: var(--transition-elastic);
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent-purple), var(--accent-magenta));
    color: #fff;
    box-shadow: 0 4px 15px rgba(139, 92, 246, 0.3);
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(139, 92, 246, 0.5), 0 0 10px rgba(217, 70, 239, 0.3);
}
.btn-primary:active {
    transform: translateY(0);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border: 1px solid var(--border-glass);
    backdrop-filter: blur(10px);
}
.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.btn-circle {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border-glass);
    backdrop-filter: blur(10px);
}
.btn-circle:hover {
    background: var(--accent-purple);
    color: #fff;
    box-shadow: var(--shadow-glow);
    transform: scale(1.1);
}

.btn-block {
    width: 100%;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.85rem;
}

/* App Header / Navigation */
.app-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 4%;
    z-index: 1000;
    transition: var(--transition-smooth);
    background: linear-gradient(to bottom, rgba(6, 5, 11, 0.9) 0%, rgba(6, 5, 11, 0) 100%);
}

.app-header.scrolled {
    background: var(--bg-glass);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-glass);
    height: 60px;
}

.header-left, .header-right {
    display: flex;
    align-items: center;
    gap: 30px;
}

.logo {
    font-size: 1.8rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    color: #fff;
    text-shadow: 0 0 10px rgba(139, 92, 246, 0.3);
}
.logo span {
    background: linear-gradient(135deg, var(--accent-purple), var(--accent-cyan));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-links {
    display: flex;
    gap: 20px;
}

.nav-link {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-muted);
    transition: var(--transition-smooth);
    position: relative;
    padding: 6px 0;
}

.nav-link:hover, .nav-link.active {
    color: #fff;
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(to right, var(--accent-purple), var(--accent-magenta));
    box-shadow: 0 0 8px var(--accent-purple);
    border-radius: 2px;
}

/* Search Box Styles */
.search-container {
    display: flex;
    align-items: center;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid var(--border-glass);
    border-radius: 20px;
    padding: 4px 14px;
    width: 40px;
    height: 38px;
    overflow: hidden;
    transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1), border-color 0.3s;
}

.search-container.expanded {
    width: 250px;
    border-color: var(--accent-purple);
    box-shadow: 0 0 8px rgba(139, 92, 246, 0.2);
}

.search-icon {
    font-size: 1.2rem;
    color: #fff;
    cursor: pointer;
    flex-shrink: 0;
}

#search-input {
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0 10px;
    width: 100%;
    height: 100%;
    color: #fff;
    font-size: 0.9rem;
}
#search-input:focus {
    box-shadow: none;
}

.clear-search-btn {
    cursor: pointer;
    font-size: 1rem;
    color: var(--text-muted);
    transition: color 0.2s;
    flex-shrink: 0;
}
.clear-search-btn:hover {
    color: #fff;
}

/* Cart Icon Button */
.cart-trigger {
    position: relative;
    cursor: pointer;
    padding: 5px;
    transition: var(--transition-smooth);
    color: var(--text-muted);
}
.cart-trigger:hover {
    color: #fff;
    transform: scale(1.05);
}

.cart-badge {
    position: absolute;
    top: -5px;
    right: -6px;
    background: linear-gradient(135deg, var(--accent-magenta), var(--accent-purple));
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--bg-dark);
}

/* Profile Menu Dropdown */
.profile-menu-container {
    position: relative;
}

.profile-trigger {
    cursor: pointer;
}

.avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--border-glass);
    transition: var(--transition-smooth);
}
.profile-trigger:hover .avatar {
    border-color: var(--accent-purple);
    box-shadow: var(--shadow-glow);
}

.profile-dropdown {
    position: absolute;
    top: 55px;
    right: 0;
    width: 240px;
    background: var(--bg-glass);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-glass);
    border-radius: 10px;
    padding: 15px;
    display: none;
    flex-direction: column;
    gap: 8px;
    box-shadow: var(--shadow-card);
    z-index: 1010;
    animation: fadeSlideIn 0.2s ease-out;
}

.profile-dropdown.active {
    display: flex;
}

.dropdown-header {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.dropdown-header .user-name {
    font-weight: 600;
    font-size: 0.95rem;
}
.dropdown-header .user-email {
    font-size: 0.78rem;
    color: var(--text-muted);
}

.profile-dropdown hr {
    border: none;
    height: 1px;
    background: var(--border-glass);
    margin: 5px 0;
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    font-size: 0.9rem;
    color: var(--text-muted);
    border-radius: 6px;
    transition: var(--transition-smooth);
}
.dropdown-item:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
}
.dropdown-item i {
    width: 16px;
    height: 16px;
}
.dropdown-item.text-danger {
    color: #ef4444;
}
.dropdown-item.text-danger:hover {
    background: rgba(239, 68, 68, 0.1);
}

/* Main Content Structure */
.main-container {
    padding-top: 70px;
    min-height: calc(100vh - 70px);
}

.content-section {
    display: none;
    padding: 0 4% 50px 4%;
    animation: fadeIn 0.4s ease-in-out;
}

.content-section.active {
    display: block;
}

/* Hero Banner Style */
.hero-banner {
    position: relative;
    height: 48vh;
    min-height: 360px;
    border-radius: 16px;
    margin: 20px 0 30px 0;
    overflow: hidden;
    display: flex;
    align-items: center;
    background: #0d0b18;
    border: 1px solid var(--border-glass);
}

.hero-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(125deg, #130d2a 0%, #0c081e 50%, #030208 100%);
    z-index: 1;
}

/* Shifting Ambient background animation for Hero */
.hero-backdrop::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, var(--accent-purple-glow) 0%, transparent 60%),
                radial-gradient(circle, var(--accent-magenta-glow) 0%, transparent 60%);
    animation: moveGlow 20s infinite alternate linear;
    z-index: 2;
    opacity: 0.8;
}

.hero-content {
    position: relative;
    z-index: 10;
    width: 50%;
    min-width: 300px;
    padding: 30px 5%;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.hero-badge {
    align-self: flex-start;
    background: rgba(139, 92, 246, 0.15);
    border: 1px solid var(--accent-purple);
    color: var(--accent-cyan);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    padding: 4px 10px;
    border-radius: 50px;
    text-transform: uppercase;
    box-shadow: 0 0 10px rgba(6, 182, 212, 0.2);
}

.hero-title {
    font-size: clamp(1.4rem, 3.2vw, 2.4rem);
    line-height: 1.1;
    font-weight: 800;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.hero-metadata {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 0.9rem;
    color: var(--text-muted);
    flex-wrap: wrap;
}

.hero-metadata .rating {
    color: #fbbf24;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 4px;
}
.hero-metadata .rating i {
    fill: #fbbf24;
    width: 14px;
    height: 14px;
}

.hero-metadata .badge-type {
    background: rgba(255,255,255,0.08);
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    color: #fff;
}

.hero-description {
    color: var(--text-muted);
    font-size: 0.95rem;
    max-width: 550px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.hero-actions {
    display: flex;
    gap: 15px;
    margin-top: 15px;
}

/* Category Rows Container */
.rows-container {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.category-row {
    position: relative;
}

.row-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    margin-bottom: 15px;
}

.row-title {
    font-size: 1.35rem;
    font-weight: 700;
}

.row-view-all {
    font-size: 0.85rem;
    color: var(--accent-purple);
    font-weight: 500;
    transition: var(--transition-smooth);
}
.row-view-all:hover {
    color: var(--accent-magenta);
    text-decoration: underline;
}

/* Horizontal Cards Carousel Scroll wrapper */
.cards-scroll-wrapper {
    position: relative;
    margin: 0 -1%;
    padding: 10px 1%;
}

.cards-scroll-container {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    scroll-behavior: smooth;
    padding: 15px 5px;
}
.cards-scroll-container::-webkit-scrollbar {
    display: none; /* Hide scrollbar for clean carousel look */
}

/* Row Scroll Buttons */
.scroll-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 45px;
    height: 60px;
    background: rgba(7, 6, 11, 0.7);
    backdrop-filter: blur(8px);
    border: 1px solid var(--border-glass);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    opacity: 0;
    transition: var(--transition-smooth);
    border-radius: 6px;
}

.cards-scroll-wrapper:hover .scroll-btn {
    opacity: 1;
}

.scroll-btn:hover {
    background: var(--accent-purple);
    box-shadow: var(--shadow-glow);
}

.scroll-btn.left {
    left: -15px;
}
.scroll-btn.right {
    right: -15px;
}

/* Premium Style Cards Poster (Aspect Ratio 2:3 Vertical) */
.product-card {
    position: relative;
    flex: 0 0 190px;
    width: 190px;
    height: 280px;
    border-radius: 10px;
    background: var(--bg-card);
    border: 1px solid var(--border-glass);
    overflow: hidden;
    cursor: pointer;
    box-shadow: var(--shadow-card);
    transition: transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1), box-shadow 0.4s;
    z-index: 1;
}

.product-card:hover {
    transform: scale(1.1) translateY(-10px);
    box-shadow: 0 15px 30px rgba(139, 92, 246, 0.25), 0 0 15px var(--accent-purple-glow);
    z-index: 5;
    border-color: var(--accent-purple);
}

.card-img-container {
    position: relative;
    width: 100%;
    height: 100%;
}

.card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}
.product-card:hover .card-img {
    transform: scale(1.05);
}

.card-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(6, 5, 11, 0.95) 0%, rgba(6, 5, 11, 0.4) 60%, rgba(6, 5, 11, 0.1) 100%);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 15px;
    opacity: 0.85;
    transition: var(--transition-smooth);
}
.product-card:hover .card-overlay {
    opacity: 1;
}

.card-tag {
    align-self: flex-start;
    background: linear-gradient(135deg, var(--accent-purple), var(--accent-cyan));
    color: #fff;
    font-size: 0.68rem;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 4px;
    margin-bottom: 8px;
    text-transform: uppercase;
    box-shadow: 0 0 5px rgba(6, 182, 212, 0.3);
}

.card-title {
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 6px;
    color: #fff;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.card-meta .rating {
    color: #fbbf24;
    display: flex;
    align-items: center;
    gap: 3px;
}
.card-meta .rating i {
    fill: #fbbf24;
    width: 10px;
    height: 10px;
}

.card-price {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-main);
}

/* Search Results UI */
.search-results-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 20px 0;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border-glass);
}
.search-results-header h2 {
    font-size: 1.4rem;
}
.search-results-header span {
    color: var(--accent-cyan);
}
.btn-clear-filter {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.85rem;
    color: var(--text-muted);
}
.btn-clear-filter:hover {
    color: var(--accent-magenta);
}

/* Modals System (Overlay & Content layout) */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1500;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal.active {
    display: flex;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(5, 4, 9, 0.85);
    backdrop-filter: blur(10px);
}

.modal-content {
    position: relative;
    z-index: 10;
    width: 100%;
    max-width: 850px;
    max-height: 90vh;
    background: var(--bg-card);
    border: 1px solid var(--border-glass);
    border-radius: 12px;
    overflow-y: auto;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.8), 0 0 30px rgba(139, 92, 246, 0.15);
    animation: zoomIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.btn-close-modal {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid var(--border-glass);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 20;
    transition: var(--transition-smooth);
}
.btn-close-modal:hover {
    background: var(--accent-magenta);
    transform: rotate(90deg);
}

/* Detail Modal Top cover design */
.modal-banner {
    position: relative;
    height: 320px;
    background-size: cover;
    background-position: center;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 40px;
}

.modal-banner-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, var(--bg-card) 0%, rgba(18, 16, 30, 0.5) 70%, rgba(18, 16, 30, 0.1) 100%);
}

.modal-product-title {
    font-size: 2.2rem;
    font-weight: 800;
    line-height: 1.1;
    position: relative;
    z-index: 5;
    margin-bottom: 20px;
    text-shadow: 0 2px 10px rgba(0,0,0,0.8);
}

.modal-banner-actions {
    display: flex;
    gap: 15px;
    position: relative;
    z-index: 5;
}

/* Modal details layout */
.modal-grid-body {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 30px;
    padding: 30px 40px;
}

.modal-body-left {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.modal-meta-row {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 0.9rem;
    color: var(--text-muted);
}
.modal-meta-row .modal-rating {
    color: #fbbf24;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 5px;
}
.modal-meta-row .modal-rating i {
    fill: #fbbf24;
    width: 15px;
    height: 15px;
}
.modal-meta-row .modal-level {
    border: 1px solid var(--border-glass);
    padding: 1px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    text-transform: uppercase;
}

.modal-description {
    color: var(--text-muted);
    font-size: 0.98rem;
    line-height: 1.6;
}

.modal-modules-section {
    margin-top: 10px;
}
.modal-modules-section h3 {
    font-size: 1.15rem;
    margin-bottom: 15px;
    border-bottom: 1px solid var(--border-glass);
    padding-bottom: 8px;
}

.modules-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.modules-list li {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-glass);
    border-radius: 6px;
    font-size: 0.9rem;
    transition: var(--transition-smooth);
}
.modules-list li:hover {
    background: rgba(139, 92, 246, 0.05);
    border-color: var(--accent-purple);
}
.modules-list li i {
    color: var(--accent-cyan);
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

/* Modal metadata column (right side) */
.modal-body-right {
    display: flex;
    flex-direction: column;
    gap: 20px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-glass);
    padding: 20px;
    border-radius: 10px;
    height: fit-content;
}

.meta-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.meta-item .label {
    font-size: 0.78rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}
.meta-item .value {
    font-weight: 500;
    font-size: 0.95rem;
}
.meta-item .price-tag {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--accent-cyan);
}

.tags-container {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 5px;
}
.tags-container .tag {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--border-glass);
    color: var(--text-muted);
    padding: 2px 10px;
    border-radius: 4px;
    font-size: 0.75rem;
}

/* Shopping Cart Drawer */
.cart-drawer {
    position: fixed;
    top: 0;
    right: -360px;
    width: 350px;
    height: 100%;
    background: var(--bg-glass);
    backdrop-filter: blur(25px);
    border-left: 1px solid var(--border-glass);
    z-index: 2000;
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.8);
    display: flex;
    flex-direction: column;
    transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.cart-drawer.active {
    right: 0;
}

.drawer-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(3px);
    z-index: 1999;
    display: none;
}
.drawer-overlay.active {
    display: block;
}

.cart-header {
    padding: 20px;
    border-bottom: 1px solid var(--border-glass);
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.cart-header h2 {
    font-size: 1.35rem;
}
.btn-close-cart {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
}
.btn-close-cart:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.05);
}

.cart-items-wrapper {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.empty-cart-view {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 15px;
    height: 100%;
    text-align: center;
    color: var(--text-muted);
}
.cart-empty-icon {
    width: 50px;
    height: 50px;
    stroke-width: 1.5;
}

.cart-item {
    display: flex;
    gap: 12px;
    padding: 10px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-glass);
    border-radius: 8px;
    align-items: center;
    animation: itemSlideIn 0.3s ease-out;
}

.cart-item-thumb {
    width: 50px;
    height: 70px;
    object-fit: cover;
    border-radius: 4px;
    border: 1px solid var(--border-glass);
}

.cart-item-details {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.cart-item-details h4 {
    font-size: 0.88rem;
    font-weight: 600;
    line-height: 1.2;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.cart-item-details .price {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--accent-cyan);
}

.btn-remove-item {
    color: var(--text-muted);
    padding: 6px;
    border-radius: 4px;
}
.btn-remove-item:hover {
    color: #ef4444;
    background: rgba(239, 68, 68, 0.1);
}

.cart-footer {
    padding: 20px;
    border-top: 1px solid var(--border-glass);
    background: rgba(7, 6, 11, 0.5);
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.total-row {
    display: flex;
    justify-content: space-between;
    font-size: 1.05rem;
    font-weight: 600;
}
.cart-total-price {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--accent-cyan);
}

/* Checkout Modal Design */
.checkout-modal-content {
    max-width: 900px;
    border-radius: 16px;
}

.checkout-grid {
    display: grid;
    grid-template-columns: 1.1fr 1.3fr;
    min-height: 520px;
}

.checkout-summary-col {
    background: rgba(0, 0, 0, 0.3);
    padding: 40px;
    border-right: 1px solid var(--border-glass);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
.checkout-summary-col h2, .checkout-payment-col h2 {
    font-size: 1.4rem;
    margin-bottom: 25px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border-glass);
}

.checkout-summary-list {
    flex: 1;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 20px;
    max-height: 250px;
    padding-right: 5px;
}

.checkout-summary-item {
    display: flex;
    gap: 12px;
    align-items: center;
}
.checkout-summary-item img {
    width: 40px;
    height: 56px;
    object-fit: cover;
    border-radius: 4px;
}
.checkout-summary-item .info {
    flex: 1;
}
.checkout-summary-item .info h5 {
    font-size: 0.85rem;
    line-height: 1.2;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.checkout-summary-item .info span {
    font-size: 0.78rem;
    color: var(--text-muted);
}
.checkout-summary-item .price {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-main);
}

.checkout-total-footer {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-top: 15px;
    border-top: 1px solid var(--border-glass);
}

.summary-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    color: var(--text-muted);
}
.summary-row.text-success {
    color: #10b981;
}
.total-row-final {
    font-size: 1.15rem;
    font-weight: 700;
    color: #fff;
    margin-top: 5px;
    padding-top: 5px;
    border-top: 1px dashed var(--border-glass);
}
.total-row-final span:last-child {
    color: var(--accent-cyan);
    font-size: 1.45rem;
    font-weight: 800;
}

.checkout-payment-col {
    padding: 40px;
    display: flex;
    flex-direction: column;
}

.payment-tabs {
    display: flex;
    background: rgba(0, 0, 0, 0.4);
    padding: 4px;
    border-radius: 8px;
    border: 1px solid var(--border-glass);
    margin-bottom: 25px;
}

.btn-tab {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 0;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-muted);
    border-radius: 6px;
}
.btn-tab.active {
    background: var(--bg-hover);
    color: #fff;
    border: 1px solid var(--border-glass);
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.payment-panel {
    display: none;
    flex-direction: column;
    gap: 20px;
    flex: 1;
}
.payment-panel.active {
    display: flex;
}

.payment-instructions {
    font-size: 0.88rem;
    color: var(--text-muted);
    line-height: 1.5;
}

/* PIX QR Code & Simulation UI */
.pix-qr-container {
    position: relative;
    align-self: center;
    width: 160px;
    height: 160px;
    background: #fff;
    padding: 10px;
    border-radius: 8px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.3);
    overflow: hidden;
}

.pix-qr-svg {
    width: 100%;
    height: 100%;
}

/* Animated laser scanner for PIX */
.pix-qr-container::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(to right, transparent, #10b981, transparent);
    box-shadow: 0 0 8px #10b981;
    animation: laserScan 2.5s infinite linear;
}

/* PIX Live Timer */
.pix-timer-container {
    margin: 5px 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 0.85rem;
    color: var(--text-muted);
    align-items: center;
    width: 100%;
}

#pix-countdown-timer {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--accent-magenta);
    font-family: monospace;
    text-shadow: 0 0 5px var(--accent-magenta-glow);
}

.pix-timer-bar-bg {
    width: 100%;
    height: 4px;
    background: rgba(255,255,255,0.06);
    border-radius: 2px;
    overflow: hidden;
}

.pix-timer-bar-fill {
    height: 100%;
    background: linear-gradient(to right, var(--accent-magenta), var(--accent-purple));
    width: 100%;
    transition: width 1s linear;
}

.pix-key-box {
    display: flex;
    border: 1px solid var(--border-glass);
    border-radius: 6px;
    overflow: hidden;
    background: rgba(0, 0, 0, 0.2);
}
.pix-key-box input {
    background: transparent;
    border: none;
    padding: 10px;
    flex: 1;
    font-size: 0.78rem;
    color: var(--text-muted);
    text-overflow: ellipsis;
}
.pix-key-box button {
    border-radius: 0;
    border-left: 1px solid var(--border-glass);
}

.btn-sim {
    background: linear-gradient(135deg, #10b981, #059669);
    border: 1px solid rgba(16, 185, 129, 0.2);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.2);
}
.btn-sim:hover {
    box-shadow: 0 6px 16px rgba(16, 185, 129, 0.4);
    transform: translateY(-2px);
}

/* Credit Card Simulator Styles */
.card-simulator-wrapper {
    perspective: 1000px;
    margin-bottom: 20px;
    align-self: center;
    width: 100%;
    max-width: 290px;
}

.card-sim {
    width: 100%;
    height: 165px;
    position: relative;
    transform-style: preserve-3d;
    transition: transform 0.6s, background 0.5s ease-out;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
    background: linear-gradient(135deg, #2e1a47, #130a21, #0f0714);
    border: 1px solid rgba(255, 255, 255, 0.1);
    overflow: hidden;
}

.card-sim::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.15) 0%, transparent 60%);
    z-index: 1;
}

.card-sim-front {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    z-index: 2;
}

.card-sim-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.card-sim-header .chip {
    color: #d1d5db;
    width: 28px;
    height: 28px;
}
.card-brand {
    font-size: 1.1rem;
    font-weight: 800;
    font-style: italic;
    color: #fff;
    text-shadow: 0 1px 3px rgba(0,0,0,0.5);
}

.card-sim-number {
    font-size: 1.25rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    color: #fff;
    word-spacing: 4px;
    text-shadow: 0 1px 2px rgba(0,0,0,0.6);
}

.card-sim-footer {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
}
.card-sim-footer .col {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.card-sim-footer .sim-label {
    font-size: 0.6rem;
    color: var(--text-muted);
    letter-spacing: 0.05em;
}
.card-sim-footer .sim-value {
    font-size: 0.78rem;
    font-weight: 500;
    color: #fff;
    text-transform: uppercase;
}

.payment-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.form-group label {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-muted);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

/* Success Feedback Overlay */
.payment-success-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 3000;
    background: rgba(5, 4, 9, 0.95);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    backdrop-filter: blur(15px);
}

.success-card {
    background: var(--bg-card);
    border: 1px solid var(--border-glass);
    padding: 40px;
    border-radius: 16px;
    max-width: 450px;
    width: 100%;
    text-align: center;
    box-shadow: 0 20px 40px rgba(0,0,0,0.5), 0 0 20px rgba(16, 185, 129, 0.15);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.success-icon-circle {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: rgba(16, 185, 129, 0.1);
    border: 2px solid #10b981;
    color: #10b981;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.3);
}
.success-check-icon {
    width: 36px;
    height: 36px;
    stroke-width: 3px;
}

.purchased-items-receipt {
    width: 100%;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-glass);
    padding: 15px;
    border-radius: 8px;
    text-align: left;
    max-height: 120px;
    overflow-y: auto;
}

/* SECTION 2: NEW LIBRARY DASHBOARD LAYOUT */
.dashboard-layout {
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 30px;
    margin-top: 20px;
}

.dashboard-sidebar {
    background: rgba(18, 16, 30, 0.3);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-glass);
    border-radius: 12px;
    padding: 25px 20px;
    display: flex;
    flex-direction: column;
    gap: 25px;
    height: fit-content;
}

.user-brief {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-avatar-brief {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--accent-purple);
    box-shadow: 0 0 10px var(--accent-purple-glow);
}

.user-brief-info {
    display: flex;
    flex-direction: column;
}

.user-name-brief {
    font-weight: 600;
    font-size: 0.95rem;
    color: #fff;
}

.student-badge {
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--accent-cyan);
    display: flex;
    align-items: center;
    gap: 4px;
    text-shadow: 0 0 5px var(--accent-cyan-glow);
}

.sidebar-menu {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.sidebar-menu-btn {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 15px;
    background: transparent;
    border-radius: 8px;
    color: var(--text-muted);
    text-align: left;
    font-size: 0.9rem;
    font-weight: 500;
    transition: var(--transition-smooth);
    border: 1px solid transparent;
}
.sidebar-menu-btn:hover {
    background: rgba(255, 255, 255, 0.03);
    color: #fff;
}
.sidebar-menu-btn.active {
    background: rgba(139, 92, 246, 0.12);
    color: #fff;
    border-color: rgba(139, 92, 246, 0.2);
    box-shadow: 0 0 10px rgba(139, 92, 246, 0.1);
}
.sidebar-menu-btn i {
    width: 16px;
    height: 16px;
}

.dashboard-main {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.dash-tab-content {
    display: none;
    animation: fadeIn 0.4s ease-out;
}
.dash-tab-content.active {
    display: block;
}

.dashboard-header-premium h1 {
    font-size: 1.85rem;
    font-weight: 800;
    background: linear-gradient(135deg, #fff 60%, var(--text-muted));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
.dashboard-header-premium p {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-top: 4px;
}

/* Statistics row */
.stats-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 20px;
}

.stat-card {
    background: rgba(18, 16, 30, 0.4);
    backdrop-filter: blur(15px);
    border: 1px solid var(--border-glass);
    border-radius: 12px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    transition: var(--transition-smooth);
}
.stat-card:hover {
    border-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.3);
}

.stat-icon {
    width: 46px;
    height: 46px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.stat-icon i {
    width: 20px;
    height: 20px;
}
.stat-icon.purple { background: rgba(139, 92, 246, 0.12); color: var(--accent-purple); border: 1px solid rgba(139, 92, 246, 0.2); }
.stat-icon.magenta { background: rgba(217, 70, 239, 0.12); color: var(--accent-magenta); border: 1px solid rgba(217, 70, 239, 0.2); }
.stat-icon.cyan { background: rgba(6, 182, 212, 0.12); color: var(--accent-cyan); border: 1px solid rgba(6, 182, 212, 0.2); }

.stat-info {
    display: flex;
    flex-direction: column;
}
.stat-num {
    font-size: 1.35rem;
    font-weight: 800;
    color: #fff;
    line-height: 1.2;
}
.stat-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 2px;
}

.resume-study-card {
    position: relative;
    border-radius: 12px;
    padding: 35px 40px;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.15) 0%, rgba(217, 70, 239, 0.05) 50%, rgba(7, 6, 11, 0.4) 100%);
    border: 1px solid var(--border-neon);
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    margin-top: 25px;
}
.resume-study-card::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 250px;
    height: 250px;
    background: radial-gradient(circle, var(--accent-purple-glow) 0%, transparent 70%);
    z-index: 1;
    pointer-events: none;
}
.resume-info {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 500px;
}
.resume-info h3 {
    font-size: 1.45rem;
    font-weight: 700;
}
.resume-info p {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 8px;
}
.small-tag {
    align-self: flex-start;
    font-size: 0.68rem;
    font-weight: 800;
    color: var(--accent-cyan);
    background: rgba(6,182,212,0.1);
    border: 1px solid var(--accent-cyan);
    padding: 2px 8px;
    border-radius: 4px;
    letter-spacing: 0.05em;
}

/* Achievements section style */
.achievements-section {
    display: flex;
    flex-direction: column;
    gap: 20px;
}
.achievements-grid {
    display: flex;
    flex-direction: column;
    gap: 15px;
}
.achievement-card {
    background: rgba(18, 16, 30, 0.4);
    backdrop-filter: blur(15px);
    border: 1px solid var(--border-glass);
    border-radius: 10px;
    padding: 15px 20px;
    display: flex;
    align-items: center;
    gap: 20px;
    transition: var(--transition-smooth);
}
.achievement-card.unlocked {
    border-color: rgba(16, 185, 129, 0.2);
}
.achievement-card.unlocked .badge-icon {
    background: rgba(16, 185, 129, 0.1);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.2);
}
.achievement-card.locked {
    opacity: 0.5;
}
.achievement-card.locked .badge-icon {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
}
.badge-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}
.badge-icon i {
    width: 22px;
    height: 22px;
}
.badge-details h4 {
    font-size: 0.95rem;
    margin-bottom: 2px;
}
.badge-details p {
    font-size: 0.82rem;
    color: var(--text-muted);
}
.badge-details .status {
    display: inline-block;
    font-size: 0.68rem;
    font-weight: 700;
    margin-top: 4px;
}
.achievement-card.unlocked .status { color: #10b981; }
.achievement-card.locked .status { color: var(--text-muted); }

.library-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 25px;
}

.empty-library {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 15px;
    padding: 80px 20px;
    color: var(--text-muted);
}
.empty-icon {
    width: 60px;
    height: 60px;
    stroke-width: 1.2;
}

.library-item {
    cursor: pointer;
    background: var(--bg-card);
    border: 1px solid var(--border-glass);
    border-radius: 10px;
    overflow: hidden;
    transition: var(--transition-smooth);
    display: flex;
    flex-direction: column;
    position: relative;
}
.library-item:hover {
    border-color: var(--accent-purple);
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(139, 92, 246, 0.15);
}

.lib-thumb-container {
    position: relative;
    aspect-ratio: 2/3;
}
.lib-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.lib-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(4px);
    color: #fff;
    font-size: 0.68rem;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 4px;
    border: 1px solid rgba(255,255,255,0.1);
}

.lib-progress-bar {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.2);
}
.lib-progress-fill {
    height: 100%;
    background: var(--accent-cyan);
    box-shadow: 0 0 5px var(--accent-cyan);
}

.lib-details {
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.lib-details h4 {
    font-size: 0.9rem;
    font-weight: 600;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.lib-details .meta-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    color: var(--text-muted);
}
.lib-action-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(7, 6, 11, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition-smooth);
    z-index: 2;
}
.library-item:hover .lib-action-overlay {
    opacity: 1;
}

/* UPGRADED CINEMA MODE WORKSPACE */
.content-workspace.cinema-mode {
    max-width: 100%;
    padding: 25px;
    margin: 0;
    background: rgba(18, 16, 30, 0.25);
    backdrop-filter: blur(25px);
}

.badge-mode {
    margin-left: auto;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--accent-magenta);
    background: rgba(217,70,239,0.1);
    border: 1px solid var(--accent-magenta);
    padding: 3px 10px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    gap: 6px;
}
.badge-mode i {
    width: 14px;
    height: 14px;
}

.workspace-body-cinema {
    display: grid;
    grid-template-columns: 280px 1fr 300px;
    gap: 25px;
    align-items: start;
    margin-top: 15px;
}

.workspace-sidebar {
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--border-glass);
    border-radius: 8px;
    padding: 15px;
    max-height: 480px;
    overflow-y: auto;
}
.workspace-sidebar h3 {
    font-size: 0.95rem;
    margin-bottom: 12px;
    color: var(--text-muted);
    text-transform: uppercase;
}

.chapters-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.chapter-btn {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    background: transparent;
    border-radius: 6px;
    font-size: 0.88rem;
    color: var(--text-muted);
    text-align: left;
    transition: var(--transition-smooth);
}
.chapter-btn:hover {
    background: rgba(255,255,255,0.03);
    color: #fff;
}
.chapter-btn.active {
    background: rgba(139, 92, 246, 0.15);
    color: #fff;
    border: 1px solid rgba(139, 92, 246, 0.2);
}
.chapter-btn i {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}
.chapter-btn.completed i {
    color: #10b981;
}

/* Custom Video Player screen */
.player-container-cinema {
    background: rgba(0,0,0,0.6);
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid var(--border-glass);
    box-shadow: 0 10px 40px rgba(0,0,0,0.6);
}

.media-player-wrapper {
    display: flex;
    flex-direction: column;
}

.custom-video-screen {
    position: relative;
    width: 100%;
    aspect-ratio: 16/9;
    background: #000;
    overflow: hidden;
    cursor: pointer;
}

#video-canvas {
    width: 100%;
    height: 100%;
    display: block;
}

.video-overlay-play-pause {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: rgba(139, 92, 246, 0.2);
    border: 2px solid var(--accent-purple);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: transform 0.3s, opacity 0.3s;
    pointer-events: none;
    box-shadow: var(--shadow-glow);
}
.video-overlay-play-pause.show {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.1);
}

.video-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.spinner {
    width: 50px;
    height: 50px;
    border: 3px solid rgba(255,255,255,0.1);
    border-top: 3px solid var(--accent-purple);
    border-radius: 50%;
    animation: rotate 1s infinite linear;
}

.video-watermark {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    opacity: 0.25;
    color: #fff;
}

/* Video Controls block */
.video-controls {
    background: var(--bg-hover);
    padding: 10px 15px;
    border-top: 1px solid var(--border-glass);
}

.progress-bar-container {
    width: 100%;
    height: 6px;
    background: rgba(255,255,255,0.1);
    border-radius: 3px;
    cursor: pointer;
    margin-bottom: 10px;
    position: relative;
    overflow: hidden;
}
.progress-bar-container:hover {
    height: 8px;
}
.progress-filled {
    height: 100%;
    background: linear-gradient(to right, var(--accent-purple), var(--accent-cyan));
    width: 0%;
    box-shadow: 0 0 8px var(--accent-purple);
    transition: width 0.1s linear;
}

.controls-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.controls-left, .controls-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.controls-left button, .controls-right button {
    color: var(--text-muted);
    font-size: 1.1rem;
}
.controls-left button:hover, .controls-right button:hover {
    color: #fff;
}

.volume-container {
    display: flex;
    align-items: center;
    gap: 8px;
}
#volume-slider {
    width: 70px;
    height: 4px;
    -webkit-appearance: none;
    background: rgba(255,255,255,0.1);
    border-radius: 2px;
}
#volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--accent-purple);
    cursor: pointer;
}

.time-display {
    font-size: 0.8rem;
    color: var(--text-muted);
}

#speed-selector {
    background: transparent;
    border: none;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-muted);
    padding: 2px;
}
#speed-selector:focus {
    box-shadow: none;
}
#speed-selector option {
    background: var(--bg-hover);
    color: #fff;
}

/* Custom PDF/E-book Reader design */
.ebook-reader-wrapper {
    display: flex;
    flex-direction: column;
    min-height: 480px;
}

.reader-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px;
    background: var(--bg-hover);
    border-bottom: 1px solid var(--border-glass);
}

.btn-tool {
    padding: 6px 10px;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    border: 1px solid transparent;
}
.btn-tool:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.05);
}
.btn-tool i {
    width: 16px;
    height: 16px;
}

.ebook-page-container {
    flex: 1;
    padding: 30px;
    background: #0f0d1a;
    display: flex;
    justify-content: center;
    overflow-y: auto;
}

.ebook-page-paper {
    background: #fff;
    color: #1f2937;
    width: 100%;
    max-width: 580px;
    min-height: 380px;
    padding: 40px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.4);
    border-radius: 4px;
    transition: var(--transition-smooth);
}

.ebook-page-paper.theme-night {
    background: #181724;
    color: #d1d5db;
    box-shadow: 0 10px 25px rgba(0,0,0,0.6);
}

.ebook-page-paper h2 {
    font-size: 1.45rem;
    color: inherit;
    margin-bottom: 20px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    padding-bottom: 10px;
}
.ebook-page-paper.theme-night h2 {
    border-bottom-color: rgba(255,255,255,0.08);
}

.ebook-page-paper p {
    font-size: 1rem;
    line-height: 1.7;
    text-align: justify;
}

.reader-navigation {
    padding: 15px 20px;
    border-top: 1px solid var(--border-glass);
    display: flex;
    justify-content: space-between;
    background: var(--bg-hover);
}

/* Translucent Workspace Notes Panel */
.workspace-notes-panel {
    background: rgba(18, 16, 30, 0.4);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-glass);
    border-radius: 10px;
    display: flex;
    flex-direction: column;
    height: 480px; /* Aligned with canvas screen */
    overflow: hidden;
}

.notes-header {
    padding: 15px;
    border-bottom: 1px solid var(--border-glass);
}
.notes-header h3 {
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-main);
}
.notes-header h3 i {
    width: 16px;
    height: 16px;
    color: var(--accent-cyan);
}

.notes-content {
    flex: 1;
    overflow-y: auto;
    padding: 15px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.note-item {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-glass);
    padding: 10px;
    border-radius: 6px;
    animation: itemSlideIn 0.3s ease-out;
}

.note-author {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--accent-cyan);
}
.note-time {
    font-size: 0.65rem;
    color: var(--text-muted);
    margin-left: 8px;
}
.note-item p {
    font-size: 0.82rem;
    color: var(--text-main);
    margin-top: 4px;
    line-height: 1.4;
}

.notes-footer-input {
    padding: 10px 12px;
    border-top: 1px solid var(--border-glass);
    display: flex;
    gap: 8px;
    background: rgba(0,0,0,0.2);
}
.notes-footer-input input {
    flex: 1;
    padding: 8px 12px;
    font-size: 0.82rem;
    border-radius: 6px;
}
.btn-add-note-btn {
    width: 34px;
    height: 34px;
    border-radius: 6px;
    background: var(--accent-purple);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-smooth);
}
.btn-add-note-btn:hover {
    background: var(--accent-magenta);
    box-shadow: 0 0 8px var(--accent-magenta-glow);
}

/* Toast System (Floating message logs) */
.toast-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.toast {
    background: rgba(13, 11, 22, 0.85);
    backdrop-filter: blur(10px);
    border-left: 4px solid var(--accent-purple);
    border-top: 1px solid var(--border-glass);
    border-right: 1px solid var(--border-glass);
    border-bottom: 1px solid var(--border-glass);
    padding: 14px 20px;
    border-radius: 6px;
    color: #fff;
    font-size: 0.9rem;
    font-weight: 500;
    min-width: 250px;
    max-width: 350px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    gap: 12px;
    animation: toastSlideIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.toast.toast-success {
    border-left-color: #10b981;
}
.toast.toast-info {
    border-left-color: var(--accent-cyan);
}

/* Animation Keyframes */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes zoomIn {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

@keyframes fadeSlideIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes rotate {
    to { transform: rotate(360deg); }
}

@keyframes moveGlow {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(30px, 30px) scale(1.1); }
}

@keyframes laserScan {
    0% { top: 0; }
    50% { top: calc(100% - 3px); }
    100% { top: 0; }
}

@keyframes toastSlideIn {
    from { opacity: 0; transform: translateX(50px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes itemSlideIn {
    from { opacity: 0; transform: translateY(15px); }
    to { opacity: 1; transform: translateY(0); }
}

.animate-pop {
    animation: popEffect 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

@keyframes popEffect {
    0% { transform: scale(0.6); opacity: 0; }
    80% { transform: scale(1.1); }
    100% { transform: scale(1); opacity: 1; }
}

/* RESPONSIVE MEDIA QUERIES */
@media (max-width: 1200px) {
    .workspace-body-cinema {
        grid-template-columns: 240px 1fr;
    }
    .workspace-notes-panel {
        grid-column: 1 / -1;
        height: 250px;
    }
}

@media (max-width: 992px) {
    .dashboard-layout {
        grid-template-columns: 1fr;
    }
    .checkout-grid {
        grid-template-columns: 1fr;
    }
    .checkout-summary-col {
        border-right: none;
        border-bottom: 1px solid var(--border-glass);
    }
    .hero-content {
        width: 75%;
    }
    .modal-grid-body {
        grid-template-columns: 1fr;
    }
    .workspace-body-cinema {
        grid-template-columns: 1fr;
    }
    .workspace-sidebar {
        max-height: 250px;
    }
    .stats-row {
        grid-template-columns: 1fr;
        gap: 12px;
    }
}

/* Bottom Mobile Navigation Bar */
.mobile-nav-bar {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 60px;
    background: rgba(13, 11, 24, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid var(--border-glass);
    z-index: 1000;
    justify-content: space-around;
    align-items: center;
    padding-bottom: env(safe-area-inset-bottom);
}

.mobile-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-size: 0.75rem;
    font-weight: 500;
    gap: 4px;
    text-decoration: none;
    flex: 1;
    height: 100%;
    transition: var(--transition-smooth);
}

.mobile-nav-item i {
    width: 20px;
    height: 20px;
}

.mobile-nav-item.active {
    color: var(--accent-purple);
    filter: drop-shadow(0 0 8px rgba(139, 92, 246, 0.5));
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    .hero-content {
        width: 100%;
        padding: 15px 20px;
        gap: 10px;
    }
    .app-header {
        padding: 0 15px;
    }
    .logo {
        font-size: 1.5rem;
    }
    .cart-drawer {
        width: 100%;
        right: -100%;
    }
    .hero-banner {
        height: auto;
        min-height: 280px;
        padding: 20px 0;
    }
    .hero-title {
        font-size: 1.5rem;
    }
    .hero-description {
        font-size: 0.85rem;
        -webkit-line-clamp: 3;
    }
    .hero-metadata {
        font-size: 0.8rem;
        gap: 10px;
    }
    .hero-actions {
        flex-direction: column;
        width: 100%;
        gap: 10px;
    }
    .hero-actions .btn {
        width: 100%;
    }
    .modal-banner {
        padding: 20px;
        height: 240px;
    }
    .modal-product-title {
        font-size: 1.6rem;
    }
    .modal-grid-body {
        padding: 20px;
    }
    .success-card {
        padding: 20px;
    }
    
    /* Mobile Cards Shelf Optimizations */
    .scroll-btn {
        display: none !important;
    }
    .cards-scroll-container {
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        -webkit-overflow-scrolling: touch;
        padding: 10px 0;
        gap: 12px;
    }
    .product-card {
        scroll-snap-align: start;
        flex: 0 0 150px;
        width: 150px;
        height: 220px;
    }
    .card-title {
        font-size: 0.85rem;
    }
    .card-meta {
        font-size: 0.75rem;
    }
    
    /* Mobile Library/Dashboard Sidebar Optimizations */
    .dashboard-sidebar {
        padding: 15px;
        border-right: none;
        border-bottom: 1px solid var(--border-glass);
        margin-bottom: 20px;
        gap: 15px;
    }
    .sidebar-menu {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 8px;
    }
    .sidebar-menu-btn {
        flex: 1 1 auto;
        justify-content: center;
        padding: 10px 15px;
        font-size: 0.8rem;
        gap: 8px;
    }
    .user-brief {
        justify-content: center;
        text-align: center;
    }
    
    /* Mobile Bottom Nav Bar integration */
    .mobile-nav-bar {
        display: flex;
    }
    body {
        padding-bottom: 80px;
    }
    
    /* Workspace (Cinema Mode) mobile adjustments */
    .media-player-wrapper {
        border-radius: 0;
        margin: 0;
    }
    .custom-video-screen {
        height: 200px;
    }
    .controls-row {
        flex-direction: column;
        gap: 10px;
    }
    .controls-left, .controls-right {
        width: 100%;
        justify-content: space-between;
    }
    .workspace-sidebar {
        max-height: 200px;
    }
    .workspace-notes-panel {
        height: 300px;
    }
    .checkout-grid {
        padding: 10px;
    }
    .card-sim {
        width: 100%;
        height: 160px;
    }
}

/* ==========================================================================
   DYNAMIC CARDS NEON GRADIENT COVERS
   ========================================================================== */
.card-gradient-cover {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.card-gradient-cover::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center, rgba(255,255,255,0.15) 0%, transparent 80%);
}

.cover-icon {
    width: 42px;
    height: 42px;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 12px;
    filter: drop-shadow(0 2px 8px rgba(0,0,0,0.3));
}

.cover-title {
    font-size: 0.95rem;
    font-weight: 800;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-shadow: 0 2px 8px rgba(0,0,0,0.5);
    z-index: 2;
}

.empty-search-msg {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
}

