* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #f59e0b;
    --primary-dark: #d97706;
    --secondary-color: #f97316;
    --success-color: #22c55e;
    --danger-color: #dc2626;
    --warning-color: #fbbf24;
    --bg-color: #fff7ed;
    --card-bg: #ffffff;
    --text-primary: #1f2937;
    --text-secondary: #7c2d12;
    --border-color: #fed7aa;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --body-gradient: linear-gradient(135deg, #fef3c7 0%, #facc15 45%, #f97316 100%);
    --header-gradient: linear-gradient(135deg, #facc15 0%, #f97316 45%, #fb923c 100%);
    --title-primary-gradient: linear-gradient(135deg, #ffffff 0%, #fef3c7 100%);
    --title-secondary-gradient: linear-gradient(135deg, #f59e0b 0%, #f97316 100%);
    --title-underline-gradient: linear-gradient(90deg, transparent, #f97316, transparent);
    --certificate-button-gradient: linear-gradient(135deg, #facc15, #f97316);
    --certificate-button-gradient-hover: linear-gradient(135deg, #f97316, #fb923c);
    --certificate-button-border: #f97316;
    --certificate-button-text: #7c2d12;
    --certificate-button-shadow: 0 6px 20px rgba(234, 179, 8, 0.5);
    --certificate-button-shadow-hover: 0 8px 25px rgba(249, 115, 22, 0.6);
    --certificate-border-color: #f97316;
    --certificate-inner-border-color: rgba(249, 115, 22, 0.25);
    --certificate-heading-color: #c2410c;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: var(--body-gradient);
    min-height: 100vh;
    padding: 20px;
    color: var(--text-primary);
    transition: background 0.6s ease, color 0.4s ease;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

header {
    position: relative;
    margin-bottom: 40px;
    background: var(--header-gradient);
    border-radius: 20px;
    padding: 40px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: headerGlow 3s ease-in-out infinite alternate;
}

@keyframes headerGlow {
    0% {
        box-shadow: 0 20px 60px rgba(102, 126, 234, 0.3);
    }
    100% {
        box-shadow: 0 20px 60px rgba(118, 75, 162, 0.5);
    }
}

.header-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    overflow: hidden;
    z-index: 0;
}

.header-shapes {
    position: absolute;
    width: 100%;
    height: 100%;
}

.shape {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    animation: float 20s infinite ease-in-out;
}

.shape-1 {
    width: 200px;
    height: 200px;
    top: -50px;
    right: -50px;
    animation-delay: 0s;
}

.shape-2 {
    width: 150px;
    height: 150px;
    bottom: -30px;
    left: 10%;
    animation-delay: 5s;
}

.shape-3 {
    width: 100px;
    height: 100px;
    top: 50%;
    right: 20%;
    animation-delay: 10s;
}

@keyframes float {
    0%, 100% {
        transform: translate(0, 0) scale(1);
        opacity: 0.3;
    }
    25% {
        transform: translate(30px, -30px) scale(1.1);
        opacity: 0.5;
    }
    50% {
        transform: translate(-20px, 20px) scale(0.9);
        opacity: 0.4;
    }
    75% {
        transform: translate(20px, 30px) scale(1.05);
        opacity: 0.5;
    }
}

.header-content {
    position: relative;
    z-index: 1;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 30px;
}

.header-main {
    display: flex;
    align-items: center;
    gap: 20px;
    flex: 1;
}

.logo-icon {
    font-size: 4rem;
    animation: pulse 2s infinite;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
}

.header-text {
    flex: 1;
}

.main-title {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
    line-height: 1.2;
}

.title-gradient {
    background: var(--title-primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    filter: drop-shadow(2px 2px 4px rgba(0, 0, 0, 0.3));
}

.title-accent {
    background: var(--title-secondary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(2px 2px 4px rgba(0, 0, 0, 0.3));
    position: relative;
}

.title-accent::after {
    content: '';
    position: absolute;
    bottom: 5px;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--title-underline-gradient);
    border-radius: 2px;
    animation: shimmer 2s infinite;
}

.subtitle {
    font-size: 1.3rem;
    color: rgba(255, 255, 255, 0.95);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    font-weight: 500;
}

.subtitle-icon {
    font-size: 1.5rem;
    animation: bounce 2s infinite;
}

.subtitle-separator {
    opacity: 0.6;
    margin: 0 5px;
}

.subtitle-description {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.85);
    margin-top: 12px;
    margin-bottom: 15px;
    line-height: 1.6;
    max-width: 700px;
}

.header-badges {
    display: flex;
    gap: 12px;
    flex-wrap: nowrap;
    align-items: center;
    margin-top: 18px;
    overflow-x: auto;
    padding-bottom: 6px;
}

.header-badges::-webkit-scrollbar {
    height: 4px;
}

.header-badges::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.25);
    border-radius: 999px;
}

.badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    padding: 10px 18px;
    border-radius: 22px;
    font-size: 0.9rem;
    font-weight: 600;
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
    white-space: nowrap;
}

.badge:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: nowrap;
    margin-left: auto;
}

.badge.track-badge {
    display: inline-flex;
    align-items: center;
    gap: 14px;
    padding: 10px 20px 10px 16px;
    background: rgba(255, 255, 255, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.45);
    border-radius: 22px;
    position: relative;
    cursor: pointer;
    min-width: 190px;
}

.badge.track-badge:focus-within {
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.35), 0 10px 24px rgba(0, 0, 0, 0.18);
}

