/* Dashboard Styles */
.dashboard-nav {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--bg-primary);
    border-bottom: 1px solid var(--border-color);
}

.user-menu {
    position: relative;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--primary-color, #ff6b6b);
    color: var(--text-accent);
    border: 1px solid var(--border-color);
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12), 0 0 0 3px rgba(var(--primary-rgb, 255, 107, 107), 0.15);
}

.user-avatar:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.18), 0 0 0 4px rgba(var(--primary-rgb, 255, 107, 107), 0.2);
}

.user-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    min-width: 180px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1000;
}

.user-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.user-dropdown a {
    display: block;
    padding: 12px 16px;
    color: var(--text-primary);
    text-decoration: none;
    transition: background-color 0.2s ease;
    border-bottom: 1px solid var(--border-light);
}

.user-dropdown a:last-child {
    border-bottom: none;
}

.user-dropdown a:hover {
    background: var(--bg-secondary);
}

/* Dashboard Layout */
.dashboard {
    padding-top: 80px;
    min-height: 100vh;
    background: var(--bg-secondary);
}

.dashboard-container {
    display: flex;
    max-width: 1400px;
    margin: 0 auto;
    gap: 24px;
    padding: 24px;
}

/* Sidebar */
.dashboard-sidebar {
    width: 280px;
    background: var(--bg-primary);
    border-radius: 12px;
    padding: 24px 0;
    height: fit-content;
    position: sticky;
    top: 104px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 24px;
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
}

.nav-item:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.nav-item.active {
    background: var(--primary-light);
    color: var(--primary-color);
    font-weight: 500;
}

.nav-item.active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: var(--primary-color);
}

.nav-icon {
    font-size: 20px;
    width: 24px;
    text-align: center;
}

/* Content Area */
.dashboard-content {
    flex: 1;
    background: var(--bg-primary);
    border-radius: 12px;
    padding: 32px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.content-section {
    display: none;
}

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

.section-header {
    margin-bottom: 32px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border-light);
}

.section-header h1 {
    font-size: 2rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.section-header p {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* Cards Grid */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
    margin-bottom: 32px;
}

.dashboard-card {
    background: var(--bg-secondary);
    border-radius: 12px;
    padding: 24px;
    border: 1px solid var(--border-light);
    transition: all 0.3s ease;
}

.dashboard-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
}

.card-header {
    display: flex;
    justify-content: between;
    align-items: center;
    margin-bottom: 16px;
}

.card-header h3 {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-primary);
}

.plan-badge {
    background: var(--primary-color);
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
}

.count-badge {
    background: var(--accent-color);
    color: white;
    padding: 4px 8px;
    border-radius: 50%;
    font-size: 0.9rem;
    font-weight: 600;
    min-width: 24px;
    text-align: center;
}

.status-badge {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
}

.status-badge.active {
    background: var(--success-light);
    color: var(--success-color);
}

.card-content p {
    color: var(--text-secondary);
    margin-bottom: 16px;
}

.plan-features {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}

.feature {
    background: var(--bg-tertiary);
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.next-billing {
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* Pricing Grid - New 4-card layout */
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    margin-bottom: 32px;
}

.pricing-card {
    background: var(--bg-primary);
    border: 2px solid var(--border-light);
    border-radius: 16px;
    padding: 28px 24px;
    text-align: left;
    transition: all 0.3s ease;
    position: relative;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
}

.pricing-card.current-plan {
    border-color: #ae08f0;
    box-shadow: 0 0 0 4px rgba(40, 167, 69, 0.15),
                0 8px 32px rgba(40, 167, 69, 0.25);
    animation: pulse-glow 2s ease-in-out infinite;
}

@keyframes pulse-glow {
    0%, 100% {
        box-shadow: 0 0 0 4px rgba(211, 3, 176, 0.15),
                    0 8px 32px rgba(226, 12, 101, 0.25);
    }
    50% {
        box-shadow: 0 0 0 6px rgba(238, 7, 77, 0.2),
                    0 12px 40px rgba(231, 64, 147, 0.35);
    }
}

.pricing-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
}

