/* =========================================================
   MIREORA — FINAL TYPOGRAPHY SYSTEM
   Approved sizes only.
   Desktop: 72 / 44 / 28 / 22 / 18 / 14 px
   Mobile:  48 / 36 / 28 / 22 / 18 / 14 px
   ========================================================= */

:root{
  --type-display:72px;
  --type-section:44px;
  --type-block:28px;
  --type-card:22px;
  --type-body:18px;
  --type-small:14px;
  --type-control:14px;
}

/* ---------- Foundation ---------- */
html,body{font-size:var(--type-body)!important}
body{
  font-family:var(--sans)!important;
  font-weight:400!important;
  line-height:1.6!important;
  letter-spacing:0!important;
}
body,button,input,textarea,select{font-synthesis:none}

h1,h2,h3,h4,h5,h6{
  margin-block-start:0;
  font-weight:400!important;
  text-transform:none!important;
  text-wrap:balance;
  overflow-wrap:normal;
}
p{margin-block-start:0}
strong,b{font-weight:500!important}

/* ---------- Display hierarchy ---------- */
/* Primary editorial statements. Every main landing-page block uses the same display scale. */
.hero h1,
.collection .section-intro h2,
.design-copy h2,
.process .section-intro h2,
.studio-copy h2,
.final-cta h2{
  font-family:var(--serif)!important;
  font-size:var(--type-display)!important;
  font-weight:400!important;
  line-height:.96!important;
  letter-spacing:-.045em!important;
  text-transform:none!important;
}

/* Dialog titles stay one level below the landing-page statements. */
.dialog-copy h2{
  font-family:var(--serif)!important;
  font-size:var(--type-section)!important;
  font-weight:400!important;
  line-height:1.04!important;
  letter-spacing:-.036em!important;
  text-transform:none!important;
}

/* Major internal groups: configurator, form and dialog subsections. */
.choice-section-heading h3,
.configurator-head h3,
.configurator-intro h3,
.form-section-head h3,
.configurator-fields-heading h4{
  font-family:var(--sans)!important;
  font-size:var(--type-block)!important;
  font-weight:500!important;
  line-height:1.18!important;
  letter-spacing:-.018em!important;
  text-transform:none!important;
}

/* Cards and secondary headings. */
#collection .product-card h3,
.process-card h3,
.service-copy strong,
.spec-heading-row h4,
.spec-grid h4,
.phone-spec-models h4{
  font-family:var(--sans)!important;
  font-size:var(--type-card)!important;
  font-weight:500!important;
  line-height:1.24!important;
  letter-spacing:-.012em!important;
  text-transform:none!important;
}

/* Preserve inherited typography inside italic emphasis. */
.hero h1 em,
.collection .section-intro h2 em,
.design-copy h2 em,
.process .section-intro h2 em,
.studio-copy h2 em,
.final-cta h2 em,
.dialog-copy h2 em{
  font:inherit!important;
  letter-spacing:inherit!important;
}

/* ---------- Reading copy ---------- */
p,
.hero-text,
.section-intro>p,
.design-copy>p:not(.kicker),
.process-card p,
.studio-copy>p:last-child,
.dialog-copy>p:last-child,
.form-section-head p,
.configurator-summary,
.configurator-note,
.choice-actions p,
.service-copy small,
.product-details-content,
.spec-grid p,
.phone-spec-models p{
  font-family:var(--sans)!important;
  font-size:var(--type-body)!important;
  font-weight:400!important;
  line-height:1.58!important;
  letter-spacing:0!important;
  text-transform:none!important;
}

/* Card descriptions need a slightly tighter measure than page copy. */
#collection .product-card-copy p,
.process-card p{
  font-size:var(--type-body)!important;
  font-weight:400!important;
  line-height:1.5!important;
}

/* Form labels, selected values and option names. */
.choice-copy strong,
.selected-order-type strong,
.upload-copy strong,
.submit-panel-copy strong,
.modern-option strong,
.product-details summary,
.config-field-label,
.modern-field-label,
.modern-field>span{
  font-family:var(--sans)!important;
  font-size:var(--type-body)!important;
  font-weight:500!important;
  line-height:1.38!important;
  letter-spacing:0!important;
  text-transform:none!important;
}

/* Inputs and text areas are reading-sized, never caption-sized. */
.modern-field input,
.modern-field textarea,
.modern-field select,
.config-text-field input,
.modern-field input::placeholder,
.modern-field textarea::placeholder,
.config-text-field input::placeholder{
  font-family:var(--sans)!important;
  font-size:var(--type-body)!important;
  font-weight:400!important;
  line-height:1.5!important;
  letter-spacing:0!important;
  text-transform:none!important;
}