.track-badge-icon {
    font-size: 1.3rem;
    filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.25));
    pointer-events: none;
    position: relative;
    z-index: 1;
}

.track-info {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
    pointer-events: none;
    position: relative;
    z-index: 1;
}

.track-label {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    opacity: 0.8;
}

.track-current {
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: 0.4px;
    opacity: 0.95;
}

.track-select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    border: none;
    background: transparent;
    cursor: pointer;
    outline: none;
    position: absolute;
    inset: 0;
    opacity: 0;
    width: 100%;
    height: 100%;
    border-radius: inherit;
    z-index: 2;
}

.track-select option {
    color: #1f2937;
    background: #ffffff;
    font-weight: 600;
}

.track-select-caret {
    font-size: 0.85rem;
    opacity: 0.85;
    pointer-events: none;
    position: absolute;
    right: 14px;
    z-index: 1;
}

.dev-mode-toggle {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 18px;
    padding: 8px 16px;
    color: white;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(10px);
}

.dev-mode-toggle:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
    background: rgba(255, 255, 255, 0.28);
}

.dev-mode-toggle input {
    display: none;
}

.dev-toggle {
    position: relative;
    width: 42px;
    height: 22px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 999px;
    transition: background 0.3s ease;
}

.dev-toggle-thumb {
    position: absolute;
    top: 3px;
    left: 4px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: white;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
}

.dev-mode-toggle input:checked + .dev-toggle {
    background: linear-gradient(135deg, var(--success-color), #34d399);
}

.dev-mode-toggle input:checked + .dev-toggle .dev-toggle-thumb {
    transform: translateX(18px);
}

.dev-mode-toggle .dev-toggle-text {
    letter-spacing: 0.4px;
    text-transform: uppercase;
    font-size: 0.8rem;
}

@media (max-width: 768px) {
    .header-badges {
        flex-wrap: wrap;
        justify-content: center;
    }

    .badge.track-badge {
        width: 100%;
        justify-content: center;
    }

    .header-actions {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
        width: 100%;
        margin-top: 16px;
    }

    .dev-mode-toggle,
    .btn-certificate {
        width: 100%;
        justify-content: center;
    }
}

.btn-certificate {
    padding: 14px 28px;
    border: 2px solid rgba(255, 255, 255, 0.5);
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.15);
    color: white;
    backdrop-filter: blur(10px);
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.btn-certificate .cert-icon {
    font-size: 1.2rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.btn-certificate:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    border-color: rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.1);
}

.btn-certificate.enabled {
    background: var(--certificate-button-gradient);
    border-color: var(--certificate-button-border);
    color: var(--certificate-button-text);
    box-shadow: var(--certificate-button-shadow);
    animation: certificateGlow 2s infinite ease-in-out;
}

.btn-certificate.enabled:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: var(--certificate-button-shadow-hover);
    background: var(--certificate-button-gradient-hover);
}

.btn-certificate.dev-mode-active {
    border-style: dashed;
    box-shadow: 0 6px 20px rgba(14, 165, 233, 0.35);
}

