@font-face {
  font-family: "CoFo Sans Trial";
  font-weight: 300 800;
  font-display: swap;
  font-style: normal;
  src:
    url("cofosansvf-Trial.ttf") format("truetype"),
    url("CoFoSans.ttf") format("truetype");
}

:root {
  --ff: "CoFo Sans Trial", Arial, Helvetica, sans-serif;
  --cream: #FBF3E8;
  --cream2: #F4E9D8;
  --pink: #FF6FA8;
  --pink-deep: #E04A85;
  --pink-soft: #FFD3E2;
  --pink-pastel: #FFE4ED;
  --green: #1F4D3A;
  --green-deep: #143828;
  --ink: #2A2823;
  --mute: #6A655B;
  --line: #E8DDC9;
  --white: #FFF;
  --r: 18px;
  --r-lg: 24px;
  --sh-sm: 0 2px 0 rgba(26, 25, 22, .06);
  --sh-md: 0 6px 18px rgba(26, 25, 22, .09);
  --sh-lg: 0 16px 40px rgba(26, 25, 22, .13);
  --sh-pink: 0 4px 0 var(--pink-deep);
  --hdr-h: 62px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
  overflow-wrap: break-word;
  hyphens: auto;
}

html {
  font-size: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: var(--hdr-h);
}

body {
  font-family: var(--ff);
  background: var(--cream);
  color: var(--ink);
  font-size: 1rem;
  line-height: 1.5;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  box-sizing: border-box;
  flex-wrap: wrap;

}

img,
svg {
  display: block;
  max-width: 100%
}

button {
  font-family: var(--ff);
  border: none;
  background: none;
  cursor: pointer;
  color: inherit
}

input,
textarea,
select {
  font-family: var(--ff);
  font-size: inherit;
  color: inherit
}

a {
  color: inherit;
  text-decoration: none
}

::selection {
  background: var(--pink);
  color: #fff
}

.h1 {
  font-weight: 700;
  font-size: clamp(2rem, 6.2vw, 4.5rem);
  line-height: .96;
  letter-spacing: -.04em;
}

.h2 {
  font-weight: 700;
  font-size: clamp(1.375rem, 3.8vw, 2.625rem);
  line-height: 1.06;
  letter-spacing: -.025em
}

.h3 {
  font-weight: 600;
  font-size: clamp(1.0625rem, 2.2vw, 1.5rem);
  line-height: 1.15
}

.eyebrow {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: .13em;
  text-transform: uppercase;
  color: var(--pink-deep)
}

.lead {
  font-size: clamp(0.9375rem, 1.2vw, 1rem);
  color: var(--mute);
  line-height: 1.55;
  max-width: 75ch
}

.wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 11px 17px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.9375rem;
  transition: transform .15s, box-shadow .15s, background .12s;
  white-space: nowrap
}

.btn-p {
  background: var(--pink);
  color: #fff;
  box-shadow: var(--sh-pink)
}

.btn-p:hover {
  background: var(--pink-deep);
  transform: translateY(-2px)
}

.btn-p:active {
  transform: translateY(1px);
  box-shadow: 0 2px 0 var(--pink-deep)
}

.btn-d {
  background: var(--green);
  color: var(--cream2);
  box-shadow: 0 4px 0 var(--green-deep)
}

.btn-d:hover {
  background: var(--green-deep);
  transform: translateY(-2px)
}

.btn-s {
  background: var(--white);
  color: var(--ink);
  border: 1px solid var(--line);
  box-shadow: var(--sh-sm)
}

.btn-s:hover {
  background: var(--pink-pastel);
  border-color: var(--pink-soft)
}

.btn-lg {
  padding: 14px 22px;
  font-size: 0.9375rem
}

.btn-bl {
  display: flex;
  width: 100%
}

.arr {
  transition: transform .15s
}

.btn:hover .arr {
  transform: translateX(3px)
}

/* ═══ HEADER ═══ */
.hdr {
  position: sticky;
  top: 0;
  z-index: 80;
  backdrop-filter: saturate(140%) blur(14px);
  -webkit-backdrop-filter: saturate(140%) blur(14px);
  background: rgba(251, 243, 232, .86);
  border-bottom: 1px solid rgba(232, 221, 201, .4);
  height: var(--hdr-h)
}

.hdr-row {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 100%
}

.logo-img {
  height: 60px;
  width: auto;
  /* cursor: pointer; */
  flex-shrink: 0
}

.nav {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-left: 20px
}

.nav a {
  font-size: 0.9375rem;
  font-weight: 500;
  padding: 4px 0;
  position: relative
}

.nav a:hover,
.nav a.active,
.nav a[aria-current="true"] {
  color: var(--pink-deep)
}

.nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  height: 2px;
  background: var(--pink);
  transform: scaleX(0);
  transition: transform .2s
}

.nav a:hover::after,
.nav a.active::after,
.nav a[aria-current="true"]::after {
  transform: scaleX(1)
}

.hdr-r {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 6px
}

.ib {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--white);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform .12s, background .12s;
  position: relative;
  flex-shrink: 0
}

.ib:hover {
  transform: translateY(-1px);
  background: var(--pink-pastel)
}

.cart-dot {
  position: absolute;
  top: -1px;
  right: -1px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--pink);
  border: 2px solid var(--cream);
  display: none
}

.burger {
  display: none
}

@media(max-width:960px) {
  .nav {
    display: none
  }

  .burger {
    display: flex
  }
}

@media(max-width:520px) {
  .hdr .btn-p {
    display: none
  }
}

/* ═══ OVERLAYS ═══ */
.ov {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, .35);
  z-index: 300;
  display: none;
  align-items: flex-start;
  justify-content: center;
  padding: 48px 14px;
  overflow-y: auto
}

.ov.open {
  display: flex
}

.mdl {
  background: var(--cream);
  border-radius: var(--r-lg);
  padding: 22px;
  max-width: 380px;
  width: 100%;
  position: relative;
  box-shadow: var(--sh-lg);
  animation: fu .2s ease
}

@keyframes fu {
  from {
    opacity: 0;
    transform: translateY(8px)
  }

  to {
    opacity: 1;
    transform: translateY(0)
  }
}

.mdl-x {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--white);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9375rem
}

.mdl h3 {
  font-size: 1.125rem;
  font-weight: 700;
  margin-bottom: 12px
}

.mdl-empty {
  padding: 16px;
  text-align: center;
  color: var(--mute);
  font-size: 0.875rem;
  background: var(--white);
  border-radius: 10px;
  border: 1px dashed var(--line)
}

/* Burger */
.bm {
  position: fixed;
  inset: 0;
  background: var(--cream);
  z-index: 250;
  display: none;
  flex-direction: column
}

.bm.open {
  display: flex
}

.bm-h {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line)
}

.bm-b {
  flex: 1;
  overflow-y: auto;
  padding: 16px
}

.bm-b a {
  display: block;
  font-size: 1.0625rem;
  font-weight: 600;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
  border-radius: 10px;
  transition: color .15s, background .15s, padding-left .15s
}


.remove-confirm-modal {
      position: fixed;
      inset: 0;
      z-index: 1200;
      display: none;
      align-items: center;
      justify-content: center;
      padding: 24px;
    }

.remove-confirm-modal.open {
      display: flex;
    }

.remove-confirm-backdrop {
    position: absolute;
    inset: 0;
    border: 0;
    background: rgba(22, 20, 17, .58);
    cursor: pointer;
  }

.remove-confirm-box {
    position: relative;
    width: min(100%, 430px);
    border: 1px solid rgba(22, 20, 17, .12);
    border-radius: 24px;
    background: var(--cream, #fffaf0);
    color: var(--ink, #241f1a);
    box-shadow: 0 24px 70px rgba(22, 20, 17, .28);
    padding: 26px;
    transform: translateY(8px) scale(.98);
    animation: removeConfirmIn .18s ease forwards;
  }

.remove-confirm-close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 999px;
    background: rgba(22, 20, 17, .08);
    cursor: pointer;
    transition: transform .18s ease, background .18s ease;
  }

.remove-confirm-close:hover {
    background: rgba(22, 20, 17, .14);
    transform: scale(1.04);
  }

.remove-confirm-box h3 {
    margin: 0 36px 10px 0;
    font-size: 1.25rem;
    line-height: 1.25;
  }

.remove-confirm-text {
    margin: 0;
    opacity: .72;
    line-height: 1.55;
  }

.remove-confirm-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 22px;
  }

.qty button:disabled {
    opacity: .45;
    cursor: not-allowed;
    transform: none;
  }

.cart-item.is-qty-zero [data-line-price] {
    opacity: .65;
  }

@keyframes removeConfirmIn {
    to {
      transform: translateY(0) scale(1);
    }
  }

.bm-b a.active,
.bm-b a[aria-current="true"] {
  color: var(--pink-deep);
  background: var(--pink-pastel);
  padding-left: 10px;
  border-bottom-color: transparent
}

.bm-f {
  padding: 14px;
  border-top: 1px solid var(--line)
}

/* Draft confirm */
.dmod {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, .45);
  z-index: 400;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px
}

.dmod.open {
  display: flex
}

.dbox {
  background: var(--cream);
  border-radius: var(--r-lg);
  padding: 24px;
  max-width: 360px;
  width: 100%;
  text-align: center;
  box-shadow: var(--sh-lg)
}

.dbox h3 {
  margin-bottom: 8px;
  font-size: 1.0625rem
}

.dbox p {
  font-size: 0.875rem;
  color: var(--mute);
  margin-bottom: 14px
}

.dbtns {
  display: flex;
  flex-direction: column;
  gap: 7px
}

/* ═══ HERO ═══ */
.hero {
  padding: 36px 0 56px;
  position: relative;
  overflow: hidden
}

.hero::before {
  content: "";
  position: absolute;
  inset: auto -10vw 0 -10vw;
  height: 50%;
  background: radial-gradient(ellipse at 20% 100%, var(--pink-pastel) 0%, transparent 50%), radial-gradient(ellipse at 80% 100%, #DCE8DE 0%, transparent 50%);
  z-index: -1
}

.hero-g {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 28px;
  align-items: center
}

@media(max-width:960px) {
  .hero-g {
    grid-template-columns: 1fr
  }
}

.hero .pk {
  color: var(--pink-deep)
}

/* Fancy underline: two pink bars with gap for descender of "р" */
.uf {
  position: relative;
  display: inline-block
}

.uf .uf-l,
.uf .uf-r {
  position: absolute;
  bottom: -.02em;
  height: clamp(3px, .5vw, 6px);
  background: var(--pink);
  border-radius: 2px
}

.uf .uf-l {
  left: 0;
  width: 53%
}

.uf .uf-r {
  left: 64%;
  right: 0
}

.hero-cta {
  margin-top: 20px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap
}

.hero-stats {
  margin-top: 24px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px
}

@media(max-width:640px) {
  .hero-stats {
    grid-template-columns: repeat(2, 1fr)
  }
}

.hs {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 11px;
  text-align: center;
  position: relative;
}

.hs b {
  display:inline-flex;
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--green);
  letter-spacing: -.02em;
  white-space: nowrap;
  align-content: center;
}

.hs b .star {
  color: var(--green);
  font-size: 1rem;
  align-content: center;
}

.hs span {
  font-size: 0.9375rem;
  color: var(--mute);
  line-height: 1.3;
  display: block;
  margin-top: 1px;
}

.hero-photos {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px
}

.hero-ph {
  border-radius: var(--r);
  overflow: hidden;
  box-shadow: var(--sh-md);
  aspect-ratio: 3/4
}

.hero-ph img {
  width: 100%;
  height: 100%;
  object-fit: cover
}

.hero-ph:first-child {
  transform: rotate(-3deg)
}

.hero-ph:nth-child(2) {
  transform: rotate(2deg);
  margin-top: 22px
}