.pricing-card.featured {
    border-color: var(--primary-color);
    box-shadow: 0 8px 32px rgba(var(--primary-rgb, 255, 107, 107), 0.15);
}

.pricing-card .popular-badge {
    position: absolute;
    top: -12px;
    right: 20px;
    background: #FFD700;
    color: #000;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    border-color: #db6414;
    box-shadow: 0 0 0 4px rgba(202, 120, 81, 0.329),
                0 8px 26px rgba(214, 66, 7, 0.432);
    animation: pulse-glow2 2s ease-in-out infinite;    
}

@keyframes pulse-glow2 {
    0%, 100% {
        box-shadow: 0 0 0 4px rgba(219, 114, 96, 0.15),
                    0 8px 26px rgba(218, 75, 9, 0.25);
    }
    50% {
        box-shadow: 0 0 0 6px rgba(206, 95, 21, 0.349),
                    0 8px 32px rgba(211, 71, 36, 0.719);
    }
}


.pricing-card .plan-header {
    margin-bottom: 24px;
    border-bottom: 3px solid var(--primary-color);
    padding-bottom: 16px;
}

.pricing-card .plan-header h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 12px 0;
}

.pricing-card .price {
    display: flex;
    align-items: baseline;
    gap: 2px;
}

.pricing-card .currency {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
}

.pricing-card .amount {
    font-size: 3rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1;
}

.pricing-card .period {
    font-size: 1.1rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.pricing-card .plan-features {
    margin-bottom: 28px;
}

.pricing-card .feature {
    display: block;
    padding: 8px 0;
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.4;
}

.pricing-card .feature:first-child {
    padding-top: 0;
}

.pricing-card .plan-button {
    width: 100%;
    padding: 14px 24px;
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: none;
}

.pricing-card .plan-button.current {
    background: #28a745;    
    color: white;
    cursor: not-allowed;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.3);
}

.pricing-card .plan-button.upgrade {
    background: #28a745;
    color: white;
}

.pricing-card .plan-button.upgrade:hover {
    background: #e70fb8;
    transform: translateY(-1px);
}

/* base button (applies to all plans) */
.pricing-card .plan-button {
  background: #383838;  /* your normal green */
  color: #fff;
}

/* ACTIVE plan only (button has .current OR card has .current-plan) */
.pricing-card .plan-button.current,
.pricing-card.current-plan .plan-button {
  background: #911df0;  /* your “current” color */
  color: #fff;
  box-shadow: 0 4px 12px rgba(31, 111, 235, .35);
}


.billing-info {
    margin-top: 40px;
    padding: 24px;
    background: var(--bg-secondary);
    border-radius: 12px;
    border: 1px solid var(--border-light);
}

.billing-info h4 {
    color: var(--text-primary);
    margin-bottom: 16px;
    font-size: 1.1rem;
}

.billing-info ul {
    list-style: none;
    padding: 0;
    margin: 0 0 16px 0;
}

.billing-info li {
    padding: 8px 0;
    color: var(--text-secondary);
    line-height: 1.5;
}

.billing-info .billing-note {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin: 8px 0 0 0;
    line-height: 1.4;
}

/* Subscription Section - Legacy styles (keeping for backward compatibility) */
.subscription-content {
    max-width: 800px;
}

.current-plan-card {
    background: var(--bg-secondary);
    border-radius: 12px;
    padding: 24px;
    border: 1px solid var(--border-light);
    margin-bottom: 32px;
}

.plan-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
}

.plan-details h4 {
    font-size: 1.4rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.plan-price {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 4px;
}

.plan-status {
    color: var(--success-color);
    font-weight: 500;
}

.plan-actions {
    display: flex;
    gap: 12px;
}

/* Upgrade Options */
.upgrade-options {
    margin-top: 32px;
}

.plans-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    margin-top: 24px;
}

.plan-card {
    background: var(--bg-secondary);
    border: 2px solid var(--border-light);
    border-radius: 12px;
    padding: 24px;
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
}