@keyframes certificateGlow {
    0%, 100% {
        box-shadow: var(--certificate-button-shadow);
    }
    50% {
        box-shadow: var(--certificate-button-shadow-hover);
    }
}

.dashboard {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    box-shadow: var(--shadow-lg);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s ease;
}

.stat-card:hover::before {
    left: 100%;
}

.stat-card:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.15), 0 10px 10px -5px rgba(0, 0, 0, 0.08);
}

.stat-icon {
    font-size: 2.5rem;
}

.stat-value {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-color);
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-top: 5px;
}

.progress-bar-container {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: var(--shadow);
}

.progress-bar {
    width: 100%;
    height: 30px;
    background: var(--border-color);
    border-radius: 15px;
    overflow: hidden;
    position: relative;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    border-radius: 15px;
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    width: 0%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.9rem;
    position: relative;
    overflow: hidden;
}

.progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% {
        transform: translateX(-100%);
    }
    100% {
        transform: translateX(100%);
    }
}

/* Floating Action Button */
.fab-toggle-settings {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 25px rgba(99, 102, 241, 0.4);
    z-index: 1000;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

.fab-toggle-settings::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.fab-toggle-settings:hover::before {
    width: 300px;
    height: 300px;
}

.fab-toggle-settings:hover {
    transform: translateY(-5px) scale(1.1);
    box-shadow: 0 12px 35px rgba(99, 102, 241, 0.5);
}

.fab-toggle-settings:active {
    transform: translateY(-2px) scale(1.05);
}

.fab-icon {
    font-size: 2rem;
    position: relative;
    z-index: 1;
    animation: rotate 3s linear infinite;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

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

.settings-text {
    position: relative;
}

/* Settings Panel */
.settings-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
    z-index: 1999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.settings-overlay.active {
    opacity: 1;
    visibility: visible;
}

.settings-panel {
    position: fixed;
    top: 0;
    right: -100%;
    width: 90%;
    max-width: 600px;
    height: 100vh;
    background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
    box-shadow: -10px 0 40px rgba(0, 0, 0, 0.2);
    z-index: 2000;
    overflow-y: auto;
    transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
}

.settings-panel.active {
    right: 0;
}

.settings-header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    padding: 30px;
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 10;
}

.settings-title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.8rem;
    font-weight: 700;
    margin: 0;
}

.settings-title-icon {
    font-size: 2rem;
    animation: pulse 2s infinite;
}

.settings-close {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: white;
    transition: all 0.3s;
}

.settings-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.settings-content {
    padding: 30px;
    flex: 1;
}

.settings-section {
    margin-bottom: 40px;
}

.settings-section:last-child {
    margin-bottom: 0;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--border-color);
}

.section-icon {
    font-size: 1.6rem;
}

.settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.setting-card {
    background: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.setting-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
    border-color: var(--primary-color);
}

.setting-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
}

.setting-label-icon {
    font-size: 1.5rem;
}

.setting-label {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
}

.setting-description {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-top: 10px;
    line-height: 1.4;
}

.setting-toggle {
    position: relative;
    display: inline-block;
    width: 60px;
    height: 30px;
    cursor: pointer;
}

.setting-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--border-color);
    transition: 0.3s;
    border-radius: 30px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 22px;
    width: 22px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.setting-toggle input:checked + .toggle-slider {
    background-color: var(--primary-color);
}

.setting-toggle input:checked + .toggle-slider:before {
    transform: translateX(30px);
}

.setting-select {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    background: white;
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-primary);
    cursor: pointer;
    transition: all 0.3s;
}

.setting-select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.action-btn {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 20px;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-align: left;
    position: relative;
    overflow: hidden;
}

.action-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

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

.action-icon {
    font-size: 2.5rem;
    flex-shrink: 0;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.action-content {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.action-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: white;
}

.action-desc {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.9);
}

.action-reset {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.3);
}

.action-reset:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(239, 68, 68, 0.4);
}

.action-export {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.3);
}

.action-export:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(245, 158, 11, 0.4);
}

.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--shadow);
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn:active::before {
    width: 300px;
    height: 300px;
}

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

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background: var(--text-secondary);
    color: white;
}

.btn-secondary:hover {
    background: #475569;
    transform: translateY(-2px);
}