.hero-badge {
  position: absolute;
  bottom: -8px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--green);
  color: var(--cream);
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 0.875rem;
  font-weight: 700;
  white-space: nowrap;
  box-shadow: var(--sh-md);
  z-index: 2
}

/* ═══ MARQUEE ═══ */
.mq {
  background: var(--green);
  color: var(--cream);
  padding: 11px 0;
  overflow: hidden
}

.mt {
  display: flex;
  white-space: nowrap;
  animation: scrl 50s linear infinite;
  font-size: 0.9375rem;
  font-weight: 600
}

.mt span {
  display: flex;
  align-items: center
}

.mt .item {
  padding: 0 16px
}

.mt .dot {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--pink);
  flex-shrink: 0
}

@keyframes scrl {
  from {
    transform: translateX(0)
  }

  to {
    transform: translateX(-50%)
  }
}

/* ═══ SECTIONS ═══ */
section {
  padding: 56px 0;
  scroll-margin-top: var(--hdr-h)
}

.sh {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 32px;
  flex-wrap: wrap
}

.sh .left {
  max-width: 800px
}

.sh .eyebrow {
  margin-bottom: 7px;
  display: block
}

/* CATEGORY CARDS */
.cg {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px
}

@media(max-width:900px) {
  .cg {
    grid-template-columns: repeat(2, 1fr)
  }
}

@media(max-width:480px) {
  .cg {
    grid-template-columns: 1fr
  }
}

.cc {
  background: var(--white);
  border-radius: var(--r);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 7px;
  border: 1px solid var(--line);
  transition: transform .2s, box-shadow .2s;
  cursor: pointer;
  min-height: 160px
}

.cc:hover {
  transform: translateY(-3px);
  box-shadow: var(--sh-md)
}

.cc-i {
  width: 44px;
  height: 44px;
  border-radius: 11px;
  display: flex;
  align-items: center;
  justify-content: center
}

.cc h4 {
  font-size: 1.3rem;
  font-weight: 700
}

.cc p {
  font-size: 0.9375rem;
  color: var(--mute);
  line-height: 1.35;
  flex: 1
}

.cc .m {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 1rem;
  font-weight: 700;
  padding-top: 4px
}

.cc .ac {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--cream);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem
}

.cc.pk {
  background: var(--pink);
  color: #fff;
  border-color: var(--pink-deep)
}

.cc.pk p {
  color: rgba(255, 255, 255, .82)
}

.cc.pk .ac {
  background: #fff;
  color: var(--pink-deep)
}

.cc.dk {
  background: var(--green);
  color: var(--cream);
  border-color: var(--green-deep)
}

.cc.dk p {
  color: rgba(244, 233, 216, .78)
}

.cc.dk .ac {
  background: var(--cream);
  color: var(--green)
}

/* TRUST */
.trust {
  background: var(--green);
  color: var(--cream);
  border-radius: var(--r-lg);
  padding: 32px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  align-items: center;
}

@media(max-width:768px) {
  .trust {
    grid-template-columns: 1fr;
    padding: 22px
  }
}

.tst {
  display: flex;
  flex-direction: column;
  grid-template-columns: 1fr 1fr;
  gap: 8px;

}

.ts {
  background: rgba(244, 233, 216, .06);
  border: 1px solid rgba(244, 233, 216, .08);
  border-radius: 11px;
  padding: 14px;
  text-align: center;
  align-content: space-around;
  overflow-wrap: break-word;
  hyphens: auto;
  flex-grow: 1;
}

.ts b {
  display: block;
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--pink)
}

.ts span {
  display: block;
  font-size: 1.1rem;
  margin-top: 2px;
  opacity: .72
}

/* STEPS */
.sg {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 9px
}

@media(max-width:900px) {
  .sg {
    grid-template-columns: repeat(2, 1fr)
  }
}

@media(max-width:480px) {
  .sg {
    grid-template-columns: 1fr
  }
}

.sc {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 16px;
  text-align: center;
  justify-content: space-between;
  align-items: center;
}

.sc-i {
  width: 46px;
  height: 46px;
  border-radius: 11px;
  background: var(--pink-pastel);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 8px
}

.sc-n {
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: .1em;
  color: var(--pink-deep);
  margin-bottom: 3px
}

.sc h5 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 2px;
  line-height: normal;
}

.sc p {
  font-size: 0.9375rem;
  color: var(--mute);
  line-height: 1.35
}

/* GALLERY */
.gg {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px
}

@media(max-width:768px) {
  .gg {
    grid-template-columns: repeat(2, 1fr)
  }
}

@media(max-width:480px) {
  .gg {
    grid-template-columns: 1fr
  }
}

.gc {
  border-radius: var(--r);
  overflow: hidden;
  position: relative;
  cursor: pointer;
  transition: transform .2s;
  background: var(--white);
  border: 1px solid var(--line)
}

.gc:hover {
  transform: translateY(-2px);
  box-shadow: var(--sh-md)
}

.gc img,
.gc video {
  width: 100%;
  aspect-ratio: 2/3;
  object-fit: cover;
  background: var(--cream2);
  display: block;
}

.gc .tg {
  position: absolute;
  bottom: 7px;
  left: 7px;
  right: 7px;
  background: rgba(251, 243, 232, .9);
  backdrop-filter: blur(5px);
  padding: 7px 9px;
  border-radius: 8px;
  font-size: 0.875rem;
  font-weight: 700;
  display: flex;
  justify-content: space-between;
  align-items: center
}

.gc .tg small {
  font-weight: 600;
  color: var(--pink-deep);
  font-size: 0.875rem;
}

/* PRICING */
.psz {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 7px;
  margin-bottom: 18px
}

@media(max-width:640px) {
  .psz {
    grid-template-columns: repeat(2, 1fr)
  }
}

.psc {
  background: var(--white);
  border: 1.5px solid var(--line);
  border-radius: 11px;
  padding: 11px;
  text-align: center
}

.psc b {
  display: block;
  font-size: 1rem;
  font-weight: 700
}

.psc .sub {
  font-size: 0.875rem;
  color: var(--mute);
  margin-top: 2px;
  line-height: 1.3
}

.psc .pr {
  font-size: 0.9375rem;
  font-weight: 800;
  margin-top: 3px;
  color: var(--green)
}

.pgr {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 12px
}

@media(max-width:900px) {
  .pgr {
    grid-template-columns: 1fr
  }
}

.pcd {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 20px
}

.pcd.dk {
  background: var(--green);
  color: var(--cream);
  border-color: var(--green-deep)
}

.prw {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px dashed rgba(232, 221, 201, .4);
  font-size: 0.875rem
}

.pcd.dk .prw {
  border-bottom-color: rgba(244, 233, 216, .08)
}

.prw:last-child {
  border-bottom: none
}

/* ACCORDION */
.ai {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--r);
  overflow: hidden;
  margin-bottom: 4px
}

.ai-q {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 13px 14px;
  font-weight: 700;
  font-size: 1rem;
  text-align: left;
  gap: 8px
}

.ai-q .ch {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--cream);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform .25s, background .25s;
  font-size: 1rem;
}

.ai.open .ai-q .ch {
  transform: rotate(45deg);
  background: var(--pink);
  color: #fff
}

.ai-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height .3s ease, padding .3s;
  display: flex;
  align-items: stretch;
  flex-direction: column;
  min-width: 0;
}

.ai.open .ai-a {
  max-height: 1400px;
  padding: 0 14px 12px;
}

.ai-a p {
  color: var(--mute);
  font-size: 0.9375rem;
  line-height: 1.45;
}

.ai-a ol {
  padding-left: 24px;
  color: var(--mute);
  font-size: 0.9375rem;
  line-height: 1.45;
}

.ai-a li {
  color: var(--mute);
}

/* Картинки в дополнительных услугах: всегда по ширине своего блока, без горизонтального скролла */
.pgr > *,
#exA,
.ai,
.ai-a,
.ai-imgs {
  min-width: 0;
  max-width: 100%;
}

.ai-imgs {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 10px;
  overflow: hidden;
}

.ai-imgs img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  border-radius: 10px;
  object-fit: contain;
}

@media(max-width:480px) {
  .ai.open .ai-a {
    padding-left: 10px;
    padding-right: 10px;
  }
}

/* TESTIMONIALS */
.teg {
  position: relative;

  width: 100vw;
  max-width: 100vw;

  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);

  overflow: hidden;
  cursor: grab;
  touch-action: pan-y;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  outline: none;
}

.teg.is-dragging {
  cursor: grabbing;
  user-select: none;
}

.te-track {
  display: flex;
  align-items: stretch;
  gap: 12px;
  width: max-content;
  min-width: 100%;

  padding: 2px max(20px, calc((100vw - 1200px) / 2 + 20px)) 18px;

  will-change: transform;
  transform: translate3d(0, 0, 0);
  backface-visibility: hidden;
}

.tc {
  flex: 0 0 clamp(280px, 31vw, 370px);

  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--r);
  overflow: hidden;
  min-width: 0;
}

.tc-img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  background: var(--cream2);
  user-select: none;
  -webkit-user-drag: none;
  pointer-events: none;
}

.tc-b {
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.tc-b .stars {
  color: var(--pink);
  font-size: 0.8rem;
  letter-spacing: 1px;
}

.tc-b p {
  font-size: 0.9375rem;
  line-height: 1.35;
}

.tc-b .who {
  font-size: 0.875rem;
  color: var(--mute);
  padding-top: 5px;
  border-top: 1px solid var(--line);
}

@media(max-width:900px) {
  .te-track {
    gap: 10px;
    padding-left: 20px;
    padding-right: 20px;
  }

  .tc {
    flex-basis: min(82vw, 360px);
  }
}

@media(max-width:480px) {
  .tc {
    flex-basis: 84vw;
  }
}

/* FOOTER */
footer {
  background: var(--green);
  color: var(--cream);
  padding: 48px 0 20px;
  margin-top: 36px
}

.fcta {
  margin-bottom: 36px;
  background: var(--green-deep);
  border-radius: var(--r-lg);
  padding: 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap
}

.fgr2 {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 28px;
  margin-bottom: 32px
}

@media(max-width:900px) {
  .fgr2 {
    grid-template-columns: 1fr 1fr
  }
}

@media(max-width:480px) {
  .fgr2 {
    grid-template-columns: 1fr
  }
}

.fgr2 h6 {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: .11em;
  text-transform: uppercase;
  color: var(--pink);
  margin-bottom: 10px
}

.fgr2 ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px
}

.fgr2 a {
  font-size: 0.875rem;
  opacity: .76
}

.fgr2 a:hover {
  opacity: 1;
  color: var(--pink)
}

.soc {
  display: flex;
  gap: 6px;
  margin-top: 10px
}

.sb {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(244, 233, 216, .08);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--cream);
  transition: background .15s
}

.sb:hover {
  background: var(--pink)
}

.sb svg {
  width: 15px;
  height: 15px;
  fill: currentColor
}

.fbt {
  padding-top: 14px;
  border-top: 1px solid rgba(244, 233, 216, .08);
  font-size: 0.8rem;
  color: rgba(244, 233, 216, .5);
  display: grid;
  grid-template-columns: minmax(220px, 1.15fr) repeat(1, minmax(220px, 1fr));
  align-items: start;
  gap: 12px 24px;
}

.fbt span {
  display: block;
  line-height: 1.45;
}

.fbt .disc {
  max-width: none;
  text-align: left;
  line-height: 1.45;
}

@media(max-width:900px) {
  .fbt {
    grid-template-columns: 1fr;
    gap: 8px;
  }
}

.mob-cta {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 8px 12px calc(8px + env(safe-area-inset-bottom));
  background: rgba(251, 243, 232, .94);
  backdrop-filter: blur(12px);
  border-top: 1px solid var(--line);
  display: none;
  z-index: 50
}

