    :root {
        --primary: #00b4ff;
        --secondary: #6a5cff;
        --dark: #0f172a;
        --light: #f8fafc;
    }
    * {
        margin: 0;
        padding: 0;
        box-sizing: border-box;
    }
    body {
        font-family: "Segoe UI", Arial, sans-serif;
        background: linear-gradient(135deg, #07111f, #12263f);
        color: white;
        min-height: 100vh;
        overflow-x: hidden;
    }
    .banner {
        width: 100%;
        max-width: 1536px;
        margin: 0 auto;
        overflow: hidden;
        border-radius: 0 0 12px 12px;
        box-shadow: 0 5px 30px rgba(0,0,0,0.3);
    }
    .banner-image {
        display: block;
        width: 100%;
        height: auto;
    }
    /* Main content */
    .container {
        max-width: 1300px;
        margin: 40px auto;
        padding: 20px;
        text-align: center;
    }
    .intro {
        font-size: 0.9rem;
        line-height: 1.7;
        color: #cbdaee;
        margin-bottom: 30px;
    }
    #code,
#highlighting,
#highlighting-content {

    text-align: left;

}
    /* Studio Workspace Split View */
.studio-workspace {

    display: grid;

    grid-template-columns: 1fr 1fr;

    grid-template-rows: 600px 180px;

    gap: 0px;

    border-radius: 14px;
    overflow: hidden;

    box-shadow: 0 12px 40px rgba(0,0,0,0.4);

    border: 1px solid rgba(255,255,255,0.1);
    text-align: left;
    background: #1e1e1e;
}

#left-pane {

    display: flex;

    flex-direction: column;

    position: relative;

    border-right: 1px solid rgba(255,255,255,0.1);

    grid-column: 1;
    grid-row: 1;