.btn-info {
    background: var(--warning-color);
    color: white;
}

.btn-info:hover {
    background: #d97706;
    transform: translateY(-2px);
}

.carousel-container {
    position: relative;
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
}

.carousel-wrapper {
    flex: 1;
    overflow: hidden;
    position: relative;
}

.weeks-container {
    display: flex;
    flex-direction: column;
    gap: 0;
    position: relative;
}

.carousel-nav-btn {
    background: var(--card-bg);
    border: 2px solid var(--primary-color);
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--primary-color);
    box-shadow: var(--shadow);
    flex-shrink: 0;
    z-index: 10;
}

.carousel-nav-btn:hover:not(:disabled) {
    background: var(--primary-color);
    color: white;
    transform: scale(1.1);
    box-shadow: var(--shadow-lg);
}

.carousel-nav-btn:active:not(:disabled) {
    transform: scale(0.95);
}

.carousel-nav-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    border-color: var(--text-secondary);
    color: var(--text-secondary);
}

.week-navigation {
    margin: 20px 0;
    padding: 20px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
    border-radius: 12px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.week-indicator {
    text-align: center;
    margin-bottom: 20px;
    font-size: 1.2rem;
    font-weight: 600;
    color: white;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
}

.week-selector {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.week-selector-label {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
}

.week-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
}

.week-btn {
    width: 45px;
    height: 45px;
    border-radius: 10px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    backdrop-filter: blur(10px);
}

.week-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.week-btn.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-color: #667eea;
    box-shadow: 0 0 20px rgba(102, 126, 234, 0.5);
    transform: scale(1.1);
}

.week-btn.completed {
    background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
    border-color: #11998e;
}

.week-btn.completed::after {
    content: '✓';
    position: absolute;
    top: -5px;
    right: -5px;
    width: 18px;
    height: 18px;
    background: #38ef7d;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    color: white;
    font-weight: bold;
    box-shadow: 0 2px 8px rgba(56, 239, 125, 0.4);
}

.week-btn.in-progress {
    border-color: #ffd700;
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.3);
}

.week-btn.in-progress::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    border: 2px solid #ffd700;
    border-radius: 10px;
    opacity: 0.5;
    animation: pulse 2s infinite;
}

.week-card {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 25px;
    box-shadow: var(--shadow-lg);
    transition: all 0.3s ease;
    width: 100%;
    animation: fadeIn 0.5s ease;
}

.week-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.15), 0 10px 10px -5px rgba(0, 0, 0, 0.08);
}

.week-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--border-color);
    flex-wrap: wrap;
    gap: 15px;
}

.week-header-actions {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

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

.btn-toggle-links:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: var(--shadow);
}

.week-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.week-progress {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 600;
}

.week-level {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-left: 10px;
}

.level-basics {
    background: #dbeafe;
    color: #1e40af;
}

.level-intermediate {
    background: #fef3c7;
    color: #92400e;
}

.level-advanced {
    background: #fce7f3;
    color: #9f1239;
}

.level-expert {
    background: #ddd6fe;
    color: #5b21b6;
}

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

.topic-item {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 12px;
    background: var(--bg-color);
    border-radius: 8px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.topic-content {
    display: flex;
    align-items: center;
    gap: 12px;
}

.topic-links {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-left: 34px;
    padding-top: 8px;
    border-top: 1px solid var(--border-color);
}

.topic-link {
    padding: 4px 10px;
    background: var(--primary-color);
    color: white;
    text-decoration: none;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.2s;
    white-space: nowrap;
    cursor: pointer;
    position: relative;
    z-index: 1;
}

.topic-link:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Custom topic links - always visible */
.topic-item.custom-topic .topic-links.custom-topic-links,
.custom-topic-links {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    margin-left: 34px;
    padding-top: 8px;
    border-top: 1px solid var(--border-color);
}

.topic-item.custom-topic .topic-link {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    cursor: pointer;
}

.topic-item.custom-topic .topic-link:hover {
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(16, 185, 129, 0.3);
}

.topic-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 4px;
    background: var(--primary-color);
    transform: scaleY(0);
    transition: transform 0.3s ease;
}

.topic-item:hover {
    background: #e2e8f0;
    transform: translateX(8px);
    border-color: var(--primary-color);
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.15);
}