.plan-card:hover {
    border-color: var(--primary-color);
    transform: translateY(-4px);
}

.plan-card.featured {
    border-color: var(--primary-color);
    box-shadow: 0 8px 32px rgba(var(--primary-rgb), 0.2);
}

.plan-header {
    margin-bottom: 24px;
}

.plan-header h4 {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.plan-price {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
}

.plan-price span {
    font-size: 1rem;
    font-weight: 400;
    color: var(--text-secondary);
}

.plan-features {
    list-style: none;
    padding: 0;
    margin-bottom: 24px;
}

.plan-features li {
    padding: 8px 0;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--border-light);
}

.plan-features li:last-child {
    border-bottom: none;
}

.btn-plan {
    width: 100%;
    padding: 12px 24px;
    border: 2px solid var(--primary-color);
    background: transparent;
    color: var(--primary-color);
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-plan:hover {
    background: var(--primary-color);
    color: white;
}

.btn-plan.primary {
    background: var(--primary-color);
    color: white;
}

.btn-plan.primary:hover {
    background: var(--primary-dark);
}

/* Form Styles */
.settings-content {
    max-width: 600px;
}

.form-section {
    margin-bottom: 32px;
    padding: 24px;
    background: var(--bg-secondary);
    border-radius: 12px;
    border: 1px solid var(--border-light);
}

.form-section h3 {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 16px;
}

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

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group label {
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: var(--bg-primary);
    color: var(--text-primary);
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.1);
}

.form-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.danger-zone {
    border-color: var(--error-light);
    background: var(--error-lighter);
}

.danger-zone h3 {
    color: var(--error-color);
}

.btn-danger {
    background: var(--error-color);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-danger:hover {
    background: var(--error-dark);
}

/* Kids Profiles */
.kids-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 24px;
}

.kid-card {
    background: var(--bg-secondary);
    border-radius: 12px;
    padding: 24px;
    text-align: center;
    border: 1px solid var(--border-light);
    transition: all 0.3s ease;
}

.kid-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
}

.kid-avatar {
    font-size: 3rem;
    margin-bottom: 16px;
}

.kid-name {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.kid-stats {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 16px;
}

.kid-actions {
    display: flex;
    gap: 8px;
    justify-content: center;
}

.kid-actions button {
    padding: 8px 16px;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.btn-edit {
    background: var(--primary-light);
    color: var(--primary-color);
}

.btn-delete {
    background: var(--error-light);
    color: var(--error-color);
}

/* Avatar Selector */
.avatar-selector {
    display: flex;
    gap: 12px;
    margin-top: 8px;
}

.avatar-selector input[type="radio"] {
    display: none;
}

.avatar-selector label {
    font-size: 2rem;
    padding: 8px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.avatar-selector input[type="radio"]:checked + label {
    border-color: var(--primary-color);
    background: var(--primary-light);
}

/* Billing Table */
.billing-table {
    background: var(--bg-secondary);
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border-light);
}

.billing-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr auto;
    gap: 16px;
    padding: 16px 24px;
    align-items: center;
    border-bottom: 1px solid var(--border-light);
}

.billing-row:last-child {
    border-bottom: none;
}

.billing-header {
    background: var(--bg-tertiary);
    font-weight: 600;
    color: var(--text-primary);
}

.billing-date {
    color: var(--text-secondary);
}

.billing-amount {
    font-weight: 600;
    color: var(--text-primary);
}

.billing-status {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
}

.billing-status.paid {
    background: var(--success-light);
    color: var(--success-color);
}

.btn-download {
    background: var(--primary-light);
    color: var(--primary-color);
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.btn-download:hover {
    background: var(--primary-color);
    color: white;
}

/* Support Cards */
.support-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
    margin-bottom: 32px;
}

.support-card {
    background: var(--bg-secondary);
    border-radius: 12px;
    padding: 24px;
    text-align: center;
    border: 1px solid var(--border-light);
    transition: all 0.3s ease;
}

.support-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
}

