        :root {
            --primary-bg: #0f0518;
            --secondary-bg: #1e0b36;
            --accent-color: #69D2C6;
            --button-color: #98E2D8;
            --text-color: #ffffff;
            --glass-bg: rgba(255, 255, 255, 0.05);
            --glass-border: rgba(255, 255, 255, 0.1);
        }

        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
            font-family: 'Poppins', sans-serif;
        }

        body {
            zoom: 1;
            background: radial-gradient(circle at 50% 0%, #482a70 0%, #200f3a 50%, #0f0518 100%);
            color: var(--text-color);
            height: 100vh;
            overflow-x: hidden;
            display: flex;
            flex-direction: column;
            background-image: url("arkaplan.png");
            background-size: cover;
            background-position: center;
            background-repeat: no-repeat;
            background-attachment: fixed;
        }

        header {
            zoom: 0.9;
            align-self: center;
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 20px 80px;
            background: rgba(106, 76, 145, 0.226);
            backdrop-filter: blur(5px);
            position: fixed;
            width: 80%;
            height: 90px;
            top: 0;
            z-index: 1000;
            border-bottom: 1px solid var(--glass-border);
            border-radius: 12px;
            animation: fadeInSlideDown 1s ease-out forwards;
            opacity: 0;
            transform: translateY(-20px);
        }

        @keyframes fadeInSlideDown {
            0% {
                opacity: 0;
                transform: translateY(-20px) scale(1);
            }

            100% {
                opacity: 1;
                transform: translateY(0) scale(1.0);
            }
        }

        .logo-container {
            display: flex;
            align-items: center;
            padding: 20px 20px;
            border-radius: 12px;
            height: 52px;
            position: relative;
            overflow: hidden;
            --mouse-x: 50%;
            --mouse-y: 50%;
        }

        .logo-container:hover {
            transform: scale(1.01);
            transition: all 0.3s ease;
        }

        .logo-img {
            height: 120px;
            width: auto;
            object-fit: contain;
            margin: 0 auto;
        }

        .logo-img:hover {
            transform: scale(1.1);
            transition: all 0.3s ease;
        }

        nav ul {
            display: flex;
            list-style: none;
            gap: 40px;
        }

        nav a {
            text-decoration: none;
            color: rgba(255, 255, 255, 0.7);
            font-weight: 400;
            font-size: 16px;
            transition: all 0.3s ease;
            position: relative;
        }

        nav a:hover,
        nav a.active {
            color: var(--text-color);
        }

        nav a::after {
            content: '';
            position: absolute;
            width: 0;
            height: 2px;
            bottom: -5px;
            left: 0;
            background-color: var(--button-color);
            transition: width 0.3s ease;
        }

        nav a:hover::after,
        nav a.active::after {
            width: 100%;
        }

        .dropdown {
            position: relative;
        }

        .dropdown-menu {
            position: absolute;
            top: 150%;
            left: 50%;
            transform: translateX(-50%) translateY(-10px);
            background: #171720;
            backdrop-filter: blur(15px);
            border: 1px solid var(--glass-border);
            border-radius: 12px;
            padding: 10px;
            min-width: 220px;
            opacity: 0;
            visibility: hidden;
            transition: all 0.3s ease;
            box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
        }

        .dropdown:hover .dropdown-menu {
            opacity: 1;
            visibility: visible;
            transform: translateX(-50%) translateY(0);
        }

        .dropdown-menu a {
            display: block;
            padding: 10px 15px;
            color: #ccc;
            border-radius: 8px;
            font-size: 14px;
            position: relative;
            overflow: hidden;
            background: transparent;
            z-index: 1;
        }

        .dropdown-menu a::before {
            zoom: 1.1;
            content: '';
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: radial-gradient(circle at var(--x, 50%) var(--y, 50%),
                    rgba(133, 70, 216, 0.4) 0%,
                    transparent 50%);
            opacity: 0;
            transition: opacity 0.3s ease;
            z-index: -1;
            border-radius: 8px;
        }

        .dropdown-menu a:hover::before {
            opacity: 1;
        }

        .dropdown-menu a:hover {
            color: white;
            transform: scale(1.02);
            padding-left: 20px;
            box-shadow: 0 0 15px rgba(133, 70, 216, 0.3);
            background: rgba(255, 255, 255, 0.03);
        }

        .hero-section {
            flex: 1;
            display: flex;
            flex-direction: column;
            justify-content: center;
            align-items: center;
            text-align: center;
            padding-top: 80px;
        }

        .hero-title {
            font-size: 80px;
            font-weight: 800;
            line-height: 1.1;
            margin-bottom: 10px;
            background: linear-gradient(to bottom, #ffffff 0%, #d4c4e8 100%);
            background-clip: text;
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            text-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
            animation: fadeInUp 0.8s ease-out;
            align-self: center;
            justify-self: center;
        }

        .hero-title span {
            display: block;
        }

        .hero-subtitle {
            font-size: 20px;
            font-weight: 600;
            background: linear-gradient(90deg, #ffffff 0%, #9c9a9e 40%, #d8d4dd 100%, #494949);
            background-clip: text;
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            max-width: 600px;
            margin: 20px auto 40px;
            line-height: 1.6;
            animation: fadeInUp 1s ease-out;
            text-shadow: 0px 0px 10px rgba(133, 70, 216, 0.4);
            align-self: center;
            justify-self: center;
        }

        .hero-subtitle i {
            font-weight: 700;
            font-style: italic;
        }

        .hero-subtitle strong {
            color: white;
            font-weight: 700;
            align-self: center;
            justify-self: center;
        }

        .cta-button {
            padding: 15px 50px;
            background-color: var(--button-color);
            color: #1a0b2e;
            font-size: 18px;
            font-weight: 600;
            border: none;
            border-radius: 8px;
            cursor: pointer;
            transition: all 0.3s ease;
            box-shadow: 0 0 20px rgba(129, 199, 188, 0.4);
            animation: fadeInUp 1.2s ease-out;
            text-decoration: none;
            display: inline-block;
        }

        .cta-button:hover {
            transform: translateY(-3px) scale(1.05);
            box-shadow: 0 0 30px rgba(129, 199, 188, 0.6);
            background-color: #92ded2;
        }

        @keyframes fadeInUp {
            from {
                opacity: 0;
                transform: translateY(30px);
            }

            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        @media (max-width: 768px) {
            header {
                padding: 20px 30px;
            }

            nav ul {
                display: none;
            }

            .hero-title {
                font-size: 48px;
            }

            .hero-subtitle {
                padding: 0 20px;
            }
        }

        .cursor-glow {
            height: 20px;
            width: 20px;
            border-radius: 0%;
            background: radial-gradient(circle, rgba(255, 133, 249, 0.8) 0%, rgba(233, 147, 255, 0.6) 40%, rgba(133, 70, 216, 0.3) 80%, transparent 100%);
            box-shadow: 0 0 20px rgba(105, 210, 198, 0.5), 0 0 40px rgba(133, 70, 216, 0.3);
            filter: blur(20px);
            position: fixed;
            pointer-events: none;
            z-index: 999;
            transform: translate(-50%, -50%);
            transition: left 0.008s ease-out, top 0.008s ease-out;
            mix-blend-mode: screen;
        }

        i {
            color: var(--accent-color);
        }



        .contact-modal-overlay {
            zoom: 0.8;
            position: fixed;
            top: 120px;
            left: 0;
            width: 100%;
            height: calc(100% - 90px);
            background: none;
            backdrop-filter: blur(90px);
            display: none;
            justify-content: center;
            align-items: center;
            z-index: 2000;
            opacity: 0;
            transition: opacity 0.3s ease;
            overflow: hidden;

        }

        .rel-btn-group {
            display: flex;
            flex-direction: column;
            gap: 10px;
        }


        .goal-modal-overlay {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: rgba(15, 5, 24, 0.6);
            backdrop-filter: blur(100px);
            display: none;
            justify-content: center;
            align-items: center;
            z-index: 999;
            opacity: 0;
            transition: opacity 0.5s ease;
            padding-top: 90px;
            zoom: 0.8;
        }

        .goal-modal-overlay.active {
            opacity: 1;
        }

        .goal-content {
            text-align: center;
            max-width: 800px;
            padding: 60px;
            background: rgba(255, 255, 255, 0.02);
            border: 1px solid rgba(255, 255, 255, 0.08);
            box-shadow: 0 0 80px rgba(133, 70, 216, 0.15);
            border-radius: 30px;
            position: relative;
            overflow: hidden;
            transform: translateY(50px);
            transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
        }

        .goal-modal-overlay.active .goal-content {
            transform: translateY(0);
        }

        .goal-logo {
            width: 160px;
            margin-bottom: 25px;
            filter: drop-shadow(0 0 30px rgba(105, 210, 198, 0.4));
            animation: floatLogo 4s ease-in-out infinite;
        }

        @keyframes floatLogo {

            0%,
            100% {
                transform: translateY(0);
            }

            50% {
                transform: translateY(-15px);
            }
        }

        .goal-title {
            font-size: 52px;
            font-weight: 800;
            background: linear-gradient(135deg, #fff 20%, #a991d8 100%);
            background-clip: text;
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            margin-bottom: 25px;
            letter-spacing: -1px;
            text-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
        }

        .goal-text {
            font-size: 18px;
            line-height: 1.8;
            color: #d1d1d1;
            font-weight: 300;
            margin-bottom: 45px;
            padding: 0 40px;
        }

        .goal-close {
            background: transparent;
            border: 1px solid rgba(255, 255, 255, 0.15);
            color: #fff;
            padding: 14px 45px;
            border-radius: 50px;
            cursor: pointer;
            font-size: 16px;
            font-weight: 500;
            transition: all 0.3s;
            backdrop-filter: blur(5px);
        }

        .goal-close:hover {
            background: rgba(255, 255, 255, 0.08);
            border-color: #fff;
            box-shadow: 0 0 30px rgba(105, 210, 198, 0.2);
            transform: translateY(-2px);
        }

        .goal-glow-1 {
            position: absolute;
            width: 400px;
            height: 400px;
            background: radial-gradient(circle, rgba(133, 70, 216, 0.2) 0%, transparent 70%);
            border-radius: 50%;
            top: -100px;
            left: -100px;
            pointer-events: none;
            z-index: -1;
            filter: blur(60px);
        }

        .goal-glow-2 {
            position: absolute;
            width: 300px;
            height: 300px;
            background: radial-gradient(circle, rgba(105, 210, 198, 0.15) 0%, transparent 70%);
            border-radius: 50%;
            bottom: -50px;
            right: -50px;
            pointer-events: none;
            z-index: -1;
            filter: blur(60px);
        }

        .contact-modal-overlay.active {
            opacity: 1;
        }

        .modal-wrapper {
            display: flex;
            flex-direction: column;
            align-items: center;
            width: 90%;
            max-width: 800px;
            animation: modalPop 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
        }

        @keyframes modalPop {
            0% {
                transform: scale(0.9);
                opacity: 0;
            }

            100% {
                transform: scale(1);
                opacity: 1;
            }
        }

        .modal-title {
            zoom: 0.65;
            font-size: 65px;
            font-weight: 800;
            line-height: 1.0;
            margin-bottom: 10px;
            background: linear-gradient(to bottom, #ffffff 0%, #d4c4e8 100%);
            background-clip: text;
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            text-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
            animation: fadeInUp 0.8s ease-out;
        }

        .modal-subtitle {
            font-size: 13px;
            font-weight: 600;
            background: linear-gradient(90deg, #ffffff 0%, #9c9a9e 40%, #d8d4dd 100%, #494949);
            background-clip: text;
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            max-width: 650px;
            margin: 20px auto 40px;
            line-height: 1.6;
            animation: fadeInUp 1s ease-out;
            text-shadow: 0px 0px 10px rgba(133, 70, 216, 0.4);
        }

        .contact-form-card {
            background: rgba(30, 20, 50, 0.4);
            border: 1px solid rgba(133, 70, 216, 0.2);
            border-radius: 16px;
            padding: 40px;
            width: 100%;
            box-shadow: 0 0 40px rgba(0, 0, 0, 0.4);
        }


        .contact-form {
            display: flex;
            flex-direction: column;
            gap: 20px;
        }

        .form-row {
            display: flex;
            gap: 25px;
        }

        .col-left {
            display: flex;
            flex-direction: column;
            gap: 20px;
            flex: 2;
        }

        .col-right {
            flex: 1;
            display: flex;
            flex-direction: column;
        }

        .row-inputs {
            display: flex;
            gap: 20px;
        }

        .form-group {
            display: flex;
            flex-direction: column;
            gap: 8px;
            flex: 1;
        }

        .form-group label {
            font-size: 12px;
            font-weight: 500;
            color: #888;
            margin-left: 2px;
        }

        .form-group input,
        .form-group textarea {
            background: transparent;
            border: 1px solid rgba(133, 70, 216, 0.3);
            border-radius: 6px;
            padding: 12px;
            color: #DDD;
            font-size: 14px;
            outline: none;
            transition: all 0.3s;
            font-family: 'Poppins', sans-serif;
            font-weight: 300;
        }

        .form-group input::placeholder,
        .form-group textarea::placeholder {
            color: rgba(255, 255, 255, 0.2);
            font-style: italic;
        }

        .form-group input:focus,
        .form-group textarea:focus {
            border-color: var(--accent-color);
            box-shadow: 0 0 10px rgba(105, 210, 198, 0.1);
            background: rgba(255, 255, 255, 0.02);
        }

        .form-group textarea {
            height: 150px;
            resize: none;
        }

        .type-group {
            height: 100%;
            display: flex;
            flex-direction: column;
        }

        .type-box {
            background: rgba(15, 5, 25, 0.3);
            border: 1px solid rgba(133, 70, 216, 0.3);
            border-radius: 8px;
            padding: 15px;
            flex: 1;
            display: flex;
            flex-direction: column;
            justify-content: center;
            gap: 12px;
        }

        .checkbox-label {
            display: flex;
            align-items: center;
            gap: 10px;
            font-size: 12px;
            color: #ccc;
            cursor: pointer;
            padding: 2px 0;
            user-select: none;
        }

        .checkbox-label input[type="checkbox"] {
            appearance: none;
            -webkit-appearance: none;
            width: 16px;
            height: 16px;
            border: 1px solid rgba(255, 255, 255, 0.3);
            border-radius: 4px;
            background: transparent;
            cursor: pointer;
            position: relative;
            display: flex;
            align-items: center;
            justify-content: center;
            margin: 0;
            transition: all 0.2s;
        }

        .checkbox-label input[type="checkbox"]:checked {
            background: #a991d8;
            border-color: #a991d8;
        }

        .checkbox-label input[type="checkbox"]:checked::after {
            content: '✓';
            color: #1e0b36;
            font-size: 12px;
            font-weight: bold;
        }

        .checkbox-label:hover input[type="checkbox"] {
            border-color: #a991d8;
        }

        .submit-btn {
            align-self: center;
            background: #98E2D8;
            color: #1a0b2e;
            border: none;
            padding: 12px 0;
            width: 300px;
            border-radius: 8px;
            font-weight: 500;
            font-size: 16px;
            cursor: pointer;
            margin-top: 10px;
            transition: all 0.3s;
            box-shadow: 0 0 15px rgba(152, 226, 216, 0.2);
        }

        .submit-btn:hover {
            background: #b4ece6;
            transform: translateY(-2px);
            box-shadow: 0 0 25px rgba(152, 226, 216, 0.4);
        }


        .slider-container {
            display: flex;
            align-items: center;
            gap: 10px;
            margin: 8px 0;
        }

        .slider-btn {
            background: rgba(105, 210, 198, 0.15);
            border: 1px solid rgba(105, 210, 198, 0.4);
            color: var(--accent-color);
            width: 32px;
            height: 32px;
            min-width: 32px;
            border-radius: 8px;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 18px;
            font-weight: 600;
            transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
            user-select: none;
            backdrop-filter: blur(5px);
        }

        .slider-btn:hover {
            background: var(--accent-color);
            color: #0f0518;
            transform: translateY(-2px);
            box-shadow: 0 4px 12px rgba(105, 210, 198, 0.3);
            border-color: var(--accent-color);
        }

        .slider-btn:active {
            transform: translateY(0) scale(0.95);
        }

        input[type="range"] {
            flex: 1;
            height: 6px;
            -webkit-appearance: none;
            background: rgba(255, 255, 255, 0.1);
            border-radius: 3px;
            outline: none;
        }

        input[type="range"]::-webkit-slider-thumb {
            -webkit-appearance: none;
            width: 18px;
            height: 18px;
            background: var(--accent-color);
            border-radius: 50%;
            cursor: pointer;
            box-shadow: 0 0 10px rgba(105, 210, 198, 0.5);
            transition: all 0.2s;
        }

        input[type="range"]::-webkit-slider-thumb:hover {
            transform: scale(1.2);
            box-shadow: 0 0 15px rgba(105, 210, 198, 0.8);
        }

        #simulation-container h1 {
            animation: fadeInUp 0.8s ease-out;
            font-size: 28px;
            color: #ffffff;
            margin-bottom: 5px;
            text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
            text-align: center;
        }

        #simulation-container h2 {
            animation: fadeInUp 0.8s ease-out;
            font-size: 18px;
            color: #eee;
            margin-top: 0;
            margin-bottom: 10px;
        }

        #mainLayout {
            animation: fadeInUp 0.8s ease-out;
            display: flex;
            flex-wrap: wrap;
            gap: 16px;
            justify-content: center;
            color: var(--text-color);
        }

        #controls {
            background: rgba(30, 20, 50, 0.75);
            backdrop-filter: blur(12px);
            border: 1px solid rgba(255, 255, 255, 0.1);
            animation: fadeInUp 0.8s ease-out;
            padding: 16px 20px;
            border-radius: 12px;
            box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
            display: flex;
            flex-direction: column;
            gap: 10px;
            min-width: 320px;
            max-width: 360px;
            height: fit-content;
        }


        #controls::-webkit-scrollbar,
        #rightPanel::-webkit-scrollbar {
            width: 8px;
        }

        #controls::-webkit-scrollbar-track,
        #rightPanel::-webkit-scrollbar-track {
            background: rgba(255, 255, 255, 0.05);
            border-radius: 4px;
        }

        #controls::-webkit-scrollbar-thumb,
        #rightPanel::-webkit-scrollbar-thumb {
            background: #69D2C6;
            border-radius: 4px;
        }

        #controls::-webkit-scrollbar-thumb:hover,
        #rightPanel::-webkit-scrollbar-thumb:hover {
            background: #98E2D8;
        }

        #controls label {
            animation: fadeInUp 0.8s ease-out;
            font-size: 14px;
            display: block;
            margin-bottom: 4px;
            color: #eee;
        }

        input[type="range"] {
            animation: fadeInUp 0.8s ease-out;
            width: 100%;
            margin: 4px 0;
        }

        .sim-button {
            width: 100%;
            background: #607D8B;
            padding: 8px 16px;
            color: #fff;
            font-size: 13px;
            font-weight: 600;
            border: none;
            border-radius: 8px;
            cursor: pointer;
            transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
            box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 6px;
        }

        .sim-button:hover {
            transform: translateY(-2px) scale(1.02);
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
            background-color: #78909C;
        }

        .close-sim-btn {
            background: rgba(255, 255, 255, 0.05);
            border: 1px solid rgba(255, 255, 255, 0.1);
            color: #ccc;
            width: auto !important;
            padding: 10px 35px;
            font-size: 14px;
            font-weight: 500;
            border-radius: 8px;
            cursor: pointer;
            transition: all 0.3s ease;
            margin-top: 30px;
            display: inline-flex;
            align-items: center;
            justify-content: center;
        }

        .close-sim-btn:hover {
            background: rgba(255, 255, 255, 0.1);
            border-color: rgba(255, 255, 255, 0.3);
            color: #fff;
            transform: translateY(-2px);
            box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
        }

        #results p {

            margin: 4px 0;
            font-size: 14px;
            line-height: 1.6;
            color: #ddd;
        }

        #rightPanel {
            animation: fadeInUp 0.8s ease-out;
            display: flex;
            flex-direction: column;
            gap: 12px;
            max-width: 400px;
            min-width: 350px;
        }

        #canvasWrapper {
            animation: fadeInUp 0.8s ease-out;
            background: rgba(30, 20, 50, 0.75);
            backdrop-filter: blur(12px);
            border: 1px solid rgba(255, 255, 255, 0.1);
            padding: 10px;
            border-radius: 12px;
            box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
        }

        #theoryBox {
            animation: fadeInUp 0.8s ease-out;
            background: rgba(40, 30, 60, 0.6);
            backdrop-filter: blur(5px);
            border: 1px solid rgba(255, 255, 255, 0.1);
            padding: 10px 12px;
            border-radius: 12px;
            box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
            font-size: 13px;
            line-height: 1.4;
            border-left: 4px solid #00bcd4;
            color: #eee;
        }

        #canvasContainer {
            position: relative;
            display: block;
            border: 1px solid rgba(255, 255, 255, 0.1);
            border-radius: 8px;
            height: 350px;
            background: #000000;
            overflow: hidden;
        }

        #hudPanel {
            animation: fadeInUp 0.8s ease-out;
            position: relative;
            margin-top: 4px;
            background: rgba(20, 10, 30, 0.6);
            border-radius: 0 0 8px 8px;
            border-top: 1px solid rgba(255, 255, 255, 0.1);
            padding: 6px 10px;
            font-size: 12px;
            display: flex;
            gap: 10px;
            justify-content: space-between;
            color: #eee;
        }

        .hud-label {
            font-weight: 600;
            color: #64b5f6;
        }

        .ball {
            position: absolute;
            width: 30px;
            height: 30px;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 14px;
            font-weight: bold;
            cursor: grab;
            user-select: none;
            touch-action: none;
            box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
            border: 1px solid rgba(0, 0, 0, 0.1);
            color: white;
            z-index: 10;
            transition: transform 0.1s;
        }

        .ball:active {
            cursor: grabbing;
            transform: scale(1.1);
            z-index: 20;
        }

        .positive {
            background-color: #ff5252;
            box-shadow: 0 0 8px rgba(255, 82, 82, 0.6);
        }

        .negative {
            background-color: #448aff;
            box-shadow: 0 0 8px rgba(68, 138, 255, 0.6);
        }

        .neutral {
            background-color: #9e9e9e;
        }

        #selection-menu {
            zoom: 0.9;
            display: none;
            padding-top: 120px;
            padding-bottom: 50px;
            flex-direction: column;
            align-items: center;
            width: 100%;
            min-height: 100vh;
        }

        .menu-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
            gap: 30px;
            width: 80%;
            max-width: 1200px;
            margin-top: 40px;
            animation: fadeInUp 0.5s ease-out;
        }

        .sim-card {
            background: rgba(30, 20, 50, 0.6);
            backdrop-filter: blur(10px);
            border: 1px solid rgba(255, 255, 255, 0.1);
            border-radius: 20px;
            padding: 30px 25px;
            display: flex;
            flex-direction: column;
            gap: 15px;
            cursor: pointer;
            transition: all 0.4s ease;
            position: relative;
            overflow: hidden;
            text-decoration: none;
        }

        .sim-card::before {
            content: '';
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, transparent 100%);
            opacity: 0;
            transition: opacity 0.4s ease;
        }

        .sim-card:hover {
            transform: translateY(-10px);
            background: rgba(40, 30, 60, 0.8);
            border-color: var(--accent-color);
            box-shadow: 0 10px 30px rgba(105, 210, 198, 0.2);
        }

        .sim-card:hover::before {
            opacity: 1;
        }

        .card-icon {
            font-size: 40px;
            margin-bottom: 10px;
            background: linear-gradient(135deg, #fff 0%, #aaa 100%);
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
        }

        .card-title {
            font-size: 22px;
            font-weight: 700;
            color: #fff;
            margin: 0;
        }

        .card-desc {
            font-size: 14px;
            color: #ccc;
            font-weight: 300;
            line-height: 1.5;
        }

        .card-arrow {
            margin-top: auto;
            align-self: flex-end;
            color: var(--accent-color);
            font-weight: bold;
            font-size: 20px;
            opacity: 0;
            transform: translateX(-10px);
            transition: all 0.3s ease;
        }

        .sim-card:hover .card-arrow {
            opacity: 1;
            transform: translateX(0);
        }

        .rel-main-layout {
            display: flex;
            flex-wrap: wrap;
            gap: 16px;
            justify-content: center;
            color: var(--text-color);
            width: 100%;
        }

        .rel-controls-panel {
            background: rgba(30, 20, 50, 0.75);
            backdrop-filter: blur(12px);
            border: 1px solid rgba(255, 255, 255, 0.1);
            padding: 20px;
            border-radius: 12px;
            box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
            display: flex;
            flex-direction: column;
            gap: 15px;
            min-width: 300px;
            max-width: 320px;
            height: fit-content;
            animation: fadeInUp 0.8s ease-out;
        }

        .rel-controls-panel h2 {
            font-size: 18px;
            color: #eee;
            margin: 0 0 5px 0;
        }

        .rel-control-group {
            display: flex;
            flex-direction: column;
            gap: 5px;
        }

        .rel-control-group label {
            font-size: 14px;
            color: #bbb;
        }

        .rel-input-row {
            display: flex;
            gap: 10px;
        }

        #relative-motion-container select,
        #relative-motion-container input {
            background: rgba(0, 0, 0, 0.3);
            border: 1px solid rgba(255, 255, 255, 0.15);
            color: #fff;
            padding: 8px;
            border-radius: 6px;
            width: 100%;
            outline: none;
            font-family: inherit;
            font-size: 14px;
        }

        #relative-motion-container select:focus,
        #relative-motion-container input:focus {
            border-color: var(--accent-color);
        }

        .rel-right-panel {
            display: flex;
            flex-direction: column;
            gap: 16px;
            flex: 1;
            max-width: 600px;
            min-width: 350px;
            animation: fadeInUp 0.8s ease-out;
        }



        .rel-canvas-wrapper {
            background: rgba(30, 20, 50, 0.75);
            backdrop-filter: blur(12px);
            border: 1px solid rgba(255, 255, 255, 0.1);
            border-radius: 12px;
            box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
            overflow: hidden;
            position: relative;
            display: flex;
            justify-content: center;
        }

        #rm-simCanvas {
            width: 100%;
            height: auto;
            object-fit: contain;
            background: #87ceeb;
        }

        .theory-box {
            background: rgba(40, 30, 60, 0.6);
            backdrop-filter: blur(5px);
            border: 1px solid rgba(255, 255, 255, 0.1);
            padding: 12px 16px;
            border-radius: 12px;
            box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
            font-size: 14px;
            line-height: 1.5;
            border-left: 4px solid var(--accent-color);
            color: #eee;
        }

        .rel-result-box {
            background: rgba(20, 10, 30, 0.6);
            padding: 15px;
            border-radius: 10px;
            border: 1px solid rgba(255, 255, 255, 0.1);
            text-align: center;
            min-height: 80px;
            display: flex;
            align-items: center;
            justify-content: center;
        }

        .rel-btn-group {
            display: flex;
            flex-direction: column;
            gap: 10px;
        }

        .ai-box {
            margin-top: 15px;
            background: linear-gradient(135deg, rgba(133, 70, 216, 0.08) 0%, rgba(105, 210, 198, 0.04) 100%);
            padding: 15px;
            border-radius: 8px;
            border-left: 4px solid #8546D8;
            border: 1px solid rgba(133, 70, 216, 0.12);
        }

        .ai-box:hover {
            box-shadow: 0 2px 10px rgba(133, 70, 216, 0.4);
            transform: translateY(-0.7px);
            transition: all 0.2s ease;


        }

        .ai-box h2 {
            font-size: 16px;
            margin-bottom: 12px;
            color: #480d96;
            display: flex;
            align-items: center;
            gap: 8px;
        }

        .ai-category-select {
            width: 100%;
            padding: 8px;
            border-radius: 4px;
            background: rgba(19, 10, 31, 0.8);
            color: #ddd;
            border: 1px solid rgba(133, 70, 216, 0.2);
            margin-bottom: 12px;
            font-size: 12px;
            cursor: pointer;
        }

        .ai-generate-btn {
            width: 100%;
            padding: 10px;
            background: linear-gradient(135deg, #8546D8 0%, #69D2C6 100%);
            color: #fff;
            border: none;
            border-radius: 4px;
            cursor: pointer;
            font-weight: 600;
            font-size: 13px;
            transition: all 0.3s;
        }

        .ai-results {
            margin-top: 12px;
        }


        .quiz-overlay {
            display: none;
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: rgba(10, 5, 20, 0.92);
            backdrop-filter: blur(18px);
            z-index: 3000;
            align-items: center;
            justify-content: center;
            opacity: 0;
            transition: opacity 0.3s ease;
        }

        .quiz-overlay.active {
            opacity: 1;
            display: flex !important;
        }

        .quiz-panel {
            background: linear-gradient(135deg, #1e0b36 0%, #2d1b4e 100%);
            border: 1px solid rgba(133, 70, 216, 0.25);
            border-radius: 20px;
            padding: 30px 35px;
            width: 92%;
            max-width: 740px;
            max-height: 85vh;
            overflow-y: auto;
            box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6), 0 0 40px rgba(133, 70, 216, 0.15);
            scrollbar-width: thin;
            scrollbar-color: #69D2C6 rgba(255, 255, 255, 0.05);
        }

        .quiz-panel::-webkit-scrollbar {
            width: 6px;
        }

        .quiz-panel::-webkit-scrollbar-track {
            background: rgba(255, 255, 255, 0.04);
            border-radius: 3px;
        }

        .quiz-panel::-webkit-scrollbar-thumb {
            background: #69D2C6;
            border-radius: 3px;
        }

        .quiz-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 24px;
            padding-bottom: 16px;
            border-bottom: 1px solid rgba(255, 255, 255, 0.08);
        }

        .quiz-header h2 {
            font-size: 22px;
            font-weight: 700;
            background: linear-gradient(135deg, #fff 20%, #a991d8 100%);
            background-clip: text;
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            margin: 0;
        }

        .quiz-close-btn {
            background: rgba(255, 255, 255, 0.06);
            border: 1px solid rgba(255, 255, 255, 0.12);
            color: #fff;
            width: 36px;
            height: 36px;
            border-radius: 10px;
            cursor: pointer;
            font-size: 18px;
            display: flex;
            align-items: center;
            justify-content: center;
            transition: all 0.2s;
            flex-shrink: 0;
        }

        .quiz-close-btn:hover {
            background: rgba(255, 82, 82, 0.2);
            border-color: rgba(255, 82, 82, 0.4);
        }

        .quiz-question {
            background: rgba(255, 255, 255, 0.03);
            border: 1px solid rgba(255, 255, 255, 0.07);
            border-radius: 14px;
            padding: 20px 22px;
            margin-bottom: 20px;
        }

        .quiz-question-text {
            font-size: 15px;
            font-weight: 600;
            color: #f0eeff;
            margin-bottom: 14px;
            line-height: 1.55;
        }

        .quiz-options {
            display: flex;
            flex-direction: column;
            gap: 9px;
        }

        .quiz-option {
            display: flex;
            align-items: center;
            gap: 12px;
            padding: 11px 15px;
            border-radius: 10px;
            border: 1px solid rgba(255, 255, 255, 0.08);
            background: rgba(255, 255, 255, 0.02);
            cursor: pointer;
            transition: all 0.2s;
            user-select: none;
        }

        .quiz-option:hover {
            background: rgba(133, 70, 216, 0.15);
            border-color: rgba(133, 70, 216, 0.4);
        }

        .quiz-option.selected {
            background: rgba(133, 70, 216, 0.25);
            border-color: rgba(133, 70, 216, 0.7);
        }

        .quiz-option.correct {
            background: rgba(76, 175, 80, 0.2);
            border-color: rgba(76, 175, 80, 0.7);
        }

        .quiz-option.wrong {
            background: rgba(255, 82, 82, 0.15);
            border-color: rgba(255, 82, 82, 0.5);
        }

        .quiz-option-label {
            width: 30px;
            height: 30px;
            border-radius: 8px;
            background: rgba(133, 70, 216, 0.3);
            display: flex;
            align-items: center;
            justify-content: center;
            font-weight: 700;
            font-size: 13px;
            color: #a991d8;
            flex-shrink: 0;
            transition: all 0.2s;
        }

        .quiz-option.selected .quiz-option-label {
            background: #8546D8;
            color: #fff;
        }

        .quiz-option.correct .quiz-option-label {
            background: #4CAF50;
            color: #fff;
        }

        .quiz-option.wrong .quiz-option-label {
            background: #ff5252;
            color: #fff;
        }

        .quiz-option-text {
            font-size: 14px;
            color: #ddd;
            line-height: 1.4;
        }

        .quiz-check-btn {
            width: 100%;
            padding: 15px;
            background: linear-gradient(135deg, #8546D8 0%, #69D2C6 100%);
            color: #fff;
            border: none;
            border-radius: 12px;
            font-size: 16px;
            font-weight: 700;
            cursor: pointer;
            margin-top: 10px;
            transition: all 0.3s;
            box-shadow: 0 4px 20px rgba(133, 70, 216, 0.4);
            letter-spacing: 0.5px;
        }

        .quiz-check-btn:hover {
            transform: translateY(-2px);
            box-shadow: 0 8px 30px rgba(133, 70, 216, 0.6);
        }

        .quiz-check-btn:disabled {
            opacity: 0.5;
            cursor: not-allowed;
            transform: none;
        }

        .quiz-score {
            text-align: center;
            padding: 20px;
            border-radius: 12px;
            background: rgba(255, 255, 255, 0.04);
            border: 1px solid rgba(255, 255, 255, 0.08);
            margin-top: 20px;
            font-size: 20px;
            font-weight: 700;
            display: none;
        }

        .quiz-score.show {
            display: block;
        }

        .quiz-loading {
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 16px;
            padding: 40px 0;
            color: #aaa;
            font-size: 15px;
        }

        .quiz-spinner {
            width: 40px;
            height: 40px;
            border: 3px solid rgba(105, 210, 198, 0.2);
            border-top: 3px solid #69D2C6;
            border-radius: 50%;
            animation: spin 0.9s linear infinite;
        }

        .quiz-error {
            color: #ff8a80;
            font-size: 14px;
            line-height: 1.6;
            padding: 10px 0;
        }

        .change-key-btn {
            font-size: 11px;
            padding: 4px 10px;
            background: rgba(255, 255, 255, 0.05);
            border: 1px solid rgba(255, 255, 255, 0.1);
            border-radius: 6px;
            color: #aaa;
            cursor: pointer;
            transition: all 0.2s;
            margin-left: auto;
            display: block;
            margin-top: 6px;
        }

        .change-key-btn:hover {
            background: rgba(255, 255, 255, 0.1);
            color: #fff;
        }

        .api-key-modal {
            display: none;
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: rgba(0, 0, 0, 0.7);
            z-index: 2000;
            align-items: center;
            justify-content: center;
        }

        .api-key-modal.active {
            display: flex;
        }

        .api-key-modal-content {
            background: linear-gradient(135deg, #1e0b36 0%, #2d1b4e 100%);
            padding: 24px;
            border-radius: 12px;
            border: 1px solid rgba(133, 70, 216, 0.2);
            width: 92%;
            max-width: 480px;
        }

        .api-key-input {
            width: 100%;
            padding: 10px;
            border-radius: 6px;
            background: rgba(255, 255, 255, 0.03);
            border: 1px solid rgba(255, 255, 255, 0.06);
            color: #ddd;
            margin-bottom: 12px;
            font-family: monospace;
        }

        .modal-buttons {
            display: flex;
            gap: 8px;
        }

        .modal-btn {
            flex: 1;
            padding: 10px;
            border-radius: 6px;
            border: none;
            cursor: pointer;
            font-weight: 600;
        }

        .modal-btn-get-key {
            background: linear-gradient(135deg, #69D2C6 0%, #50b8a9 100%);
            color: #0f0518;
        }

        .modal-btn-submit {
            background: linear-gradient(135deg, #8546D8 0%, #69D2C6 100%);
            color: #fff;
        }

        .modal-btn-cancel {
            background: rgba(255, 255, 255, 0.06);
            color: #ddd;
            border: 1px solid rgba(255, 255, 255, 0.08);
        }

        .ai-loading {
            display: none;
            text-align: center;
            padding: 12px;
        }

        .ai-loading.active {
            display: block;
        }

        .spinner {
            display: inline-block;
            width: 16px;
            height: 16px;
            border: 2px solid rgba(105, 210, 198, 0.3);
            border-top: 2px solid #69D2C6;
            border-radius: 50%;
            animation: spin 1s linear infinite;
        }

        @keyframes spin {
            0% {
                transform: rotate(0deg);
            }

            100% {
                transform: rotate(360deg);
            }
        }