.topic-item:hover::before {
    transform: scaleY(1);
}

.topic-item.completed {
    background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
    border-color: var(--success-color);
    animation: fadeIn 0.5s ease;
}

.topic-item.completed::before {
    background: var(--success-color);
    transform: scaleY(1);
}

.topic-item.completed .topic-text {
    text-decoration: line-through;
    color: var(--text-secondary);
    font-weight: 500;
}

.topic-item.completed:hover {
    transform: translateX(8px) scale(1.02);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.2);
}

.topic-checkbox {
    width: 22px;
    height: 22px;
    cursor: pointer;
    accent-color: var(--primary-color);
    flex-shrink: 0;
}

.topic-text {
    font-size: 0.95rem;
    color: var(--text-primary);
    font-weight: 500;
    flex: 1;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.notes-section {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 25px;
    margin-top: 30px;
    box-shadow: var(--shadow-lg);
}

.notes-section h2 {
    margin-bottom: 15px;
    color: var(--primary-color);
}

#notesArea {
    width: 100%;
    min-height: 150px;
    padding: 15px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-family: inherit;
    font-size: 1rem;
    resize: vertical;
    margin-bottom: 15px;
}

#notesArea:focus {
    outline: none;
    border-color: var(--primary-color);
}

@media (max-width: 768px) {
    header {
        padding: 25px 20px;
    }

    .header-content {
        flex-direction: column;
        text-align: center;
    }

    .header-main {
        flex-direction: column;
        text-align: center;
    }

    .logo-icon {
        font-size: 3rem;
    }

    .main-title {
        font-size: 2.5rem;
        justify-content: center;
    }

    .subtitle {
        font-size: 1.1rem;
        justify-content: center;
    }
    
    .subtitle-description {
        font-size: 0.9rem;
        text-align: center;
    }

    .header-badges {
        justify-content: center;
    }
    
    .week-navigation {
        padding: 15px;
    }
    
    .week-buttons {
        gap: 8px;
    }
    
    .week-btn {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }

    .header-actions {
        flex-direction: column;
        width: 100%;
    }

    .btn-certificate {
        width: 100%;
        justify-content: center;
    }

    .dashboard {
        grid-template-columns: repeat(2, 1fr);
    }

    .topics-list {
        grid-template-columns: 1fr;
    }

    .week-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .carousel-container {
        gap: 10px;
    }

    .carousel-nav-btn {
        width: 40px;
        height: 40px;
    }

    .carousel-nav-btn svg {
        width: 20px;
        height: 20px;
    }

    .settings-panel {
        width: 100%;
        max-width: 100%;
    }

    .settings-grid,
    .actions-grid {
        grid-template-columns: 1fr;
    }

    .fab-toggle-settings {
        bottom: 20px;
        right: 20px;
        width: 56px;
        height: 56px;
    }

    .fab-icon {
        font-size: 1.8rem;
    }
}

/* Challenge Modal */
.challenge-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 20px;
    animation: fadeIn 0.3s ease;
    overflow-y: auto;
}

.challenge-content {
    background: white;
    border-radius: 16px;
    padding: 30px;
    max-width: 700px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    margin: 20px 0;
}

.challenge-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: var(--text-secondary);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
}

.challenge-close:hover {
    background: var(--bg-color);
    color: var(--text-primary);
}

.challenge-content h2 {
    color: var(--primary-color);
    margin-bottom: 10px;
}

.challenge-info {
    color: var(--text-secondary);
    margin-bottom: 25px;
}

.challenge-section {
    background: var(--bg-color);
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    border-left: 4px solid var(--primary-color);
}

.challenge-section h3 {
    color: var(--primary-color);
    margin-bottom: 10px;
}

.challenge-question {
    color: var(--text-primary);
    margin-bottom: 15px;
    font-weight: 500;
}

.code-block {
    background: #1e293b;
    color: #e2e8f0;
    padding: 15px;
    border-radius: 8px;
    overflow-x: auto;
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    margin-bottom: 15px;
    line-height: 1.6;
}

.challenge-input {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.challenge-input:focus {
    outline: none;
    border-color: var(--primary-color);
}

.challenge-error {
    margin-top: 15px;
    padding: 10px;
    border-radius: 8px;
    text-align: center;
    font-weight: 600;
}

/* Name Input Modal */
.name-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 2001;
    align-items: center;
    justify-content: center;
    padding: 20px;
    animation: fadeIn 0.3s ease;
}

