/* =========================================================================
   Kopak Tegels — stijl
   Palet: porselein, kobalt (Delfts blauw), inkt, voeg-grijs, eigeel (azulejo)
   ========================================================================= */
:root {
  --porcelain: #F7F8FA;
  --white: #FFFFFF;
  --glaze: #E6EBF8;
  --cobalt: #1D3FA8;
  --cobalt-dark: #15307F;
  --ink: #0F1A36;
  --ink-2: #47506B;
  --grout: #D4D8E0;
  --yolk: #F3B524;
  --rose: #C2385B;
  --ok: #1F7A4D;
  --warn: #9A6200;
  --bad: #B3261E;

  --f-display: "Bricolage Grotesque", "Avenir Next", "Segoe UI", sans-serif;
  --f-body: "Instrument Sans", "Avenir Next", "Segoe UI", system-ui, sans-serif;

  --s-1: .25rem; --s-2: .5rem; --s-3: .75rem; --s-4: 1rem; --s-5: 1.5rem; --s-6: 2rem; --s-7: 3rem; --s-8: 4.5rem; --s-9: 7rem;
  --r-tile: 3px;      /* tegels: bijna haaks, zoals echte tegels */
  --r-ui: 10px;       /* bedieningselementen */
  --r-pill: 999px;
  --grout-line: 4px solid var(--grout);
  --max: 1240px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } }
