/* Configurateur AMBER//OPS : barre latérale ambrée, panneaux à coins coupés, aucun arrondi */
@import url("fonts.css");
:root {
  --bg0: #08080b; --bg1: #0e0e13; --bg2: #13131a; --bg3: #1a1a23; --line: #22222c; --line2: #32323e;
  --text: #ece9e2; --text2: #bdb9b1; --muted: #85828c; --dim: #55535e;
  --accent: #ffb000; --accent-soft: #2a1f06; --accent-lo: #8a5e00; --ink: #1c1200;
  --side-top: #ffb627; --side-bottom: #ef8a00; --side-edge: #b86a00; --side-ink: #241600; --slot: #0e0e13;
  --ui: "Chakra Petch", "Bahnschrift", "Segoe UI", Arial, sans-serif; --mono: "Share Tech Mono", Consolas, monospace;
  color-scheme: dark;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body { min-height: 100vh; font: 400 14px/1.5 var(--ui); color: var(--text);
  background: radial-gradient(circle at 22% -5%, rgb(255 176 0 / .12), transparent 45%), radial-gradient(circle at 100% 110%, rgb(0 229 255 / .06), transparent 40%), var(--bg0); }
body::before { content: ''; position: fixed; inset: 0; pointer-events: none; opacity: .14;
  background: repeating-linear-gradient(90deg, var(--line2) 0 1px, transparent 1px 112px), repeating-linear-gradient(0deg, var(--line2) 0 1px, transparent 1px 112px),
    repeating-linear-gradient(90deg, rgb(50 50 62 / .5) 0 1px, transparent 1px 28px), repeating-linear-gradient(0deg, rgb(50 50 62 / .5) 0 1px, transparent 1px 28px); }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; }
:focus-visible { outline: 1.5px dashed var(--accent); outline-offset: 2px; }
.mono { font-family: var(--mono); }

.app { position: relative; display: grid; grid-template-columns: 112px minmax(0, 1fr); min-height: 100vh; }
.side { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; align-items: center; padding: 18px 8px; gap: 6px; color: var(--side-ink);
  background: linear-gradient(90deg, rgb(255 255 255 / .16), transparent 50%), linear-gradient(var(--side-top), var(--side-bottom));
  box-shadow: inset -2px 0 0 var(--side-edge), inset -3px 0 0 rgb(255 255 255 / .27); }
.logo { width: 66px; height: 66px; display: grid; place-content: center; text-align: center; background: var(--slot); color: var(--accent); margin-bottom: 12px;
  clip-path: polygon(0 0, calc(100% - 12px) 0, 100% 12px, 100% 100%, 12px 100%, 0 calc(100% - 12px)); filter: drop-shadow(0 3px 6px rgb(110 60 0 / .5)); }
.logo b { font: 700 24px/1 var(--ui); letter-spacing: 1px; }
.logo small { font: 9px/1.4 var(--mono); opacity: .7; }
.nav { display: flex; flex-direction: column; gap: 5px; width: 100%; overflow-y: auto; }
.nav small { font: 600 9.5px/1 var(--ui); letter-spacing: 1.6px; text-transform: uppercase; opacity: .65; margin: 10px 0 2px 6px; }
.nav__btn { position: relative; width: 100%; padding: 12px 6px; font: 700 10.5px/1.1 var(--ui); letter-spacing: 1.2px; text-transform: uppercase; text-align: center;
  clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 10px, 100% 100%, 10px 100%, 0 calc(100% - 10px)); }
.nav__btn:hover { background: rgb(255 255 255 / .27); }
.nav__btn[aria-current="page"] { background: var(--slot); color: var(--accent); box-shadow: inset 3px 0 0 var(--accent); }
.side__foot { margin-top: auto; display: flex; flex-direction: column; align-items: center; gap: 6px; font: 9.5px/1 var(--mono); opacity: .7; }
.hazard { width: 80px; height: 8px; background: repeating-linear-gradient(-45deg, var(--side-ink) 0 6px, transparent 6px 12px); }

