/* ===========================================================================
   Designing page — search box styles.
   Kept in its own file so it can never interfere with the page's own
   <style> block (the page prints a very large amount of inline markup).
   =========================================================================== */
.dg-search{max-width:760px;margin:0 auto 26px;position:relative}
.dg-search-box{display:flex;align-items:center;gap:10px;background:var(--card);border:1px solid var(--border2);border-radius:40px;padding:0 16px;height:50px;box-shadow:0 4px 16px rgba(16,24,40,.06)}
.dg-search-box:focus-within{border-color:var(--gold);box-shadow:0 6px 22px rgba(190,129,43,.18)}
.dg-search-box i{color:var(--muted);font-size:14px}
.dg-search-box input{flex:1;border:0;background:none;outline:none;font:15px Arial;color:var(--text);height:100%;min-width:0}
/* hide the browser's own clear glyph — we draw our own vector cross */
.dg-search-box input::-webkit-search-cancel-button,
.dg-search-box input::-webkit-search-cancel-button:hover,
.dg-search-box input::-webkit-search-cancel-button:active{display:none;-webkit-appearance:none;appearance:none}
.dg-search-box input::-ms-clear{display:none;width:0;height:0}
.dg-search-box input::-ms-reveal{display:none;width:0;height:0}
/* the clear (x) button — a clean vector cross, always visible when there is text */
.dg-search-box .dg-search-clear{border:0;background:rgba(255,255,255,.14);color:#dbe3f0;width:26px;height:26px;border-radius:50%;cursor:pointer;display:grid;place-items:center;flex:none;padding:0;line-height:0;transition:background .15s,color .15s}
.dg-search-box .dg-search-clear svg{display:block;pointer-events:none}
.dg-search-box .dg-search-clear:hover{background:rgba(255,255,255,.26);color:#fff}
.dg-search-box .dg-search-clear:focus-visible{outline:2px solid var(--gold);outline-offset:2px}
.dg-search-box .dg-search-clear[hidden]{display:none}
.dg-search-hint{font-size:11.5px;color:var(--muted);margin:7px 4px 0}
.dg-search-results{position:absolute;z-index:40;left:0;right:0;top:56px;background:var(--card);border:1px solid var(--border2);border-radius:14px;box-shadow:0 14px 40px rgba(16,24,40,.16);max-height:min(62vh,560px);overflow:auto;padding:6px}
.dg-sr-group{padding:12px 12px 5px;font-size:10.5px;font-weight:800;letter-spacing:.1em;text-transform:uppercase;color:var(--muted);border-top:1px solid var(--border)}
.dg-sr-group:first-child{border-top:0}
.dg-sr-meta{color:var(--text)}
.dg-sr-meta strong{color:var(--text)}
/* THEME-AWARE colours — the site is dark, so every surface here must come
   from the theme variables (a hard-coded light background made the white
   result text invisible on hover).
   The results are TEXT ONLY — no thumbnail, so the row is a clean text line. */
.dg-sr-item{display:flex;align-items:center;gap:11px;padding:10px 12px;border-radius:10px;text-decoration:none;color:var(--text);border:1px solid transparent;transition:background .15s,border-color .15s}
.dg-sr-item:hover,.dg-sr-item:focus-visible{background:rgba(237,152,36,.16);border-color:rgba(237,152,36,.5);outline:none;color:var(--text)}
.dg-sr-item:hover .dg-sr-meta strong,.dg-sr-item:focus-visible .dg-sr-meta strong{color:#fff}
.dg-sr-item:hover .dg-sr-meta small,.dg-sr-item:focus-visible .dg-sr-meta small{color:#dbe3f0}
/* text selection inside the results must also be readable on the dark theme */
.dg-sr-item::selection,.dg-sr-meta::selection,.dg-sr-meta strong::selection,.dg-sr-meta small::selection{background:rgba(237,152,36,.55);color:#fff}
/* the thumbnail box keeps the design's own aspect ratio so the colours,
   background and artwork match the real design exactly */
.dg-sr-thumb{flex:none;border-radius:6px;overflow:hidden;border:1px solid var(--border);background:#fff;position:relative;display:block;isolation:isolate;contain:paint;box-shadow:0 1px 3px #0003}
.dg-sr-thumb .doc{position:absolute;left:0;top:0;transform-origin:top left;pointer-events:none;max-width:none;box-shadow:none}
/* on a narrow phone the row still needs room for the name */
@media(max-width:570px){.dg-sr-item{padding:8px 10px;gap:9px}.dg-sr-thumb{max-width:44px}}
.dg-sr-thumb>div{position:absolute;left:0;top:0;transform-origin:top left}
.dg-sr-meta{min-width:0;flex:1;line-height:1.35}
.dg-sr-meta strong::before{content:'\25CF';color:var(--gold,#f5b301);font-size:9px;margin-right:8px;vertical-align:middle}
.dg-sr-meta strong{display:block;font-size:13.5px;line-height:1.3}
.dg-sr-meta small{display:block;color:var(--muted);font-size:11px;margin-top:2px}
.dg-sr-empty{padding:18px 12px;text-align:center;color:var(--muted);font-size:12.5px}
.dg-sr-empty b{color:var(--text)}


/* ===========================================================================
   Long-form guide under the designs of each tab (designing.php).
   Fills the whole content column — the same width as the design grid above it,
   so nothing is left stranded at the sides.  On wide screens the four sections
   sit in two columns, which keeps each line of text a comfortable length
   instead of running edge to edge across 1300px.
   =========================================================================== */
.dg-guide{width:100%;max-width:none;margin:52px 0 0;padding:36px 38px 32px;background:var(--card);border:1px solid var(--border);border-radius:20px;box-shadow:0 10px 34px #0b122010;box-sizing:border-box}
.dg-guide-head{padding-bottom:22px;border-bottom:1px solid var(--border)}
.dg-guide-kicker{display:inline-block;font-size:10.5px;font-weight:800;letter-spacing:.16em;text-transform:uppercase;color:#c78321;background:#c7832114;border:1px solid #c7832133;border-radius:20px;padding:4px 11px;margin-bottom:13px}
.dg-guide h2{font-size:clamp(21px,2.3vw,28px);line-height:1.24;margin:0 0 12px;color:var(--text);letter-spacing:-.01em;max-width:34ch}
.dg-guide-lead{font-size:15px;line-height:1.74;color:var(--muted);margin:0;max-width:96ch}

/* four sections: single column on narrow screens, two even columns above 1000px */
.dg-guide-body{display:grid;grid-template-columns:1fr;gap:26px 44px;margin-top:28px;align-items:start}
.dg-guide-sec{min-width:0}
.dg-guide-sec h3{font-size:15.5px;line-height:1.35;margin:0 0 8px;color:var(--text);font-weight:800}
.dg-guide-sec h3:before{content:'';display:inline-block;width:5px;height:5px;border-radius:50%;background:#c78321;margin-right:9px;vertical-align:middle}
.dg-guide-sec p{font-size:14px;line-height:1.78;color:var(--muted);margin:0}

/* questions keep their own full-width strip under the sections */
.dg-guide-faq{margin-top:32px;padding-top:26px;border-top:1px solid var(--border);display:grid;grid-template-columns:1fr;gap:9px;align-items:start}
.dg-guide-faq h3{grid-column:1/-1;font-size:15.5px;margin:0 0 4px;color:var(--text);font-weight:800}
.dg-faq{border:1px solid var(--border2);border-radius:11px;background:var(--bg2);overflow:hidden;min-width:0}
.dg-faq summary{cursor:pointer;list-style:none;padding:13px 16px;font-size:13.5px;font-weight:700;color:var(--text);display:flex;align-items:center;gap:10px}
.dg-faq summary::-webkit-details-marker{display:none}
.dg-faq summary:before{content:'\f078';font-family:'Font Awesome 6 Free';font-weight:900;font-size:10px;color:#c78321;transition:transform .15s;flex:none}
.dg-faq[open] summary:before{transform:rotate(90deg)}
.dg-faq summary:focus-visible{outline:2px solid var(--gold);outline-offset:-2px}
.dg-faq p{margin:0;padding:0 16px 14px 35px;font-size:13.5px;line-height:1.72;color:var(--muted)}

@media(min-width:1001px){
 .dg-guide-body{grid-template-columns:repeat(2,minmax(0,1fr))}
 .dg-guide-faq{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(max-width:1000px){
 .dg-guide{padding:30px 26px 26px}
 .dg-guide-lead{font-size:14.5px}
}
@media(max-width:760px){
 .dg-guide{margin-top:34px;padding:24px 18px 20px;border-radius:16px}
 .dg-guide-lead{font-size:13.5px}
 .dg-guide-body{gap:20px;margin-top:22px}
 .dg-guide-sec p{font-size:13px;line-height:1.72}
 .dg-guide-faq{margin-top:26px;padding-top:22px}
 .dg-faq summary{font-size:13px;padding:11px 13px}
 .dg-faq p{font-size:13px;padding:0 13px 12px 32px}
}
@media(max-width:570px){
 .dg-guide{width:auto;margin-left:-1px;margin-right:-1px}
}