.name-content {
    background: white;
    border-radius: 16px;
    padding: 30px;
    max-width: 500px;
    width: 100%;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.name-content h2 {
    color: var(--primary-color);
    margin-bottom: 10px;
}

.name-info {
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.name-input {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 1.1rem;
    margin-bottom: 20px;
    transition: border-color 0.3s;
}

.name-input:focus {
    outline: none;
    border-color: var(--primary-color);
}

.name-warning {
    background: #fef3c7;
    border: 2px solid #f59e0b;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
}

.name-warning p {
    margin: 0;
    color: #92400e;
    font-size: 0.9rem;
    line-height: 1.5;
}

.name-buttons {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
}

/* Custom Topic Modal */
.custom-topic-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 2002;
    align-items: center;
    justify-content: center;
    padding: 20px;
    animation: fadeIn 0.3s ease;
    overflow-y: auto;
}

.custom-topic-content {
    background: white;
    border-radius: 16px;
    padding: 30px;
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    margin: 20px 0;
}

.custom-topic-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: var(--text-secondary);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
}

.custom-topic-close:hover {
    background: var(--bg-color);
    color: var(--text-primary);
}

.custom-topic-content h2 {
    color: var(--primary-color);
    margin-bottom: 10px;
}

.custom-topic-info {
    color: var(--text-secondary);
    margin-bottom: 25px;
}

.custom-topic-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

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

.form-group label {
    font-weight: 600;
    color: var(--text-primary);
}

.custom-topic-input {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.custom-topic-input:focus {
    outline: none;
    border-color: var(--primary-color);
}

.custom-topic-textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    resize: vertical;
    transition: border-color 0.3s;
    min-height: 100px;
}

.custom-topic-textarea:focus {
    outline: none;
    border-color: var(--primary-color);
}

.references-section {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.references-section label {
    font-weight: 600;
    color: var(--text-primary);
}

.references-section > label {
    margin-bottom: 5px;
}

#referencesContainer {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.reference-field {
    padding: 15px;
    background: var(--bg-color);
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.reference-inputs {
    display: flex;
    gap: 10px;
    align-items: center;
}

.reference-name-input,
.reference-url-input {
    flex: 1;
    padding: 10px;
    border: 2px solid var(--border-color);
    border-radius: 6px;
    font-size: 0.95rem;
    transition: border-color 0.3s;
}

.reference-name-input:focus,
.reference-url-input:focus {
    outline: none;
    border-color: var(--primary-color);
}

.btn-remove-reference {
    background: #ef4444;
    color: white;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    flex-shrink: 0;
}

.btn-remove-reference:hover {
    background: #dc2626;
    transform: scale(1.1);
}

.btn-add-reference {
    padding: 10px 20px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.95rem;
    font-weight: 600;
    transition: all 0.3s;
    align-self: flex-start;
}

.btn-add-reference:hover:not(:disabled) {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

.btn-add-reference:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.custom-topic-error {
    color: #ef4444;
    font-size: 0.9rem;
    padding: 10px;
    background: #fee2e2;
    border-radius: 6px;
    display: none;
}

.custom-topic-buttons {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
    margin-top: 10px;
}

.btn-add-topic {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.3s;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
}

.btn-add-topic:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
}

.topic-item.custom-topic {
    border-left: 3px solid #10b981;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.08) 0%, rgba(16, 185, 129, 0.12) 100%);
    border: 2px solid rgba(16, 185, 129, 0.2);
}

.topic-item.custom-topic:hover {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.15) 0%, rgba(16, 185, 129, 0.2) 100%);
    border-color: #10b981;
    transform: translateX(8px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.25);
}

.topic-item.custom-topic.completed {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.2) 0%, rgba(16, 185, 129, 0.3) 100%);
    border-color: #10b981;
}

.topic-item.custom-topic.completed:hover {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.25) 0%, rgba(16, 185, 129, 0.35) 100%);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.topic-item.custom-topic .topic-text {
    max-width: calc(100% - 60px);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    display: inline-block;
}

