/* ==========================================
   ADDITIONAL FEATURES STYLES
   ========================================== */

/* Scroll to Top Button */
.scroll-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background: rgba(15, 15, 25, 0.9);
    backdrop-filter: blur(10px);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: scale(0.8) translateY(20px);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.scroll-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: scale(1) translateY(0);
}

.scroll-to-top:hover {
    transform: scale(1.1) translateY(-5px);
    box-shadow: 0 8px 30px rgba(170, 100, 255, 0.4);
}

.scroll-to-top i {
    position: absolute;
    font-size: 1.2rem;
    color: #fff;
    z-index: 2;
}

.progress-ring-circle {
    transform: rotate(-90deg);
    transform-origin: 50% 50%;
    transition: stroke-dashoffset 0.1s ease;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.toast {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 20px;
    background: rgba(15, 15, 25, 0.95);
    backdrop-filter: blur(20px);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    min-width: 300px;
    opacity: 0;
    transform: translateX(400px);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.toast.show {
    opacity: 1;
    transform: translateX(0);
}

.toast-icon {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    font-weight: bold;
    flex-shrink: 0;
}

.toast-success .toast-icon {
    background: linear-gradient(135deg, #00c896 0%, #00a878 100%);
    color: white;
}

.toast-error .toast-icon {
    background: linear-gradient(135deg, #ff6b6b 0%, #ff5252 100%);
    color: white;
}

.toast-info .toast-icon {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    color: white;
}

.toast-message {
    color: var(--color-text);
    flex: 1;
}

/* Form Validation Styles */
.form-group.error input,
.form-group.error textarea {
    border-color: #ff6b6b !important;
    box-shadow: 0 0 0 3px rgba(255, 107, 107, 0.1) !important;
}

.error-message {
    color: #ff6b6b;
    font-size: 0.85rem;
    margin-top: 0.5rem;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.shake {
    animation: shake 0.5s ease;
}

@keyframes shake {

    0%,
    100% {
        transform: translateX(0);
    }

    10%,
    30%,
    50%,
    70%,
    90% {
        transform: translateX(-10px);
    }

    20%,
    40%,
    60%,
    80% {
        transform: translateX(10px);
    }
}

/* Confetti Animation */
.confetti {
    position: fixed;
    width: 10px;
    height: 10px;
    top: -10px;
    z-index: 9999;
    animation: confettiFall 3s linear forwards;
    pointer-events: none;
}

@keyframes confettiFall {
    to {
        transform: translateY(100vh) rotate(720deg);
        opacity: 0;
    }
}

/* Theme Toggle Button */
.theme-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    background: rgba(15, 15, 25, 0.9);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 999;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.theme-toggle:hover {
    transform: rotate(180deg) scale(1.1);
    box-shadow: 0 6px 25px rgba(170, 100, 255, 0.4);
}

.theme-toggle i {
    color: var(--color-text);
    font-size: 1.2rem;
}

/* Light Theme */
[data-theme="light"] {
    --color-bg: hsl(0, 0%, 98%);
    --color-bg-secondary: hsl(0, 0%, 95%);
    --color-bg-tertiary: hsl(0, 0%, 92%);
    --color-text: hsl(0, 0%, 10%);
    --color-text-secondary: hsl(0, 0%, 30%);
    --color-text-tertiary: hsl(0, 0%, 50%);
}

[data-theme="light"] #particleCanvas {
    background: linear-gradient(135deg, #f5f5f5 0%, #e8e8f5 50%, #f0f0f8 100%);
}

[data-theme="light"] .glass-card {
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(0, 0, 0, 0.1);
}

[data-theme="light"] header {
    background: rgba(255, 255, 255, 0.9);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

/* Keyboard Shortcuts Hint */
.shortcuts-hint {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: rgba(15, 15, 25, 0.95);
    backdrop-filter: blur(20px);
    padding: 15px 30px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    z-index: 9998;
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.shortcuts-hint.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.hint-content {
    color: var(--color-text-secondary);
    font-size: 0.9rem;
    text-align: center;
}

.hint-content strong {
    color: var(--color-text);
    margin-right: 10px;
}

/* Rainbow Mode (Easter Egg) */
.rainbow-mode {
    animation: rainbowBackground 3s linear infinite;
}

@keyframes rainbowBackground {
    0% {
        filter: hue-rotate(0deg);
    }

    100% {
        filter: hue-rotate(360deg);
    }
}

.rainbow-mode * {
    animation: rainbowText 3s linear infinite;
}

@keyframes rainbowText {
    0% {
        filter: hue-rotate(0deg);
    }

    100% {
        filter: hue-rotate(360deg);
    }
}

/* Ultra-Smooth Transitions */
* {
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

/* Enhanced Smooth Scroll */
html {
    scroll-behavior: smooth;
    scroll-padding-top: 100px;
}

@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .scroll-to-top {
        bottom: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
    }

    .theme-toggle {
        top: 15px;
        right: 15px;
        width: 45px;
        height: 45px;
    }

    .toast {
        min-width: 250px;
    }

    .toast-container {
        right: 10px;
        left: 10px;
    }

    .shortcuts-hint {
        left: 10px;
        right: 10px;
        transform: translateX(0) translateY(100px);
    }

    .shortcuts-hint.show {
        transform: translateX(0) translateY(0);
    }
}

/* Print Styles */
@media print {

    .scroll-to-top,
    .theme-toggle,
    .toast-container,
    .shortcuts-hint,
    #particleCanvas,
    .mesh-overlay {
        display: none !important;
    }

    body {
        background: white !important;
        color: black !important;
    }

    * {
        animation: none !important;
        transition: none !important;
    }
}