@media(max-width:768px) {
  .mob-cta {
    display: block
  }

  body {
    padding-bottom: 58px
  }
}

/* ═══ CONSTRUCTOR ═══ */
.cstr {
  position: fixed;
  inset: 0;
  background: var(--green);
  z-index: 200;
  display: none;
  flex-direction: column
}

.cstr.open {
  display: flex
}

.cstr-h {
  display: flex;
  align-items: center;
  height: 48px;
  padding: 0 12px;
  background: var(--cream);
  border-bottom: 1px solid var(--line);
  gap: 8px;
  flex-shrink: 0
}

.cstr-h .logo-img {
  height: 26px
}

.cstr-hr {
  margin-left: auto;
  display: flex;
  gap: 4px
}

.cstr-pr {
  padding: 7px 12px;
  display: flex;
  align-items: center;
  gap: 5px;
  background: var(--green-deep);
  flex-wrap: wrap;
  flex-shrink: 0
}

.cst {
  display: flex;
  align-items: center;
  gap: 3px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--cream);
  opacity: .35;
  cursor: pointer
}

.cst.a {
  opacity: 1;
  color: var(--pink)
}

.cst.d {
  opacity: .75
}

.cst .n {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: rgba(244, 233, 216, .08);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700
}

.cst.a .n {
  background: var(--pink);
  color: #fff
}

.cst.d .n {
  background: var(--cream);
  color: var(--green)
}

.csep {
  width: 6px;
  height: 2px;
  background: rgba(244, 233, 216, .08);
  border-radius: 1px
}

@media(max-width:700px) {
  .cst .lb {
    display: none
  }
}

/* CRITICAL: constructor body layout for scroll */
.cstr-bd {
  flex: 1;
  display: flex;
  min-height: 0;
  overflow: hidden;
  box-sizing: border-box;
}

@media(min-width:1025px) {
  .cstr-bd {
    flex-direction: row
  }
}

@media(max-width:1024px) {
  .cstr-bd {
    flex-direction: column
  }
}

.cstr-pv {
  align-items: flex-start;
  justify-content: space-between; 
  background: radial-gradient(ellipse at 50% 30%, rgba(255, 111, 168, .08) 0%, transparent 50%), var(--green);
  position: relative;
  box-sizing: border-box;
  display:flex;
  flex-direction:row;
  min-height: 400px;
  margin-bottom: 40px;
  margin: 15px;
  transition: max-height 0.3s ease-in-out;
  overflow: hidden;
}

@media(min-width:1025px) {
  .cstr-pv {
    flex: 1;
    min-width: 0
  }
}

@media(max-width:1024px) {
  .cstr-pv {
    height: 35vh;
    min-height: 160px
  }
}

.cstr-pv .hint {
  top: 8px;
  left: 8px;
  font-size: 0.75rem;
  color: rgba(244, 233, 216, .35);
  letter-spacing: .1em;
  text-transform: uppercase;
  font-weight: 700;
  margin-top: 8px;
}


.cstr-pv .pp small {
  display: block;
  font-weight: 600;
  font-size: 0.75rem;
  color: var(--mute);
  letter-spacing: .06em;
  text-transform: uppercase;
}

.cstr-pv .pp {
  z-index: 3;
  box-sizing: border-box;
  background: var(--cream);
  color: var(--ink);
  border-radius: 9px;
  padding: 6px 16px;
  font-weight: 800;
  font-size: 0.875rem;
  box-shadow: var(--sh-md);
  overflow: hidden;
}

#pC {
  overflow: hidden;
  overflow-y: auto;
}

.fr-stg {
  display: flex;
  transition: none;
  left: 70px;
  align-items: center;
}

.fr-o {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 3px;
  overflow: hidden;
  box-shadow: var(--sh-lg);
}

.fr-b {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  border-radius: 3px
}

.fr-d {
  position: absolute;
  inset: 12px;
  background: var(--white);
  box-shadow: inset 0 2px 10px rgba(0, 0, 0, .05)
}

.fr-bg {
  position: absolute;
  inset: 18px;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  align-content: flex-end;
  justify-content: center;
  padding: 4% 3%;
  gap: 2px;
  overflow: hidden
}

.fw {
  display: flex;
  flex-direction: column;
  align-items: center
}

.fn {
  font-family: var(--ff);
  font-size: 0.58rem;
  font-weight: 700;
  text-align: center;
  margin-top: 1px;
  color: var(--ink);
  background: rgba(255, 255, 255, .75);
  padding: 0 2px;
  border-radius: 2px;
  max-width: 44px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap
}

/* CRITICAL: panel must scroll */
.cstr-pn {
  background: var(--cream);
  display: flex;
  flex-direction: column;
  min-height: 0;
  position: relative;
  overflow: hidden
}

@media(min-width:1025px) {
  .cstr-pn {
    width: 420px;
    flex-shrink: 0;
    border-left: 1px solid var(--line)
  }
}

@media(max-width:1024px) {
  .cstr-pn {
    flex: 1;
    border-top: 1px solid var(--line)
  }
}

.pnl-h {
  padding: 12px 14px 8px;
  border-bottom: 1px solid var(--line);
  flex-shrink: 0
}

.pnl-h .so {
  font-size: 0.75rem;
  color: var(--pink-deep);
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase
}

.pnl-h h3 {
  font-size: 1.0625rem;
  font-weight: 700
}

.pnl-h p {
  font-size: 0.8rem;
  color: var(--mute);
  margin-top: 1px
}

/* THE FIX: panel body MUST be scrollable */
.pnl-b {
  flex: 1 1 0;
  min-height: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 12px 14px 60px
}

.pnl-b::-webkit-scrollbar {
  width: 3px
}

.pnl-b::-webkit-scrollbar-thumb {
  background: var(--line);
  border-radius: 2px
}

.fd {
  margin-bottom: 14px
}

.fl {
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
  margin-bottom: 6px;
  display: flex;
  justify-content: space-between;
  align-items: center
}

.fl .inf {
  font-size: 0.75rem;
  color: var(--mute);
  font-weight: 500;
  text-transform: none;
  letter-spacing: 0
}

.og {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px
}

.og.c2 {
  grid-template-columns: repeat(2, 1fr)
}

.og.c4 {
  grid-template-columns: repeat(4, 1fr)
}

.og.c5 {
  grid-template-columns: repeat(5, 1fr)
}

.o {
  background: var(--white);
  border: 1.5px solid var(--line);
  border-radius: 8px;
  padding: 6px;
  text-align: center;
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  transition: all .12s;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px
}

.o small {
  font-size: 0.75rem;
  color: var(--mute);
  font-weight: 500
}

.o:hover {
  border-color: var(--pink);
  background: var(--pink-pastel)
}

.o.a {
  border-color: var(--pink);
  background: var(--pink);
  color: #fff;
  box-shadow: 0 2px 0 var(--pink-deep)
}

.o.a small {
  color: rgba(255, 255, 255, .8)
}

/* Part card with image placeholder */
.o .part-img {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 4px;
  background: var(--cream2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  color: var(--mute);
  overflow: hidden;
  margin-bottom: 2px
}

.o .part-img img {
  width: 100%;
  height: 100%;
  object-fit: contain
}

.swg {
  display: flex;
  flex-wrap: wrap;
  gap: 4px
}

.sw {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 2.5px solid transparent;
  cursor: pointer;
  transition: all .12s;
  background-clip: content-box;
  padding: 1px;
  background-origin: border-box
}

.sw:hover {
  transform: scale(1.08)
}

.sw.a {
  border-color: var(--ink);
  box-shadow: 0 0 0 2px var(--pink)
}

/* Rainbow color picker wheel */
.cpick {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: conic-gradient(red, yellow, lime, cyan, blue, magenta, red);
  cursor: pointer;
  position: relative;
  overflow: hidden;
  border: 2px solid var(--line)
}

.cpick input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  width: 100%;
  height: 100%
}

.cpick.a {
  border-color: var(--ink);
  box-shadow: 0 0 0 2px var(--pink)
}

.counter {
  display: flex;
  align-items: center;
  gap: 7px;
  background: var(--white);
  border: 1.5px solid var(--line);
  border-radius: 8px;
  padding: 3px;
  width: fit-content
}

.counter button {
  width: 28px;
  height: 28px;
  border-radius: 5px;
  background: var(--cream);
  font-weight: 800;
  font-size: 0.9375rem
}

.counter button:hover {
  background: var(--pink);
  color: #fff
}

.counter b {
  font-size: 1.0625rem;
  min-width: 22px;
  text-align: center;
  font-weight: 700
}

.ftabs {
  display: flex;
  gap: 3px;
  margin-bottom: 8px;
  flex-wrap: wrap;
  padding-bottom: 7px;
  border-bottom: 1px solid var(--line)
}

.ft {
  padding: 4px 7px;
  border-radius: 6px;
  background: var(--white);
  border: 1.5px solid var(--line);
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer
}

.ft.a {
  background: var(--green);
  color: var(--cream);
  border-color: var(--green-deep)
}

.ft.add {
  border-style: dashed;
  color: var(--pink-deep);
  border-color: var(--pink)
}

.inp {
  width: 100%;
  padding: 9px 10px;
  border-radius: 8px;
  border: 1.5px solid var(--line);
  background: var(--white);
  font-size: 0.875rem;
  outline: none;
  transition: border-color .12s
}

.inp:focus {
  border-color: var(--pink)
}

textarea.inp {
  min-height: 54px;
  resize: vertical
}

.ck {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 10px;
  background: var(--white);
  border: 1.5px solid var(--line);
  border-radius: 8px;
  cursor: pointer;
  margin-bottom: 4px
}

.ck.a {
  border-color: var(--pink);
  background: var(--pink-pastel)
}

.ck .dt {
  width: 15px;
  height: 15px;
  border-radius: 3px;
  border: 2px solid var(--line);
  background: #fff;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 0.75rem
}

.ck.a .dt {
  background: var(--pink);
  border-color: var(--pink)
}

.ck .bd {
  flex: 1
}

.ck .bd b {
  display: block;
  font-size: 0.875rem;
  font-weight: 700
}

.ck .bd small {
  font-size: 0.8rem;
  color: var(--mute);
  display: block
}

.ck .pr {
  font-weight: 800;
  font-size: 0.8rem;
  flex-shrink: 0
}

/* Pet card */
.pet-c {
  background: var(--white);
  border: 1.5px solid var(--line);
  border-radius: 8px;
  padding: 8px;
  text-align: center;
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  transition: all .12s;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px
}

.pet-c:hover {
  border-color: var(--pink);
  background: var(--pink-pastel)
}

.pet-c.a {
  border-color: var(--pink);
  background: var(--pink);
  color: #fff
}

.pet-i {
  width: 28px;
  height: 28px
}

.pet-c.a .pet-i svg {
  fill: #fff
}

.cstr-nv {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 9px 12px;
  display: flex;
  gap: 5px;
  background: var(--cream);
  border-top: 1px solid var(--line);
  z-index: 5;
  flex-shrink: 0
}

.cstr-nv .btn {
  flex: 1
}

.cstr-nv .bk {
  flex: 0 0 auto;
  padding: 11px 10px
}

.sgr {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3px
}

.sr {
  padding: 7px 8px;
  background: var(--white);
  border-radius: 5px;
  border: 1px solid var(--line);
  font-size: 0.875rem
}

.sr b {
  display: block;
  font-size: 0.75rem;
  color: var(--mute);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .05em
}

.fgrid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5px
}

.fgrid .full {
  grid-column: 1/-1
}

.success {
  padding: 28px 12px;
  text-align: center
}

.success .sic {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--pink);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  margin: 0 auto 12px;
  box-shadow: var(--sh-pink)
}

