@import url("https://fonts.googleapis.com/css2?family=Dancing+Script:wght@400..700&display=swap");

:root {
  --orange: #ff8200;
  --red: #e20015;
  --fuchsia: #b90276;
  --violet: #50237f;
  --dark-purple: #160821;
  --white: #ffffff;
  --ink: #24102e;
  --muted: #7c5c86;
}

* {
  box-sizing: border-box;
}
* {
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
}
html,
body {
  margin: 0;
  min-height: 100%;
  font-family:
    "Segoe UI",
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    sans-serif;
}

body {
  min-height: 100vh;
  overflow: hidden;
  color: var(--white);
  background: var(--dark-purple);
}

/* ===============================
   VIDEO BACKGROUND
================================ */

.video-background {
  position: fixed;
  inset: 0;
  z-index: -3;
  overflow: hidden;
  background: var(--dark-purple);
}

.video-background video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.12) contrast(1.04) brightness(0.68);
  transform: scale(1.02);
  pointer-events: none;
  backface-visibility: hidden;
}

.video-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(
      circle at 18% 18%,
      rgba(185, 2, 118, 0.55),
      transparent 34%
    ),
    radial-gradient(
      circle at 82% 82%,
      rgba(255, 130, 0, 0.22),
      transparent 34%
    ),
    linear-gradient(
      135deg,
      rgba(22, 8, 33, 0.88),
      rgba(80, 35, 127, 0.68),
      rgba(185, 2, 118, 0.54)
    );
}

/* ===============================
   FLOATING EFFECTS
================================ */

.magic-bg span {
  position: fixed;
  border-radius: 50%;
  opacity: 0.38;
  filter: blur(1px);
  z-index: 1;
  pointer-events: none;
  animation: bubbleFloat 9s infinite ease-in-out;
}

.magic-bg span:nth-child(1) {
  width: 150px;
  height: 150px;
  left: 5%;
  top: 18%;
  background: var(--fuchsia);
}

.magic-bg span:nth-child(2) {
  width: 110px;
  height: 110px;
  right: 8%;
  top: 14%;
  background: var(--orange);
  animation-delay: 1.2s;
}

.magic-bg span:nth-child(3) {
  width: 170px;
  height: 170px;
  left: 14%;
  bottom: 10%;
  background: var(--violet);
  animation-delay: 2.4s;
}

.magic-bg span:nth-child(4) {
  width: 125px;
  height: 125px;
  right: 18%;
  bottom: 12%;
  background: var(--red);
  animation-delay: 3.6s;
}

.magic-bg span:nth-child(5) {
  width: 90px;
  height: 90px;
  left: 47%;
  top: 10%;
  background: var(--fuchsia);
  animation-delay: 4.8s;
}

@keyframes bubbleFloat {
  0%,
  100% {
    transform: translateY(0) scale(1);
  }

  50% {
    transform: translateY(-48px) scale(1.18);
  }
}

/* ===============================
   MAIN LAYOUT
================================ */

.app {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 32px;
  position: relative;
  z-index: 5;
}

.screen {
  display: none;
}

.screen.active {
  display: block;
  animation: pagePop 0.75s cubic-bezier(0.2, 0.9, 0.2, 1);
}

@keyframes pagePop {
  from {
    opacity: 0;
    transform: translateY(55px) scale(0.9) rotateX(10deg);
  }

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

/* ===============================
   WELCOME SCREEN
================================ */

#welcomeScreen {
  position: relative;
  width: 100vw;
  min-height: 100vh;
  display: none;
  place-items: center;
}

#welcomeScreen.active {
  display: grid;
}

.welcome-card,
.form-card {
  width: min(780px, 94vw);
  padding: 56px;
  border-radius: 48px;
  text-align: center;
  color: var(--white);
  position: relative;
  overflow: hidden;
  z-index: 8;

  background: linear-gradient(
    145deg,
    rgba(255, 255, 255, 0.28),
    rgba(255, 255, 255, 0.08)
  );

  border: 1px solid rgba(255, 255, 255, 0.34);
  backdrop-filter: blur(26px);

  box-shadow:
    0 45px 120px rgba(0, 0, 0, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.38),
    0 0 70px rgba(185, 2, 118, 0.28);
}

.welcome-card::before,
.form-card::before {
  content: "";
  position: absolute;
  inset: 14px;
  border-radius: 38px;
  border: 2px solid rgba(255, 255, 255, 0.18);
  pointer-events: none;
}

.welcome-card::after,
.form-card::after {
  content: "✦ ★ ✧ ✦ ★ ✧";
  position: absolute;
  left: 28px;
  right: 28px;
  bottom: 24px;
  color: rgba(255, 255, 255, 0.42);
  font-size: 30px;
  letter-spacing: 18px;
  animation: twinkle 1.4s infinite alternate;
  pointer-events: none;
}