text-align: left;
    min-width: 0;
}
    .load-button {
        padding: 12px;
        background: linear-gradient(
            135deg,
            #90a863,
            #987055
        );
        color: #fff;
        border: none;
        cursor: pointer;
        font-weight: bold;
        font-family: "Segoe UI", Arial, sans-serif;
        z-index: 10;
        transition: opacity 0.2s;
    }
    .load-button:hover {
        opacity: 0.9;
    }
    .run-button {
        padding: 12px;
        background: linear-gradient(135deg, var(--primary), var(--secondary));
        color: #fff;
        border: none;
        cursor: pointer;
        font-weight: bold;
        font-family: "Segoe UI", Arial, sans-serif;
        z-index: 10;
        transition: opacity 0.2s;
    }
    .run-button:hover {
        opacity: 0.9;
    }
    .glscene-button {
        padding: 12px;
        background: linear-gradient(
            135deg,
            #20c863,
            #489055
        );
        color: #fff;
        border: none;
        cursor: pointer;
        font-weight: bold;
        font-family: "Segoe UI", Arial, sans-serif;
        transition: opacity 0.2s;
        flex: 1;
        min-width: 0;
    }
    .glscene-button:hover {
        opacity: 0.85;
    }
    /* Editor container wrapping the highlighter and textarea */
    .editor-wrapper {
        flex: 1;
        position: relative;
        overflow: hidden;
        background: #1e1e1e;
        text-align: left;
    }
    #lineNumbers {
        position:absolute;
        left:0;
        top:0;
        width:55px;
        bottom: 0;
        font-family: monospace;
        padding:15px 8px;
        background:#161616;
        color:#888;
        text-align:right;
        overflow:hidden;
        font-size:12.5px;
        line-height:1.4;
        border-right:1px solid #333;
        white-space: pre-line;
        user-select:none;
    }
    /* Shared text formatting metrics */
    #code, #highlighting {
        position: absolute;
        top: 0;
        left: 55px;
        width:calc(100% - 55px);
        height: 100%;
        padding: 15px;
        margin: 0;
        border: none;
        font-size: 12.5px;
        font-family: monospace;
        line-height: 1.4;
        tab-size: 2;
        white-space: pre;
        word-wrap: normal;overflow-wrap: normal;
    }
    /* Textarea handles scrolling and user interaction */
    #code {
        background: transparent;
        color: transparent;
        caret-color: #eee;
        outline: none;
        resize: none;
        overflow: auto;
        z-index: 2;
    }

    /* Highlight layer stays fixed underneath and follows textarea scroll */
    #highlighting {
        background: #1e1e1e;
        color: #eee;
        pointer-events: none;
        overflow: hidden;
        z-index: 1;
    }
    /* Comment Styling (Green) */
    .token-comment {
        color: #6a9955;
        font-style: italic;
    }
    .token-keyword {
        color: #569cd6;   /* VS Code blue */
        font-weight: 600;
    }
    .token-string {
        color: #ecdc90;
    }
    .token-function {
        color: #dea1de;
    }
    .error-line {
        background: rgba(255, 80, 80, 0.18);
    }
    #exampleGallery {
        display: flex;
        gap: 8px;
        overflow-x: auto;
        padding: 4px 4px;
        background: #181818;
        border-bottom: 1px solid rgba(255,255,255,0.10);
    }
    .example-card {
        font-size: 11px;
        width: 120px;
        background: #222;
        color: white;
        border: 1px solid #444;
        border-radius: 4px;
        padding: 2px 8px;
        cursor: pointer;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        display: flex;
        align-items: center;
        height: 28px;
        min-height: 28px;
    
    }
    .example-card:hover {
        background: #235;
    }
    .example-card.active-document {
        background: linear-gradient(
            135deg,
            #00b4ff,
            #6a5cff
        );
    
        color: white;
        border-color: #7ccfff;
    
        box-shadow:
            0 0 0 1px rgba(255,255,255,0.2),
            0 0 12px rgba(0,180,255,0.4);
    
        font-weight: bold;
    }
    .example-card.active-document:hover {
        background: linear-gradient(
            135deg,
            #00c8ff,
            #7a6cff
        );
    }
    .modal-overlay {
    
        position: fixed;
        inset: 0;
    
        background: rgba(0,0,0,0.65);
    
        display: none;
    
        align-items: center;
        justify-content: center;
    
        z-index: 20000;
    }
    .modal-panel {
    
        width: min(33vw, 420px);
        min-width: 280px;
    
        background: #1b2235;
    
        border-radius: 10px;
        text-align: center;
        padding: 20px;
    }
    .modal-panel h3 {
    
        margin-bottom: 12px;
    
        color: white;
    
        font-size: 1rem;
    }
    
    .modal-panel label {
    
        display: block;
    
        margin-bottom: 6px;
    
        color: #ccc;
    
        font-size: 0.85rem;
    }
    .modal-panel input {
    
        width: 80%;
    
        padding: 8px 10px;
    
        background: #111827;
    
        color: white;
    
        border: 1px solid #444;
    
        border-radius: 6px;
    
        font-size: 14px;
    
        box-sizing: border-box;
    }    
    .modal-panel input:focus {
    
        outline: none;
    
        border-color: #00b4ff;
    
        box-shadow:
            0 0 8px rgba(0,180,255,0.4);
    }
    .modal-buttons {
        display: flex;
        justify-content: center;
        gap: 8px;
        margin-top: 18px;
    }
.preview-container {

    position: relative;

    background: #1a1a2e;

    grid-column: 2;
    grid-row: 1;

    min-width: 0;
}    #preview {
        width: 100%;
        height: 100%;
        border: none;
        background: #1a1a2e;
    }
    .resource-select {
    
     appearance: none;
    
     background: linear-gradient(
     135deg,
     rgba(0,180,255,0.12),
     rgba(106,92,255,0.12)
     );
    
     color: #dcecff;
    
     border: 1px solid rgba(124,181,255,0.35);
    
     border-radius: 8px;
    
     padding: 8px 12px;
    
     font-family: "Segoe UI", Arial, sans-serif;
    
     font-size: 13px;
    
     cursor: pointer;
    
     transition:
     background 0.2s,
     border-color 0.2s,
     box-shadow 0.2s;
    
     box-shadow:
     inset 0 1px 0 rgba(255,255,255,0.06),
     0 0 8px rgba(0,180,255,0.08);
    
    }
    .resource-select:hover {
    
     background: #22385a;
    
     border-color: #7cb5ff;
    
    }
    .resource-select:focus {
    
     outline: none;
    
     border-color: #00b4ff;
    
     box-shadow:
     0 0 0 2px rgba(0,180,255,0.15),
     0 0 12px rgba(0,180,255,0.35);
    
    }
    .resource-select optgroup {
    
     background: #16213b;
    
     color: #7cb5ff;
    
     font-weight: bold;
    
    }
    
    .resource-select option {
    
     background: #1b2d4a;
    
     color: #dcecff;
    
    }        
    .resource-tabs {
    
     display: flex;
     gap: 4px;
    
     margin: 8px 0 8px 8px;
    
    }
    .resource-tab {
    
     background: #123;
     color: white;
    
     border: 1px solid #444;
    
     border-radius: 6px;
    
     padding: 8px 12px;
     cursor: pointer;
    
     transition:
      background 0.2s,
      border-color 0.2s;
    
    }
    
    .resource-tab.active {
    
     background:
     linear-gradient(
     135deg,
     var(--primary),
     var(--secondary)
     );
    
    }    
    
    .fullscreen-btn {
        position: absolute;
        top: 12px;
        right: 12px;
        background: rgba(15, 23, 42, 0.85);
        color: white;
        border: 1px solid rgba(255, 255, 255, 0.3);
        padding: 6px 12px;
        border-radius: 6px;
        cursor: pointer;
        font-size: 12px;
        font-family: "Segoe UI", Arial, sans-serif;
        z-index: 9999;
        transition: background 0.2s, border-color 0.2s;
        box-shadow: 0 4px 12px rgba(0,0,0,0.5);
    }
    .fullscreen-btn:hover {
        background: rgba(0, 180, 255, 0.9);
        border-color: rgba(255, 255, 255, 0.7);
    }

    @media (max-width: 900px) {
        .studio-workspace {
            flex-direction: column;
            height: 800px;
        }
        #left-pane, .preview-container {
            width: 100%;
            height: 50%;
        }
    }
