/* pide.now staff door (La bolsita con su comanda). Tokens from pide_home.css, scoped to the body class. */

.sd-door--pide {
  --sd-ink: var(--theme-ink);
  --sd-muted: var(--theme-muted);
  --sd-accent: var(--theme-primary-dark);
  --sd-error: var(--theme-error);
  --sd-radius: 16px;
  --sd-ok: #1f7a3d;
  --sd-ok-bg: #e4f6e8;
  --theme-primary: #ef7c2d;
  --theme-primary-dark: #d9661a;
  --theme-accent: #fac954;
  --theme-cream: #fef1d1;
  --theme-ink: #1e1a17;
  --theme-muted: #6d6057;
  --theme-error-bg: #ffe4de;
  --theme-error: #b42318;
  --theme-error-ink: #7a1a10;
  --display: "Fredoka", system-ui, sans-serif;
  --body: "Nunito", system-ui, sans-serif;

  margin: 0;
  min-height: 100vh;
  font-family: var(--body);
  color: var(--theme-ink);
  line-height: 1.55;
  overflow-x: clip;
  background: var(--theme-primary);
}

/* ── The form, shared by both variants ─────────────────────── */
.sd-door--pide .sd-form {
  display: grid;
  gap: 18px;
}

.sd-door--pide .sd-host {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin: 4px 0 0;
  font: 700 14px/1.3 var(--body);
  color: var(--theme-muted);
  overflow-wrap: anywhere;
}

.sd-door--pide .sd-host i {
  color: var(--theme-primary-dark);
  font-size: 12px;
}

.sd-door--pide .sd-field {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.sd-door--pide .sd-label {
  font: 600 17px/1.2 var(--display);
}

.sd-door--pide .sd-input {
  width: 100%;
  min-width: 0;
  min-height: 54px;
  padding: 12px 16px;
  font: 700 17px/1.3 var(--body);
  color: var(--theme-ink);
  background: var(--theme-cream);
  border: 3px solid var(--theme-ink);
  border-radius: 16px;
}

.sd-door--pide .sd-input:focus-visible {
  outline: 3px solid var(--theme-accent);
  outline-offset: 2px;
  background: #fff;
}

.sd-door--pide .sd-help {
  margin: 0;
  font: 600 14px/1.4 var(--body);
  color: var(--theme-muted);
}

.sd-door--pide .sd-pass {
  display: flex;
  gap: 8px;
}

.sd-door--pide .sd-pass .sd-input {
  flex: 1 1 auto;
}

.sd-door--pide .sd-eye {
  flex: 0 0 54px;
  border: 3px solid var(--theme-ink);
  border-radius: 16px;
  background: #fff;
  color: var(--theme-ink);
  font-size: 17px;
  cursor: pointer;
}

.sd-door--pide .sd-eye:focus-visible {
  outline: 3px solid var(--theme-accent);
  outline-offset: 2px;
}

.sd-door--pide .sd-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  margin-top: 4px;
  padding: 18px 24px;
  font: 700 19px/1 var(--display);
  color: #fff;
  background: var(--theme-primary);
  border: 3px solid var(--theme-ink);
  border-radius: 20px;
  box-shadow: 0 5px 0 var(--theme-ink);
  cursor: pointer;
  transition:
    transform 0.12s ease,
    box-shadow 0.12s ease;
}

.sd-door--pide .sd-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 7px 0 var(--theme-ink);
}

.sd-door--pide .sd-btn:active {
  transform: translateY(4px);
  box-shadow: 0 1px 0 var(--theme-ink);
}

.sd-door--pide .sd-btn:focus-visible {
  outline: 3px solid var(--theme-accent);
  outline-offset: 3px;
}

.sd-door--pide .sd-alt {
  margin: 0;
  text-align: center;
}

.sd-door--pide .sd-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font: 700 16px/1.2 var(--display);
  color: var(--theme-ink);
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

.sd-door--pide .sd-error {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin: 0;
  padding: 14px 16px;
  font: 700 15px/1.4 var(--body);
  color: var(--theme-error-ink);
  background: var(--theme-error-bg);
  border: 3px solid var(--theme-error);
  border-radius: 18px;
}

.sd-door--pide .sd-error i {
  margin-top: 3px;
  color: var(--theme-error);
}

@keyframes pide-wiggle {
  0%,
  100% {
    rotate: -3deg;
  }

  50% {
    rotate: 3deg;
  }
}

/* ── A · La bolsita te abre ────────────────────────────────── */
.pa {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.pa-top {
  width: min(1120px, 100% - 32px);
  margin: 18px auto 0;
}

.pa-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.pa-brand__icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  box-shadow: 0 0 0 3px #fff;
}

.pa-brand__word {
  height: 22px;
  width: auto;
}

