/*-------------------------------------------------------------------------------
* Name:               styles.css
* Summary:            Global styling for layout, components, training UI, and responsive behavior.
*
* Created:            24 02 2026
* Project:            FlowCMD™
*
* Developers:         Meit Sant
*                     Goutham Krishna
*                     Shubham Khadilkar
*-------------------------------------------------------------------------------*/

:root {

    --bg-primary: #111214;
    --bg-secondary: #1a1b1e;
    --bg-surface: #202124;
    --bg-surface-active: #2a2b2f;


    --text-primary: #e2b714;
    --text-secondary: #d1d0c5;
    --text-muted: #646669;
    --glow-color: rgba(226, 183, 20, 0.4);


    --accent-blue: #7aa2f7;
    --accent-green: #9ece6a;
    --error: #ca4754;
    --success: #9ece6a;

    --radius-sm: 4px;
    --radius-md: 10px;
    --radius-lg: 16px;

    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
    --font-sans: 'Inter', system-ui, -apple-system, sans-serif;
    --transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-mono);
    background: var(--bg-primary);
    color: var(--text-secondary);
    min-height: 100vh;
    line-height: 1.5;
    overflow-x: hidden;
    overflow-y: auto;
    cursor: auto;

}




/* --- SCROLLBAR --- */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: var(--bg-surface-active);
    border-radius: 4px;
}

#app-container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    width: 100%;
}

/* --- NAV --- */
.top-nav {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    padding: 1.5rem 2rem;
    width: 100%;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 800;
    font-size: 1.25rem;
    cursor: pointer;
    transition: var(--transition);
}

.nav-logo span {
    color: #fff;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.4);
    transition: var(--transition);
}

.nav-logo:hover span {
    color: var(--text-primary);
    text-shadow: 0 0 15px var(--glow-color);
}

.nav-center {
    display: flex;
    gap: 1rem;
    background: var(--bg-secondary);
    padding: 6px 12px;
    border-radius: var(--radius-lg);
}

.nav-icon {
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    border-radius: var(--radius-md);
    transition: var(--transition);
}

.nav-icon img {
    width: 24px;
    filter: invert(0.5);
    transition: var(--transition);
}

.nav-logo img {
    width: 24px;
    filter: brightness(0) saturate(100%) invert(80%) sepia(85%) saturate(760%) hue-rotate(352deg) brightness(97%) contrast(89%);
}

.nav-icon:hover img,
.nav-icon.active img {
    filter: brightness(0) saturate(100%) invert(80%) sepia(85%) saturate(760%) hue-rotate(352deg) brightness(97%) contrast(89%);
}

.nav-right {
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

.nav-profile {
    color: var(--text-muted);
    cursor: pointer;
    transition: var(--transition);
    font-size: 1.05rem;
    font-weight: 600;
}

.nav-profile:hover {
    color: var(--text-primary);
}


.theme-icon {
    filter: brightness(0) saturate(100%) invert(80%) sepia(85%) saturate(760%) hue-rotate(352deg) brightness(97%) contrast(89%);
}


.profile-icon {
    filter: invert(1);
    opacity: 0.8;
}

/* --- LAYOUT --- */
.app-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    width: 100%;
    margin: 0;
    padding: 0.5rem 2rem;
    animation: fadeIn 0.3s ease-out;
    overflow-y: auto;
}

.app-main.center-full {
    justify-content: center;
    padding-bottom: 8vh;

}