@keyframes twinkle {
  from {
    opacity: 0.35;
    transform: scale(0.96);
  }

  to {
    opacity: 1;
    transform: scale(1.04);
  }
}

.logo {
  max-width: 320px;
  margin-bottom: 30px;
  animation: logoFloat 2.8s infinite ease-in-out;
  filter: drop-shadow(0 18px 28px rgba(0, 0, 0, 0.35));
}

@keyframes logoFloat {
  0%,
  100% {
    transform: translateY(0) scale(1);
  }

  50% {
    transform: translateY(-10px) scale(1.05);
  }
}

/* ===============================
   CHARACTERS
================================ */

.welcome-character {
  position: absolute;
  bottom: 120px;
  z-index: 10;
  pointer-events: none;
  filter: drop-shadow(0 22px 28px rgba(0, 0, 0, 0.45))
    drop-shadow(0 0 20px rgba(255, 255, 255, 0.18));
}

.character-left {
  left: 220px;
  width: clamp(220px, 18vw, 320px);

  animation: characterLeftDance 3.4s infinite ease-in-out;
}

.character-right {
  right: 220px;
  width: clamp(200px, 16vw, 290px);
  animation: characterRightDance 3.2s infinite ease-in-out;
}

@keyframes characterLeftDance {
  0%,
  100% {
    transform: translateY(0) rotate(-6deg) scale(1);
  }

  25% {
    transform: translateY(-18px) rotate(2deg) scale(1.03);
  }

  50% {
    transform: translateY(-30px) rotate(6deg) scale(1.06);
  }

  75% {
    transform: translateY(-12px) rotate(-2deg) scale(1.03);
  }
}

@keyframes characterRightDance {
  0%,
  100% {
    transform: translateY(0) rotate(6deg) scale(1);
  }

  25% {
    transform: translateY(-20px) rotate(-2deg) scale(1.03);
  }

  50% {
    transform: translateY(-34px) rotate(-6deg) scale(1.06);
  }

  75% {
    transform: translateY(-12px) rotate(2deg) scale(1.03);
  }
}

/* ===============================
   TYPOGRAPHY
================================ */

h1 {
  margin: 10px 0 16px;
  font-size: clamp(42px, 5vw, 62px);
  line-height: 1.04;
  font-weight: 950;
  font-family: "Dancing Script", cursive;
  color: var(--white);
  text-shadow:
    0 8px 22px rgba(0, 0, 0, 0.35),
    0 0 32px rgba(185, 2, 118, 0.42);
}

h2 {
  margin: 0 0 30px;
  font-size: clamp(34px, 4vw, 48px);
  font-weight: 950;
  color: var(--white);
  text-shadow: 0 8px 22px rgba(0, 0, 0, 0.32);
}

p {
  max-width: 560px;
  margin: 0 auto 34px;
  font-size: 22px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.94);
}

/* ===============================
   FORM ELEMENTS
================================ */

input {
  width: 100%;
  height: 72px;
  padding: 0 26px;
  margin: 13px 0;
  border: 0;
  border-radius: 26px;
  outline: none;
  font-size: 23px;
  font-weight: 800;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.96);
  box-shadow:
    0 20px 42px rgba(0, 0, 0, 0.22),
    inset 0 0 0 2px rgba(255, 255, 255, 0.7);
  transition: 0.25s ease;
}

input::placeholder {
  color: #a78aad;
}

input:focus {
  transform: translateY(-4px) scale(1.01);
  box-shadow:
    0 26px 58px rgba(0, 0, 0, 0.3),
    inset 0 0 0 4px var(--fuchsia);
}

.date-field {
  width: 100%;
  margin: 14px 0;
  text-align: left;
}

.date-field label {
  display: block;
  margin: 0 0 10px 8px;
  color: rgba(255, 255, 255, 0.92);
  font-size: 16px;
  font-weight: 900;
  letter-spacing: 0.4px;
}

.date-input-wrapper {
  position: relative;
  width: 100%;
}

.date-input-wrapper .date-icon {
  position: absolute;
  left: 24px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 26px;
  z-index: 2;
  pointer-events: none;
}

.date-input-wrapper .date-arrow {
  position: absolute;
  right: 24px;
  top: 50%;
  transform: translateY(-54%);
  color: #b90276;
  font-size: 32px;
  font-weight: 900;
  z-index: 2;
  pointer-events: none;
}

.date-input-wrapper .date-input {
  width: 100%;
  height: 74px;
  padding: 0 70px 0 66px;
  margin: 0;
  border: 0;
  border-radius: 28px;
  outline: none;

  color: #24102e;
  font-size: 22px;
  font-weight: 900;

  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.98),
    rgba(255, 242, 250, 0.96)
  );

  box-shadow:
    0 22px 44px rgba(0, 0, 0, 0.24),
    inset 0 0 0 2px rgba(255, 255, 255, 0.75),
    inset 0 -8px 18px rgba(185, 2, 118, 0.06);

  transition: 0.25s ease;

  appearance: none;
  -webkit-appearance: none;
}