.onum {
  font-size: 1.25rem;
  font-weight: 800;
  background: var(--cream);
  padding: 7px 14px;
  border-radius: 8px;
  display: inline-block;
  border: 2px dashed var(--pink-soft);
  margin-bottom: 12px
}

.fade-in {
  animation: none
}

.legal-hero {
    padding: 44px 0 28px;
    background: linear-gradient(180deg, rgba(255, 211, 226, .18), transparent);
}

.legal-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 280px;
    gap: 20px;
    align-items: start;
}

.legal-card,
.legal-toc,
.legal-note {
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    box-shadow: var(--sh-sm);
}

.legal-card {
    padding: 28px;
}

.legal-note {
    padding: 14px 16px;
    margin-top: 16px;
    color: var(--mute);
    font-size: 0.9375rem;
}

.legal-meta {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-top: 20px;
}

.legal-meta div {
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 12px;
}

.legal-meta b {
    display: block;
    font-size: 0.8rem;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--pink-deep);
    margin-bottom: 3px;
}

.legal-meta span {
    display: block;
    font-size: 0.9375rem;
    color: var(--ink);
    font-weight: 600;
}

.legal-toc {
    position: sticky;
    top: calc(var(--hdr-h) + 16px);
    padding: 16px;
}

.legal-toc h3 {
    font-size: 0.875rem;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--pink-deep);
    margin-bottom: 10px;
}

.legal-toc a {
    display: block;
    position: relative;
    font-size: 0.875rem;
    padding: 7px 10px 7px 14px;
    color: var(--mute);
    border-bottom: 1px dashed var(--line);
    border-radius: 10px;
    transition: color .15s, background .15s, border-color .15s;
}

.legal-toc a:hover {
    color: var(--pink-deep);
}

.legal-toc a.active,
.legal-toc a[aria-current="true"] {
    color: var(--pink-deep);
    background: var(--pink-pastel);
    border-bottom-color: transparent;
    font-weight: 700;
}

.legal-toc a.active::before,
.legal-toc a[aria-current="true"]::before {
    content: "";
    position: absolute;
    left: 0;
    top: 8px;
    bottom: 8px;
    width: 3px;
    border-radius: 999px;
    background: var(--pink);
}

.legal-section {
    scroll-margin-top: calc(var(--hdr-h) + 16px);
    padding: 24px 0;
    border-bottom: 1px solid var(--line);
}

.legal-section:first-child {
    padding-top: 0;
}

.legal-section:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.legal-section h2 {
    font-size: clamp(1.25rem, 2.2vw, 1.75rem);
    line-height: 1.15;
    letter-spacing: -.02em;
    margin-bottom: 10px;
}

.legal-section h3 {
    font-size: 1.1rem;
    margin: 18px 0 8px;
}

.legal-section p,
.legal-section li {
    color: var(--mute);
    font-size: 1rem;
    line-height: 1.65;
}

.legal-section p + p,
.legal-section ul + p,
.legal-section ol + p {
    margin-top: 10px;
}

.legal-section ul,
.legal-section ol {
    padding-left: 22px;
    margin: 10px 0;
}

.legal-section li + li {
    margin-top: 6px;
}

.legal-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 12px;
    overflow: hidden;
    border-radius: 12px;
}

.legal-table th,
.legal-table td {
    text-align: left;
    vertical-align: top;
    padding: 12px;
    border: 1px solid var(--line);
    font-size: 1rem;
}

.legal-table th {
    width: 32%;
    background: var(--cream2);
    color: var(--ink);
}

.legal-callout {
    margin: 14px 0;
    padding: 14px 16px;
    border-radius: 14px;
    background: var(--pink-pastel);
    border: 1px solid var(--pink-soft);
    color: var(--ink);
}

.legal-callout p {
    color: var(--ink);
}

.legal-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 20px;
}

@media(max-width:960px) {
    .legal-layout {
        grid-template-columns: 1fr;
    }

    .legal-toc {
        position: static;
    }
}

@media(max-width:640px) {
    .legal-meta {
        grid-template-columns: 1fr;
    }

    .legal-card {
        padding: 18px;
    }

    .legal-table,
    .legal-table tbody,
    .legal-table tr,
    .legal-table th,
    .legal-table td {
        display: block;
        width: 100%;
    }

    .legal-table th {
        border-bottom: none;
    }
}

/* === FTM readability patch: predictable rem fonts + larger constructor text === */
.cstr-pr {
  gap: 8px;
}

.cst {
  font-size: 0.8125rem;
  line-height: 1.2;
}

.cst .n {
  width: 20px;
  height: 20px;
  font-size: 0.75rem;
}

.pnl-h .so,
.fl,
.fl .inf {
  font-size: 0.8125rem;
}

.pnl-h h3 {
  font-size: 1.25rem;
}

.pnl-h p {
  font-size: 0.9375rem;
}

.o,
.pet-c,
.ft,
.ck .bd b,
.ck .pr,
.sr,
.cstr-pv .pp,
.counter b,
.counter button,
.inp {
  font-size: 0.9375rem;
}

.o small,
.pet-c small,
.ck .bd small,
.sr b,
.o .part-img,
.cstr-pv .pp small {
  font-size: 0.8125rem;
}

.pet-c b,
.o b {
  font-size: 0.875rem !important;
  line-height: 1.15;
}

.og.c5 {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

@media(min-width:1025px) {
  .cstr-pn {
    width: 420px;
  }
}

@media(max-width:640px) {
  .cstr-pr {
    gap: 6px;
  }

  .cst {
    font-size: 0.75rem;
  }

  .pnl-h h3 {
    font-size: 1.15rem;
  }

  .og.c5 {
    grid-template-columns: repeat(3, 1fr);
  }
}
/* === FTM extended blocks from newer styles: LEGO figure builder + auth/account/cart pages === */
.lf-artboard {
  position: absolute;
  inset: 0;
  display: block;
  overflow: hidden;
}

.fr-o.lf-mode-plain {
  background: transparent;
  box-shadow: none;
  border-radius: 14px;
}

.fr-o.lf-mode-frame {
  box-shadow: var(--sh-lg);
}

.lf-frame-empty {
  position: absolute;
  left: 50%;
  top: 52%;
  transform: translate(-50%, -50%);
  width: 36%;
  aspect-ratio: 1 / 1.24;
  border: 1.5px dashed rgba(31, 77, 58, .26);
  border-radius: 8px;
  display: grid;
  place-items: center;
  color: rgba(31, 77, 58, .46);
  font-size: .75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.lf-build-board {
  position: absolute;
  inset: 0;
  border: 1.5px dashed rgba(224, 74, 133, .22);
  border-radius: 16px;
  background:
    linear-gradient(rgba(255, 255, 255, .64) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .64) 1px, transparent 1px),
    linear-gradient(135deg, #FFF7EF, #FFE4ED);
  background-size: 34px 34px, 34px 34px, 100% 100%;
  overflow: hidden;
}

.lf-bg-preview {
  border-radius: 16px;
  box-shadow: inset 0 0 0 1.5px rgba(31, 77, 58, .12);
}

.lf-bg-sample {
  position: absolute;
  left: 50%;
  top: 52%;
  transform: translate(-50%, -50%);
  width: 48%;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  background: rgba(255, 255, 255, .34);
  border: 1.5px solid rgba(255, 255, 255, .52);
  display: grid;
  place-items: center;
  color: rgba(31, 77, 58, .48);
  font-size: .75rem;
  font-weight: 800;
  text-transform: uppercase;
}

.lf-extra {
  position: absolute;
  z-index: 8;
  display: grid;
  place-items: center;
  transform: translate(-50%, -50%);
  min-width: 58px;
  min-height: 34px;
  padding: 7px 9px;
  border-radius: 8px;
  background: rgba(255, 255, 255, .82);
  border: 1.5px solid rgba(31, 77, 58, .14);
  color: var(--green-deep);
  font-size: .625rem;
  font-weight: 800;
  cursor: default;
  user-select: none;
}

.lf-extra-pets {
  cursor: grab;
  background: rgba(255, 255, 255, .88);
  border-color: rgba(224, 74, 133, .35);
  color: var(--pink-deep);
}

.lf-extra-card {
  color: var(--pink-deep);
}

.lf-extra-urgent {
  background: rgba(31, 77, 58, .88);
  color: var(--cream);
}

.lf-extra.is-dragging,
.lf-figure.is-dragging {
  cursor: grabbing;
  z-index: 12;
  transition: none;
}

.lf-title,
.lf-subtitle {
  position: absolute;
  left: 8%;
  right: 8%;
  text-align: center;
  color: var(--green-deep);
  font-weight: 800;
  pointer-events: none;
}

.lf-title {
  top: 9%;
  font-size: clamp(.625rem, 2.6vw, 1.875rem);
}

.lf-subtitle {
  bottom: 9%;
  font-size: clamp(.5rem, 1.6vw, 1.125rem);
  color: var(--pink-deep);
}

.lf-figure {
  position: absolute;
  width: 34%;
  min-width: 92px;
  aspect-ratio: 1.6 / 4;
  transform: translate(-50%, -50%) scale(var(--scale));
  transform-origin: center bottom;
  border: 0;
  background: transparent;
  color: var(--pink-deep);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  cursor: default;
  touch-action: none;
  user-select: none;
}

.lf-figure.lf-frame {
  cursor: grab;
  width: var(--fig-w);
  height: var(--fig-h);
  min-width: 0;
  aspect-ratio: auto;
  gap: 0;
}

.lf-figure.lf-build {
  width: 42%;
  min-width: 150px;
  transform-origin: center center;
}

.lf-figure.is-active {
  filter: drop-shadow(0 8px 16px rgba(20, 56, 40, .18));
}

.lf-stack {
  position: relative;
  width: 100%;
  flex: 1;
  overflow: hidden;
}

.lf-frame .lf-stack {
  height: 100%;
  flex: 0 0 100%;
}

.lf-build .lf-stack {
  aspect-ratio: 1.6 / 4;
  flex: 0 0 auto;
}

.lf-stack.is-empty::after {
  content: "выберите детали";
  position: absolute;
  left: 50%;
  bottom: 18%;
  transform: translateX(-50%);
  font-size: .625rem;
  font-weight: 800;
  color: rgba(224, 74, 133, .7);
  white-space: nowrap;
}

.lf-frame .lf-stack.is-empty::after {
  display: none;
}

.lf-silhouette {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: fill;
  object-position: center;
  pointer-events: none;
  opacity: .92;
  transform: translate(-50%, -50%);
  filter: drop-shadow(0 1px 0 rgba(255, 255, 255, .35));
}

.lf-layer {
  position: absolute;
  object-fit: contain;
  object-position: center;
  pointer-events: none;
}

.lf-shape {
  background: var(--layer-color);
  opacity: .96;
}

.lf-slot {
  border: 1.5px dashed rgba(31, 77, 58, .34);
  background: rgba(255, 255, 255, .1);
}

.lf-full {
  clip-path: polygon(43% 0, 57% 0, 57% 12%, 69% 12%, 69% 32%, 76% 38%, 73% 67%, 65% 67%, 64% 100%, 52% 100%, 52% 68%, 48% 68%, 48% 100%, 36% 100%, 35% 67%, 27% 67%, 24% 38%, 31% 32%, 31% 12%, 43% 12%);
}

.lf-legs {
  background:
    linear-gradient(90deg,
      var(--layer-color) 0 42%,
      transparent 42% 58%,
      var(--layer-color) 58% 100%);
  clip-path: none;
}

.lf-leg-set i,
.lf-leg-set b {
  position: absolute;
  display: block;
  background: var(--layer-color);
  opacity: .96;
}

.lf-leg-set i {
  top: 2%;
  width: 33%;
  height: 72%;
}

.lf-leg-set i:first-child {
  left: 9%;
}

.lf-leg-set i:nth-child(2) {
  right: 9%;
}

.lf-leg-set b {
  top: 72%;
  width: 42%;
  height: 20%;
}

.lf-leg-set b:nth-child(3) {
  left: 2%;
}

.lf-leg-set b:nth-child(4) {
  right: 2%;
}

.lf-torso {
  clip-path: polygon(7% 0, 93% 0, 82% 100%, 18% 100%);
}

.lf-head {
  border-radius: 2px;
}

.lf-hair {
  border-radius: 0;
  object-fit: contain;
}

.lf-shape.lf-hair {
  clip-path: polygon(12% 58%, 12% 20%, 24% 0, 76% 0, 88% 20%, 88% 58%, 74% 45%, 26% 45%);
}

.lf-accessory {
  border-radius: 0;
  clip-path: polygon(50% 0, 64% 32%, 100% 34%, 72% 56%, 82% 100%, 50% 76%, 18% 100%, 28% 56%, 0 34%, 36% 32%);
}

.lf-scale-block {
  display: none;
  pointer-events: none;
}

.lf-frame .lf-scale-block {
  position: absolute;
  left: 50%;
  top: calc(69.5% - 1px);
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  align-items: start;
  gap: 10%;
  width: 34%;
  height: calc(var(--stand-h, 5.5%) * .78);
  min-height: 1px;
  padding: .75% 10% 1.1%;
  transform: translateX(-50%);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .9) 0 16%, transparent 17%),
    linear-gradient(180deg, #fffdf9 0%, #f3eee7 48%, #d8d1c7 100%);
  border: 1.5px solid #1b1917;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, .95) inset,
    0 -1px 0 rgba(0, 0, 0, .2) inset,
    0 2px 3px rgba(0, 0, 0, .2);
}

.lf-frame .lf-scale-block i {
  display: block;
  aspect-ratio: 1 / .62;
  min-height: 1px;
  border-radius: 1px 1px 0 0;
  background: linear-gradient(180deg, #ffffff 0%, #ece5db 100%);
  border: 1px solid #1b1917;
  box-shadow: 0 1px 0 rgba(255, 255, 255, .95) inset;
}

.lf-frame span {
  position: absolute;
  left: 50%;
  top: calc(69.5% + var(--stand-h, 5.5%) * .78 + 3px);
  transform: translateX(-50%);
}

.lf-figure span {
  font-size: .6875rem;
  font-weight: 800;
  line-height: 1.1;
  max-width: 120%;
  white-space: nowrap;
}

.lf-choice-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

.lf-choice,
.lf-layer-row,
.lf-summary>div,
.lf-note {
  background: var(--white);
  border: 1.5px solid var(--line);
  border-radius: 8px;
}

.lf-choice {
  padding: 12px;
  text-align: left;
  display: grid;
  gap: 3px;
}

.lf-choice b {
  font-size: .8125rem;
}

.lf-choice small,
.lf-choice span,
.lf-note {
  font-size: .6875rem;
  color: var(--mute);
}

.lf-choice span {
  font-weight: 800;
  color: var(--pink-deep);
}

.lf-choice.a {
  border-color: var(--pink);
  background: var(--pink-pastel);
  box-shadow: 0 2px 0 var(--pink-deep);
}

.lf-swatch {
  width: 28px;
  height: 28px;
  border-radius: 4px;
  border: 2px solid var(--line);
}

.lf-note {
  padding: 12px;
  line-height: 1.35;
}

.lf-danger {
  width: 100%;
  min-height: 38px;
  border-radius: 8px;
  border: 1.5px solid rgba(224, 74, 133, .34);
  background: rgba(255, 111, 168, .12);
  color: var(--pink-deep);
  font-size: .75rem;
  font-weight: 800;
  cursor: pointer;
}

.lf-danger:hover {
  background: var(--pink);
  color: #fff;
  border-color: var(--pink-deep);
}

.lf-empty-build {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  padding: 12px 16px;
  border: 1.5px dashed rgba(224, 74, 133, .32);
  border-radius: 8px;
  background: rgba(255, 255, 255, .62);
  color: var(--pink-deep);
  font-size: .8125rem;
  font-weight: 800;
}

.lf-range {
  width: 100%;
  accent-color: var(--pink);
}

.lf-layers {
  display: grid;
  gap: 8px;
}

.lf-part-section {
  display: grid;
  gap: 8px;
  padding: 10px 0;
  border-top: 1px solid var(--line);
}

.lf-part-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.lf-part-head b {
  font-size: .75rem;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--mute);
  letter-spacing: .05em;
}

.lf-part-head button {
  font-size: .625rem;
  font-weight: 800;
  color: var(--pink-deep);
}

.lf-photo-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.lf-photo-card {
  min-height: 92px;
  border: 1.5px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  display: grid;
  grid-template-rows: 1fr auto;
  place-items: center;
  gap: 5px;
  padding: 8px;
  font-size: .625rem;
  font-weight: 800;
  color: var(--mute);
  cursor: pointer;
  overflow: hidden;
}

.lf-photo-card:hover,
.lf-photo-card.a {
  border-color: var(--pink);
  background: var(--pink-pastel);
}

.lf-photo-card.a {
  box-shadow: 0 2px 0 var(--pink-deep);
  color: var(--ink);
}

.lf-photo-card img {
  width: 100%;
  height: 58px;
  object-fit: contain;
}

.lf-photo-card.add {
  border-style: dashed;
  color: var(--pink-deep);
}

.lf-photo-card.add span {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--pink);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 1.375rem;
  line-height: 1;
}