.main { display: flex; flex-direction: column; gap: 18px; padding: 22px 26px 40px; min-width: 0; }
.card { position: relative; isolation: isolate; padding: 16px 20px 20px; background: var(--line2); --c: 16px;
  clip-path: polygon(0 0, calc(100% - var(--c)) 0, 100% var(--c), 100% 100%, var(--c) 100%, 0 calc(100% - var(--c))); display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.card::before { content: ''; position: absolute; inset: 1px; z-index: -1; clip-path: inherit; background: linear-gradient(var(--bg1), color-mix(in srgb, var(--bg1) 60%, var(--bg0))); }
.card::after { content: ''; position: absolute; left: 0; top: 0; width: 60%; height: 2px; background: linear-gradient(90deg, var(--accent), transparent); }
.hero { padding: 20px 26px; }
.prompt { font: 12px/1.4 var(--mono); color: var(--text2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.prompt b { font-weight: 400; color: var(--accent); }
.prompt i { font-style: normal; color: var(--muted); }
.htitle { font: 700 clamp(30px, 6vw, 44px)/1 var(--ui); letter-spacing: 1px; }
.htitle b { color: var(--accent); }
.sub { color: var(--muted); max-width: 720px; }
.head { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.head__sep { font: 12px var(--mono); color: var(--dim); }
.head__title { font: 700 13.3px/1 var(--ui); letter-spacing: 2.6px; text-transform: uppercase; }
.head__cmd { font: 12px var(--mono); color: var(--muted); }
.label { font: 600 11.3px/1.2 var(--ui); letter-spacing: 1.6px; text-transform: uppercase; color: var(--text2); }
.hint { font: 12px/1.5 var(--mono); color: var(--muted); }
.hint b { color: var(--accent); font-weight: 400; }

.split { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 18px; align-items: start; }
.screen { position: relative; width: 100%; overflow: hidden; border: 1px solid var(--line2); background:
  repeating-conic-gradient(var(--bg2) 0 25%, var(--bg1) 0 50%) 0 0 / 24px 24px; }
.screen iframe { position: absolute; left: 0; top: 0; border: 0; transform-origin: 0 0; }
.row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.field { display: flex; flex-direction: column; gap: 6px; border: 0; min-width: 0; }
fieldset.field { gap: 8px; }
.input { width: 100%; min-width: 0; height: 36px; padding: 0 10px; background: var(--bg2); border: 1px solid var(--line2); color: var(--text); font-size: 13.3px; }
.input:hover { border-color: var(--dim); }
.input:focus { outline: none; border-color: var(--accent); }
.url .row .input { flex: 1; font-size: 12px; }
.btn { min-height: 34px; padding: 0 14px; font: 700 12px/1 var(--ui); letter-spacing: 1.4px; text-transform: uppercase; background: var(--bg3); border: 1px solid var(--line2); color: var(--text2); }
.btn:hover { border-color: var(--accent); color: var(--accent); }
.btn--acc { background: var(--accent); color: var(--ink); border-color: var(--accent); }
.btn--acc:hover { color: var(--ink); filter: brightness(1.1); }
.swatches { display: flex; flex-wrap: wrap; gap: 6px; }
.swatches label { display: flex; align-items: center; gap: 7px; padding: 6px 10px; border: 1px solid var(--line2); background: var(--bg2); cursor: pointer; font-size: 12.5px; color: var(--text2); }
.swatches label:has(input[type=radio]:checked) { border-color: var(--accent); background: var(--accent-soft); color: var(--text); }
.swatches input[type=radio] { position: absolute; opacity: 0; pointer-events: none; }
.swatches i { width: 14px; height: 14px; display: block; clip-path: polygon(0 0, 75% 0, 100% 25%, 100% 100%, 25% 100%, 0 75%); }
[data-c=amber] { background: #ffb000; } [data-c=cyan] { background: #00e5ff; } [data-c=lime] { background: #e8ff47; }
[data-c=pink] { background: #ff2d6f; } [data-c=violet] { background: #b18cff; } [data-c=green] { background: #2ef2a0; }
.swatches input[type=color] { width: 18px; height: 18px; border: 0; padding: 0; background: none; cursor: pointer; }
.check { display: flex; align-items: center; gap: 10px; color: var(--text2); cursor: pointer; }
.check input { position: absolute; opacity: 0; }
.check i { width: 16px; height: 16px; flex: none; border: 1px solid var(--line2); background: var(--bg2); display: grid; place-items: center; }
.check input:checked + i::after { content: ''; width: 8px; height: 8px; background: var(--accent); }
.check input:focus-visible + i { outline: 1.5px dashed var(--accent); outline-offset: 2px; }

.all { display: flex; flex-direction: column; gap: 6px; }
.all__row { display: grid; grid-template-columns: 150px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 8px 10px; background: var(--bg2); border: 1px solid var(--line); }
.all__row code { font: 11.5px var(--mono); color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.toast { position: fixed; right: 22px; bottom: 22px; padding: 12px 18px; background: var(--bg1); border-left: 3px solid var(--accent); font: 700 12px/1 var(--ui); letter-spacing: 1.6px; color: var(--accent);
  opacity: 0; transform: translateX(60px); transition: opacity .22s, transform .26s; pointer-events: none; }
.toast.is-on { opacity: 1; transform: none; }

@media (max-width: 1180px) { .split { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 720px) {
  .app { grid-template-columns: minmax(0, 1fr); }
  .side { position: sticky; z-index: 5; height: auto; flex-direction: row; padding: 8px 12px; gap: 10px; box-shadow: inset 0 -2px 0 var(--side-edge); }
  .logo { width: 46px; height: 46px; margin: 0; flex: none; }
  .logo b { font-size: 17px; } .logo small { display: none; }
  .nav { flex-direction: row; overflow-x: auto; scrollbar-width: none; }
  .nav small, .side__foot { display: none; }
  .nav__btn { width: auto; flex: none; padding: 12px 12px; }
  .main { padding: 16px; }
  .all__row { grid-template-columns: minmax(0, 1fr) auto; }
  .all__row code { grid-column: 1 / -1; grid-row: 2; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
.preview .url, .preview .card:has(> .all) { display: none; }
.preview-note { border-left: 3px solid var(--accent); padding: 10px 14px; background: var(--accent-soft); color: var(--text); }