.btn-delete-topic {
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 1.1rem;
    padding: 5px 8px;
    margin-left: auto;
    opacity: 0.7;
    transition: all 0.2s;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 32px;
    position: relative;
    z-index: 1;
}

.btn-delete-topic:hover {
    opacity: 1;
    background: rgba(239, 68, 68, 0.15);
    transform: scale(1.15);
}

.btn-delete-topic .delete-icon {
    display: inline-block;
    transition: transform 0.2s;
}

.btn-delete-topic:hover .delete-icon {
    transform: scale(1.2);
}

.topic-item.custom-topic .topic-content {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    width: 100%;
}

.custom-topic-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
}

.custom-topic-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    word-wrap: break-word;
}

.custom-topic-description {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.5;
    word-wrap: break-word;
    white-space: pre-wrap;
}

/* Certificate Modal */
.certificate-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 20px;
    animation: fadeIn 0.3s ease;
}

.certificate-content {
    background: white;
    border-radius: 16px;
    padding: 30px;
    max-width: 800px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.certificate-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: var(--text-secondary);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
}

.certificate-close:hover {
    background: var(--bg-color);
    color: var(--text-primary);
}

.certificate {
    background: linear-gradient(135deg, #f8fafc 0%, #ffffff 100%);
    border: 8px solid var(--certificate-border-color);
    border-radius: 12px;
    padding: 50px;
    text-align: center;
    box-shadow: inset 0 0 50px rgba(245, 158, 11, 0.1);
    position: relative;
    margin-bottom: 20px;
    -webkit-user-select: none !important;
    -moz-user-select: none !important;
    -ms-user-select: none !important;
    user-select: none !important;
    -webkit-user-drag: none !important;
    pointer-events: auto;
}

.certificate::before {
    content: '';
    position: absolute;
    top: 20px;
    left: 20px;
    right: 20px;
    bottom: 20px;
    border: 2px solid var(--certificate-inner-border-color);
    border-radius: 8px;
    pointer-events: none;
}

.certificate-header h1 {
    font-size: 2.5rem;
    color: var(--certificate-heading-color);
    margin-bottom: 30px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}

.certificate-body {
    margin: 30px 0;
}

.certificate-text {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin: 15px 0;
}

.certificate-name {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-color);
    margin: 20px 0;
    text-decoration: underline;
    text-decoration-color: #f59e0b;
    text-decoration-thickness: 3px;
}

.certificate-course {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 20px 0;
}

.certificate-date {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 2px solid var(--border-color);
}

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

.certificate-footer {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 2px solid var(--border-color);
}

.certificate-footer p {
    font-size: 1rem;
    color: var(--text-secondary);
    font-style: italic;
}

.certificate-warning {
    background: #fee2e2;
    border: 2px solid #ef4444;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
    text-align: center;
}

.certificate-warning p {
    margin: 0;
    color: #991b1b;
    font-size: 0.9rem;
}

.certificate-download-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        text-align: center;
    }

    header h1 {
        text-align: center;
    }

    .certificate {
        padding: 30px 20px;
    }

    .certificate-header h1 {
        font-size: 2rem;
    }

    .certificate-name {
        font-size: 2rem;
    }

    .certificate-course {
        font-size: 1.5rem;
    }
}

.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: var(--success-color);
    color: white;
    padding: 15px 20px;
    border-radius: 8px;
    box-shadow: var(--shadow-lg);
    z-index: 1000;
    animation: slideIn 0.3s ease;
}

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

@keyframes slideOut {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(-100px);
        opacity: 0;
    }
}

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

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

/* Dark Theme */
.dark-theme {
    --bg-color: #1e293b;
    --card-bg: #334155;
    --text-primary: #f1f5f9;
    --text-secondary: #cbd5e1;
    --border-color: #475569;
}

.dark-theme body {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
}

.dark-theme .code-block {
    background: #0f172a;
    color: #e2e8f0;
}

/* Compact Mode */
.compact-mode .topic-item {
    padding: 8px;
}

.compact-mode .stat-card {
    padding: 15px;
}

.compact-mode .week-card {
    padding: 20px;
}

.compact-mode .topic-links {
    margin-left: 30px;
    padding-top: 6px;
}

/* Font Size Adjustments */
:root {
    --font-size: 1rem;
}

body {
    font-size: var(--font-size);
}
