.bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  /* --bg-landscape / --bg-portrait are set inline in the view (asset-pipeline aware) */
  background-image: var(--bg-landscape);
  background-position: center center;
  background-size: cover;
  background-repeat: no-repeat;
  background-attachment: fixed;
}

.bg::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: inherit;
  background-position: inherit;
  background-size: inherit;
  background-repeat: inherit;
  background-attachment: inherit;
  filter: blur(10px);
  z-index: -1;
}

/* Portrait screens get the taller background image */
@media (orientation: portrait) {
  .bg {
    background-image: var(--bg-portrait);
  }
}

.home-root {
  text-align: center;
}

.home-root__layer {
  position: fixed;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 1.25rem 1rem;
  overflow-y: auto;
  text-align: center;
}

.home-root__overlay {
  position: fixed;
  inset: 0;
  background:
    radial-gradient(circle at top, rgba(255, 219, 128, 0.18), transparent 30%),
    linear-gradient(180deg, rgba(8, 15, 28, 0.45), rgba(8, 15, 28, 0.2) 30%, rgba(8, 15, 28, 0.5));
  pointer-events: none;
}

.home-root__backdrop {
  position: fixed;
  top: 50%;
  left: 50%;
  height: 100%;
  transform: translate(-50%, -50%);
  z-index: -1;
}

.home-root__store-badges {
  position: relative;
  display: flex;
  flex-flow: row wrap;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 0.6rem 0.85rem;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.18);
  -webkit-backdrop-filter: blur(10px);
          backdrop-filter: blur(10px);
}

.home-root__store-image {
  max-width: 130px;
}

.home-root__center {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 56rem;
  flex: 0 1 auto;
  padding: 1rem 0;
}

.home-root__hero-card {
  width: 100%;
  padding: 1.5rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 1.75rem;
  background: rgba(248, 249, 250, 0.14);
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.24);
  -webkit-backdrop-filter: blur(14px);
          backdrop-filter: blur(14px);
}

.home-root__hero-copy {
  max-width: 36rem;
  margin: 0 auto;
}

.home-root__eyebrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  padding: 0.45rem 0.8rem;
  border-radius: 999px;
  background: rgba(25, 135, 84, 0.18);
  color: #f5f7fa;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.home-root__welcome {
  max-width: 32rem;
  margin: 0 auto 1rem;
  color: #fff;
  font-size: clamp(1.9rem, 4vw, 3rem);
  font-weight: 800;
  line-height: 1.05;
  text-shadow: 0 8px 24px rgba(0, 0, 0, 0.24);
}

.home-root__intro {
  max-width: 34rem;
  margin: 0 auto 1.75rem;
  padding: 0 0.25rem;
  color: rgba(255, 255, 255, 0.92);
  font-size: 1.02rem;
  line-height: 1.7;
  text-shadow: 0 6px 16px rgba(0, 0, 0, 0.22);
}

.home-root__scan-panel {
  max-width: 32rem;
  margin: 0 auto;
  padding: 1.1rem 1rem 1.35rem;
  border-radius: 1.4rem;
  background: rgba(8, 20, 35, 0.34);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.home-root__how {
  width: 100%;
  margin-top: 2rem;
  padding: 1.5rem 1rem 1.25rem;
  border-radius: 1.25rem;
  background: rgba(248, 249, 250, 0.92);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.14);
}

.home-root__how-title {
  margin: 0 0 1.25rem;
  font-size: 1.25rem;
  font-weight: 700;
  color: #314254;
}

.home-root__steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.home-root__step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.55rem;
  padding: 1rem 0.85rem;
  border: 1px solid rgba(49, 66, 84, 0.08);
  border-radius: 1rem;
  background: #fff;
  box-shadow: 0 12px 24px rgba(18, 30, 45, 0.08);
}

.home-root__step-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3rem;
  height: 3rem;
  border-radius: 999px;
  background: rgba(25, 135, 84, 0.12);
  font-size: 1.4rem;
  color: var(--bs-success, #198754);
}

.home-root__step-title {
  font-weight: 600;
  color: var(--bs-body-color, #212529);
}

.home-root__step-text {
  font-size: 0.9rem;
  color: var(--bs-secondary-color, #6c757d);
}

.home-root__no-code {
  margin: 1.5rem 0 0;
  font-size: 0.9rem;
  color: var(--bs-secondary-color, #6c757d);
}

.home-root__camera-button {
  min-width: 13rem;
  padding: 0.85rem 1.35rem;
  border: 0;
  border-radius: 999px;
  font-weight: 700;
  box-shadow: 0 16px 32px rgba(25, 135, 84, 0.3);
}

.home-root__manager-button {
  margin-top: 1rem;
  border-radius: 999px;
  padding: 0.75rem 1.2rem;
  font-weight: 600;
}

.home-root__scanner-form {
  width: 100%;
  max-width: 32rem;
  margin: 0 auto;
  padding: 0 1rem;
}

.home-root__qr-canvas {
  display: block;
  margin: 1.5rem auto 0;
  width: min(440px, calc(100vw - 2rem));
  height: auto;
  padding: 0.65rem;
  border-color: rgba(255, 255, 255, 0.92) !important;
  border-radius: 1.5rem !important;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.22), rgba(255, 255, 255, 0.08)),
    rgba(13, 27, 42, 0.58);
  box-shadow:
    0 20px 45px rgba(0, 0, 0, 0.28),
    0 0 0 1px rgba(255, 255, 255, 0.12);
  -webkit-backdrop-filter: blur(6px);
          backdrop-filter: blur(6px);
}

.home-root__footer {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  gap: 0.5rem;
}

.home-root__customer-link,
.home-root__admin-link {
  border-radius: 999px;
  padding: 0.75rem 1rem;
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.16);
  -webkit-backdrop-filter: blur(10px);
          backdrop-filter: blur(10px);
}