.support-card h3 {
    font-size: 1.2rem;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.support-card p {
    color: var(--text-secondary);
    margin-bottom: 16px;
}

/* Contact Form */
.contact-form {
    background: var(--bg-secondary);
    border-radius: 12px;
    padding: 24px;
    border: 1px solid var(--border-light);
}

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.loading-overlay.show {
    opacity: 1;
    visibility: visible;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top: 4px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 16px;
}

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

.loading-overlay p {
    color: white;
    font-size: 1.1rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .dashboard {
        padding-top: 90px; /* Account for navbar + mobile nav (2 rows) */
    }
    
    .dashboard-container {
        flex-direction: column;
        padding: 16px;
        gap: 16px;
    }
    
    .dashboard-sidebar {
        width: 100%;
        position: fixed;
        top: 60px; /* Below main navbar */
        left: 0;
        right: 0;
        z-index: 90;
        padding: 12px 0;
        border-radius: 0;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
        height: auto;
    }
    
    .sidebar-nav {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        grid-template-rows: repeat(2, 1fr);
        gap: 0;
        padding: 0;
    }
    
    .nav-item {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 4px;
        padding: 8px 4px;
        text-align: center;
        font-size: 0.75rem;
        min-height: 30px;
        white-space: nowrap;
        border-right: 1px solid var(--border-light);
    }
    
    .nav-item:last-child {
        border-right: none;
    }
    
    .nav-item .nav-icon {
       display: none;
    }
    
    .nav-item.active::before {
        display: none;
    }
    
    .nav-item.active {
        background: var(--primary-color);
        color: white;
    }
    
    .dashboard-content {
        padding: 24px 16px;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .plan-info {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }
    
    .plan-actions {
        width: 100%;
    }
    
    .billing-row {
        grid-template-columns: 1fr;
        gap: 8px;
        text-align: left;
    }
    
    .cards-grid {
        grid-template-columns: 1fr;
    }
    
    .subcategories-grid {
        grid-template-columns: 1fr;
    }
    
    .lists-controls {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
}

/* List Management Styles */
.lists-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding: 16px 0;
    border-bottom: 1px solid var(--border-light);
}

.lists-controls h3 {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.sorting-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}

.sorting-controls label {
    font-weight: 500;
    color: var(--text-secondary);
}

.sorting-controls select {
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    background: var(--bg-primary);
    color: var(--text-primary);
    font-size: 0.9rem;
}

.category-section {
    margin-bottom: 32px;
}

.category-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border-light);
}

.category-header h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin: 0;
}

.category-count {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.subcategories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}

.subcategory-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    padding: 16px;
    transition: all 0.3s ease;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
}

.subcategory-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.subcategory-card.subscribed {
    background: rgba(34, 197, 94, 0.05);
    border-color: rgba(34, 197, 94, 0.2);
}

.subcategory-card.grayed-out {
    background: var(--bg-tertiary);
    border-color: var(--border-light);
    opacity: 0.6;
}

.card-info {
    flex: 1;
    min-width: 0;
}

.card-title {
    margin-bottom: 4px;
}

.card-title h5 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 8px 0;
    line-height: 1.3;
    word-wrap: break-word;
}

.card-badges {
    display: flex;
    gap: 6px;
    margin-bottom: 8px;
    flex-wrap: wrap;
}

.subcategory-card.grayed-out .card-title h5 {
    color: var(--text-muted);
}

.premium-badge {
    background: rgba(59, 130, 246, 0.1);
    color: rgb(59, 130, 246);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    white-space: nowrap;
}

.locked-badge {
    background: rgba(239, 68, 68, 0.1);
    color: rgb(239, 68, 68);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
    white-space: nowrap;
}

.video-count {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin: 0 0 4px 0;
}

.subcategory-card.grayed-out .video-count {
    color: var(--text-muted);
}

.access-message {
    font-size: 0.8rem;
    color: rgb(239, 68, 68);
    margin: 0;
}

.card-actions {
    flex-shrink: 0;
}