.page-title {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
    margin-top: 0;
    letter-spacing: -0.02em;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* --- INTRO --- */
.landing-container {
    width: 100%;
    display: flex;
    flex-direction: column;
}

.landing-section {
    width: 100%;
    padding: 8rem 2rem;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.landing-section:nth-child(even) {
    background: var(--bg-secondary);
}

.landing-content {
    max-width: 1100px;
    width: 100%;
    text-align: center;
}

.hero-section {
    min-height: calc(100vh - 86px);
    padding: 0 2rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.hero-title {
    font-size: clamp(3rem, 10vw, 5rem);
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1.1;
    margin-bottom: 1rem;
    letter-spacing: -0.04em;
    animation: fadeIn 0.8s ease-out;
}

.hero-tagline {
    font-size: clamp(1.1rem, 3vw, 1.5rem);
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.hero-sub {
    font-size: 1.1rem;
    color: var(--text-muted);
    max-width: 700px;
    margin: 0 auto 3rem;
    line-height: 1.6;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 4rem;
}

.feature-card {
    background: var(--bg-surface);
    border: 1px solid rgba(255, 255, 255, 0.02);
    padding: 2.5rem;
    border-radius: var(--radius-lg);
    text-align: left;
    transition: var(--transition);
}

.feature-card:hover {
    transform: translateY(-10px);
    border-color: var(--text-primary);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.feature-icon {
    width: 40px;
    height: 40px;
    margin-bottom: 1.5rem;
    filter: brightness(0) saturate(100%) invert(80%) sepia(85%) saturate(760%) hue-rotate(352deg) brightness(97%) contrast(89%);
}

.feature-card h3 {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.feature-card p {
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.6;
}

.steps-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-top: 4rem;
}

.step-block {
    position: relative;
    padding: 2.5rem 2rem;
    background: var(--bg-surface);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-lg);
    text-align: left;
    overflow: hidden;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.step-block:hover {
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-5px);
}

.step-number {
    font-size: 8rem;
    font-weight: 900;
    color: var(--text-primary);
    opacity: 0.03;
    position: absolute;
    top: 30px;
    left: 50px;
    z-index: 0;
    line-height: 1;
    pointer-events: none;
}

.step-content {
    position: relative;
    z-index: 1;
    margin-top: 1rem;
}

.step-content h4 {
    color: var(--text-primary);
    margin-bottom: 1rem;
    font-size: 1.25rem;
    display: flex;
    align-items: center;
    gap: 12px;
}

.step-content p {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
}

.cta-banner {
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
    border: 1px solid var(--text-primary);
    border-radius: var(--radius-lg);
    padding: 4rem;
    box-shadow: 0 0 50px rgba(226, 183, 20, 0.1);
}

.about-section p {
    font-size: 1.2rem;
    line-height: 1.8;
    color: var(--text-secondary);
    max-width: 800px;
    margin: 0 auto;
}

@media (max-width: 768px) {
    .landing-section {
        padding: 4rem 1.5rem;
    }
}

.onboarding-view {
    text-align: center;
    margin-top: 5vh;
    max-width: 1000px;
    margin-left: auto;
    margin-right: auto;
}

.onboarding-title {
    font-size: 2.5rem;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.onboarding-subtitle {
    color: var(--text-muted);
    margin-bottom: 3rem;
}

.app-selection-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    width: 100%;
    margin: 0 auto 1.5rem;
    padding: 0.75rem 0;
    justify-content: center;
}

.app-selection-grid::-webkit-scrollbar {
    height: 6px;
}

.app-selection-grid::-webkit-scrollbar-track {
    background: var(--bg-primary);
}

.app-selection-grid::-webkit-scrollbar-thumb {
    background: var(--bg-surface-active);
    border-radius: 10px;
}

.selectable-card {
    background: var(--bg-surface);
    border: 1px solid rgba(255, 255, 255, 0.03);
    padding: 0.75rem 0.5rem;
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    position: relative;
    overflow: hidden;
    width: 130px;
    height: 110px;
    flex-shrink: 0;
}

.selectable-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at center, var(--glow-color) 0%, transparent 70%);
    opacity: 0;
    transition: var(--transition);
    pointer-events: none;
}

.selectable-card:hover {
    transform: translateY(-8px);
    border-color: var(--text-primary);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.4);
}

.selectable-card:hover::before {
    opacity: 0.1;
}

.selectable-card.selected {
    border-color: var(--text-primary);
    background: var(--bg-surface-active);
    box-shadow: 0 0 25px var(--glow-color);
}

.selectable-card img {
    width: 36px;
    height: 36px;
    filter: grayscale(1) invert(0.8);
    transition: var(--transition);
    z-index: 1;
}

.selectable-card.selected img {
    filter: drop-shadow(0 0 10px var(--text-primary)) brightness(0) saturate(100%) invert(80%) sepia(85%) saturate(760%) hue-rotate(352deg) brightness(97%) contrast(89%);
}

.selectable-card span {
    font-weight: 500;
    font-size: 0.8rem;
    z-index: 1;
}

/* --- TRAINING --- */
.training-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 2fr) minmax(0, 1.2fr);
    gap: 4rem;
    width: 100%;
    align-items: center;
    margin-top: 1rem;
    min-height: 60vh;
}