.date-input-wrapper .date-input:hover {
  transform: translateY(-3px);
  box-shadow:
    0 28px 58px rgba(0, 0, 0, 0.3),
    inset 0 0 0 3px rgba(185, 2, 118, 0.45);
}

.date-input-wrapper .date-input:focus {
  transform: translateY(-4px) scale(1.01);
  box-shadow:
    0 30px 65px rgba(0, 0, 0, 0.34),
    inset 0 0 0 4px #b90276,
    0 0 28px rgba(185, 2, 118, 0.36);
}

.date-input-wrapper .date-input::-webkit-calendar-picker-indicator {
  opacity: 0;
  cursor: pointer;
  position: absolute;
  right: 0;
  width: 100%;
  height: 100%;
}
.birth-date-group {
  width: 100%;
  margin: 18px 0;
  text-align: left; 
}

.birth-date-group label {
  display: block;
  margin: 0 0 12px 8px;
  color: rgba(255, 255, 255, 0.95);
  font-size: 18px;
  font-weight: 950;
}

.birth-date-boxes {
  display: grid;
  grid-template-columns: 1fr 1fr 1.4fr;
  gap: 14px;
}

.birth-date-boxes input {
  height: 76px;
  margin: 0;
  text-align: center;
  border-radius: 28px;
  font-size: 23px;
  font-weight: 950;
  background: linear-gradient(135deg, #ffffff, #fff0fa);
}

.birth-date-boxes input:focus {
  transform: translateY(-4px) scale(1.03);
  box-shadow:
    0 26px 58px rgba(0, 0, 0, 0.3),
    inset 0 0 0 4px var(--fuchsia),
    0 0 28px rgba(185, 2, 118, 0.38);
}
.gender-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
  margin: 22px 0 32px;
}

.gender-grid button {
  min-height: 100px;
  border: 0;
  border-radius: 30px;
  color: var(--violet);
  background: rgba(255, 255, 255, 0.96);
  cursor: pointer;
  font-size: 22px;
  font-weight: 950;
  box-shadow: 0 20px 42px rgba(0, 0, 0, 0.22);
  transition: 0.25s ease;
  position: relative;
  overflow: hidden;
}

.gender-grid button::before {
  display: block;
  font-size: 34px;
  margin-bottom: 6px;
}

.gender-grid button[data-gender="girl"]::before {
  content: "🌸";
}

.gender-grid button[data-gender="boy"]::before {
  content: "🧸";
}

.gender-grid button[data-gender="other"]::before {
  content: "⭐";
}

.gender-grid button:hover,
.gender-grid button.selected {
  transform: translateY(-8px) scale(1.045);
  color: white;
  background: linear-gradient(
    135deg,
    var(--violet),
    var(--fuchsia),
    var(--red)
  );
}

/* ===============================
   BUTTONS
================================ */

.primary-btn {
  min-width: 270px;
  border: 0;
  padding: 23px 52px;
  border-radius: 999px;
  color: white;
  font-size: 24px;
  font-weight: 950;
  cursor: pointer;
  background: linear-gradient(
    135deg,
    var(--orange),
    var(--red),
    var(--fuchsia),
    var(--violet)
  );
  box-shadow:
    0 24px 55px rgba(185, 2, 118, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
  transition: 0.25s ease;
  position: relative;
  overflow: hidden;
}

.primary-btn:hover {
  transform: translateY(-7px) scale(1.05);
  box-shadow:
    0 34px 80px rgba(185, 2, 118, 0.55),
    0 0 40px rgba(255, 130, 0, 0.3);
}

.primary-btn::after {
  content: "";
  position: absolute;
  top: 0;
  left: -80%;
  width: 55%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.55),
    transparent
  );
  transform: skewX(-20deg);
  animation: shine 2.2s infinite;
}

@keyframes shine {
  0% {
    left: -80%;
  }

  60%,
  100% {
    left: 130%;
  }
}

/* ===============================
   CERTIFICATE PAGE
================================ */

.print-body {
  background: var(--dark-purple) !important;
  overflow: auto;
}

.certificate-pro {
    width: 297mm;
    height: 210mm;
    margin: 0 auto;
    padding: 16mm;
    position: relative;
    overflow: hidden;
    color: #24102e;
background:
    radial-gradient(circle at 10% 20%, rgba(255,183,236,.9), transparent 20%),
    radial-gradient(circle at 90% 12%, rgba(255,209,102,.55), transparent 22%),
    radial-gradient(circle at 85% 85%, rgba(147,197,253,.42), transparent 22%),
    radial-gradient(circle at 20% 90%, rgba(192,132,252,.36), transparent 20%),
    linear-gradient(
        135deg,
        #fff6fb 0%,
        #ffffff 38%,
        #fff0fa 65%,
        #f7efff 100%
    );
}