.lf-card-shape {
  width: 54px;
  height: 58px;
  background: var(--layer-color);
}

.lf-layer-row {
  display: grid;
  grid-template-columns: 28px 1fr auto 34px;
  gap: 8px;
  align-items: center;
  padding: 9px;
}

.lf-eye {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  background: var(--cream);
  color: var(--mute);
  font-size: .875rem;
}

.lf-eye.a {
  background: var(--green);
  color: var(--cream);
}

.lf-layer-meta {
  min-width: 0;
}

.lf-layer-meta b,
.lf-layer-meta small {
  display: block;
}

.lf-layer-meta b {
  font-size: .75rem;
  font-weight: 800;
}

.lf-layer-meta small {
  font-size: .625rem;
  color: var(--mute);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.lf-upload {
  padding: 7px 9px;
  border-radius: 7px;
  background: var(--pink);
  color: #fff;
  font-size: .625rem;
  font-weight: 800;
  cursor: pointer;
}

.lf-mini-color {
  width: 34px;
  height: 30px;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.lf-summary {
  display: grid;
  gap: 8px;
  margin-bottom: 12px;
}

.lf-summary>div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px;
  font-size: .75rem;
}

.lf-summary span {
  color: var(--mute);
}

.lf-summary b {
  text-align: right;
}

.lf-summary .total {
  background: var(--green);
  color: var(--cream);
  border-color: var(--green-deep);
}

.lf-summary .total span {
  color: rgba(244, 233, 216, .7);
}

/* === FTM auth/account/cart pages === */
:root {
  --auth-max: 1120px;
}

body[data-page="login"],
body[data-page="register"],
body[data-page="account"],
body[data-page="cart"] {
  min-height: 100vh;
}

.page-main {
  min-height: calc(100vh - var(--hdr-h));
}

.page-hero-soft {
  position: relative;
  overflow: hidden;
  padding: 48px 0 36px;
  background:
    radial-gradient(ellipse at 12% 0%, rgba(255, 111, 168, .18), transparent 46%),
    radial-gradient(ellipse at 88% 12%, rgba(31, 77, 58, .12), transparent 48%);
}

.page-hero-soft::after {
  content: "";
  position: absolute;
  inset: auto -10vw -34% -10vw;
  height: 64%;
  background: radial-gradient(ellipse at 50% 100%, rgba(255, 211, 226, .5), transparent 58%);
  pointer-events: none;
}

.page-hero-soft .wrap {
  position: relative;
  z-index: 1;
}

.muted {
  color: var(--mute);
}

.link-pink {
  color: var(--pink-deep);
  font-weight: 800;
}

.link-pink:hover {
  color: var(--pink);
}

.icon-pill {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: var(--pink-pastel);
  color: var(--pink-deep);
  flex: 0 0 auto;
}

.auth-shell {
  max-width: var(--auth-max);
  margin: 0 auto;
  padding: 42px 20px 64px;
  display: grid;
  grid-template-columns: minmax(0, .94fr) minmax(360px, 1.06fr);
  gap: 18px;
  align-items: stretch;
}

body[data-page="login"] .auth-shell,
body[data-page="register"] .auth-shell {
  max-width: 620px;
  grid-template-columns: 1fr;
  align-items: center;
}

body[data-page="login"] .auth-card,
body[data-page="register"] .auth-card {
  width: 100%;
}

.auth-panel,
.auth-card,
.account-card,
.cart-card,
.summary-card,
.checkout-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-sm);
}

.auth-panel {
  padding: 28px;
  background:
    radial-gradient(circle at 20% 18%, rgba(255, 111, 168, .22), transparent 30%),
    linear-gradient(145deg, var(--green), var(--green-deep));
  color: var(--cream);
  overflow: hidden;
  position: relative;
  min-height: 590px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.auth-panel::after {
  content: "";
  position: absolute;
  right: -72px;
  bottom: -72px;
  width: 240px;
  height: 240px;
  border-radius: 50%;
  background: rgba(255, 111, 168, .16);
  border: 1px solid rgba(244, 233, 216, .12);
}

.auth-panel .eyebrow {
  color: var(--pink);
}

.auth-panel .lead {
  color: rgba(244, 233, 216, .74);
  max-width: 42ch;
}

.auth-visual {
  margin-top: 34px;
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  z-index: 1;
}

.auth-mini-frame {
  min-height: 210px;
  border-radius: 18px;
  background: rgba(244, 233, 216, .09);
  border: 1px solid rgba(244, 233, 216, .11);
  padding: 14px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 0 16px 36px rgba(0, 0, 0, .12);
}

.auth-mini-frame:nth-child(2) {
  transform: translateY(28px) rotate(2deg);
}

.auth-frame-inner {
  flex: 1;
  border-radius: 12px;
  background: linear-gradient(135deg, #fff7ef, #ffe4ed);
  border: 10px solid rgba(251, 243, 232, .94);
  box-shadow: inset 0 0 0 1px rgba(31, 77, 58, .08);
  display: grid;
  place-items: center;
  color: var(--green-deep);
  font-weight: 800;
  text-align: center;
  padding: 12px;
}

.auth-mini-frame span {
  margin-top: 10px;
  font-size: .8125rem;
  color: rgba(244, 233, 216, .72);
  font-weight: 700;
}

.auth-benefits {
  display: grid;
  gap: 9px;
  position: relative;
  z-index: 1;
}

.auth-benefit {
  display: flex;
  gap: 10px;
  padding: 12px;
  border-radius: 14px;
  background: rgba(244, 233, 216, .07);
  border: 1px solid rgba(244, 233, 216, .08);
}

.auth-benefit b {
  display: block;
  font-size: .9375rem;
}

.auth-benefit span {
  display: block;
  margin-top: 1px;
  font-size: .8125rem;
  color: rgba(244, 233, 216, .68);
}

.auth-card {
  padding: 32px;
  align-self: center;
}

.auth-card-head {
  margin-bottom: 22px;
}

.auth-card-head .lead {
  margin-top: 8px;
}

.form-stack {
  display: grid;
  gap: 14px;
}

.form-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.field label,
.field .field-label {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
  font-size: .8125rem;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--ink);
}

.field-hint {
  display: block;
  margin-top: 6px;
  color: var(--mute);
  font-size: .8125rem;
  line-height: 1.35;
}

.register-code label {
  display: block;
  margin-bottom: 6px;
  font-size: .8125rem;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--ink);
}