.btn-subscribe {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.btn-subscribe:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

.btn-unsubscribe {
    background: transparent;
    color: rgb(239, 68, 68);
    border: 1px solid rgba(239, 68, 68, 0.3);
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.btn-unsubscribe:hover {
    background: rgba(239, 68, 68, 0.05);
    border-color: rgb(239, 68, 68);
}

.btn-locked {
    background: var(--bg-tertiary);
    color: var(--text-muted);
    border: 1px solid var(--border-light);
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: not-allowed;
    white-space: nowrap;
}

.loading-state {
    text-align: center;
    padding: 48px 24px;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid var(--border-light);
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 16px;
}

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

.error-state {
    text-align: center;
    padding: 48px 24px;
}

.error-state p {
    color: var(--text-secondary);
    margin-bottom: 16px;
}

.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 12px 20px;
    border-radius: 8px;
    color: white;
    font-weight: 500;
    z-index: 1000;
    animation: slideIn 0.3s ease;
}

.notification-success {
    background: rgb(34, 197, 94);
}

.notification-error {
    background: rgb(239, 68, 68);
}

.notification-info {
    background: rgb(59, 130, 246);
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Support Ticket Styles */
.support-ticket {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 16px;
    transition: all 0.3s ease;
}

.support-ticket.unread-ticket {
    border-left: 4px solid var(--primary-color);
    background: linear-gradient(to right, rgba(var(--primary-rgb, 255, 107, 107), 0.05), var(--bg-primary));
}

.support-ticket:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.ticket-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-light);
}

.ticket-header h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.unread-indicator {
    background: #ef4444;
    color: white;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: 700;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.ticket-status {
    padding: 4px 12px;
    border-radius: 16px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.status-pending {
    background: #fef3c7;
    color: #92400e;
}

.status-replied {
    background: #dbeafe;
    color: #1e40af;
}

.status-resolved {
    background: #d1fae5;
    color: #065f46;
}

.ticket-content {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.user-message, .admin-reply {
    padding: 16px;
    border-radius: 8px;
    background: var(--bg-secondary);
}

.admin-reply {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(139, 92, 246, 0.1));
    border-left: 3px solid #3b82f6;
}

.admin-reply.unread-reply {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.2), rgba(139, 92, 246, 0.2));
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.3);
    animation: glow 2s ease-in-out infinite;
}

@keyframes glow {
    0%, 100% { box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.3); }
    50% { box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.5); }
}

.user-message strong, .admin-reply strong {
    display: block;
    margin-bottom: 8px;
    color: var(--text-primary);
    font-weight: 600;
}

.user-message p, .admin-reply p {
    color: var(--text-secondary);
    line-height: 1.6;
    margin: 0;
    white-space: pre-wrap;
}

.user-message small, .admin-reply small {
    display: block;
    margin-top: 8px;
    color: var(--text-muted);
    font-size: 0.85rem;
}

.reply-actions {
    display: flex;
    gap: 8px;
    margin-top: 12px;
}

.btn-reply {
    padding: 8px 16px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-reply:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(var(--primary-rgb, 255, 107, 107), 0.4);
}

.no-tickets {
    text-align: center;
    color: var(--text-muted);
    padding: 40px;
    font-style: italic;
}

/* Notification Badge */
.notification-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    background: #ef4444;
    color: white;
    border-radius: 50%;
    min-width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 700;
    padding: 2px 6px;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.5);
    animation: badgePulse 2s ease-in-out infinite;
}

@keyframes badgePulse {
    0%, 100% { 
        transform: scale(1);
        box-shadow: 0 2px 8px rgba(239, 68, 68, 0.5);
    }
    50% { 
        transform: scale(1.1);
        box-shadow: 0 4px 12px rgba(239, 68, 68, 0.8);
    }
}

.nav-item {
    position: relative;
}

.support-tickets-list {
    max-height: 600px;
    overflow-y: auto;
    padding-right: 8px;
}

.support-tickets-list::-webkit-scrollbar {
    width: 6px;
}

.support-tickets-list::-webkit-scrollbar-track {
    background: var(--bg-secondary);
    border-radius: 3px;
}

.support-tickets-list::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 3px;
}

.support-tickets-list::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}
