/* ==========================
   GLOBAL RESET
   ========================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html,
body {
    width: 100%;
    height: 100%;
    overflow: hidden;
    font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background: linear-gradient(135deg, #0b0e14 0%, #111827 50%, #1f2937 100%);
    color: #ffffff;
}

/* ==========================
   MAIN LAYOUT
   ========================== */
.app-container {
    display: flex;
    width: 100vw;
    height: 100vh;
}

/* ==========================
   LEFT PANEL - 3D CANVAS
   ========================== */
.canvas-section {
    flex: 2;
    position: relative;
    background:
        radial-gradient(circle at top left, rgba(59, 130, 246, 0.08), transparent 45%),
        radial-gradient(circle at bottom right, rgba(16, 185, 129, 0.05), transparent 40%),
        #1a1a1a;
}

/* Subtle glow overlay */
.canvas-section::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background:
        linear-gradient(
            to bottom,
            rgba(255, 255, 255, 0.02),
            rgba(0, 0, 0, 0.05)
        );
}

/* Three.js canvas */
#scene {
    width: 100% !important;
    height: 100% !important;
    display: block;
}

/* ==========================
   RIGHT PANEL - SIDEBAR
   ========================== */
.description-section {
    flex: 1;
    min-width: 380px;
    max-width: 460px;

    display: flex;
    flex-direction: column;
    gap: 24px;

    padding: 40px 32px;

    background: rgba(255, 255, 255, 0.06);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);

    border-left: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: -20px 0 40px rgba(0, 0, 0, 0.45);

    overflow-y: auto;
}

/* ==========================
   HEADINGS
   ========================== */
h1 {
    font-size: 2.2rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1.1;

    background: linear-gradient(90deg, #ffffff, #93c5fd);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.subtitle {
    font-size: 0.95rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.72);
}

/* ==========================
   INPUT SECTION
   ========================== */
.input-group {
    display: flex;
    gap: 12px;
    align-items: stretch;
}

/* Command input */
input {
    flex: 1;
    padding: 14px 16px;

    font-size: 0.95rem;
    color: #ffffff;

    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;

    outline: none;
    transition: all 0.3s ease;
}

input::placeholder {
    color: rgba(255, 255, 255, 0.45);
}

input:focus {
    border-color: rgba(59, 130, 246, 0.6);
    background: rgba(255, 255, 255, 0.09);
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.12);
}

/* ==========================
   BUTTON
   ========================== */
button {
    padding: 14px 22px;

    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 0.01em;

    color: #ffffff;
    background: linear-gradient(135deg, #3b82f6, #2563eb);

    border: none;
    border-radius: 12px;
    cursor: pointer;

    transition: all 0.25s ease;
    box-shadow: 0 8px 24px rgba(37, 99, 235, 0.28);
}

button:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(37, 99, 235, 0.35);
}

button:active {
    transform: translateY(0);
}

button:disabled {
    cursor: not-allowed;
    opacity: 0.65;
    transform: none;
    box-shadow: none;
}

/* ==========================
   DESCRIPTION CARD
   ========================== */
.description-text {
    padding: 22px 24px;

    line-height: 1.8;
    font-size: 0.96rem;

    color: rgba(255, 255, 255, 0.85);

    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 16px;

    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}


/* ==========================
   RESPONSIVE DESIGN
   ========================== */
@media (max-width: 1024px) {
    .description-section {
        min-width: 320px;
        padding: 32px 24px;
    }

    h1 {
        font-size: 1.9rem;
    }
}

@media (max-width: 768px) {
    .app-container {
        flex-direction: column;
    }

    .canvas-section {
        flex: none;
        height: 55vh;
    }

    .description-section {
        flex: 1;
        min-width: 100%;
        max-width: 100%;
        border-left: none;
        border-top: 1px solid rgba(255, 255, 255, 0.08);
    }

    .input-group {
        flex-direction: column;
    }

    button {
        width: 100%;
    }
}