.register-code .auth-input-code {
  width: 100%;
  border: 1.5px solid var(--line);
  background: var(--white);
  border-radius: 12px;
  padding: 12px 13px;
  min-height: 46px;
  outline: none;
  transition: border-color .14s, box-shadow .14s, background .14s;
  font-size: 1.25rem;
  letter-spacing: .2em;
  text-align: center;
}

.register-code {
  display: grid;
  gap: 10px;
}

.register-verify-button {
  margin-top: 2px;
}

.auth-input,
.auth-select,
.auth-textarea {
  width: 100%;
  border: 1.5px solid var(--line);
  background: var(--white);
  border-radius: 12px;
  padding: 12px 13px;
  min-height: 46px;
  outline: none;
  transition: border-color .14s, box-shadow .14s, background .14s;
}

.auth-textarea {
  min-height: 94px;
  resize: vertical;
}

.auth-input:focus,
.auth-select:focus,
.auth-textarea:focus {
  border-color: var(--pink);
  box-shadow: 0 0 0 4px rgba(255, 111, 168, .12);
}

.password-wrap {
  position: relative;
}

.password-wrap .auth-input {
  padding-right: 54px;
}

.pass-toggle {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 32px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--cream);
  color: var(--mute);
  font-size: .75rem;
  font-weight: 800;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.pass-toggle img {
  width: 28px;
}

.pass-toggle:hover {
  background: var(--pink-pastel);
  color: var(--pink-deep);
}

.checkline {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  color: var(--mute);
  font-size: .9rem;
  line-height: 1.35;
}

.checkline input {
  width: 18px;
  height: 18px;
  accent-color: var(--pink);
  flex: 0 0 auto;
  margin-top: 1px;
}

.form-actions {
  display: grid;
  gap: 10px;
  margin-top: 4px;
}


.auth-alt {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.auth-note {
  margin-top: 16px;
  padding: 14px;
  border-radius: 14px;
  background: var(--cream2);
  color: var(--mute);
  font-size: .9rem;
  line-height: 1.45;
}

.account-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: end;
}

.account-hero-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.account-layout {
  display: grid;
  grid-template-columns: 270px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
  padding: 34px 20px 64px;
}

.account-sidebar {
  position: sticky;
  top: calc(var(--hdr-h) + 16px);
  display: grid;
  gap: 12px;
}

.account-profile-mini {
  padding: 16px;
}

.avatar {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: var(--pink);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 1.25rem;
  font-weight: 800;
  box-shadow: var(--sh-pink);
}

.account-profile-mini .avatar {
  margin-bottom: 10px;
}

.account-profile-mini b {
  display: block;
  font-size: 1.05rem;
}

.account-profile-mini span {
  display: block;
  color: var(--mute);
  font-size: .875rem;
  margin-top: 2px;
}

.account-menu {
  padding: 8px;
}

.account-tab {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 11px 12px;
  border-radius: 12px;
  font-weight: 800;
  color: var(--mute);
  text-align: left;
  transition: background .12s, color .12s;
}

.account-tab:hover {
  background: var(--pink-pastel);
  color: var(--pink-deep);
}

.account-tab.active {
  background: var(--green);
  color: var(--cream);
}

.account-content {
  display: grid;
  gap: 14px;
}

.account-section {
  display: none;
}

.account-section.active {
  display: grid;
  gap: 14px;
  padding: 0px;
}

.account-profile-mini {
  display: grid;
  gap: 8px;
}

#exit_from_account {
  width: 100%;
  margin-top: 10px;

  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;

  padding: 11px 17px;
  border-radius: 999px;

  background: var(--pink);
  color: #fff;
  box-shadow: var(--sh-pink);

  font-family: var(--ff);
  font-weight: 700;
  font-size: 0.9375rem;
  line-height: 1;

  border: none;
  cursor: pointer;
  white-space: nowrap;

  transition:
    transform .15s,
    box-shadow .15s,
    background .12s;
}

#exit_from_account:hover {
  background: var(--pink-deep);
  transform: translateY(-2px);
}

#exit_from_account:active {
  transform: translateY(1px);
  box-shadow: 0 2px 0 var(--pink-deep);
}

#exit_from_account:focus-visible {
  outline: 3px solid rgba(255, 111, 168, .38);
  outline-offset: 3px;
}

.logout-modal {
  position: fixed;
  inset: 0;
  z-index: 140;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.logout-modal.open {
  display: flex;
}

.logout-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(42, 40, 35, .42);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.logout-modal__dialog {
  position: relative;
  z-index: 1;
  width: min(100%, 430px);
  padding: 30px;
  border-radius: 28px;
  background:
    radial-gradient(circle at 18% 12%, rgba(255, 111, 168, .18), transparent 32%),
    var(--white);
  border: 1px solid var(--line);
  box-shadow: var(--sh-lg);
  text-align: center;
}

.logout-modal__close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--cream);
  border: 1px solid var(--line);
  color: var(--mute);
  font-size: 1.35rem;
  line-height: 1;
  transition: transform .15s, background .12s, color .12s;
}

.logout-modal__close:hover {
  background: var(--pink-pastel);
  color: var(--pink-deep);
  transform: translateY(-1px);
}

.logout-modal__icon {
  width: 58px;
  height: 58px;
  margin: 0 auto 14px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--pink);
  color: #fff;
  box-shadow: var(--sh-pink);
  font-size: 1.35rem;
  font-weight: 800;
}

.logout-modal__dialog h2 {
  font-size: clamp(1.5rem, 4vw, 2rem);
  line-height: 1.05;
  letter-spacing: -.03em;
}

.logout-modal__dialog p {
  margin: 8px auto 20px;
  max-width: 34ch;
  color: var(--mute);
  font-size: .95rem;
}

.logout-modal__actions {
  display: grid;
  gap: 10px;
}

.logout-modal__actions .btn {
  min-height: 46px;
}

.logout-modal__actions .btn:disabled {
  opacity: .65;
  pointer-events: none;
}

@media(max-width:460px) {
  .logout-modal {
    align-items: flex-end;
    padding: 12px;
  }

  .logout-modal__dialog {
    padding: 28px 18px 18px;
    border-radius: 24px;
  }
}

.account-card {
  padding: 20px;
}

.card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 16px;
}

.card-head h2,
.card-head h3 {
  font-size: clamp(1.25rem, 2vw, 1.75rem);
  line-height: 1.12;
  letter-spacing: -.02em;
}

.card-head p {
  color: var(--mute);
  margin-top: 4px;
  font-size: .95rem;
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 9px;
}

.stat-card {
  background: var(--cream2);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 14px;
}

.stat-card b {
  display: block;
  font-size: 1.6rem;
  line-height: 1;
  letter-spacing: -.03em;
  color: var(--green);
}

.stat-card span {
  display: block;
  color: var(--mute);
  margin-top: 6px;
  font-size: .875rem;
  line-height: 1.25;
}

.order-list,
.project-list,
.address-list,
.support-list {
  display: grid;
  gap: 9px;
}

.order-card {
  border: 1.5px solid var(--line);
  border-radius: 16px;
  background: var(--white);
  overflow: hidden;
}

.order-top {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 12px;
  align-items: center;
  padding: 14px;
}

.order-title b {
  display: block;
  font-size: 1rem;
}

.order-title span {
  display: block;
  color: var(--mute);
  font-size: .875rem;
  margin-top: 2px;
}

.status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: .75rem;
  font-weight: 800;
  white-space: nowrap;
}

.status.pink {
  background: var(--pink-pastel);
  color: var(--pink-deep);
}

.status.green {
  background: rgba(31, 77, 58, .1);
  color: var(--green);
}

.status.gray {
  background: var(--cream2);
  color: var(--mute);
}

.order-more {
  border-top: 1px dashed var(--line);
  padding: 0 14px 14px;
  display: none;
  color: var(--mute);
  font-size: .9375rem;
}

.order-card.open .order-more {
  display: block;
}

.timeline {
  display: grid;
  gap: 7px;
  margin-top: 12px;
}

.timeline div {
  display: flex;
  gap: 8px;
  align-items: flex-start;
}

.timeline i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--line);
  margin-top: 7px;
  flex: 0 0 auto;
}

.timeline div.done i {
  background: var(--pink);
}

.project-card,
.address-card,
.support-card {
  padding: 14px;
  border: 1.5px solid var(--line);
  border-radius: 16px;
  background: var(--white);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
}

.project-card b,
.address-card b,
.support-card b {
  display: block;
  font-size: 1rem;
}

.project-card span,
.address-card span,
.support-card span {
  display: block;
  margin-top: 3px;
  color: var(--mute);
  font-size: .875rem;
}

.profile-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.profile-form .full {
  grid-column: 1 / -1;
}

.cart-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 18px;
  align-items: start;
  padding: 34px 20px 64px;
}

.cart-stack {
  display: grid;
  gap: 14px;
}

.cart-card,
.summary-card,
.checkout-card {
  padding: 20px;
}

.cart-item {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr) auto;
  gap: 14px;
  padding: 14px 0;
  border-top: 1px solid var(--line);
}

.cart-item:first-child {
  border-top: none;
  padding-top: 0;
}

.cart-preview {
  width: 112px;
  display: grid;
  gap: 6px;
}

.cart-thumb,
.cart-preview-mini {
  width: 100%;
  border-radius: 18px;
  background: var(--cream2);
  border: 1px solid var(--line);
  overflow: hidden;
  display: block;
  padding: 0;
  cursor: zoom-in;
}

.cart-thumb {
  aspect-ratio: 1 / 1;
}

.cart-thumb img,
.cart-preview-mini img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: var(--cream2);
  transition: transform .18s ease;
}

.cart-thumb:hover img,
.cart-preview-mini:hover img {
  transform: scale(1.04);
}

.cart-preview-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 4px;
}

.cart-preview-mini {
  aspect-ratio: 1 / 1;
  border-radius: 10px;
}

.cart-item-body h3 {
  font-size: 1.125rem;
  line-height: 1.15;
}

.cart-item-body p {
  color: var(--mute);
  margin-top: 5px;
  font-size: .9375rem;
}

.cart-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 10px;
}

.cart-tag {
  padding: 4px 8px;
  border-radius: 999px;
  background: var(--cream2);
  color: var(--mute);
  font-size: .75rem;
  font-weight: 800;
}

.cart-item-side {
  display: grid;
  align-content: space-between;
  justify-items: end;
  gap: 12px;
}

.cart-price {
  font-size: 1.125rem;
  font-weight: 800;
  color: var(--green);
  white-space: nowrap;
}

.qty {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  border: 1.5px solid var(--line);
  background: var(--white);
  border-radius: 999px;
  padding: 3px;
}

.qty button {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--cream);
  font-weight: 800;
}

.qty button:hover {
  background: var(--pink);
  color: #fff;
}

.qty span {
  min-width: 26px;
  text-align: center;
  font-weight: 800;
}

.remove-item {
  color: var(--mute);
  font-size: .8125rem;
  font-weight: 800;
}

.remove-item:hover {
  color: var(--pink-deep);
}

.summary-card {
  position: sticky;
  top: calc(var(--hdr-h) + 16px);
}

.summary-row {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 10px 0;
  border-bottom: 1px dashed var(--line);
  color: var(--mute);
}

.summary-row b {
  color: var(--ink);
  text-align: right;
}

.summary-row.total {
  margin-top: 6px;
  border-bottom: none;
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--ink);
}

.summary-row.total b {
  color: var(--green);
}

.promo-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 7px;
  margin: 14px 0;
}

.image-preview-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 22px;
}

.image-preview-modal.open {
  display: flex;
}

.image-preview-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(20, 56, 40, .62);
  cursor: zoom-out;
}

.image-preview-box {
  position: relative;
  z-index: 1;
  width: min(920px, 100%);
  max-height: min(86vh, 760px);
  display: grid;
  gap: 10px;
  padding: 14px;
  border-radius: var(--r-lg);
  background: var(--cream);
  border: 1px solid var(--line);
  box-shadow: var(--sh-lg);
}