body { margin: 0; font-family: var(--f-body); font-size: 1.0625rem; line-height: 1.55; color: var(--ink); background: var(--porcelain); }
img, canvas { max-width: 100%; display: block; }
a { color: var(--cobalt); }
h1, h2, h3, h4 { font-family: var(--f-display); line-height: 1.08; margin: 0 0 var(--s-4); letter-spacing: -0.015em; font-weight: 700; }
h1 { font-size: clamp(2.5rem, 5.5vw, 4.6rem); font-weight: 800; letter-spacing: -0.03em; font-variation-settings: "wdth" 85; }
h2 { font-size: clamp(1.9rem, 3.4vw, 2.9rem); letter-spacing: -0.025em; }
h3 { font-size: 1.3rem; }
p { margin: 0 0 var(--s-4); }
.muted { color: var(--ink-2); }
.lede { font-size: 1.2rem; color: var(--ink-2); max-width: 36em; }
:focus-visible { outline: 3px solid var(--yolk); outline-offset: 2px; }
.skip { position: absolute; left: -999px; top: 0; background: var(--ink); color: #fff; padding: var(--s-3) var(--s-4); z-index: 100; }
.skip:focus { left: var(--s-4); }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--s-5); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Knoppen ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: var(--s-2); font: 600 1rem/1 var(--f-body); padding: .95rem 1.4rem; border-radius: var(--r-ui); border: 2px solid transparent; cursor: pointer; text-decoration: none; transition: background .15s, color .15s, border-color .15s, transform .1s; white-space: nowrap; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--cobalt); color: #fff; }
.btn-primary:hover { background: var(--cobalt-dark); }
.btn-yolk { background: var(--yolk); color: var(--ink); }
.btn-yolk:hover { background: #E3A512; }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn-ghost:hover { background: var(--ink); color: #fff; }
.btn-quiet { background: var(--white); color: var(--ink); border-color: var(--grout); }
.btn-quiet:hover { border-color: var(--ink); }
.btn-sm { padding: .65rem 1rem; font-size: .95rem; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .45; cursor: not-allowed; }

/* ---------- Topbar & header ---------- */
.topbar { background: var(--ink); color: #DDE3F5; font-size: .85rem; text-align: center; padding: .45rem var(--s-4); }
.topbar p { margin: 0; }
.site-header { position: sticky; top: 0; z-index: 40; display: flex; align-items: center; justify-content: space-between; gap: var(--s-5); padding: var(--s-3) var(--s-5); background: rgba(247,248,250,.92); backdrop-filter: blur(10px); border-bottom: var(--grout-line); }
.logo { display: inline-flex; align-items: center; gap: .6rem; text-decoration: none; color: var(--ink); }
.logo-mark { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; width: 30px; height: 30px; padding: 2px; background: var(--grout); border-radius: 3px; }
.logo-mark i { background: var(--cobalt); border-radius: 1px; }
.logo-mark i:nth-child(2) { background: var(--yolk); }
.logo-mark i:nth-child(3) { background: var(--white); }
.logo-word { font: 800 1.25rem/1 var(--f-display); letter-spacing: -0.02em; }
.logo-light { color: #fff; }
.main-nav { display: flex; align-items: center; gap: var(--s-2); flex-wrap: wrap; justify-content: flex-end; }
.nav-link { color: var(--ink); text-decoration: none; font-weight: 500; padding: .5rem .7rem; border-radius: var(--r-ui); }
.nav-link:hover { background: var(--glaze); }
.nav-link.is-active { background: var(--glaze); color: var(--cobalt); }
.badge { display: inline-grid; place-items: center; min-width: 1.35rem; height: 1.35rem; padding: 0 .35rem; border-radius: var(--r-pill); background: var(--yolk); color: var(--ink); font-size: .78rem; font-weight: 700; margin-left: .2rem; }
.badge[hidden] { display: none; }
@media (max-width: 760px) {
  .site-header { flex-wrap: wrap; padding: var(--s-3) var(--s-4); }
  .main-nav { width: 100%; justify-content: flex-start; gap: 0; flex-wrap: nowrap; overflow-x: auto; }
  .main-nav .nav-link { padding: .45rem .45rem; font-size: .92rem; }
  .main-nav .btn { display: none; }
}

/* ---------- Secties: voeglijnen als structuur ---------- */
.section { padding: var(--s-9) 0; }
.section + .section { border-top: var(--grout-line); }
.section-head { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: var(--s-5); margin-bottom: var(--s-7); }
.section-head p { margin: 0; max-width: 34em; }
@media (max-width: 760px) { .section { padding: var(--s-8) 0; } .section-head { grid-template-columns: 1fr; } }

/* ---------- Hero ---------- */
.hero { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: var(--s-8); align-items: center; padding: var(--s-8) 0 var(--s-9); }
.hero-copy h1 { margin-bottom: var(--s-5); }
.hero-actions { display: flex; flex-wrap: wrap; gap: var(--s-3); margin: var(--s-6) 0 var(--s-5); }
.hero-facts { display: flex; flex-wrap: wrap; gap: var(--s-5); padding: 0; margin: 0; list-style: none; color: var(--ink-2); font-size: .95rem; }
.hero-facts strong { display: block; color: var(--ink); font: 700 1.4rem/1.1 var(--f-display); }
.hero-wall { position: relative; }
.wall-frame { background: var(--grout); padding: 0; border-radius: var(--r-tile); box-shadow: 0 30px 60px -30px rgba(15,26,54,.45); overflow: hidden; }
.wall-frame canvas { width: 100%; height: auto; }
.wall-switch { display: inline-flex; background: var(--white); border: 2px solid var(--ink); border-radius: var(--r-pill); padding: 3px; margin-bottom: var(--s-4); }
.wall-switch button { font: 600 .95rem/1 var(--f-body); border: 0; background: transparent; color: var(--ink); padding: .65rem 1.1rem; border-radius: var(--r-pill); cursor: pointer; }
.wall-switch button[aria-pressed="true"] { background: var(--ink); color: #fff; }
.wall-caption { display: flex; justify-content: space-between; gap: var(--s-4); margin-top: var(--s-3); font-size: .92rem; color: var(--ink-2); }
@media (max-width: 960px) { .hero { grid-template-columns: 1fr; gap: var(--s-6); padding-top: var(--s-6); } }

/* ---------- Stappen ---------- */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; border: var(--grout-line); border-radius: var(--r-tile); background: var(--grout); gap: 4px; padding: 0; list-style: none; margin: 0; counter-reset: step; }
.steps li { background: var(--white); padding: var(--s-6); counter-increment: step; }
.steps li::before { content: counter(step); display: grid; place-items: center; width: 2.4rem; height: 2.4rem; border-radius: var(--r-tile); background: var(--cobalt); color: #fff; font: 700 1.1rem/1 var(--f-display); margin-bottom: var(--s-5); }
.steps li:nth-child(2)::before { background: var(--yolk); color: var(--ink); }
.steps li:nth-child(3)::before { background: var(--ink); }
.steps p { margin: 0; color: var(--ink-2); }
@media (max-width: 760px) { .steps { grid-template-columns: 1fr; } }

/* ---------- Formaten ---------- */
.sizes { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s-5); align-items: end; }
.size { text-align: left; }
.size-tile { background: var(--white); border: 1px solid var(--grout); border-radius: var(--r-tile); margin-bottom: var(--s-4); position: relative; box-shadow: 0 12px 24px -18px rgba(15,26,54,.5); overflow: hidden; }
.size-tile canvas { width: 100%; height: 100%; }
.size h3 { margin-bottom: var(--s-1); }
.size .price { font: 700 1.5rem/1 var(--f-display); color: var(--cobalt); }
.staffel { margin-top: var(--s-7); display: grid; grid-template-columns: auto 1fr; gap: var(--s-5); align-items: center; background: var(--glaze); border-radius: var(--r-ui); padding: var(--s-5) var(--s-6); }
.staffel table { border-collapse: collapse; width: 100%; font-size: .98rem; }
.staffel td, .staffel th { text-align: left; padding: .4rem .8rem .4rem 0; }
.staffel th { font-weight: 600; color: var(--ink-2); }
@media (max-width: 760px) { .sizes { grid-template-columns: 1fr 1fr; } .staffel { grid-template-columns: 1fr; } }

/* ---------- Wand-galerij ---------- */
.walls-grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: var(--s-6); }
.wall-card { grid-column: span 6; text-decoration: none; color: inherit; display: block; }
.wall-card.is-wide { grid-column: span 12; }
.wall-card .wall-frame { transition: transform .25s ease; }
.wall-card:hover .wall-frame { transform: translateY(-3px); }
.wall-card h3 { margin: var(--s-4) 0 var(--s-1); }
.wall-card p { margin: 0; color: var(--ink-2); font-size: .98rem; }
.wall-meta { display: flex; flex-wrap: wrap; gap: var(--s-2); margin-top: var(--s-3); }
.chip { display: inline-flex; align-items: center; gap: .35rem; padding: .3rem .7rem; border-radius: var(--r-pill); background: var(--white); border: 1px solid var(--grout); font-size: .85rem; color: var(--ink-2); }
.chip-strong { background: var(--ink); border-color: var(--ink); color: #fff; }
@media (max-width: 860px) { .wall-card { grid-column: span 12; } }

/* Wand-detail (muren.html) */
.wall-feature { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: var(--s-7); align-items: start; padding: var(--s-8) 0; }
.wall-feature + .wall-feature { border-top: var(--grout-line); }
.wall-feature:nth-of-type(even) { grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); }
.wall-feature:nth-of-type(even) .wall-visual { order: 2; }
.wall-info dl { display: grid; grid-template-columns: auto 1fr; gap: .35rem var(--s-5); margin: var(--s-5) 0; }
.wall-info dt { color: var(--ink-2); }
.wall-info dd { margin: 0; font-weight: 600; }
.wall-info .total { font: 700 2rem/1 var(--f-display); color: var(--cobalt); margin: var(--s-3) 0 var(--s-1); }
.view-tabs { display: flex; gap: var(--s-2); margin-bottom: var(--s-3); }
.view-tabs button { font: 500 .92rem/1 var(--f-body); padding: .5rem .85rem; border-radius: var(--r-pill); border: 1px solid var(--grout); background: var(--white); cursor: pointer; color: var(--ink); }
.view-tabs button[aria-pressed="true"] { background: var(--ink); color: #fff; border-color: var(--ink); }
.room-canvas { width: 100%; height: auto; border-radius: var(--r-ui); background: #EEE; }
@media (max-width: 960px) { .wall-feature, .wall-feature:nth-of-type(even) { grid-template-columns: 1fr; } .wall-feature:nth-of-type(even) .wall-visual { order: 0; } }

/* ---------- Inspiratie ---------- */
.filters { display: flex; flex-wrap: wrap; gap: var(--s-2); margin-bottom: var(--s-6); }
.filters button { font: 500 .95rem/1 var(--f-body); padding: .6rem 1rem; border-radius: var(--r-pill); border: 1px solid var(--grout); background: var(--white); cursor: pointer; color: var(--ink); }
.filters button[aria-pressed="true"] { background: var(--cobalt); border-color: var(--cobalt); color: #fff; }
.tile-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: var(--s-5); }
.tile-card { text-decoration: none; color: inherit; }
#home-templates { grid-template-columns: repeat(6, 1fr); }
@media (max-width: 960px) { #home-templates { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 520px) { #home-templates { grid-template-columns: repeat(2, 1fr); } }
.tile-card canvas { width: 100%; aspect-ratio: 1; border-radius: var(--r-tile); box-shadow: 0 14px 26px -20px rgba(15,26,54,.6); }
.tile-card h3 { font-size: 1.05rem; margin: var(--s-3) 0 0; }
.tile-card span { font-size: .9rem; color: var(--cobalt); }

/* ---------- Zakelijk ---------- */
.biz { background: var(--ink); color: #E8ECF8; border-radius: var(--r-ui); padding: var(--s-8) var(--s-7); display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--s-7); align-items: center; }
.biz h2 { color: #fff; }
.biz ul { padding: 0; margin: 0 0 var(--s-5); list-style: none; }
.biz li { padding: .55rem 0 .55rem 1.8rem; position: relative; border-bottom: 1px solid rgba(255,255,255,.12); }
.biz li::before { content: ""; position: absolute; left: 0; top: .95rem; width: .8rem; height: .8rem; background: var(--yolk); border-radius: 2px; }
.biz canvas { width: 100%; border-radius: var(--r-tile); }
@media (max-width: 860px) { .biz { grid-template-columns: 1fr; padding: var(--s-7) var(--s-5); } }

/* ---------- FAQ ---------- */
.faq { max-width: 52rem; }
.faq details { border-bottom: var(--grout-line); padding: var(--s-4) 0; }
.faq summary { cursor: pointer; font: 600 1.15rem/1.3 var(--f-display); list-style: none; display: flex; justify-content: space-between; gap: var(--s-4); }
.faq summary::after { content: "+"; font-size: 1.5rem; line-height: 1; color: var(--cobalt); }
.faq details[open] summary::after { content: "–"; }
.faq summary::-webkit-details-marker { display: none; }
.faq p { margin: var(--s-3) 0 0; color: var(--ink-2); max-width: 44em; }

/* ---------- Reviews ---------- */
.quotes { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s-6); }
.quotes blockquote { margin: 0; padding-top: var(--s-4); border-top: 4px solid var(--cobalt); }
.quotes blockquote:nth-child(2) { border-color: var(--yolk); }
.quotes blockquote:nth-child(3) { border-color: var(--ink); }
.quotes p { font: 500 1.15rem/1.45 var(--f-display); }
.quotes cite { font-style: normal; color: var(--ink-2); font-size: .92rem; }
@media (max-width: 860px) { .quotes { grid-template-columns: 1fr; } }

/* ---------- CTA-band ---------- */
.cta-band { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: var(--s-5); background: var(--yolk); border-radius: var(--r-ui); padding: var(--s-7); }
.cta-band h2 { margin: 0 0 var(--s-2); }
.cta-band p { margin: 0; }
@media (max-width: 760px) { .cta-band { grid-template-columns: 1fr; padding: var(--s-6) var(--s-5); } }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: #C9D1EA; margin-top: var(--s-9); padding: var(--s-8) var(--s-5) var(--s-5); }
.footer-grid { max-width: var(--max); margin: 0 auto; display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: var(--s-6); }
.site-footer h3 { color: #fff; font-size: 1rem; margin-bottom: var(--s-3); }
.site-footer a:not(.logo) { display: block; color: #C9D1EA; text-decoration: none; padding: .2rem 0; }
.site-footer a:not(.logo):hover { color: #fff; }
.site-footer .muted { color: #9AA6C8; margin-top: var(--s-4); }
.footer-note { max-width: var(--max); margin: var(--s-7) auto 0; padding-top: var(--s-4); border-top: 1px solid rgba(255,255,255,.12); font-size: .85rem; color: #8592B8; }
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-grid > div:first-child { grid-column: 1 / -1; } }

/* ---------- Toast ---------- */
.toast { position: fixed; left: 50%; bottom: var(--s-5); transform: translate(-50%, 140%); background: var(--ink); color: #fff; padding: .9rem 1.2rem; border-radius: var(--r-ui); display: flex; gap: var(--s-4); align-items: center; z-index: 90; transition: transform .25s ease; box-shadow: 0 18px 40px -16px rgba(0,0,0,.5); max-width: calc(100% - 2rem); }
.toast.is-on { transform: translate(-50%, 0); }
.toast a { color: var(--yolk); font-weight: 600; }

/* =========================================================================
   STUDIO
   ========================================================================= */
.studio-body { background: #EEF0F4; }
.studio { display: grid; grid-template-columns: 300px minmax(0, 1fr) 320px; gap: 0; min-height: calc(100vh - 110px); }
.panel { background: var(--white); padding: var(--s-5); overflow-y: auto; max-height: calc(100vh - 110px); position: sticky; top: 72px; }
.panel-left { border-right: var(--grout-line); }
.panel-right { border-left: var(--grout-line); }
.panel h2 { font-size: 1.05rem; margin: 0 0 var(--s-3); letter-spacing: -0.01em; }
.panel section + section { margin-top: var(--s-5); padding-top: var(--s-5); border-top: 1px solid #ECEEF2; }
.panel label, .field-label { display: block; font-size: .88rem; font-weight: 600; margin: var(--s-3) 0 var(--s-1); color: var(--ink); }
.panel input[type="text"], .panel textarea, .panel select, .form input, .form select { width: 100%; font: inherit; font-size: .95rem; padding: .6rem .7rem; border: 1px solid #C9CEDA; border-radius: 8px; background: #fff; color: var(--ink); }
.panel input[type="range"] { width: 100%; accent-color: var(--cobalt); }
.panel input[type="color"] { width: 44px; height: 36px; border: 1px solid #C9CEDA; border-radius: 8px; padding: 2px; background: #fff; cursor: pointer; }
.row { display: flex; gap: var(--s-2); align-items: center; }
.row > * { flex: 1; }
.row > .shrink { flex: 0 0 auto; }

.seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; background: #EEF0F4; border-radius: var(--r-ui); padding: 3px; gap: 3px; }
.seg button { font: 600 .88rem/1.15 var(--f-body); border: 0; background: transparent; padding: .6rem .4rem; border-radius: 8px; cursor: pointer; color: var(--ink-2); }
.seg button small { display: block; font-weight: 500; font-size: .78rem; margin-top: 2px; }
.seg button[aria-pressed="true"] { background: var(--white); color: var(--ink); box-shadow: 0 1px 3px rgba(15,26,54,.18); }

.grid-presets { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; }
.grid-presets button { aspect-ratio: 1; border: 1px solid #C9CEDA; border-radius: 8px; background: #fff; cursor: pointer; display: grid; place-items: center; font: 600 .78rem/1 var(--f-body); color: var(--ink); padding: 0; }
.grid-presets button[aria-pressed="true"] { border: 2px solid var(--cobalt); color: var(--cobalt); background: var(--glaze); }
.grid-custom { display: grid; grid-template-columns: 1fr auto 1fr; gap: var(--s-2); align-items: center; margin-top: var(--s-2); }
.grid-custom select { text-align: center; }

.add-layer { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.add-layer button { border: 1px dashed #AEB6C8; background: #fff; border-radius: 8px; padding: .6rem .2rem; font: 600 .82rem/1.1 var(--f-body); cursor: pointer; color: var(--ink); display: grid; gap: 4px; justify-items: center; }
.add-layer button:hover { border-color: var(--cobalt); border-style: solid; color: var(--cobalt); }
.add-layer svg { width: 20px; height: 20px; }

.layers { list-style: none; margin: var(--s-3) 0 0; padding: 0; display: grid; gap: 6px; }
.layers li { display: grid; grid-template-columns: 32px 1fr auto; gap: var(--s-2); align-items: center; padding: 6px 6px 6px 8px; border: 1px solid #DDE1EA; border-radius: 8px; background: #fff; cursor: pointer; font-size: .9rem; }
.layers li.is-active { border-color: var(--cobalt); box-shadow: 0 0 0 1px var(--cobalt); }
.layers .thumb { width: 28px; height: 28px; border-radius: 4px; background: #EEF0F4; display: grid; place-items: center; font-weight: 700; font-size: .8rem; overflow: hidden; }
.layers .ops { display: flex; gap: 2px; }
.icon-btn { width: 28px; height: 28px; border: 0; background: transparent; border-radius: 6px; cursor: pointer; color: var(--ink-2); display: grid; place-items: center; padding: 0; }
.icon-btn:hover { background: #EEF0F4; color: var(--ink); }
.icon-btn svg { width: 16px; height: 16px; }

.lib { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.lib button { padding: 0; border: 2px solid transparent; border-radius: 6px; cursor: pointer; background: none; aspect-ratio: 1; overflow: hidden; }
.lib button canvas { width: 100%; height: 100%; }
.lib button:hover { border-color: var(--grout); }
.lib button[aria-pressed="true"] { border-color: var(--cobalt); }
.swatches { display: flex; flex-wrap: wrap; gap: 6px; }
.swatches button { width: 34px; height: 34px; border-radius: 6px; border: 2px solid transparent; cursor: pointer; padding: 3px; background: #fff; box-shadow: 0 0 0 1px #DDE1EA; }
.swatches button span { display: block; width: 100%; height: 100%; border-radius: 3px; }
.swatches button[aria-pressed="true"] { border-color: var(--cobalt); }

/* Canvas-stage */
.stage { padding: var(--s-5); display: flex; flex-direction: column; gap: var(--s-4); min-width: 0; }
.stage-bar { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--s-3); align-items: center; }
.stage-bar .seg { min-width: 260px; }
.stage-view { flex: 1; display: grid; place-items: center; background: repeating-conic-gradient(#E4E7ED 0% 25%, #EEF0F4 0% 50%) 50% / 22px 22px; border-radius: var(--r-ui); padding: var(--s-5); min-height: 420px; position: relative; overflow: hidden; }
#design-canvas, #room-canvas { max-width: 100%; max-height: calc(100vh - 290px); width: auto; height: auto; box-shadow: 0 24px 50px -26px rgba(15,26,54,.55); border-radius: 2px; touch-action: none; }
#design-canvas { cursor: crosshair; }
#design-canvas.is-image { cursor: grab; }
.stage-hint { font-size: .9rem; color: var(--ink-2); margin: 0; }
.quality { display: flex; gap: var(--s-2); align-items: flex-start; padding: .7rem .9rem; border-radius: 8px; font-size: .88rem; line-height: 1.4; }
.quality::before { content: ""; flex: 0 0 .65rem; height: .65rem; border-radius: 50%; margin-top: .3rem; background: currentColor; }
.quality.ok { background: #E5F4EC; color: var(--ok); }
.quality.warn { background: #FDF2DC; color: var(--warn); }
.quality.bad { background: #FBE6E4; color: var(--bad); }
.quality span { color: var(--ink); }

/* Bestel-paneel */
.summary dl { display: grid; grid-template-columns: 1fr auto; gap: .4rem var(--s-3); margin: 0 0 var(--s-4); font-size: .95rem; }
.summary dt { color: var(--ink-2); }
.summary dd { margin: 0; text-align: right; font-weight: 600; }
.summary .discount { color: var(--ok); }
.summary .grand { font: 800 2.1rem/1 var(--f-display); color: var(--ink); margin: var(--s-2) 0; }
.summary .grand small { font: 500 .9rem var(--f-body); color: var(--ink-2); display: block; margin-top: var(--s-2); }
.qty { display: grid; grid-template-columns: 40px 1fr 40px; border: 1px solid #C9CEDA; border-radius: 8px; overflow: hidden; max-width: 150px; }
.qty button { border: 0; background: #F3F4F7; font-size: 1.1rem; cursor: pointer; color: var(--ink); }
.qty input { border: 0; text-align: center; font: 600 1rem var(--f-body); width: 100%; padding: .55rem 0; }
.dims { font: 700 1.25rem/1.2 var(--f-display); margin: 0; }
.dims + p { font-size: .9rem; color: var(--ink-2); margin: .2rem 0 0; }

@media (max-width: 1180px) { .studio { grid-template-columns: 280px minmax(0, 1fr); } .panel-right { grid-column: 1 / -1; position: static; max-height: none; border-left: 0; border-top: var(--grout-line); } }
@media (max-width: 820px) {
  .studio { grid-template-columns: 1fr; }
  .panel { position: static; max-height: none; }
  .panel-left { border-right: 0; border-bottom: var(--grout-line); order: 2; }
  .stage { order: 1; padding: var(--s-3); }
  .panel-right { order: 3; }
  #design-canvas, #room-canvas { max-height: 70vh; }
}

/* ---------- Winkelwagen & afrekenen ---------- */
.cart { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: var(--s-7); align-items: start; }
.cart-items { list-style: none; margin: 0; padding: 0; border-top: var(--grout-line); }
.cart-item { display: grid; grid-template-columns: 120px 1fr auto; gap: var(--s-5); padding: var(--s-5) 0; border-bottom: var(--grout-line); align-items: start; }
.cart-item img, .cart-item .ph { width: 120px; aspect-ratio: 1; object-fit: contain; background: var(--white); border-radius: var(--r-tile); border: 1px solid var(--grout); }
.cart-item h3 { margin: 0 0 var(--s-1); font-size: 1.15rem; }
.cart-item p { margin: 0 0 var(--s-2); font-size: .93rem; color: var(--ink-2); }
.cart-item .line-total { font: 700 1.2rem/1 var(--f-display); text-align: right; }
.cart-item .actions { display: flex; gap: var(--s-4); align-items: center; margin-top: var(--s-3); flex-wrap: wrap; }
.link-btn { background: none; border: 0; padding: 0; color: var(--cobalt); font: inherit; font-size: .93rem; cursor: pointer; text-decoration: underline; }
.totals { background: var(--white); border-radius: var(--r-ui); padding: var(--s-5); border: 1px solid var(--grout); position: sticky; top: 90px; }
.totals dl { display: grid; grid-template-columns: 1fr auto; gap: .5rem 0; margin: 0 0 var(--s-4); }
.totals dt { padding-right: var(--s-4); }
.totals dd { margin: 0; text-align: right; font-weight: 600; }
.totals .sum { border-top: var(--grout-line); padding-top: var(--s-3); font: 700 1.3rem var(--f-display); }
.empty { text-align: left; padding: var(--s-7) 0; max-width: 34rem; }
.form { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s-2) var(--s-4); }
.form .full { grid-column: 1 / -1; }
.form label { display: block; font-weight: 600; font-size: .92rem; margin-bottom: var(--s-1); }
.form input:invalid:not(:placeholder-shown) { border-color: var(--bad); }
.pay-methods { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s-2); }
.pay-methods label { border: 1px solid #C9CEDA; border-radius: 8px; padding: .8rem; display: flex; gap: .5rem; align-items: center; font-weight: 500; cursor: pointer; background: #fff; margin: 0; }
.pay-methods label:has(input:checked) { border-color: var(--cobalt); box-shadow: 0 0 0 1px var(--cobalt); }
@media (max-width: 900px) { .cart { grid-template-columns: 1fr; } .cart-item { grid-template-columns: 84px 1fr; } .cart-item img, .cart-item .ph { width: 84px; } .cart-item .line-total { grid-column: 2; text-align: left; } .form { grid-template-columns: 1fr; } .pay-methods { grid-template-columns: 1fr; } }

.page-head { padding: var(--s-8) 0 var(--s-6); }
.page-head h1 { font-size: clamp(2.2rem, 4.5vw, 3.6rem); }
