.gdh-wrap{--bg:#0d1624;--panel:#152238;--panel2:#1d2d47;--border:#344a68;--text:#f6f9fd;--muted:#aebdd0;--accent:#4d78ff;--danger:#e65361;color:var(--text)}
.gdh-header{display:flex;align-items:center;justify-content:space-between;gap:15px;background:var(--bg);border:1px solid #1f314a;border-radius:12px;padding:20px 22px;margin-bottom:14px}
.gdh-header h1{margin:0 0 5px;color:#fff;font-size:28px}
.gdh-header h1 span{font-size:12px;background:#50a6ff;color:#07111f;padding:4px 8px;border-radius:5px;vertical-align:middle}
.gdh-header p{margin:0;color:var(--muted)}
.gdh-grid{display:grid;grid-template-columns:340px minmax(0,1fr);gap:14px;align-items:start}
.gdh-sidebar,.gdh-main{display:flex;flex-direction:column;gap:14px}
.gdh-sidebar{position:sticky;top:14px;max-height:calc(100vh - 28px);overflow:auto;padding-right:4px}
.gdh-main{position:sticky;top:14px;max-height:calc(100vh - 28px);overflow:auto}
.gdh-orientation-actions{margin:-3px 0 12px}
.gdh-text-toggles{margin:12px 0 0}
.gdh-card{padding:16px;background:var(--panel);border:1px solid var(--border);border-radius:12px}
.gdh-card h2{margin:0 0 14px;color:#fff;font-size:18px}
.gdh-field{display:flex;flex-direction:column;gap:6px;margin-bottom:12px;color:#edf4fc;font-weight:650;font-size:12px}
.gdh-field input,.gdh-field select,.gdh-field textarea{width:100%;min-height:40px;background:var(--panel2);color:#fff;border:1px solid var(--border);border-radius:8px;padding:9px 11px;font:inherit}
.gdh-field textarea{min-height:88px;resize:vertical}
.gdh-field span{display:flex;align-items:center;gap:8px}
.gdh-row{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.gdh-toggle-grid{display:grid;gap:8px;margin-bottom:10px}
.gdh-check{display:flex;align-items:center;gap:8px;font-size:13px;color:#edf4fc}
.gdh-actions{display:flex;flex-wrap:wrap;gap:8px}
.gdh-preview-head,.gdh-piece-head{display:flex;justify-content:space-between;align-items:center;gap:14px;margin-bottom:12px}
.gdh-preview-head p,.gdh-piece-head p{margin:5px 0 0;color:var(--muted)}
.gdh-page-nav{display:flex;align-items:center;gap:8px}
.gdh-canvas-wrap{padding:14px;background:#0b1320;border:1px solid var(--border);border-radius:10px;overflow:auto;text-align:center}
#gdh-canvas{display:block;max-width:100%;height:auto;margin:auto;background:repeating-conic-gradient(#e7e9ed 0 25%,#fff 0 50%) 50%/18px 18px;box-shadow:0 8px 25px rgba(0,0,0,.45)}
.gdh-piece-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.gdh-piece{padding:12px;border:1px solid var(--border);border-radius:10px;background:#101b2c}
.gdh-piece strong{display:block;margin-bottom:8px;color:#fff}
.gdh-piece textarea{width:100%;min-height:72px;padding:9px 10px;border:1px solid #465d7d;border-radius:8px;background:#1b2d49;color:#fff;font:inherit;resize:vertical}
.gdh-piece small{display:block;margin-top:7px;color:var(--muted)}
@media(max-width:1200px){.gdh-grid{grid-template-columns:1fr}.gdh-sidebar{position:static;display:grid;grid-template-columns:1fr 1fr;gap:14px;max-height:none;overflow:visible;padding-right:0}.gdh-main{position:static;max-height:none;overflow:visible}}
@media(max-width:760px){.gdh-sidebar,.gdh-piece-list,.gdh-row{grid-template-columns:1fr}.gdh-preview-head,.gdh-piece-head{align-items:flex-start;flex-direction:column}}

/* Laser Tools Hub light theme */
.tool-hearts-tags-studio .tool-shell-inner{width:min(1760px,calc(100% - 28px));max-width:none}
.tool-hearts-tags-studio .gdh-wrap{--bg:#fff;--panel:#fff;--panel2:#f7f9fc;--border:#dce4ef;--text:#13213a;--muted:#64748b;--accent:#5b7cff;color:var(--text);padding-bottom:34px}
.tool-hearts-tags-studio .gdh-header{background:#fff;border-color:#dce4ef;box-shadow:0 8px 24px rgba(15,23,42,.05)}
.tool-hearts-tags-studio .gdh-header h1,.tool-hearts-tags-studio .gdh-card h2,.tool-hearts-tags-studio .gdh-piece strong{color:#13213a}
.tool-hearts-tags-studio .gdh-header h1 span{background:#dbe5ff;color:#2949b8}
.tool-hearts-tags-studio .gdh-header p,.tool-hearts-tags-studio .gdh-preview-head p,.tool-hearts-tags-studio .gdh-piece-head p,.tool-hearts-tags-studio .gdh-piece small{color:#64748b}
.tool-hearts-tags-studio .gdh-card{background:#fff;border-color:#dce4ef;box-shadow:0 8px 24px rgba(15,23,42,.04)}
.tool-hearts-tags-studio .gdh-field,.tool-hearts-tags-studio .gdh-check{color:#26364f}
.tool-hearts-tags-studio .gdh-field input,.tool-hearts-tags-studio .gdh-field select,.tool-hearts-tags-studio .gdh-field textarea,.tool-hearts-tags-studio .gdh-piece textarea{background:#f7f9fc;color:#13213a;border-color:#ced9e8}
.tool-hearts-tags-studio .gdh-piece{background:#f7f9fc;border-color:#dce4ef}
.tool-hearts-tags-studio .gdh-canvas-wrap{background:#eef3f9;border-color:#dce4ef}
.tool-hearts-tags-studio .gdh-actions .button:not(.button-outline-dark),
.tool-hearts-tags-studio #gdh-build{background:#5b7cff;border-color:#5b7cff;color:#fff}
.tool-hearts-tags-studio .tool-output-notice{width:100%;margin:0 0 2px}


/* v3.7 direct text editing and fitted sheet preview */
.tool-hearts-tags-studio .gdh-main{height:calc(100vh - 28px);max-height:calc(100vh - 28px);overflow:hidden}
.tool-hearts-tags-studio .gdh-main>.gdh-card:first-child{height:100%;min-height:0;display:flex;flex-direction:column;overflow:hidden}
.tool-hearts-tags-studio .gdh-canvas-wrap{position:relative;flex:1 1 auto;min-height:0;overflow:hidden;display:flex;align-items:center;justify-content:center;padding:10px}
.tool-hearts-tags-studio #gdh-canvas{max-width:100%;max-height:100%;width:auto;height:auto;object-fit:contain;cursor:text}
.tool-hearts-tags-studio .gdh-preview-head,.tool-hearts-tags-studio .gdh-actions,.tool-hearts-tags-studio .tool-output-notice{flex-shrink:0}
.tool-hearts-tags-studio .gdh-inline-editor{position:absolute;z-index:8;transform:translate(-50%,-50%);min-width:100px;min-height:42px;padding:6px 8px;border:2px solid #5b7cff;border-radius:8px;background:rgba(255,255,255,.97);color:#13213a;font:700 16px/1.2 Arial;text-align:center;resize:none;box-shadow:0 8px 24px rgba(15,23,42,.22)}
.tool-hearts-tags-studio .gdh-inline-editor:focus{outline:3px solid rgba(91,124,255,.2)}
@media(max-width:1200px){.tool-hearts-tags-studio .gdh-main{height:auto;max-height:none;overflow:visible}.tool-hearts-tags-studio .gdh-main>.gdh-card:first-child{height:auto}.tool-hearts-tags-studio .gdh-canvas-wrap{min-height:520px}}
