/* ==========================================================
   House name plate designer
   ========================================================== */

.np-hero { padding-bottom: clamp(20px, 4vw, 44px); }
.np-hero h1 { font-size: clamp(2.8rem, 11vw, 5.6rem); }
.npd { padding-bottom: var(--section); }
.npd__grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; }

/* Preview: sticks under the header on phones so it stays in view while typing */
.npd__preview {
  position: sticky; top: var(--hdr-h); z-index: 5;
  margin-inline: calc(var(--gutter) * -1);
  background: var(--black);
}
.npd__house { border-radius: 0; border-width: 0 0 1px; transition: transform .5s var(--ease), border-radius .5s var(--ease), box-shadow .5s; }
.npd__sentinel { display: block; height: 1px; margin-bottom: -1px; }

/* When the preview sticks while you fill the form: it settles into a framed
   card with lime focus corners, like a camera locking focus */
.npd__frame {
  position: absolute; inset: 14px; z-index: 3; pointer-events: none;
  opacity: 0; transform: scale(1.08);
  transition: opacity .45s var(--ease), transform .55s var(--ease);
  --c: var(--lime); --l: 26px; --w: 2px;
  background:
    linear-gradient(var(--c), var(--c)) top left / var(--l) var(--w) no-repeat,
    linear-gradient(var(--c), var(--c)) top left / var(--w) var(--l) no-repeat,
    linear-gradient(var(--c), var(--c)) top right / var(--l) var(--w) no-repeat,
    linear-gradient(var(--c), var(--c)) top right / var(--w) var(--l) no-repeat,
    linear-gradient(var(--c), var(--c)) bottom left / var(--l) var(--w) no-repeat,
    linear-gradient(var(--c), var(--c)) bottom left / var(--w) var(--l) no-repeat,
    linear-gradient(var(--c), var(--c)) bottom right / var(--l) var(--w) no-repeat,
    linear-gradient(var(--c), var(--c)) bottom right / var(--w) var(--l) no-repeat;
  filter: drop-shadow(0 0 6px rgba(213, 251, 99, .6));
}
.npd__preview.is-stuck .npd__frame { opacity: 1; transform: none; }
.npd__preview.is-stuck .npd__house {
  transform: scale(.94); border-radius: 18px; border-width: 1px;
  box-shadow: 0 0 0 1px var(--lime-line), 0 18px 40px rgba(0, 0, 0, .6), 0 0 40px rgba(213, 251, 99, .12);
}
.npd__preview.is-stuck .npd__live { border-color: var(--lime-line); }
.npd__live {
  position: absolute; z-index: 4; left: 26px; top: 24px; transition: border-color .4s;
  display: inline-flex; align-items: center; gap: 8px; padding: 6px 11px; border-radius: 999px;
  background: rgba(10, 10, 10, .72); border: 1px solid rgba(255, 255, 255, .1);
  font-family: var(--f-mono); font-size: .66rem; letter-spacing: .12em; text-transform: uppercase;
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
}
.npd__live i { width: 7px; height: 7px; border-radius: 50%; background: var(--lime); box-shadow: 0 0 8px var(--lime); animation: live 2s ease-in-out infinite; }
@keyframes live { 50% { opacity: .3; } }

@media (min-width: 900px) {
  .npd__grid { grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: clamp(28px, 4vw, 56px); align-items: start; }
  .npd__preview { margin: 0; top: calc(var(--hdr-h) + 20px); background: none; }
  .npd__house { border-radius: var(--radius-lg); border-width: 1px; box-shadow: 0 30px 80px rgba(0, 0, 0, .5); }
  .npd__live { left: 28px; top: 26px; }
}

/* ---------- Controls ---------- */

.npd__controls { display: grid; gap: 12px; }
.npf { border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--charcoal); padding: 18px; margin: 0; min-width: 0; display: grid; gap: 14px; }
.npf legend { float: left; width: 100%; display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 1.08rem; padding: 0; }
.npf legend + * { clear: both; }
.npf__n { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 50%; background: var(--lime); color: var(--black); font-family: var(--f-mono); font-size: .78rem; font-weight: 500; }
.npf__row { display: grid; gap: 12px; }
@media (min-width: 480px) { .npf__row { grid-template-columns: 1fr 1.6fr; } }
.npf__field { display: grid; gap: 6px; font-size: .9rem; color: var(--grey); }
.npf__field small { color: var(--grey); }
.npf__field input {
  width: 100%; height: 54px; padding: 0 14px; border-radius: 12px;
  background: #0b0b0b; border: 1px solid var(--line); color: var(--white); font-size: 1.05rem;
}
.npf__field input:focus { outline: none; border-color: var(--lime); box-shadow: 0 0 0 3px var(--lime-soft); }

/* Material cards */
.npm { display: grid; gap: 8px; }
.npm__opt { position: relative; display: block; cursor: pointer; }
.npm__opt input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.npm__box {
  display: grid; grid-template-columns: 64px 1fr 24px; align-items: center; gap: 14px;
  min-height: 64px; padding: 10px 14px 10px 10px; border-radius: 14px;
  border: 1px solid var(--line); background: #0f0f0f;
  transition: border-color .2s, background .2s;
}
.npm__sw { display: grid; place-items: center; width: 64px; height: 44px; border-radius: 8px; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .35), 0 4px 10px rgba(0, 0, 0, .3); }
.npm__sw b { font-family: 'Playfair Display', Georgia, serif; font-size: 1.1rem; }
.npm__txt { display: grid; gap: 2px; line-height: 1.25; min-width: 0; }
.npm__txt strong { font-size: 1rem; }
.npm__txt small { color: var(--grey); font-size: .82rem; }
.npm__tick { width: 24px; height: 24px; border-radius: 50%; border: 1.5px solid var(--line); display: grid; place-items: center; color: transparent; }
.npm__tick .icon { width: 14px; height: 14px; }
.npm__opt:hover .npm__box { border-color: #3d3d3a; }
.npm__opt input:checked + .npm__box { border-color: var(--lime); background: var(--lime-soft); }
.npm__opt input:checked + .npm__box strong { color: var(--lime); }
.npm__opt input:checked + .npm__box .npm__tick { background: var(--lime); border-color: var(--lime); color: var(--black); }
.npm__opt input:focus-visible + .npm__box { outline: 2px solid var(--lime); outline-offset: 2px; }

.npd__send { display: grid; gap: 10px; padding-top: 6px; }