.home-root__customer-link {
  background: rgba(248, 249, 250, 0.86);
}

.home-root__admin-link {
  border: 0;
  background: rgba(108, 117, 125, 0.92);
}

.home-landing {
  min-height: 100vh;
  padding: 2rem 1rem;
  background:
    radial-gradient(circle at top, rgba(81, 189, 125, 0.18), transparent 25%),
    linear-gradient(180deg, #f4f7f6 0%, #e9efec 100%);
}

.home-landing__shell {
  max-width: 70rem;
  margin: 0 auto;
}

.home-landing__hero,
.home-landing__contact-card {
  padding: 2rem;
  border-radius: 1.5rem;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 20px 50px rgba(22, 37, 33, 0.12);
}

.home-landing__eyebrow {
  display: inline-block;
  margin-bottom: 1rem;
  padding: 0.45rem 0.8rem;
  border-radius: 999px;
  background: rgba(25, 135, 84, 0.12);
  color: #198754;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.home-landing__title {
  margin: 0 0 1rem;
  color: #162521;
  font-size: clamp(2rem, 4vw, 3.4rem);
  font-weight: 800;
  line-height: 1.05;
}

.home-landing__description,
.home-landing__contact-text {
  color: #4b5b56;
  font-size: 1rem;
  line-height: 1.7;
}

.home-landing__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.home-landing__primary-button,
.home-landing__secondary-button,
.home-landing__whatsapp-button {
  border-radius: 999px;
  padding: 0.85rem 1.25rem;
  font-weight: 700;
}

.home-landing__whatsapp-button {
  display: inline-flex;
  align-items: center;
  border: 0;
  color: #fff;
  background: #25d366;
}

.home-landing__whatsapp-button:hover,
.home-landing__whatsapp-button:focus {
  color: #fff;
  background: #1ebe5a;
}

.home-landing__benefits {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin: 1.5rem 0;
}

.home-landing__benefit-card {
  padding: 1.5rem;
  border-radius: 1.25rem;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 16px 36px rgba(22, 37, 33, 0.1);
}

.home-landing__benefit-card h2,
.home-landing__contact-title {
  margin: 0 0 0.75rem;
  color: #162521;
  font-size: 1.2rem;
  font-weight: 700;
}

.home-landing__benefit-card p {
  margin: 0;
  color: #4b5b56;
  line-height: 1.65;
}

.home-landing__benefit-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3rem;
  height: 3rem;
  margin-bottom: 1rem;
  border-radius: 999px;
  background: rgba(25, 135, 84, 0.12);
  color: #198754;
  font-size: 1.3rem;
}

.home-landing__contact-link {
  color: #198754;
  font-weight: 700;
  text-decoration: none;
}

.home-landing__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.home-landing__brand {
  color: #162521;
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.home-landing__nav-link {
  color: #198754;
  font-weight: 600;
  text-decoration: none;
}

.home-landing__nav-link:hover {
  text-decoration: underline;
}

.home-landing__contact-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  margin-top: 1.25rem;
}

.home-landing__footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(22, 37, 33, 0.1);
}

.home-landing__footer-brand {
  color: #4b5b56;
  font-weight: 700;
}

.home-landing__store-badges {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
}

.home-landing__store-image {
  max-width: 130px;
}

@media (max-width: 768px) {
  .home-root__hero-card {
    padding: 1.1rem;
  }

  .home-root__steps {
    grid-template-columns: 1fr;
  }

  .home-landing__benefits {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .home-root__store-image {
    max-width: 108px;
  }

  .home-root__layer {
    padding: 1rem 0.75rem;
  }

  .home-root__footer {
    flex-wrap: wrap;
    justify-content: center;
  }

  .home-root__scan-panel,
  .home-root__how {
    padding-left: 0.85rem;
    padding-right: 0.85rem;
  }

  .home-landing {
    padding: 1rem 0.75rem;
  }

  .home-landing__hero,
  .home-landing__contact-card,
  .home-landing__benefit-card {
    padding: 1.25rem;
  }
}
