.gdt-wrap{
    --bg:#0d1624;
    --panel:#152238;
    --panel2:#1d2d47;
    --border:#344a68;
    --text:#f6f9fd;
    --muted:#aebdd0;
    --accent:#4d78ff;
    color:var(--text);
    padding-bottom:36px;
}
.gdt-header{
    background:var(--bg);
    border:1px solid #1f314a;
    border-radius:12px;
    padding:20px 22px;
    margin-bottom:14px;
}
.gdt-header h1{margin:0 0 5px;color:#fff;font-size:28px}
.gdt-header h1 span{
    font-size:12px;
    background:#50a6ff;
    color:#07111f;
    padding:4px 8px;
    border-radius:5px;
    vertical-align:middle;
}
.gdt-header p{margin:0;color:var(--muted)}

.gdt-grid{
    display:flex;
    align-items:flex-start;
    gap:14px;
    width:100%;
    min-width:0;
}
.gdt-controls{
    flex:0 0 360px;
    width:360px;
    min-width:0;
    display:flex;
    flex-direction:column;
    gap:12px;
    position:sticky;
    top:12px;
    max-height:calc(100vh - 24px);
    overflow-y:auto;
    overflow-x:hidden;
    padding-right:4px;
    scrollbar-gutter:stable;
}
.gdt-preview-panel{
    flex:1 1 auto;
    min-width:0;
    height:calc(100vh - 24px);
    max-height:calc(100vh - 24px);
    position:sticky;
    top:12px;
    display:flex;
    flex-direction:column;
    padding:14px;
    background:var(--panel);
    border:1px solid var(--border);
    border-radius:12px;
    overflow:hidden;
}
.gdt-card{
    padding:15px;
    background:var(--panel);
    border:1px solid var(--border);
    border-radius:12px;
}
.gdt-card h2{margin:0 0 13px;color:#fff;font-size:18px}
.gdt-card summary{
    cursor:pointer;
    color:#fff;
    font-weight:800;
    margin:-2px 0 12px;
}
.gdt-toolbar{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:14px;
    margin-bottom:12px;
    flex:0 0 auto;
}
.gdt-toolbar>div:first-child{display:grid}
.gdt-toolbar span{color:var(--muted);font-size:13px}
.gdt-view-switch{display:flex;flex-wrap:wrap;gap:5px}
.gdt-view{
    border:1px solid var(--border);
    background:#101b2c;
    color:var(--muted);
    padding:8px 11px;
    border-radius:7px;
    cursor:pointer;
}
.gdt-view.active{background:var(--accent);color:#fff}
.gdt-canvas-wrap{
    flex:1 1 auto;
    min-width:0;
    min-height:0;
    display:flex;
    align-items:center;
    justify-content:center;
    padding:14px;
    background:#0b1320;
    border:1px solid var(--border);
    border-radius:10px;
    overflow:hidden;
}
#gdt-canvas{
    display:block;
    max-width:100%;
    max-height:100%;
    width:auto;
    height:auto;
    margin:auto;
    background:#f5f6f7;
    box-shadow:0 8px 25px rgba(0,0,0,.45);
    border-radius:8px;
}
.gdt-downloads{
    display:flex;
    flex-wrap:wrap;
    gap:8px;
    margin-top:12px;
    flex:0 0 auto;
}
.gdt-stats{
    display:grid;
    grid-template-columns:repeat(4,minmax(0,1fr));
    gap:10px;
    margin-top:12px;
    flex:0 0 auto;
}
.gdt-stat{
    background:#0d1a2c;
    border:1px solid var(--border);
    border-radius:10px;
    padding:12px 14px;
}
.gdt-stat strong{display:block;color:#fff;font-size:18px;margin-bottom:4px}
.gdt-stat span{display:block;color:var(--muted);font-size:12px}
.gdt-field{
    display:flex;
    flex-direction:column;
    gap:6px;
    margin-bottom:11px;
    color:#edf4fc;
    font-size:12px;
    font-weight:650;
}
.gdt-field input,.gdt-field select{
    width:100%;
    min-height:40px;
    padding:9px 10px;
    border:1px solid var(--border);
    border-radius:8px;
    background:var(--panel2);
    color:#fff;
    font:inherit;
}
.gdt-field input[type="color"]{padding:4px;height:42px}
.gdt-field span{display:flex;align-items:center;gap:7px}
.gdt-row{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.gdt-check{display:flex;align-items:center;gap:8px;color:#edf4fc;font-size:13px;margin-bottom:11px}
.gdt-mini-button{width:100%}.gdt-help{margin:0 0 10px;color:var(--muted);font-size:11px;line-height:1.45}.gdt-text-grid{display:grid;grid-template-columns:1.15fr .8fr .8fr .8fr;gap:6px;align-items:center;margin-bottom:10px}.gdt-text-grid strong,.gdt-text-grid span{font-size:11px;color:#dfe9f6}.gdt-text-grid input{width:100%;min-width:0;height:36px;padding:6px;border:1px solid var(--border);border-radius:7px;background:var(--panel2);color:#fff}#gdt-canvas.gdt-text-ready{cursor:move}#gdt-canvas.gdt-artwork-ready{cursor:grab}#gdt-canvas.gdt-artwork-dragging{cursor:grabbing}

@media(max-width:1100px){
    .gdt-stats{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(max-width:900px){
    .gdt-grid{display:block}
    .gdt-controls{
        position:static;
        width:100%;
        max-height:none;
        overflow:visible;
        display:grid;
        grid-template-columns:repeat(2,minmax(0,1fr));
        margin-bottom:14px;
        padding-right:0;
    }
    .gdt-preview-panel{
        position:static;
        width:100%;
        height:auto;
        max-height:none;
        min-height:700px;
    }
    .gdt-canvas-wrap{min-height:520px;overflow:auto}
}
@media(max-width:650px){
    .gdt-controls,.gdt-row,.gdt-stats{grid-template-columns:1fr}
    .gdt-toolbar{align-items:flex-start;flex-direction:column}
    .gdt-preview-panel{min-height:620px}
    .gdt-canvas-wrap{min-height:420px}
}

/* Laser Tools Hub standalone and light visual system */
.tool-cake-topper-studio > .cake-topper-container{
    width:min(1760px,calc(100% - 28px));
    max-width:none;
}
.tool-cake-topper-studio .gdt-wrap{
    --bg:#ffffff;
    --panel:#ffffff;
    --panel2:#ffffff;
    --border:#dce4ef;
    --text:#14213a;
    --muted:#65748b;
    --accent:#5b7cff;
    color:var(--text);
}
.tool-cake-topper-studio .gdt-header,
.tool-cake-topper-studio .gdt-card,
.tool-cake-topper-studio .gdt-preview-panel{
    border-color:#dce4ef;
    background:#ffffff;
    box-shadow:0 10px 30px rgba(9,28,56,.05);
}
.tool-cake-topper-studio .gdt-header h1,
.tool-cake-topper-studio .gdt-card h2,
.tool-cake-topper-studio .gdt-card summary,
.tool-cake-topper-studio .gdt-toolbar strong,
.tool-cake-topper-studio .gdt-stat strong{color:#14213a}
.tool-cake-topper-studio .gdt-header p,
.tool-cake-topper-studio .gdt-toolbar span,
.tool-cake-topper-studio .gdt-help,
.tool-cake-topper-studio .gdt-stat span{color:#65748b}
.tool-cake-topper-studio .gdt-field,
.tool-cake-topper-studio .gdt-check,
.tool-cake-topper-studio .gdt-text-grid strong,
.tool-cake-topper-studio .gdt-text-grid span{color:#26364f}
.tool-cake-topper-studio .gdt-field input,
.tool-cake-topper-studio .gdt-field select,
.tool-cake-topper-studio .gdt-text-grid input{
    border-color:#ccd6e4;
    background:#fff;
    color:#14213a;
}
.tool-cake-topper-studio .gdt-view{border-color:#dce4ef;background:#f8fafc;color:#65748b}
.tool-cake-topper-studio .gdt-view.active{border-color:#5b7cff;background:#5b7cff;color:#fff}
.tool-cake-topper-studio .gdt-canvas-wrap{border-color:#dce4ef;background:#f1f5f9}
.tool-cake-topper-studio .gdt-stat{border-color:#dce4ef;background:#f8fafc}
.tool-cake-topper-studio .gdt-output-lock{
    margin-bottom:14px;
    padding:14px 16px;
    border:1px solid #f3c7cd;
    border-radius:12px;
    background:#fff5f6;
    color:#8f1d2c;
    font-size:13px;
    font-weight:700;
}
@media(max-width:700px){
    .tool-cake-topper-studio > .cake-topper-container{width:calc(100% - 20px)}
}