/* Prices are secondary display information. */
.selected-order-price strong,
.choice-price strong,
.configurator-price strong,
.submit-price strong,
#configuratorPrice,
#choicePriceValue,
#selectedProductPrice{
  font-family:var(--serif)!important;
  font-size:var(--type-card)!important;
  font-weight:400!important;
  line-height:1.12!important;
  letter-spacing:-.012em!important;
}

/* ---------- Small information ---------- */
.kicker,
.interface-label,
.interface-status,
.visual-chip,
.design-specs span,
.design-hud,
.hero-trust,
.service-label,
.service-tags i,
.service-visual-caption,
.selected-order-type>span,
.configurator-eyebrow,
.configurator-fields-heading>span,
.config-field-top>span:first-child,
.config-field-label small,
.modern-field-label small,
.modern-field>span small,
.option-meta,
.option-price,
.choice-copy small,
.upload-copy small,
.submit-panel-copy span,
.spec-heading-row span,
.spec-heading-row b,
.spec-measure-note,
.spec-facts span,
.phone-spec-models p,
.table-scroll th,
.table-scroll td,
.choice-price small,
.selected-order-price small,
.configurator-price small,
.submit-price small,
.form-success,
footer p{
  font-family:var(--sans)!important;
  font-size:var(--type-small)!important;
  font-weight:400!important;
  line-height:1.45!important;
  letter-spacing:0!important;
  text-transform:none!important;
}
.kicker{
  font-weight:500!important;
  letter-spacing:.055em!important;
}

/* ---------- Brand and interface ---------- */
.brand-name,
.footer-brand .brand-name{
  font-family:var(--serif)!important;
  font-size:var(--type-card)!important;
  font-weight:400!important;
  line-height:1!important;
  letter-spacing:0!important;
}

.desktop-nav a,
.header-action,
.button,
.product-card-button,
.product-link,
.upload-action,
.selected-order button,
.occasion-pill,
.phone-brand,
.phone-model,
.product-carousel-control,
.mobile-menu a,
.mobile-menu .button{
  font-family:var(--sans)!important;
  font-size:var(--type-control)!important;
  font-weight:500!important;
  line-height:1.3!important;
  letter-spacing:0!important;
  text-transform:none!important;
}
.desktop-nav a *,
.header-action *,
.button *,
.product-card-button *,
.product-link *,
.upload-action *,
.selected-order button *{
  font:inherit!important;
  letter-spacing:inherit!important;
  text-transform:inherit!important;
}

/* ---------- Editorial spacing corrected for the new scale ---------- */
.hero-copy{max-width:47rem!important}
.hero h1{
  max-width:10.5ch!important;
  margin-top:26px!important;
}
.hero-text{
  max-width:42rem!important;
  margin-top:34px!important;
}
.hero-actions{margin-top:34px!important}
.hero-trust{margin-top:30px!important}

.section-intro{
  align-items:end!important;
  gap:clamp(2rem,6vw,6rem)!important;
  margin-bottom:48px!important;
}
.collection .section-intro h2,
.process .section-intro h2{max-width:11.5ch!important}
.section-intro>p{max-width:35rem!important}

/* The design-service statement is intentionally display-sized. */
.design-service{
  grid-template-columns:minmax(0,1.02fr) minmax(31rem,.98fr)!important;
  align-items:center!important;
}
.design-copy{
  max-width:49rem!important;
  padding-block:26px!important;
}
.design-copy h2{
  max-width:10.5ch!important;
  margin-top:26px!important;
}
.design-copy>p:not(.kicker){
  max-width:42rem!important;
  margin-top:34px!important;
}
.design-specs{margin:28px 0 32px!important}

.process-card h3{margin-bottom:16px!important}
.studio-copy h2{max-width:11.5ch!important}
.studio-copy>p:last-child{margin-top:28px!important}
.final-cta h2{
  max-width:12ch!important;
  margin:26px auto 40px!important;
}

/* Dialog titles should read as dialog titles, not as card headings. */
.dialog-copy h2{
  width:min(100%,16ch)!important;
  margin-top:16px!important;
}
.dialog-copy>p:last-child{margin-top:16px!important}
.choice-section{margin-top:38px!important}
.choice-section-heading{margin-bottom:20px!important}
.form-section-head p{margin-top:10px!important}
.configurator-intro h3{margin:.75rem 0 1rem!important}

/* Prevent the accepted sizes from being visually compressed. */
#collection .product-card h3,
.process-card h3,
.choice-section-heading h3,
.form-section-head h3,
.configurator-intro h3,
.configurator-fields-heading h4{
  max-height:none!important;
  overflow:visible!important;
  -webkit-line-clamp:unset!important;
}

/* Decorative typography also stays inside the approved scale. */
.design-word,
.service-visual-bg{
  font-size:var(--type-display)!important;
  font-weight:400!important;
}
.service-visual-mark{
  font-size:var(--type-section)!important;
  font-weight:400!important;
}

