/* Interactive Games Workspace Styling */

.game-templates-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 15px;
}

.game-template-card {
    border-radius: 16px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(30, 41, 59, 0.4);
    backdrop-filter: blur(10px);
}

.game-template-card:hover {
    transform: translateY(-6px);
    border-color: rgba(59, 130, 246, 0.4);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.3), 0 0 15px rgba(59, 130, 246, 0.1);
}

.game-icon-banner {
    height: 120px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 3rem;
    color: white;
}

.game-card-body {
    padding: 15px;
}

.game-card-body h3 {
    margin: 0 0 8px 0;
    font-size: 1.15rem;
    color: white;
}

.game-card-body p {
    margin: 0;
    font-size: 0.88rem;
    color: #94a3b8;
    line-height: 1.4;
}

/* Split Pane Layout */
.workspace-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 20px;
    height: 75vh;
}

.workspace-left-pane {
    max-height: 100%;
    overflow-y: auto;
    padding-right: 12px;
}

.workspace-left-pane::-webkit-scrollbar {
    width: 6px;
}

.workspace-left-pane::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
}

/* Forms */
#interactiveGamesSection .form-control {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 10px;
    color: white;
    transition: border-color 0.2s;
}

#interactiveGamesSection .form-control:focus {
    border-color: #3b82f6;
    outline: none;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
}

/* Question Cards */
.question-edit-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 15px;
    margin-bottom: 15px;
    position: relative;
    transition: all 0.2s;
}

.question-edit-card:hover {
    border-color: rgba(255, 255, 255, 0.15);
    background: rgba(255, 255, 255, 0.03);
}

.remove-question-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: none;
    border: none;
    color: #ef4444;
    cursor: pointer;
    font-size: 1.1rem;
    opacity: 0.7;
    transition: opacity 0.2s;
}

.remove-question-btn:hover {
    opacity: 1;
}

/* Scraper & Refiner */
.scraper-zone {
    transition: border-color 0.3s;
}
.scraper-zone.dragover {
    border-color: #3b82f6 !important;
    background: rgba(59, 130, 246, 0.05) !important;
}

/* Micro Animations inside webview */
@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20%, 60% { transform: translateX(-6px); }
    40%, 80% { transform: translateX(6px); }
}

@keyframes pullLeft {
    0% { transform: skewX(-5deg) translateX(0); }
    50% { transform: skewX(-15deg) translateX(-15px); }
    100% { transform: skewX(-5deg) translateX(-10px); }
}

@keyframes pullRight {
    0% { transform: skewX(5deg) translateX(0); }
    50% { transform: skewX(15deg) translateX(15px); }
    100% { transform: skewX(5deg) translateX(10px); }
}

@keyframes slipLeft {
    0% { transform: skewX(-5deg) translateX(0); }
    100% { transform: skewX(15deg) translateX(30px) translateY(5px); }
}

@keyframes slipRight {
    0% { transform: skewX(5deg) translateX(0); }
    100% { transform: skewX(-15deg) translateX(-30px) translateY(5px); }
}

/* Specific Theme Overrides for Games Configurator in Light Dashboard */
#gamesConfiguratorView {
    color: #1e293b !important;
}

#gamesConfiguratorView label, 
#gamesConfiguratorView span,
#gamesConfiguratorView h4 {
    color: #0f172a !important;
}

#gamesConfiguratorView .form-control,
#gamesConfiguratorView input[type="text"],
#gamesConfiguratorView input[type="number"],
#gamesConfiguratorView select,
#gamesConfiguratorView textarea {
    background: #ffffff !important;
    color: #0f172a !important;
    border: 1px solid #cbd5e1 !important;
    border-radius: 8px !important;
    padding: 10px !important;
}

#gamesConfiguratorView select option {
    background-color: #ffffff !important;
    color: #0f172a !important;
}

#gamesConfiguratorView textarea::placeholder,
#gamesConfiguratorView input::placeholder {
    color: #94a3b8 !important;
}

#gamesConfiguratorView .question-edit-card {
    background: #f8fafc !important;
    border: 1px solid #e2e8f0 !important;
}

#gamesConfiguratorView .question-edit-card label {
    color: #475569 !important;
}

#gamesConfiguratorView .ai-refiner-box {
    background: #f0f9ff !important;
    border: 1px solid #bae6fd !important;
}

#gamesConfiguratorView .ai-refiner-box h4 {
    color: #0369a1 !important;
}

#gamesConfiguratorView .ai-refiner-box p {
    color: #0369a1 !important;
}