.image-preview-box img {
  width: 100%;
  max-height: calc(86vh - 92px);
  object-fit: contain;
  border-radius: 16px;
  background: var(--cream2);
}

.image-preview-close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--white);
  border: 1px solid var(--line);
  box-shadow: var(--sh-sm);
  font-weight: 800;
}

.image-preview-caption {
  color: var(--mute);
  font-size: .9375rem;
  font-weight: 700;
  text-align: center;
}

.checkout-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.checkout-option {
  text-align: left;
  padding: 12px;
  border: 1.5px solid var(--line);
  border-radius: 14px;
  background: var(--white);
  cursor: pointer;
}

.checkout-option:hover,
.checkout-option.active {
  border-color: var(--pink);
  background: var(--pink-pastel);
}

.checkout-option b,
.checkout-option span {
  display: block;
}

.checkout-option b {
  font-size: .9375rem;
}

.checkout-option span {
  color: var(--mute);
  font-size: .8125rem;
  margin-top: 3px;
}

.cart-empty {
  display: none;
  text-align: center;
  padding: 36px 18px;
  border: 1.5px dashed var(--line);
  border-radius: var(--r-lg);
  background: var(--white);
}

.cart-empty.show {
  display: block;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 22px;
  transform: translateX(-50%) translateY(18px);
  opacity: 0;
  pointer-events: none;
  z-index: 999;
  background: var(--green);
  color: var(--cream);
  border-radius: 999px;
  padding: 11px 16px;
  box-shadow: var(--sh-lg);
  font-weight: 800;
  font-size: .9rem;
  transition: opacity .2s, transform .2s;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

@media(max-width:1000px) {
  .auth-shell,
  .account-layout,
  .cart-layout {
    grid-template-columns: 1fr;
  }

  .auth-panel {
    min-height: auto;
  }

  .account-sidebar,
  .summary-card {
    position: static;
  }

  .account-menu {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
  }
}

@media(max-width:760px) {
  .auth-shell {
    padding-top: 24px;
  }

  .auth-panel {
    display: none;
  }

  .auth-card,
  .account-card,
  .cart-card,
  .summary-card,
  .checkout-card {
    padding: 18px;
  }

  .form-grid-2,
  .profile-form,
  .checkout-grid,
  .stat-grid {
    grid-template-columns: 1fr;
  }

  .account-hero-grid {
    grid-template-columns: 1fr;
  }

  .account-hero-actions {
    justify-content: flex-start;
  }

  .account-menu {
    grid-template-columns: 1fr 1fr;
  }

  .order-top,
  .project-card,
  .address-card,
  .support-card {
    grid-template-columns: 1fr;
    justify-items: start;
  }

  .cart-item {
    grid-template-columns: 88px minmax(0, 1fr);
  }

  .cart-item-side {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    justify-items: stretch;
  }

  .promo-row {
    grid-template-columns: 1fr;
  }
}

@media(max-width:460px) {
  .auth-alt,
  .account-menu {
    grid-template-columns: 1fr;
  }

  .cart-item {
    grid-template-columns: 1fr;
  }

  .cart-preview {
    width: min(160px, 100%);
  }

  .cart-thumb {
    max-width: 160px;
  }

  .page-hero-soft {
    padding-top: 34px;
  }
}



/* === Account order status mockup === */
.account-dev-note {
  display: grid;
  gap: 6px;
  padding: 14px;
  background: var(--cream2);
}

.account-dev-note b {
  color: var(--green);
}

.account-dev-note span,
.account-dev-note code {
  font-size: .875rem;
  color: var(--mute);
}

.account-dev-note code {
  color: var(--pink-deep);
  font-weight: 800;
}

.stat-grid-wide .stat-card b {
  color: var(--pink-deep);
}

.order-list-rich {
  gap: 14px;
}

.order-card-rich {
  border-width: 1.5px;
  box-shadow: var(--sh-sm);
}

.order-top-rich {
  grid-template-columns: minmax(0, 1fr) auto auto auto;
  align-items: start;
  gap: 10px;
}

.order-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 9px;
}

.order-tag {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 4px 8px;
  border-radius: 999px;
  background: var(--cream2);
  color: var(--mute);
  font-size: .75rem;
  font-weight: 800;
  line-height: 1;
}

.order-tag.paid {
  background: rgba(31, 77, 58, .1);
  color: var(--green);
}

.status.amber {
  background: #FFF0C2;
  color: #8A5A00;
}

.status.blue {
  background: #E7F0FF;
  color: #255AA8;
}

.status.red {
  background: #FFE2E2;
  color: #B3261E;
}

.btn-manager {
  box-shadow: 0 4px 0 var(--green-deep);
}

.order-mockup-note {
  padding: 14px 16px;
  margin-bottom: 14px;
  border: 1.5px dashed var(--pink-soft);
  border-radius: 16px;
  background: var(--pink-pastel);
  color: var(--ink);
  font-size: .9375rem;
}

.order-mockup-note a {
  color: var(--pink-deep);
  font-weight: 800;
}

.order-more {
  padding-top: 14px;
}

.order-stage-note {
  padding: 12px 14px;
  border-radius: 14px;
  background: var(--cream2);
  color: var(--mute);
  line-height: 1.45;
  margin-bottom: 12px;
}

.order-stage-note b {
  color: var(--ink);
}

.order-info-grid,
.order-detail-grid {
  display: grid;
  gap: 10px;
}

.order-info-grid {
  grid-template-columns: repeat(3, 1fr);
  margin-bottom: 12px;
}

.order-info-grid > div,
.order-breakdown,
.order-progress-card {
  border: 1.5px solid var(--line);
  border-radius: 14px;
  background: var(--white);
}

.order-info-grid > div {
  padding: 12px;
}

.order-info-grid span,
.order-breakdown h3,
.order-progress-card h3 {
  display: block;
  font-size: .75rem;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--pink-deep);
}

.order-info-grid b {
  display: block;
  margin-top: 4px;
  font-size: .98rem;
  color: var(--ink);
}

.order-info-grid small {
  display: block;
  margin-top: 4px;
  color: var(--mute);
  line-height: 1.35;
}

.order-detail-grid {
  grid-template-columns: minmax(0, 1.08fr) minmax(260px, .92fr);
}

.order-breakdown,
.order-progress-card {
  padding: 14px;
}

.order-price-line,
.order-price-total {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 8px 0;
  border-bottom: 1px dashed var(--line);
  color: var(--mute);
}

.order-price-line b,
.order-price-total b {
  color: var(--ink);
  text-align: right;
  white-space: nowrap;
}

.order-price-total {
  margin-top: 6px;
  padding: 12px 0 0;
  border-bottom: none;
  color: var(--ink);
  font-weight: 800;
}

.order-price-total b {
  color: var(--green);
  font-size: 1.25rem;
}

.order-timeline {
  margin-top: 10px;
}

.timeline div.active i {
  background: var(--green);
  box-shadow: 0 0 0 4px rgba(31, 77, 58, .1);
}

.timeline div.active span {
  color: var(--green);
  font-weight: 800;
}

.status-def-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
}

.status-def {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 10px;
  padding: 12px;
  border: 1.5px solid var(--line);
  border-radius: 14px;
  background: var(--white);
}

.status-index {
  grid-row: span 2;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--green);
  color: var(--cream);
  font-size: .75rem;
  font-weight: 800;
}

.status-def b {
  line-height: 1.2;
}

.status-def p {
  color: var(--mute);
  font-size: .875rem;
  line-height: 1.35;
}

@media(max-width:1040px) {
  .order-top-rich {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .btn-manager,
  .order-top-rich [data-order-toggle] {
    justify-self: start;
  }
}

@media(max-width:760px) {
  .order-top-rich,
  .order-info-grid,
  .order-detail-grid,
  .status-def-grid {
    grid-template-columns: 1fr;
  }

  .btn-manager,
  .order-top-rich [data-order-toggle] {
    width: 100%;
  }

  .order-price-line,
  .order-price-total {
    align-items: flex-start;
  }
}

/* === FTM smooth button interactions === */
@media (prefers-reduced-motion: no-preference) {
  :where(
    .btn,
    .ib,
    .bm-b a,
    .bm-f .btn,
    .account-tab,
    .checkout-option,
    .qty button,
    .remove-item,
    .promo-row button,
    .cart-thumb,
    .image-preview-close,
    .image-preview-backdrop,
    .pass-toggle,
    .sb,
    .ai-q,
    .cc,
    .gc,
    .psc,
    .o,
    .sw,
    .counter button,
    .ft,
    .ck,
    .pet-c,
    .lf-choice,
    .lf-photo-card,
    .lf-danger,
    .lf-upload,
    .lf-eye,
    .lf-part-head button
  ) {
    transition:
      transform .22s cubic-bezier(.22, 1, .36, 1),
      box-shadow .22s cubic-bezier(.22, 1, .36, 1),
      background-color .18s ease,
      border-color .18s ease,
      color .18s ease,
      opacity .18s ease,
      filter .18s ease;
  }

  :where(.btn, .ib, .checkout-option, .qty button, .promo-row button, .cart-thumb, .pass-toggle, .sb, .account-tab):hover {
    will-change: transform;
  }

  .btn-s:hover {
    transform: translateY(-2px);
    box-shadow: var(--sh-md);
  }

  .checkout-option:hover {
    transform: translateY(-2px);
    box-shadow: var(--sh-sm);
  }

  .checkout-option.active {
    box-shadow: 0 3px 0 var(--pink-deep);
  }

  .qty button:hover,
  .promo-row button:hover,
  .pass-toggle:hover,
  .image-preview-close:hover,
  .account-tab:hover,
  .remove-item:hover {
    transform: translateY(-1px);
  }

  .cart-thumb:hover {
    transform: translateY(-2px);
    border-color: var(--pink-soft);
    box-shadow: var(--sh-md);
  }

  .sb:hover {
    transform: translateY(-2px) scale(1.04);
  }

  .btn:active,
  .ib:active,
  .checkout-option:active,
  .qty button:active,
  .promo-row button:active,
  .cart-thumb:active,
  .pass-toggle:active,
  .image-preview-close:active,
  .account-tab:active,
  .sb:active,
  .remove-item:active {
    transform: translateY(1px) scale(.98);
    box-shadow: none;
  }

  .btn-p:active {
    box-shadow: 0 2px 0 var(--pink-deep);
  }

  .btn-d:active {
    box-shadow: 0 2px 0 var(--green-deep);
  }

  .btn-s:active,
  .checkout-option:active,
  .cart-thumb:active {
    box-shadow: var(--sh-sm);
  }
}

:where(button, a, input, textarea, select):focus-visible {
  outline: 3px solid rgba(255, 111, 168, .38);
  outline-offset: 3px;
}


/* === Cart production deadline options === */
.production-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.production-grid .checkout-option b {
  line-height: 1.15;
}

.production-grid .checkout-option span {
  line-height: 1.35;
}

[data-summary-production].positive {
  color: var(--pink-deep);
}

[data-summary-production].negative {
  color: var(--green);
}

@media(max-width:760px) {
  .production-grid {
    grid-template-columns: 1fr;
  }
}

/* === Register page fixes: custom password eye and code confirm button === */
.password-wrap input[type="password"]::-ms-reveal,
.password-wrap input[type="password"]::-ms-clear {
  display: none;
  width: 0;
  height: 0;
}

.password-wrap input[type="password"]::-webkit-credentials-auto-fill-button,
.password-wrap input[type="password"]::-webkit-caps-lock-indicator {
  visibility: hidden;
  display: none !important;
  pointer-events: none;
}

.password-wrap .pass-toggle:hover {
  transform: translateY(calc(-50% - 1px));
}

.password-wrap .pass-toggle:active {
  transform: translateY(calc(-50% + 1px)) scale(.98);
}



/* === Register page polish: compact code confirm + stable password eye === */
.register-code[aria-hidden="false"] {
  display: grid !important;
  gap: 8px;
}

.register-code-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: stretch;
}