.pa-stage {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
  width: min(460px, 100% - 32px);
  margin: 6px auto 0;
}

.pa-mascot {
  position: relative;
  width: 100%;
  display: grid;
  justify-items: end;
  margin-bottom: -34px;
}

.pa-mascot__img {
  width: 150px;
  margin-right: 18px;
  animation: pide-wiggle 3.2s ease-in-out infinite;
  transform-origin: 50% 100%;
}

.pa-bubble {
  position: absolute;
  left: 0;
  top: 22px;
  max-width: 200px;
  margin: 0;
  padding: 12px 16px;
  font: 600 17px/1.25 var(--display);
  background: #fff;
  border: 3px solid var(--theme-ink);
  border-radius: 22px;
  box-shadow: 0 5px 0 var(--theme-ink);
  transform: rotate(-3deg);
}

.pa-bubble::after {
  content: "";
  position: absolute;
  right: -13px;
  top: 26px;
  width: 20px;
  height: 20px;
  background: #fff;
  border-top: 3px solid var(--theme-ink);
  border-right: 3px solid var(--theme-ink);
  transform: rotate(45deg);
}

.pa-who {
  display: flex;
  gap: 14px;
  align-items: center;
  margin-bottom: 22px;
}

.pa-avatar {
  flex: 0 0 58px;
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  font: 700 22px/1 var(--display);
  background: var(--theme-accent);
  border: 3px solid var(--theme-ink);
  border-radius: 18px;
  transform: rotate(-4deg);
}

.pa-title {
  margin: 0;
  font: 700 clamp(28px, 7.5vw, 34px) / 1 var(--display);
  letter-spacing: -0.01em;
}

.pa-ground {
  height: 70px;
  margin-top: -36px;
  background: var(--theme-cream);
  border-radius: 50% 50% 0 0 / 100% 100% 0 0;
}

.pa-foot {
  flex: 1;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 6px;
  padding: 0 16px 28px;
  font: 600 15px/24px var(--display);
  color: var(--theme-muted);
  background: var(--theme-cream);
}

.pa-foot b {
  color: var(--theme-ink);
}

.pa-foot__icon {
  width: 24px;
  height: 24px;
  border-radius: 7px;
}

@media (width >= 900px) {
  .pa-stage {
    width: min(980px, 100% - 64px);
    grid-template-columns: 1fr 460px;
    align-items: center;
    gap: 48px;
    margin-top: 24px;
  }

  .pa-mascot {
    justify-items: center;
    margin-bottom: 0;
    padding-top: 70px;
  }

  .pa-mascot__img {
    width: 340px;
    margin-right: 0;
  }

  .pa-bubble {
    top: 0;
    left: 6%;
    max-width: 280px;
    font-size: 21px;
  }

  .pa-bubble::after {
    inset: auto auto -13px 44px;
    border-top: 0;
    border-bottom: 3px solid var(--theme-ink);
  }

}

.pb-rail {
  position: relative;
  z-index: 2;
  width: calc(100% + 8px);
  max-width: 476px;
  height: 18px;
  background: #fff;
  border: 3px solid var(--theme-ink);
  border-radius: 999px;
  box-shadow: 0 4px 0 var(--theme-ink);
}

.pb-ticket__head {
  display: flex;
  justify-content: space-between;
  margin: 0 0 16px;
  padding-bottom: 12px;
  font: 700 13px/1 var(--display);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--theme-muted);
  border-bottom: 3px dashed var(--theme-ink);
}

/* ── C · La bolsita con su comanda ─────────────────────────── */

/* A's whole stage, with the card swapped for B's ticket: the outline
   comes from stacked drop-shadows because the mask clips any border. */
.pc-printer {
  position: relative;
  display: grid;
  justify-items: center;
  width: 100%;
}

.pc-rail {
  width: calc(100% + 16px);
  max-width: none;
}

.pc-ticket-wrap {
  position: relative;
  width: calc(100% - 12px);
  margin-top: -6px;
  filter: drop-shadow(3px 0 0 var(--theme-ink)) drop-shadow(-3px 0 0 var(--theme-ink))
    drop-shadow(0 3px 0 var(--theme-ink)) drop-shadow(0 8px 0 var(--theme-ink));
}

.pc-ticket {
  --zig: 12px;

  padding: 22px 22px calc(22px + var(--zig));
  background: #fff;
  mask: conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) 50% / calc(2 * var(--zig)) 100%;
}

.pc-ticket .pa-who {
  margin-bottom: 20px;
}

@media (width >= 900px) {
  .pc-ticket {
    padding: 28px 34px calc(26px + var(--zig));
  }
}

@media (prefers-reduced-motion: reduce) {
  .pa-mascot__img {
    animation: none;
  }
}