.console-panel {

    display: flex;

    flex-direction: column;

    background: #0f172a;

    border-radius: 0;

    border-top: 1px solid rgba(255,255,255,0.1);

    overflow: hidden;

    grid-column: 1 / 3;
    grid-row: 2;
}    
    .console-title {
        padding: 10px 15px;
        background: rgba(255,255,255,0.05);
        font-weight: bold;
        color: #5070a0;
        border-bottom: 1px solid rgba(255,255,255,0.1);
    }
.console-output {

    flex: 1;

    padding: 15px;

    color: #ff9090;

    overflow-y: auto;

    white-space: pre-wrap;

    min-height: 0;
}

.snippet-panel {
        margin-top: 15px;
        width: 100%;
        background: linear-gradient(
            180deg,
            #0d1f22,
            #10272c
        );
        border-radius: 10px;
        border: 1px solid rgba(60,220,200,0.25);
        overflow: hidden;
    
        box-shadow:
            inset 0 1px 0 rgba(255,255,255,0.04),
            0 0 20px rgba(0,200,180,0.08);
    }
.snippet-title {

    padding: 10px 15px;

    background: rgba(255,255,255,0.05);

    color: #00a598;

    font-weight: bold;

    border-bottom: 1px solid rgba(255,255,255,0.1);

    text-align: left;
}
    .snippet-toolbar {
        display:flex;
        gap:8px;
        padding:10px;
    
        background:#13292d;
    
        border-bottom: 1px solid rgba(60,220,200,0.15);
    }
    #snippetPreview,
    #templatePreview {
        padding:15px;
    
        font-family:Consolas, monospace;
        font-size:13px;
    
        background:#0f1d20;
        color:#d7fff8;
    
        white-space:pre-wrap;
        text-align:left;
        line-height:1.45;
    
        overflow:hidden;
    }
    .toolbar {
        background: #252525;
        display: flex;
        align-items: center;
        gap: 8px;
        padding: 0;
    }
    .load-button,
    .glscene-button,
    .run-button,
    .reset-button {
        opacity: 0.5;
        flex: 1;
        min-width: 0;
    }
    .reset-button {
        padding: 12px;
        background: linear-gradient(
            135deg,
            #de7043,
            #ce4948
        );
        color: white;
        border: none;
        cursor: pointer;
        font-weight: bold;
        font-family: "Segoe UI", Arial, sans-serif;
        transition: opacity 0.2s;
    }
    .reset-button:hover {
        opacity: 0.8;
    }
    .footer {
        margin-top: 80px;
        padding: 30px;
        text-align: center;
        background: rgba(0,0,0,0.25);
        border-top: 1px solid rgba(255,255,255,0.1);
    }
    .footer-title {
        font-size: 1.1rem;
        font-weight: 600;
        margin-bottom: 10px;
    }
    .footer-copy {
        margin-top: 15px;
        opacity: 0.7;
        font-size: 0.85rem;
    }