.training-layout--no-gif {
    grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
}

.training-layout--solo {
    grid-template-columns: 1fr;
    max-width: 800px;
}

.column-left,
.column-right {
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    padding: 1.75rem;
    border: 1px solid rgba(255, 255, 255, 0.02);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.column-left:empty,
.column-right:empty {
    display: none !important;
}

.column-center {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.gif-placeholder {
    width: 100%;
    aspect-ratio: 3/4;
    min-height: 250px;
    max-height: 500px;
    background: var(--bg-surface);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px dashed rgba(255, 255, 255, 0.08);
    margin-bottom: 2rem;
    overflow: hidden;
    position: relative;
}

.gif-placeholder:empty::after {
    display: block;
    content: 'NO PREVIEW';
    font-size: 0.6rem;
    letter-spacing: 0.3em;
    color: var(--text-muted);
    opacity: 0.4;
}

.context-info h3 {
    font-size: 0.7rem;
    text-transform: uppercase;
    color: var(--text-primary);
    margin-bottom: 1rem;
    letter-spacing: 0.15em;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding-bottom: 0.5rem;
}

.context-info p {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

/* --- TEST HEADER --- */
.test-header {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    font-family: var(--font-mono);
    padding: 0 0.5rem;
}

.test-timer,
.test-score {
    font-size: 1rem;
    letter-spacing: 0.05em;
    color: var(--text-muted);
}

/* --- RESULTS --- */
.results-container {
    text-align: center;
    width: 100%;
    padding: 2rem 0;
}

.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
    width: 100%;
}

.stat-card {
    background: rgba(255, 255, 255, 0.02);
    padding: 2rem;
    border-radius: var(--radius-md);
    border: 1px solid rgba(255, 255, 255, 0.04);
}

.stat-label {
    font-size: 0.7rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 0.5rem;
}

.stat-value {
    font-size: 2.5rem;
    font-weight: 700;
}

.tip-box {
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    font-style: italic;
    color: var(--text-muted);
    font-size: 0.85rem;
    display: flex;
    gap: 10px;
}

/* --- SHORTCUT DISPLAY --- */
.shortcut-display {
    text-align: center;
    margin-bottom: 3rem;
    padding: 2rem;
    border-radius: var(--radius-lg);
    transition: var(--transition);
    width: 100%;
}

.shortcut-display:hover {
    background: rgba(255, 255, 255, 0.01);
}

.shortcut-caption {
    font-size: 1.2rem;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
    letter-spacing: 0.05em;
}

.shortcut-command {
    font-size: 3.5rem;
    color: var(--text-primary);
    font-weight: 800;
    text-shadow: 0 0 30px var(--glow-color);
    letter-spacing: -0.02em;
    transition: color 0.15s, text-shadow 0.15s;
}

.pressed-keys-text {
    margin-top: 1.5rem;
    font-family: var(--font-mono);
    font-size: 1rem;
    color: var(--text-primary);
    opacity: 0.3;
    letter-spacing: 0.05em;
    transition: opacity 0.15s;
    min-height: 1.5em;
    text-align: center;
}

.keyboard-container {
    width: 100%;
}

.virtual-keyboard {
    background: var(--bg-secondary);
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
    max-width: 1000px;
    margin: 2rem auto 0;
    border: 1px solid rgba(255, 255, 255, 0.02);
}

.keyboard-row {
    display: flex;
    gap: 8px;
    justify-content: center;
}

.k-key {
    background: var(--bg-primary);
    color: var(--text-muted);
    height: 42px;
    min-width: 36px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    position: relative;
    transition: all 0.08s;
    border: 1px solid rgba(255, 255, 255, 0.03);
    box-shadow: 0 3px 0 rgba(0, 0, 0, 0.3);
    flex: 1;
}

.k-key.active {
    background: var(--text-primary) !important;
    color: var(--bg-primary) !important;
    transform: translateY(3px);
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.1) !important;
    border-color: var(--text-primary) !important;
}

.k-key.highlight-hint {
    background: rgba(226, 183, 20, 0.12);
    border-color: var(--text-primary);
    box-shadow: 0 0 15px var(--glow-color);
    color: var(--text-primary);
}

.k-shift {
    position: absolute;
    top: 4px;
    left: 6px;
    font-size: 0.65rem;
    opacity: 0.5;
}

/* --- UI --- */
.tab-link {
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-size: 0.9rem;
    color: var(--text-muted);
    transition: var(--transition);
    user-select: none;
}

.tab-link:hover {
    color: var(--text-secondary);
    background: rgba(255, 255, 255, 0.03);
}

.tab-link.active {
    color: var(--text-primary);
}

.btn {
    background: var(--bg-surface);
    color: var(--text-secondary);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 1rem 2.5rem;
    border-radius: var(--radius-md);
    cursor: pointer;
    font-family: var(--font-mono);
    font-weight: 600;
    transition: var(--transition);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.btn-primary {
    border-color: var(--text-primary);
    color: var(--text-primary);
}

.btn:hover {
    background: var(--bg-surface-active);
    border-color: var(--text-primary);
    box-shadow: 0 0 15px var(--glow-color);
    transform: translateY(-2px);
}

.heatmap-container {
    width: 100%;
    background: var(--bg-secondary);
    padding: 2rem;
    border-radius: var(--radius-lg);
    border: 1px solid rgba(255, 255, 255, 0.02);
}

.heatmap-layout {
    display: grid;
    grid-template-columns: auto 1fr;
    grid-template-rows: 1fr auto;
    gap: 1rem;
    margin-top: 1.5rem;
}

.heatmap-months-container {
    display: flex;
    gap: 8px;
    flex-wrap: nowrap;
    justify-content: flex-start;
    padding: 0.5rem 0;
    align-items: flex-start;
    overflow: visible;
}

.heatmap-month-block {
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: center;
}

.heatmap-month-grid {
    display: grid;
    grid-template-rows: repeat(7, 12px);
    grid-auto-flow: column;
    gap: 4px;
}

.heatmap-y-labels {
    display: grid;
    grid-template-rows: repeat(7, 12px);
    gap: 4px;
    font-size: 0.55rem;
    color: var(--text-muted);
    justify-content: end;
    align-items: center;
    margin-right: 8px;
}

.heatmap-month-label {
    font-size: 0.65rem;
    color: var(--text-muted);
    text-transform: lowercase;
    letter-spacing: 0.05em;
}

.heatmap-cell {
    width: 12px;
    height: 12px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 2px;
    transition: var(--transition);
    cursor: default;
}

.heatmap-empty {
    opacity: 0;
    pointer-events: none;
}

.heatmap-cell[data-intensity="1"] {
    background: rgba(226, 183, 20, 0.2);
}

.heatmap-cell[data-intensity="2"] {
    background: rgba(226, 183, 20, 0.45);
}

.heatmap-cell[data-intensity="3"] {
    background: rgba(226, 183, 20, 0.75);
    box-shadow: 0 0 10px var(--glow-color);
}

.heatmap-cell[data-intensity="4"] {
    background: var(--text-primary);
    box-shadow: 0 0 15px var(--glow-color);
}

.heatmap-cell:hover {
    transform: scale(1.5);
    z-index: 10;
    box-shadow: 0 0 20px var(--text-primary);
    border: 1px solid white;
}

input {
    background: var(--bg-surface);
    border: 1px solid rgba(255, 255, 255, 0.08);
    padding: 14px;
    color: var(--text-primary);
    font-family: var(--font-mono);
    border-radius: var(--radius-md);
    width: 100%;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

input:hover {
    border-color: rgba(255, 255, 255, 0.2);
}

input:focus {
    border-color: var(--text-primary);
    outline: none;
    box-shadow: 0 0 0 3px rgba(226, 183, 20, 0.1), 0 0 12px var(--glow-color);
}




.xp-popup {
    position: fixed;
    bottom: 20%;
    right: 10%;
    background: var(--bg-secondary);
    padding: 12px 24px;
    border-radius: var(--radius-md);
    color: var(--text-primary);
    border: 1px solid var(--text-primary);
    box-shadow: 0 0 30px var(--glow-color);
    animation: slideUpFade 1s forwards;
    z-index: 2000;
}

@keyframes slideUpFade {
    0% {
        transform: translateY(20px);
        opacity: 0;
    }

    20% {
        transform: translateY(0);
        opacity: 1;
    }

    80% {
        transform: translateY(-10px);
        opacity: 1;
    }

    100% {
        transform: translateY(-20px);
        opacity: 0;
    }
}

.zen-btn {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: var(--bg-surface);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 1rem;
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition);
    opacity: 0.4;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.zen-btn:hover {
    opacity: 1;
    border-color: var(--text-primary);
    box-shadow: 0 0 15px var(--glow-color);
}

.zen-btn img {
    width: 22px;
    filter: invert(0.8);
}

.profile-header {
    width: 100%;
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.02);
    margin-bottom: 0.5rem;
    flex-wrap: nowrap;
}

.mt-dashboard {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    flex: 1;
    overflow-y: auto;
    padding-bottom: 1rem;
}

.profile-info {
    flex: 1;
}

.profile-name {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.profile-join-date {
    font-size: 0.7rem;
    color: var(--text-muted);
    letter-spacing: 0.08em;
}

.profile-stats-row {
    display: flex;
    gap: 1.5rem;
    margin-left: auto;
}

.p-stat {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0;
}

.p-stat-label {
    font-size: 0.6rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.p-stat-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-secondary);
}

.app-selection-section {
    width: 100%;
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    padding: 0.5rem 1.25rem;
    border: 1px solid rgba(255, 255, 255, 0.02);
}

.profile-avatar {
    width: 80px;
    height: 80px;
    background: var(--bg-surface);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--text-primary);
    box-shadow: 0 0 15px var(--glow-color);
}

.settings-grid {
    display: grid;
    gap: 1.5rem;
    grid-template-columns: repeat(3, 1fr);
}

@media (max-width: 1200px) {
    .settings-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 800px) {
    .settings-grid {
        grid-template-columns: 1fr;
    }
}

.setting-card {
    background: var(--bg-secondary);
    padding: 2.5rem;
    border-radius: var(--radius-lg);
    border: 1px solid rgba(255, 255, 255, 0.02);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.setting-control {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1rem;
}

.toggle-switch {
    width: 40px;
    height: 20px;
    background: #333;
    border-radius: 20px;
    position: relative;
    cursor: pointer;
    transition: 0.3s;
}

.toggle-switch.on {
    background: var(--text-primary);
}

.toggle-switch::after {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    background: #fff;
    border-radius: 50%;
    top: 2px;
    left: 2px;
    transition: 0.3s;
}

.toggle-switch.on::after {
    transform: translateX(20px);
}

/* --- MODALS --- */
.fullscreen-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(17, 18, 20, 0.98);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    animation: fadeIn 0.3s ease-out;
}

.modal-content {
    background: var(--bg-secondary);
    padding: 3rem;
    border-radius: var(--radius-lg);
    border: 1px solid var(--text-primary);
    box-shadow: 0 0 50px rgba(226, 183, 20, 0.2);
    max-width: 500px;
    width: 90%;
    text-align: center;
}

/* ============================================
   RESPONSIVE BREAKPOINTS
   ============================================ */
@media (max-width: 1024px) {
    .training-layout {
        grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
        gap: 1.5rem;
    }

    .training-layout .column-left {
        display: none;
    }
}

@media (max-width: 768px) {
    .app-main {
        padding: 0.75rem 1rem;
    }

    .training-layout {
        grid-template-columns: 1fr;
    }

    .column-left,
    .column-right {
        display: none;
    }
}

@media (max-width: 480px) {
    .shortcut-command {
        font-size: 1.8rem;
    }
}

/* --- ANIMATIONS --- */
@keyframes countUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.completion-animation {
    animation: countUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.heatmap-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    font-size: 0.75rem;
}

.heatmap-legend span {
    margin: 0 4px;
}

.leaderboard-view {
    max-width: 1100px;
    width: 100%;
    margin: -2.5rem auto 0;
}

.settings-view {
    max-width: 1400px;
    width: 100%;
    margin: 0 auto;
}

.heatmap-legend {
    display: flex;
    align-items: center;
    gap: 4px;
    color: var(--text-muted);
    font-size: 0.65rem;
}

.legend-box {
    width: 10px;
    height: 10px;
    border-radius: 2px;
}

.year-select {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    font-family: var(--font-mono);
    font-size: 0.7rem;
    cursor: pointer;
}

/* --- CURSOR --- */
.custom-cursor {
    position: fixed;
    top: 0;
    left: 0;
    width: 22px;
    height: 22px;
    pointer-events: none;
    z-index: 10002;

    transform: translate3d(-200px, -200px, 0);
    will-change: transform;
}


.custom-cursor svg {
    display: block;
    transform: rotate(-8deg);
    transition: transform 0.13s cubic-bezier(0.16, 1, 0.3, 1),
        filter 0.13s cubic-bezier(0.16, 1, 0.3, 1),
        opacity 0.13s ease;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
}


.custom-cursor.hovering-btn svg {
    transform: rotate(-8deg) scale(1.18);
    filter: drop-shadow(0 0 8px var(--glow-color)) drop-shadow(0 2px 4px rgba(0, 0, 0, 0.4));
}


.custom-cursor.hovering-text svg {
    transform: rotate(-8deg) scale(0.82);
    opacity: 0.55;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.3));
}