.register-code .auth-input-code {
  min-height: 46px;
  padding: 12px 14px;
  border-radius: 12px;
  font-size: .9375rem;
  letter-spacing: .04em;
  text-align: left;
}

.register-code .auth-input-code::placeholder {
  color: var(--mute);
  opacity: .62;
  letter-spacing: normal;
}

.register-verify-button {
  min-height: 46px;
  padding: 0 22px;
  border-radius: 12px;
  font-size: .9375rem;
  align-self: stretch;
  box-shadow: 0 4px 0 var(--pink-deep);
}

.register-verify-button:hover {
  transform: translateY(-1px);
}

.register-verify-button:active {
  transform: translateY(1px) scale(.99);
  box-shadow: 0 2px 0 var(--pink-deep);
}

[data-password-hint] {
  max-width: 126px;
  text-align: right;
  line-height: 1.1;
  font-size: .72rem;
  letter-spacing: .035em;
}

.password-wrap .auth-input[type="password"],
.password-wrap .auth-input[type="text"] {
  -webkit-appearance: none;
  appearance: none;
  background-image: none !important;
}

.password-wrap .auth-input::-ms-reveal,
.password-wrap .auth-input::-ms-clear {
  display: none !important;
  width: 0 !important;
  height: 0 !important;
}

.password-wrap .auth-input::-webkit-credentials-auto-fill-button,
.password-wrap .auth-input::-webkit-caps-lock-indicator,
.password-wrap .auth-input::-webkit-contacts-auto-fill-button {
  visibility: hidden !important;
  display: none !important;
  pointer-events: none !important;
}

.password-wrap .pass-toggle {
  z-index: 2;
  overflow: visible;
  transform: translateY(-50%);
}

.password-wrap .pass-toggle::before {
  content: "";
  position: absolute;
  top: 50%;
  right: 100%;
  width: 30px;
  height: 36px;
  transform: translateY(-50%);
  background: var(--white);
  pointer-events: none;
}

.password-wrap .pass-toggle img {
  position: relative;
  z-index: 1;
  width: 22px;
  height: 22px;
  object-fit: contain;
}

.password-wrap .pass-toggle:hover {
  transform: translateY(calc(-50% - 1px));
}

.password-wrap .pass-toggle:active {
  transform: translateY(calc(-50% + 1px)) scale(.98);
}

@media(max-width:560px) {
  .register-code-row {
    grid-template-columns: 1fr;
  }

  .register-verify-button {
    width: 100%;
  }

  [data-password-hint] {
    max-width: none;
  }
}

/* === Register code field v3: identical input + inline confirm button === */
.register-code[aria-hidden="false"] {
  display: block !important;
}

.register-code-row {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) 150px !important;
  gap: 10px;
  align-items: stretch;
}

.register-code-row .auth-input {
  width: 100%;
  min-height: 46px;
  height: 46px;
  padding: 12px 13px;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  background: var(--white);
  font-size: inherit;
  letter-spacing: normal;
  text-align: left;
}

.register-code-row .auth-input::placeholder {
  color: var(--mute);
  opacity: .62;
  letter-spacing: normal;
}

.register-verify-button {
  width: 150px;
  min-height: 46px;
  height: 46px;
  padding: 0 16px;
  border-radius: 12px;
  font-size: .9375rem;
  align-self: stretch;
  box-shadow: var(--sh-pink);
}

.register-verify-button:hover {
  transform: translateY(-2px);
}

.register-verify-button:active {
  transform: translateY(1px);
  box-shadow: 0 2px 0 var(--pink-deep);
}

@media(max-width:420px) {
  .register-code-row {
    grid-template-columns: minmax(0, 1fr) 132px !important;
    gap: 7px;
  }

  .register-verify-button {
    width: 132px;
    padding: 0 12px;
    font-size: .875rem;
  }
}

/* === Recovery page: final success state === */
.recovery-password-success {
  justify-items: center;
  padding: 32px 14px 8px;
}

.recovery-password-success h3 {
  font-size: clamp(1.35rem, 3vw, 1.75rem);
  color: var(--green);
}

.recovery-password-success .sic {
  width: 64px;
  height: 64px;
  font-size: 2rem;
}

/* === Auth visibility states: login / forgot password / recovery success === */
[hidden] {
  display: none !important;
}

.forgot-password-form[aria-hidden="true"],
.forgot-password-success[aria-hidden="true"],
.recovery-password-success[aria-hidden="true"] {
  display: none !important;
}

.forgot-password-form[aria-hidden="false"] {
  display: grid;
}

.forgot-password-success[aria-hidden="false"],
.recovery-password-success[aria-hidden="false"] {
  display: grid;
  gap: 12px;
  justify-items: center;
  text-align: center;
}

.forgot-password-success,
.recovery-password-success {
  padding: 32px 14px 8px;
}

.forgot-password-success .sic,
.recovery-password-success .sic {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--pink);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  font-weight: 800;
  line-height: 1;
  box-shadow: var(--sh-pink);
}

.forgot-password-success h3,
.recovery-password-success h3 {
  font-size: clamp(1.35rem, 3vw, 1.75rem);
  color: var(--green);
  line-height: 1.15;
}

.forgot-password-success p,
.recovery-password-success p {
  max-width: 34ch;
  color: var(--mute);
  font-size: 1rem;
  line-height: 1.45;
}

.forgot-password-message {
  padding: 12px 14px;
  border-radius: 14px;
  background: var(--pink-pastel);
  border: 1px solid var(--pink-soft);
  color: var(--pink-deep);
  font-weight: 700;
  font-size: .9375rem;
  line-height: 1.35;
}


/* === FTM 404 page === */
body[data-page="error"] {
  min-height: 100vh;
}

body[data-page="error"] .page-main {
  min-height: calc(100vh - var(--hdr-h));
}

.error-shell {
  max-width: 860px;
  margin: 0 auto;
  padding: 52px 20px 72px;
  display: grid;
  place-items: center;
}

.error-card {
  position: relative;
  width: 100%;
  padding: clamp(28px, 5vw, 52px);
  overflow: hidden;
  text-align: center;
  background:
    radial-gradient(circle at 16% 12%, rgba(255, 111, 168, .20), transparent 34%),
    radial-gradient(circle at 86% 18%, rgba(31, 77, 58, .10), transparent 36%),
    var(--white);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-sm);
}

.error-card::after {
  content: "";
  position: absolute;
  right: -72px;
  bottom: -82px;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: rgba(255, 111, 168, .13);
  border: 1px solid rgba(255, 111, 168, .18);
  pointer-events: none;
}

.error-card > * {
  position: relative;
  z-index: 1;
}

.error-code {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(8px, 2.2vw, 20px);
  margin: 4px auto 18px;
  color: var(--green);
  font-size: clamp(4.5rem, 18vw, 10.5rem);
  font-weight: 800;
  line-height: .82;
  letter-spacing: -.08em;
}

.error-code span {
  display: block;
  transform: translateY(.04em);
}

.error-face {
  width: clamp(84px, 16vw, 154px);
  aspect-ratio: 1 / 1;
  object-fit: contain;
  flex: 0 0 auto;
  filter: drop-shadow(0 6px 0 rgba(224, 74, 133, .18));
}

.error-title {
  margin-top: 8px;
}

.error-card .lead {
  max-width: 48ch;
  margin: 10px auto 0;
}

.error-actions {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 24px;
}

.error-actions .btn {
  min-width: 190px;
}

.error-hint {
  display: inline-block;
  margin-top: 20px;
  padding: 10px 14px;
  border-radius: 999px;
  background: var(--cream2);
  color: var(--mute);
  font-size: .875rem;
  font-weight: 700;
}

@media(max-width:640px) {
  .error-shell {
    padding: 28px 14px 52px;
  }

  .error-card {
    padding: 26px 18px;
  }

  .error-code {
    font-size: clamp(4rem, 24vw, 7rem);
    gap: 6px;
    letter-spacing: -.07em;
  }

  .error-face {
    width: clamp(72px, 24vw, 112px);
  }

  .error-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .error-actions .btn {
    width: 100%;
    min-width: 0;
  }
}

/* === Account profile email verification === */
.profile-email-code {
  display: grid;
  gap: 10px;
  margin-top: 10px;
  padding: 12px;
  border: 1.5px dashed var(--pink-soft);
  border-radius: 14px;
  background: var(--pink-pastel);
}

.profile-email-code[hidden],
.profile-email-code[aria-hidden="true"] {
  display: none !important;
}

.profile-email-code__message {
  color: var(--pink-deep);
  font-size: .875rem;
  font-weight: 800;
  line-height: 1.35;
}

.profile-email-code label {
  display: block;
  margin-bottom: -4px;
  font-size: .75rem;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--ink);
}

.profile-email-code .auth-input {
  min-height: 46px;
  height: 46px;
  background: var(--white);
}

.profile-email-code__actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.profile-email-code__actions .btn {
  min-height: 44px;
  width: 100%;
  border-radius: 12px;
  padding-left: 12px;
  padding-right: 12px;
}

@media(max-width:560px) {
  .profile-email-code__actions {
    grid-template-columns: 1fr;
  }
}

/* === FTM header fix: clean icons, always visible nav, animated underline === */
.hdr {
  height: auto;
  min-height: var(--hdr-h);
}

.hdr-row {
  min-height: var(--hdr-h);
  flex-wrap: nowrap;
}

.nav {
  display: flex !important;
  flex: 1 1 auto;
  min-width: 0;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
  gap: clamp(8px, 1.8vw, 16px);
  margin-left: clamp(6px, 1.6vw, 20px);
  -webkit-overflow-scrolling: touch;
}

.nav::-webkit-scrollbar {
  display: none;
}

.nav a {
  flex: 0 0 auto;
  padding: 4px 0 7px;
  white-space: nowrap;
  hyphens: none;
  overflow-wrap: normal;
  transition: color .3s ease;
}

.nav a::after {
  left: 50%;
  right: auto;
  bottom: 1px;
  width: 100%;
  height: 2px;
  border-radius: 999px;
  transform: translateX(-50%) scaleX(0);
  transform-origin: center;
  transition: transform .48s cubic-bezier(.22, 1, .36, 1);
}

.nav a:hover::after,
.nav a.active::after,
.nav a[aria-current="true"]::after {
  transform: translateX(-50%) scaleX(1);
}

.burger {
  display: none !important;
}

.hdr-r {
  flex: 0 0 auto;
}

.hdr-r .btn-p {
  display: inline-flex !important;
}

@media(max-width:720px) {
  .hdr-row {
    gap: 8px;
    padding-top: 6px;
    padding-bottom: 6px;
  }

  .logo-img {
    height: 46px;
  }

  .nav {
    margin-left: 0;
    gap: 10px;
  }

  .nav a {
    font-size: .875rem;
  }

  .hdr-r {
    gap: 5px;
  }

  .hdr-r .btn-p {
    font-size: .8125rem !important;
    padding: 7px 11px !important;
  }
}

@media(max-width:520px) {
  .hdr .btn-p {
    display: inline-flex !important;
  }

  .wrap.hdr-row {
    padding-left: 10px;
    padding-right: 10px;
  }

  .logo-img {
    height: 40px;
  }

  .ib {
    width: 32px;
    height: 32px;
  }
}

@media(max-width:390px) {
  .logo-img {
    height: 34px;
  }

  .nav {
    gap: 8px;
  }

  .hdr-r .btn-p {
    font-size: .75rem !important;
    padding: 7px 9px !important;
  }
}