/* ---------- Full-scale main section rhythm ---------- */
.collection .section-intro,
.process .section-intro{
  display:block!important;
  max-width:58rem!important;
}
.collection .section-intro h2,
.process .section-intro h2{
  max-width:14ch!important;
  margin-top:26px!important;
}
.collection .section-intro>p,
.process .section-intro>p{
  max-width:42rem!important;
  margin-top:34px!important;
  justify-self:auto!important;
}
.studio-copy h2{
  margin-top:26px!important;
}
.studio-copy>p:last-child{
  max-width:44rem!important;
  margin-top:34px!important;
}

/* ---------- Responsive ---------- */
@media (max-width:74rem){
  .design-service{
    grid-template-columns:1fr!important;
  }
  .design-copy{
    max-width:52rem!important;
  }
  .design-copy h2{max-width:11ch!important}
}

@media (max-width:620px){
  :root{
    --type-display:48px;
    --type-section:36px;
    --type-block:28px;
    --type-card:22px;
    --type-body:18px;
    --type-small:14px;
    --type-control:18px;
  }

  .hero h1,
  .collection .section-intro h2,
  .design-copy h2,
  .process .section-intro h2,
  .studio-copy h2,
  .final-cta h2{
    line-height:1.01!important;
    letter-spacing:-.038em!important;
  }
  .dialog-copy h2{
    line-height:1.08!important;
    letter-spacing:-.03em!important;
  }

  .hero-copy,
  .design-copy{max-width:none!important}
  .hero h1,
  .design-copy h2,
  .final-cta h2,
  .collection .section-intro h2,
  .process .section-intro h2,
  .studio-copy h2,
  .dialog-copy h2{
    max-width:none!important;
  }

  .hero h1{margin-top:20px!important}
  .hero-text{margin-top:26px!important}
  .hero-actions{margin-top:28px!important}
  .section-intro{
    align-items:start!important;
    gap:22px!important;
    margin-bottom:34px!important;
  }
  .design-copy h2{margin-top:20px!important}
  .design-copy>p:not(.kicker){margin-top:26px!important}
  .design-specs{margin:24px 0 28px!important}
  .final-cta h2{margin:20px auto 32px!important}
  .dialog-copy h2{margin-top:12px!important}
  .choice-section{margin-top:30px!important}

  /* Mobile touch controls are readable without introducing another size. */
  .desktop-nav a,
  .header-action,
  .button,
  .product-card-button,
  .product-link,
  .upload-action,
  .selected-order button,
  .occasion-pill,
  .phone-brand,
  .phone-model,
  .mobile-menu a,
  .mobile-menu .button{
    font-size:var(--type-control)!important;
  }
  .product-carousel-control{
    font-size:var(--type-card)!important;
    font-weight:400!important;
  }
}

/* High-specificity cleanup for legacy card rules. */
#collection .product-card:nth-child(n) h3,
#collection .product-card.product-card-featured h3,
#collection .product-card.product-card-wide h3{
  font-size:var(--type-card)!important;
  font-weight:500!important;
  line-height:1.24!important;
  letter-spacing:-.012em!important;
  text-transform:none!important;
}

/* ---------- Final visual QA refinements ---------- */
.hero h1,
.design-copy h2{max-width:14ch!important}
.collection .section-intro h2,
.process .section-intro h2{max-width:14ch!important}
.studio-copy h2{max-width:12ch!important}
.final-cta h2{max-width:14ch!important}
.option-check{font-weight:500!important}

/* Only the navigation capsule follows the scroll. The brand banner stays at the top. */
.site-header,
.site-header.scrolled{
  position:relative!important;
  top:auto!important;
  left:auto!important;
  transform:none!important;
  z-index:1100!important;
  width:min(94rem,calc(100vw - 2rem))!important;
  margin:14px auto 0!important;
  grid-template-columns:minmax(0,1fr) auto!important;
  overflow:visible!important;
}
.site-header .brand{justify-self:start!important}
.site-header .header-action{justify-self:end!important}

.sticky-nav-shell{
  position:sticky;
  top:14px;
  z-index:1200;
  width:max-content;
  max-width:calc(100vw - 2rem);
  height:var(--header-h);
  display:flex;
  align-items:center;
  justify-content:center;
  margin:calc(-1 * var(--header-h)) auto 0;
  pointer-events:none;
}
.sticky-nav-shell .desktop-nav{
  pointer-events:auto;
  margin:0!important;
}
main{padding-top:1rem!important}

@media (max-width:860px){
  .sticky-nav-shell{display:none!important}
  .site-header,
  .site-header.scrolled{
    width:calc(100vw - 1rem)!important;
    margin-top:8px!important;
  }
  main{padding-top:.75rem!important}
}