.custom-cursor.hovering-disabled svg {
    transform: rotate(-8deg) scale(0.9);
    opacity: 0.3;
    filter: none;
}


.custom-cursor.clicking svg {
    transform: rotate(-8deg) scale(0.78);
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.6));
}

/* --- TOASTS --- */
.toast-container {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    z-index: 10003;
}

.toast {
    background: var(--bg-surface);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 1rem 1.5rem;
    border-radius: var(--radius-md);
    min-width: 250px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    animation: toastSlideIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    position: relative;
    overflow: hidden;
}

.toast-hide {
    animation: toastSlideOut 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes toastSlideIn {
    from {
        transform: translateX(120%);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes toastSlideOut {
    from {
        transform: translateX(0);
        opacity: 1;
    }

    to {
        transform: translateX(120%);
        opacity: 0;
    }
}

.toast-success {
    border-left: 4px solid var(--text-primary);
}

.toast-error {
    border-left: 4px solid var(--error);
}

.toast-info {
    border-left: 4px solid var(--text-primary);
}

.toast-content {
    font-size: 0.85rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.toast-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 2px;
    background: var(--text-primary);
    width: 100%;
    animation: toastProgress linear forwards;
}

@keyframes toastProgress {
    from {
        width: 100%;
    }

    to {
        width: 0%;
    }
}

.toast-error .toast-progress {
    background: var(--error);
}

.toast-success .toast-progress {
    background: var(--text-primary);
}

/* --- SELECT --- */
.custom-select-container {
    position: relative;
    width: 120px;
    font-family: var(--font-mono);
}

.custom-select-trigger {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-size: 0.8rem;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition);
}

.custom-select-trigger:hover {
    border-color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

.custom-select-container.open .custom-select-trigger {
    border-color: var(--text-primary);
    box-shadow: 0 0 10px var(--glow-color);
}

.custom-select-arrow {
    transition: transform 0.3s ease;
}

.custom-select-container.open .custom-select-arrow {
    transform: rotate(180deg);
}

.custom-select-menu {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    background: var(--bg-surface);
    border: 1px solid var(--text-primary);
    border-radius: var(--radius-sm);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1001;
    max-height: 250px;
    overflow-y: auto;
}

.custom-select-container.open .custom-select-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.custom-select-item {
    padding: 10px 12px;
    font-size: 0.8rem;
    color: var(--text-muted);
    cursor: pointer;
    transition: var(--transition);
}

.custom-select-item:hover {
    background: rgba(226, 183, 20, 0.1);
    color: var(--text-primary);
}

.custom-select-item.selected {
    color: var(--text-primary);
    font-weight: 700;
}

/* --- NUMERIC INPUT --- */


.setting-input {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-primary);
    padding: 10px 16px;
    border-radius: var(--radius-md);
    font-family: var(--font-mono);
    font-size: 0.9rem;
    width: 100px;
    text-align: center;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    /* Suppress browser number spinners */
    appearance: textfield;
    -moz-appearance: textfield;
}

.setting-input::-webkit-inner-spin-button,
.setting-input::-webkit-outer-spin-button {
    -webkit-appearance: none;
    appearance: none;
    margin: 0;
}

.setting-input:hover {
    border-color: rgba(255, 255, 255, 0.18);
    background: rgba(255, 255, 255, 0.05);
}

.setting-input:focus {
    border-color: var(--text-primary);
    background: rgba(226, 183, 20, 0.04);
    box-shadow: 0 0 0 3px rgba(226, 183, 20, 0.12), 0 0 20px var(--glow-color);
    outline: none;
}


.numeric-input-wrapper {
    display: inline-flex;
    align-items: stretch;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    height: 42px;
}

.numeric-input-wrapper:hover {
    border-color: rgba(255, 255, 255, 0.2);
}

.numeric-input-wrapper:focus-within {
    border-color: var(--text-primary);
    box-shadow: 0 0 0 3px rgba(226, 183, 20, 0.12), 0 0 20px var(--glow-color);
}


.numeric-input-wrapper .setting-input {
    border: none;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    width: 70px;
    padding: 0 8px;
    height: 100%;
    font-size: 1rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    text-align: center;
}

.numeric-input-wrapper .setting-input:hover {
    border: none;
    background: transparent;
}

.numeric-input-wrapper .setting-input:focus {
    border: none;
    box-shadow: none;
    background: transparent;
    outline: none;
}


.numeric-ctrl-btn {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: 1.1rem;
    font-weight: 700;
    width: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: color 0.15s ease, background 0.15s ease;
    user-select: none;
    flex-shrink: 0;
    border-right: 1px solid rgba(255, 255, 255, 0.05);
}

.numeric-ctrl-btn:last-child {
    border-right: none;
    border-left: 1px solid rgba(255, 255, 255, 0.05);
}

.numeric-ctrl-btn:hover {
    color: var(--text-primary);
    background: rgba(226, 183, 20, 0.08);
}

.numeric-ctrl-btn:active {
    background: rgba(226, 183, 20, 0.15);
}

/* ============================================
   CURSOR INTERACTIVE STATES — text hint
   ============================================ */
/* Hover-text cursor path dims slightly (opacity handled on svg level) */
.custom-cursor.hovering-text .cursor-path {
    fill: var(--text-secondary);
}