.theme-girl.certificate-pro {
    background:
        radial-gradient(circle at 15% 15%, rgba(255,179,236,.70), transparent 24%),
        radial-gradient(circle at 90% 25%, rgba(255,130,0,.22), transparent 25%),
        linear-gradient(135deg, #fff5fb, #ffffff 45%, #ffe9f6);
}

.theme-boy.certificate-pro {
    background:
        radial-gradient(circle at 15% 15%, rgba(147,197,253,.65), transparent 24%),
        radial-gradient(circle at 90% 25%, rgba(80,35,127,.22), transparent 25%),
        linear-gradient(135deg, #f2f8ff, #ffffff 45%, #eaf4ff);
}

.certificate-pro::before {
    content: "";
    position: absolute;
    inset: 9mm;
    border-radius: 34px;
    border: 5px solid transparent;
    background:
        linear-gradient(#fff, #fff) padding-box,
        linear-gradient(135deg, var(--fuchsia), var(--orange), var(--violet)) border-box;
    z-index: 1;
    box-shadow:
        0 0 0 8px rgba(185,2,118,.08),
        inset 0 0 55px rgba(185,2,118,.08);
}

.theme-boy.certificate-pro::before {
    background:
        linear-gradient(#fff, #fff) padding-box,
        linear-gradient(135deg, #008ECF, var(--violet), #00A8B0) border-box;
}

.cert-pattern {
    position: absolute;
    inset: 0;

    background-image:
        radial-gradient(circle, rgba(185,2,118,.18) 2px, transparent 3px),
        radial-gradient(circle, rgba(255,130,0,.16) 1.6px, transparent 2.6px),
        radial-gradient(circle, rgba(147,197,253,.18) 2px, transparent 3px);

    background-size:
        34px 34px,
        58px 58px,
        82px 82px;

    opacity: .9;

    z-index: 0;
}

.cert-pro-header,
.cert-pro-body,
.cert-pro-footer {
    position: relative;
    z-index: 3;
}

.cert-pro-header {
    display: flex;
    justify-content: center;
    align-items: center;
}

.cert-pro-logo {
    width: 250px;
    object-fit: contain;
}

.cert-pro-badge {
    padding: 13px 26px;
    display: none;
    border-radius: 999px;
    color: white;
    font-size: 15px;
    font-weight: 950;
    letter-spacing: 1px;
    background: linear-gradient(135deg, var(--violet), var(--fuchsia), var(--red));
    box-shadow: 0 14px 32px rgba(185,2,118,.25);
}

.theme-boy .cert-pro-badge {
    background: linear-gradient(135deg, #005691, #008ECF, var(--violet));
}

.cert-pro-body {
    height: 122mm;
    display: grid;
    grid-template-columns: 165px 1fr 170px;
    align-items: center;
    gap: 20px;
    margin-top: 6mm;
}

.cert-pro-center {
    text-align: center;
}

.small-title {
    display: inline-block;
    margin-bottom: 12px;
    padding: 8px 18px;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 900;
    color: var(--fuchsia);
    background: rgba(185,2,118,.08);
}

.theme-boy .small-title {
    color: #005691;
    background: rgba(0,142,207,.10);
}

.cert-pro-center h1 {
    position: relative;
    margin: 0 0 22px;
    font-size: 60px;
    line-height: 1.02;
    font-weight: 950;
    letter-spacing: -2px;
    /* background: linear-gradient(135deg, #ffffff, #ffe082, #ff9de1, #d8b4fe, #93c5fd, #ffffff); */
    background-size: 300% 300%;
    /* -webkit-background-clip: text; */
    /* -webkit-text-fill-color: transparent; */
    text-shadow: none;
    color: #cd8cd6;
    /* animation: magicalGradient 8s ease infinite; */
    /* filter: drop-shadow(0 4px 12px rgba(80, 35, 127, .28)); */
}

.cert-pro-center h1::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: -12px;
    transform: translateX(-50%);
    width: 200px;
    height: 6px;
    border-radius: 999px;
    background: linear-gradient(90deg, #ffb3ec, #ffd166, #c084fc, #8be9fd);
}

.cert-pro-center p {
    width: 88%;
    margin: 0 auto 18px;
    color: #3d2947;
    font-size: 23px;
    line-height: 1.48;
    font-weight: 600;
}

.cert-pro-center p strong {
    color: var(--fuchsia);
}

.theme-boy .cert-pro-center p strong {
    color: #005691;
}

.toy-name-pro {
    display: inline-flex;
    justify-content: center;
    min-width: 410px;
    padding: 18px 52px;
    margin: 8px 0 22px;
    border-radius: 32px;
    color: white;
    font-size: 50px;
    font-weight: 950;
    background: linear-gradient(135deg, var(--fuchsia), var(--red), var(--orange));
    box-shadow:
        0 22px 44px rgba(185,2,118,.26),
        inset 0 1px 0 rgba(255,255,255,.35);
    transform: rotate(-1deg);
}

.theme-boy .toy-name-pro {
    background: linear-gradient(135deg, #008ECF, #005691, var(--violet));
}

.cert-pro-info {
    display: flex;
    justify-content: center;
    gap: 18px;
}

.cert-pro-info div {
    min-width: 230px;
    padding: 15px 22px;
    border-radius: 22px;
    background: rgba(255,255,255,.86);
    border: 2px solid rgba(185,2,118,.14);
    box-shadow: 0 12px 28px rgba(80,35,127,.12);
}

.cert-pro-info span {
    display: block;
    color: var(--muted);
    font-size: 14px;
    font-weight: 900;
    margin-bottom: 5px;
}

.cert-pro-info strong {
    color: var(--ink);
    font-size: 21px;
}

.plush-circle {
    width: 148px;
    height: 148px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: radial-gradient(circle, #fff, #fff4fb 58%, #ffd7ee);
    border: 5px solid var(--fuchsia);
    box-shadow:
        0 20px 40px rgba(185,2,118,.25),
        inset 0 0 0 8px rgba(255,255,255,.75);
}

.theme-boy .plush-circle {
    background: radial-gradient(circle, #fff, #eef7ff 58%, #d9edff);
    border-color: #008ECF;
}

.plush-circle span {
    font-size: 68px;
}

.magic-label {
    margin-top: 18px;
    width: 160px;
    text-align: center;
    padding: 10px 14px;
    border-radius: 999px;
    color: white;
    font-size: 14px;
    font-weight: 950;
    background: linear-gradient(135deg, var(--orange), var(--red));
    box-shadow: 0 12px 26px rgba(226,0,21,.24);
}

.seal-pro {
    width: 152px;
    height: 152px;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--violet);
    text-align: center;
    background: radial-gradient(circle, #fff 0 48%, #ffe4f3 49% 63%, var(--fuchsia) 64% 100%);
    border: 6px double var(--orange);
    box-shadow: 0 20px 44px rgba(80, 35, 127, .22);
    transform: rotate(347deg);
    position: absolute;
    left: -2mm;
    top: 1mm;
}
.theme-boy .seal-pro {
    background:
        radial-gradient(circle, #fff 0 48%, #e1f2ff 49% 63%, #008ECF 64% 100%);
}

.seal-pro span {
    font-size: 13px;
    font-weight: 950;
}

.seal-pro strong {
    font-size: 17px;
    color: var(--fuchsia);
}

.theme-boy .seal-pro strong {
    color: #005691;
}

.seal-pro em {
    margin-top: 7px;
    font-size: 10px;
    font-style: normal;
    font-weight: 950;
}

.cert-pro-footer {
    display: grid;
    grid-template-columns: 1fr auto auto;
    align-items: center;
    gap: 20px;
    z-index: 1;
}

.cert-pro-footer div {
    height: 3px;
    border-radius: 999px;
    background: linear-gradient(90deg, transparent, var(--fuchsia), var(--orange));
}

.cert-pro-footer p {
    margin: 0;
    color: var(--violet);
    font-size: 17px;
    font-weight: 900;
}

.cert-pro-footer strong {
    padding: 13px 25px;
    border-radius: 999px;
    color: white;
    font-size: 18px;
    background: linear-gradient(135deg, var(--violet), var(--fuchsia));
}


.cert-bg-shape {
  position: absolute;
  border-radius: 999px;
  filter: blur(0.2px);
  z-index: 0;
}

.shape-1 {
  width: 260px;
  height: 260px;
  background: rgba(185, 2, 118, 0.18);
  left: -80px;
  top: -70px;
}

.shape-2 {
  width: 300px;
  height: 300px;
  background: rgba(255, 130, 0, 0.18);
  right: -95px;
  bottom: -95px;
}

.shape-3 {
  width: 220px;
  height: 220px;
  background: rgba(80, 35, 127, 0.14);
  right: 80px;
  top: 42px;
}

.cert-header,
.cert-content,
.cert-footer,
.cert-stars {
  position: relative;
  z-index: 3;
}

.cert-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.cert-main-logo {
  width: 245px;
  height: auto;
  object-fit: contain;
}

.cert-badge {
  padding: 12px 24px;
  border-radius: 999px;
  color: #fff;
  font-size: 16px;
  font-weight: 900;
  letter-spacing: 0.5px;
  background: linear-gradient(
    135deg,
    var(--violet),
    var(--fuchsia),
    var(--red)
  );
  box-shadow: 0 12px 32px rgba(185, 2, 118, 0.28);
}

.cert-stars span {
  position: absolute;
  color: var(--orange);
  font-size: 30px;
  opacity: 0.85;
}

.cert-stars span:nth-child(1) {
  left: 58mm;
  top: 33mm;
}

.cert-stars span:nth-child(2) {
  right: 58mm;
  top: 38mm;
  color: var(--fuchsia);
}

.cert-stars span:nth-child(3) {
  left: 28mm;
  bottom: 48mm;
  color: var(--violet);
}

.cert-stars span:nth-child(4) {
  right: 36mm;
  bottom: 42mm;
}

.cert-stars span:nth-child(5) {
  left: 143mm;
  top: 26mm;
  color: var(--fuchsia);
}

.cert-content {
  height: 122mm;
  display: grid;
  grid-template-columns: 150px 1fr 170px;
  align-items: center;
  gap: 22px;
  margin-top: 6mm;
}

.cert-center {
  text-align: center;
}

#welcomeScreen h1 {
  position: relative;
  margin: 0 0 18px;
  font-size: 58px;
  line-height: 1.02;
  font-weight: 950;
  letter-spacing: -2px;

  background: linear-gradient(
    135deg,
    #ffffff 0%,
    #ffe082 15%,
    #ff9de1 32%,
    #d8b4fe 48%,
    #93c5fd 65%,
    #f9a8d4 82%,
    #ffffff 100%
  );

  background-size: 300% 300%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;

  animation: magicalGradient 8s ease infinite;
  filter: drop-shadow(0 0 18px rgba(255, 255, 255, 0.25));

  text-shadow:
    0 0 22px rgba(255, 255, 255, 0.18),
    0 8px 25px rgba(185, 2, 118, 0.18);
}

.cert-center h1::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -10px;
  transform: translateX(-50%);
  width: 180px;
  height: 6px;
  border-radius: 999px;
  background: linear-gradient(90deg, #ffb3ec, #ffd166, #c084fc, #8be9fd);
  opacity: 0.9;
  box-shadow: 0 0 14px rgba(255, 255, 255, 0.4);
}

@keyframes magicalGradient {
  0% {
    background-position: 0% 50%;
  }

  50% {
    background-position: 100% 50%;
  }

  100% {
    background-position: 0% 50%;
  }
}

.cert-desc {
  width: 88%;
  margin: 0 auto 20px;
  font-size: 23px;
  line-height: 1.5;
  color: #3d2947;
}

.cert-desc strong {
  color: var(--fuchsia);
}

.toy-name-v2 {
  display: inline-flex;
  min-width: 390px;
  justify-content: center;
  margin: 6px 0 22px;
  padding: 18px 46px;
  border-radius: 30px;
  color: white;
  font-size: 48px;
  font-weight: 950;
  background: linear-gradient(
    135deg,
    var(--orange),
    var(--red) 38%,
    var(--fuchsia) 72%,
    var(--violet)
  );
  box-shadow:
    0 22px 44px rgba(185, 2, 118, 0.26),
    inset 0 1px 0 rgba(255, 255, 255, 0.35);
  transform: rotate(-1deg);
}

.cert-info-v2 {
  display: flex;
  justify-content: center;
  gap: 18px;
}

.cert-info-v2 div {
  min-width: 230px;
  padding: 15px 22px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.82);
  border: 2px solid rgba(185, 2, 118, 0.14);
  box-shadow: 0 12px 28px rgba(80, 35, 127, 0.12);
}

.cert-info-v2 small {
  display: block;
  color: var(--muted);
  font-weight: 800;
  font-size: 14px;
  margin-bottom: 5px;
}

.cert-info-v2 strong {
  color: var(--ink);
  font-size: 21px;
}

.toy-medal {
  width: 142px;
  height: 142px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  position: relative;
  background: radial-gradient(circle, #fff 0%, #fff4fb 58%, #ffd7ee 100%);
  border: 5px solid var(--fuchsia);
  box-shadow:
    0 20px 40px rgba(185, 2, 118, 0.25),
    inset 0 0 0 8px rgba(255, 255, 255, 0.75);
}

.toy-icon {
  font-size: 64px;
  transform: translateY(-8px);
}

.toy-ribbon {
  position: absolute;
  bottom: -18px;
  left: 50%;
  transform: translateX(-50%);
  width: 155px;
  padding: 9px 12px;
  text-align: center;
  border-radius: 999px;
  color: white;
  font-size: 14px;
  font-weight: 950;
  background: linear-gradient(135deg, var(--orange), var(--red));
  box-shadow: 0 12px 24px rgba(226, 0, 21, 0.25);
}

.official-seal {
  width: 148px;
  height: 148px;
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--violet);
  text-align: center;
  background: radial-gradient(
    circle,
    #fff 0 48%,
    #ffe4f3 49% 63%,
    var(--fuchsia) 64% 100%
  );
  border: 6px double var(--orange);
  box-shadow: 0 20px 44px rgba(80, 35, 127, 0.22);
}

.official-seal span {
  font-size: 13px;
  font-weight: 900;
}

.official-seal strong {
  font-size: 17px;
  line-height: 1.1;
  color: var(--fuchsia);
}

.official-seal em {
  margin-top: 7px;
  font-size: 10px;
  font-style: normal;
  font-weight: 900;
  color: var(--violet);
}

.cert-footer {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 20px;
  margin-top: 2mm;
}

.footer-line {
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(
    90deg,
    transparent,
    var(--fuchsia),
    var(--orange)
  );
}

.footer-text {
  text-align: center;
  color: var(--violet);
  font-size: 17px;
  font-weight: 850;
}

.signature-v2 {
  justify-self: end;
  padding: 13px 25px;
  border-radius: 999px;
  color: white;
  font-size: 19px;
  font-weight: 950;
  background: linear-gradient(135deg, var(--violet), var(--fuchsia));
  box-shadow: 0 14px 28px rgba(80, 35, 127, 0.22);
}

.theme-girl .toy-name-v2 {
  background: linear-gradient(
    135deg,
    var(--fuchsia),
    var(--red),
    var(--orange)
  );
}

.theme-boy .toy-name-v2 {
  background: linear-gradient(135deg, var(--violet), var(--fuchsia), #008ecf);
}

.theme-other .toy-name-v2 {
  background: linear-gradient(135deg, var(--violet), var(--fuchsia), #78be20);
}

/* ===============================
   PRINT ACTIONS
================================ */

.print-actions {
  text-align: center;
  padding: 22px;
  background: var(--dark-purple);
}

.print-actions button,
.print-actions a,
.print-link {
  display: inline-block;
  margin: 0 6px;
  padding: 13px 25px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--violet), var(--fuchsia));
  color: white;
  font-size: 15px;
  font-weight: 900;
  text-decoration: none;
  cursor: pointer;
}

/* ===============================
   PANEL
================================ */

.panel-body {
  overflow: auto;
  background:
    radial-gradient(
      circle at 15% 18%,
      rgba(185, 2, 118, 0.45),
      transparent 28%
    ),
    linear-gradient(135deg, var(--dark-purple), var(--violet), var(--fuchsia));
  color: var(--ink);
}

.panel {
  max-width: 1250px;
  margin: 42px auto;
  padding: 34px;
  background: rgba(255, 255, 255, 0.92);
  border-radius: 34px;
  box-shadow: 0 34px 90px rgba(0, 0, 0, 0.32);
  border: 1px solid rgba(255, 255, 255, 0.5);
}

.panel h1 {
  color: var(--violet);
  font-size: 38px;
  margin: 0 0 26px;
}

table {
  width: 100%;
  border-collapse: collapse;
  overflow: hidden;
  border-radius: 22px;
}

th {
  background: linear-gradient(135deg, var(--violet), var(--fuchsia));
  color: white;
  padding: 16px;
  text-align: left;
}

td {
  padding: 15px;
  border-bottom: 1px solid rgba(80, 35, 127, 0.12);
  color: var(--ink);
}

tr:hover td {
  background: rgba(185, 2, 118, 0.06);
}

/* ===============================
   RESPONSIVE
================================ */

@media (max-width: 1400px) {
  .character-left {
    left: 70px;
    width: 240px;
  }

  .character-right {
    right: 70px;
    width: 220px;
  }
}

@media (max-width: 1000px) {
  .character-left,
  .character-right {
    opacity: 0.25;
  }
}

@media (max-width: 768px) {
  .welcome-card,
  .form-card {
    padding: 34px 24px;
    border-radius: 34px;
  }

  .gender-grid {
    grid-template-columns: 1fr;
  }

  .primary-btn {
    width: 100%;
    min-width: auto;
  }

  .logo {
    max-width: 240px;
  }

  .welcome-character {
    display: none;
  }
}

/* ===============================
   PRINT
================================ */

@page {
  size: A4 landscape;
  margin: 0;
}

@media print {
 html,
    body {
        width: 297mm;
        height: 210mm;
        margin: 0 !important;
        padding: 0 !important;
        background: white !important;
        overflow: hidden !important;
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    .certificate-pro {
        width: 297mm !important;
        height: 210mm !important;
        margin: 0 !important;
        padding: 16mm !important;
        box-shadow: none !important;
        page-break-after: avoid;
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    .print-actions,
    .video-background,
    .magic-bg {
        display: none !important;
    }
}
.cert-character {
    position: absolute;
    z-index: 2;
    pointer-events: none;
    filter:
        drop-shadow(0 18px 28px rgba(0,0,0,.22))
        drop-shadow(0 0 22px rgba(255,255,255,.18));
}

.cert-sponge {
    left: 12mm;
    bottom: 85mm;
    width: 210px;
    transform: rotate(-8deg);

}

.cert-masha {
  right: 4mm;
    top: 9mm;
    width: 310px;
    transform: rotate(8deg);    

}



.toy-name-pro {
    border: 5px solid rgba(255,255,255,.42);

    position: relative;
}

.toy-name-pro::before {
    content: "✨";

    position: absolute;

    left: -18px;
    top: -18px;

    font-size: 34px;
}

.toy-name-pro::after {
    content: "⭐";

    position: absolute;

    right: -18px;
    bottom: -18px;

    font-size: 28px;
}
.qr-box {
    left: 1mm;
    bottom: -65px;
    z-index: 10;
    width: 115px;
    position: absolute;
    padding: 10px;
    border-radius: 18px;
    background: white;
    border: 2px solid rgba(185, 2, 118, .22);
    text-align: center;
    box-shadow: 0 16px 34px rgba(80, 35, 127, .18), inset 0 0 0 2px rgba(255, 255, 255, .55);
}

.qr-box img {
    width: 88px;
    height: 88px;
    display: block;
    margin: 0 auto 6px;
}

.qr-box span {
    display: block;
    color: var(--violet);
    font-size: 10px;
    font-weight: 950;
}

/* VERIFY PAGE */

.verify-body {
    min-height: 100vh;
    display: grid;
    place-items: center;
    overflow: auto;

    background:
        radial-gradient(circle at 15% 20%, rgba(185,2,118,.45), transparent 30%),
        radial-gradient(circle at 85% 80%, rgba(255,130,0,.28), transparent 28%),
        linear-gradient(135deg, var(--dark-purple), var(--violet), var(--fuchsia));
}

.verify-card {
    width: min(680px, 92vw);
    padding: 46px;
    border-radius: 38px;
    text-align: center;
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.28), rgba(255, 255, 255, 0.08));
    color: var(--ink);
    box-shadow: 0 34px 90px rgba(0, 0, 0, .35);
    border: 1px solid white;
}
.verify-logo {
    width: 230px;
    margin-bottom: 22px;
}

.verify-icon {
    width: 100px;
    height: 100px;
    margin: 0 auto 22px;

    display: grid;
    place-items: center;

    border-radius: 50%;
    color: white;
    font-size: 44px;
    font-weight: 950;

    background: #3ca83c;
    box-shadow: 0 18px 40px rgba(185,2,118,.35);
}

.verify-card h1 {
    color: white;
    font-size: 34px;
        font-family: emoji;
    line-height: 1.2;
    margin-bottom: 28px;
    text-shadow: none;
}

.verify-info {
    display: grid;
    gap: 14px;
}

.verify-info div {
    padding: 16px 20px;
    border-radius: 20px;
    background: #fff5fb;
    border: 1px solid rgba(185,2,118,.16);
}

.verify-info span {
    display: block;
    color: var(--muted);
    font-size: 14px;
    font-weight: 900;
    margin-bottom: 5px;
}

.verify-info strong {
    color: var(--ink);
    font-size: 22px;
}

.language-grid {
    display: flex;
    justify-content: center;
    gap: 18px;
    margin: 28px 0 34px;
}

.language-grid button {
    width: 78px;
    height: 78px;
    border-radius: 50%;
    border: 4px solid rgba(255,255,255,.75);
    background: rgba(255,255,255,.18);
    font-size: 38px;
    cursor: pointer;
    box-shadow:
        0 18px 34px rgba(0,0,0,.30),
        inset 0 1px 0 rgba(255,255,255,.35);
    transition: .25s ease;
}

.language-grid button:hover,
.language-grid button.selected {
    transform: translateY(-8px) scale(1.12);
    border-color: var(--orange);
    box-shadow:
        0 24px 48px rgba(185,2,118,.45),
        0 0 28px rgba(255,130,0,.38);
}
.language-grid button {
    width: 78px;
    height: 78px;

    padding: 0;

    overflow: hidden;

    border-radius: 50%;
    border: 4px solid rgba(255,255,255,.75);

    background: rgba(255,255,255,.18);

    cursor: pointer;

    box-shadow:
        0 18px 34px rgba(0,0,0,.30),
        inset 0 1px 0 rgba(255,255,255,.35);

    transition: .25s ease;
}

.language-grid button img {
    width: 100%;
    height: 100%;

    object-fit: cover;

    display: block;
}

.language-grid button:hover,
.language-grid button.selected {
    transform: translateY(-8px) scale(1.12);

    border-color: var(--orange);

    box-shadow:
        0 24px 48px rgba(185,2,118,.45),
        0 0 28px rgba(255,130,0,.38);
}