@media (max-width:620px){
  .hero h1,
  .design-copy h2,
  .final-cta h2,
  .collection .section-intro h2,
  .process .section-intro h2{max-width:none!important}
}

/* Fixed navigation capsule: this is the only header element that follows scroll. */
.sticky-nav-shell{
  position:fixed!important;
  top:14px!important;
  left:50%!important;
  transform:translateX(-50%)!important;
  width:max-content!important;
  height:var(--header-h)!important;
  margin:0!important;
}


/* =========================================================
   STATIC TOP MENU + RETURN TO TOP
   The header and navigation stay in the document flow and
   leave the viewport naturally. Controls use regular weight.
   ========================================================= */
.site-header,
.site-header.scrolled{
  position:relative!important;
  top:auto!important;
  left:auto!important;
  transform:none!important;
}

.sticky-nav-shell{
  position:relative!important;
  top:auto!important;
  z-index:1200!important;
}

.desktop-nav a,
.header-action,
.button,
.product-card-button,
.product-link,
.upload-action,
.selected-order button,
.occasion-pill,
.phone-brand,
.phone-model,
.mobile-menu a,
.mobile-menu .button{
  font-weight:400!important;
}

.back-to-top{
  position:fixed;
  right:max(18px,env(safe-area-inset-right));
  bottom:max(18px,env(safe-area-inset-bottom));
  z-index:1400;
  width:52px;
  height:52px;
  display:grid;
  place-items:center;
  padding:0;
  border:1px solid rgba(190,174,255,.24);
  border-radius:50%;
  background:rgba(12,10,18,.72);
  color:#e9e3f2;
  box-shadow:0 14px 40px rgba(0,0,0,.28),0 0 24px rgba(139,92,246,.10),inset 0 1px rgba(255,255,255,.05);
  -webkit-backdrop-filter:blur(18px) saturate(120%);
  backdrop-filter:blur(18px) saturate(120%);
  opacity:0;
  visibility:hidden;
  pointer-events:none;
  transform:translateY(10px);
  transition:opacity .22s ease,visibility .22s ease,transform .22s ease,border-color .22s ease,background .22s ease,box-shadow .22s ease;
}
.back-to-top span{
  font-family:var(--sans);
  font-size:var(--type-card);
  font-weight:400;
  line-height:1;
  transform:translateY(-1px);
}
.back-to-top.is-visible{
  opacity:1;
  visibility:visible;
  pointer-events:auto;
  transform:translateY(0);
}
.back-to-top:hover,
.back-to-top:focus-visible{
  border-color:rgba(190,174,255,.52);
  background:rgba(78,49,132,.55);
  box-shadow:0 16px 44px rgba(0,0,0,.30),0 0 30px rgba(139,92,246,.20),inset 0 1px rgba(255,255,255,.07);
}
.back-to-top:focus-visible{
  outline:2px solid rgba(199,181,255,.85);
  outline-offset:4px;
}

@media (max-width:620px){
  .back-to-top{
    right:max(14px,env(safe-area-inset-right));
    bottom:max(14px,env(safe-area-inset-bottom));
    width:48px;
    height:48px;
  }
}

@media (prefers-reduced-motion:reduce){
  .back-to-top{transition:none}
}

/* =========================================================
   HEADER NAVIGATION CONTAINMENT FIX
   Desktop navigation belongs to the header grid itself.
   This removes the detached row that appeared below the banner.
   ========================================================= */
.sticky-nav-shell{
  display:none!important;
}

.site-header,
.site-header.scrolled{
  display:grid!important;
  grid-template-columns:minmax(0,1fr) auto minmax(0,1fr)!important;
  align-items:center!important;
  column-gap:1.25rem!important;
  height:var(--header-h)!important;
  overflow:hidden!important;
}

.site-header > .brand{
  grid-column:1!important;
  grid-row:1!important;
  justify-self:start!important;
}

.site-header > .desktop-nav{
  grid-column:2!important;
  grid-row:1!important;
  justify-self:center!important;
  margin:0!important;
  max-width:100%!important;
}

.site-header > .header-action{
  grid-column:3!important;
  grid-row:1!important;
  justify-self:end!important;
}

.site-header > .menu-toggle{
  grid-column:3!important;
  grid-row:1!important;
  justify-self:end!important;
}

@media (max-width:74rem){
  .site-header,
  .site-header.scrolled{
    column-gap:.75rem!important;
  }
  .site-header > .desktop-nav a{
    padding-inline:.75rem!important;
  }
}

@media (max-width:860px){
  .site-header,
  .site-header.scrolled{
    grid-template-columns:minmax(0,1fr) auto!important;
  }
  .site-header > .desktop-nav,
  .site-header > .header-action{
    display:none!important;
  }
  .site-header > .menu-toggle{
    display:block!important;
    grid-column:2!important;
  }
}
