*,
*::before,
*::after {
  box-sizing: border-box;
}

:root {
  color-scheme: light;
  --bg: #eef4fb;
  --navy: #10284d;
  --navy-soft: #1a3f73;
  --blue: #1662d8;
  --blue-strong: #0e56c7;
  --blue-soft: #eaf3ff;
  --cyan: #10b5c8;
  --teal: #14b8a6;
  --teal-strong: #0f9e97;
  --green: #0f9f74;
  --green-soft: #e8fbf4;
  --red: #d83b52;
  --red-soft: #fff0f3;
  --line: #d7e3f1;
  --text: #18324f;
  --muted: #5f7592;
  --white: #ffffff;
  --shadow: 0 24px 60px rgba(20, 53, 102, 0.12);
}

html,
body {
  min-width: 320px;
  min-height: 100%;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 12% 18%, rgba(22, 98, 216, 0.12), transparent 22rem),
    radial-gradient(circle at 84% 24%, rgba(16, 181, 200, 0.12), transparent 20rem),
    linear-gradient(180deg, #f7fbff 0%, var(--bg) 100%);
  color: var(--text);
  font-family: "Manrope", "Segoe UI", sans-serif;
}

button,
input,
select {
  font: inherit;
}

.resident-register-page {
  width: min(2048px, 100%);
  margin: 0 auto;
  padding: 12px;
}

.register-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 26px;
  border-radius: 22px 22px 0 0;
  color: #eff6ff;
  background:
    radial-gradient(circle at 20% 10%, rgba(61, 155, 255, 0.22), transparent 24rem),
    linear-gradient(135deg, #0d223f 0%, #183966 48%, #284976 100%);
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.08);
}

.register-brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.register-brand strong,
.register-brand small {
  display: block;
}

.register-brand strong {
  font-size: clamp(1rem, 2vw, 1.35rem);
  font-weight: 800;
}

.register-brand small {
  margin-top: 4px;
  color: #7fe1ff;
  font-size: 0.85rem;
  font-weight: 700;
}

.register-brand-mark {
  width: 74px;
  height: 74px;
  position: relative;
  display: grid;
  place-items: center;
}

.register-brand-mark::before,
.register-brand-mark::after,
.register-brand-mark span {
  position: absolute;
  inset: 0;
  clip-path: polygon(50% 0, 90% 16%, 84% 73%, 50% 100%, 16% 73%, 10% 16%);
}

.register-brand-mark::before {
  content: "";
  background: linear-gradient(145deg, #58e0f0, #1494db);
}

.register-brand-mark::after {
  content: "";
  inset: 7px;
  background: linear-gradient(145deg, #193761, #0e2547);
}

.register-brand-mark span {
  inset: 26px;
  background: #ffffff;
  clip-path: path("M12 0C8.685 0 6 2.685 6 6V8H4C1.791 8 0 9.791 0 12V20C0 22.209 1.791 24 4 24H20C22.209 24 24 22.209 24 20V12C24 9.791 22.209 8 20 8H18V6C18 2.685 15.315 0 12 0ZM12 3C13.657 3 15 4.343 15 6V8H9V6C9 4.343 10.343 3 12 3ZM12 12C13.105 12 14 12.895 14 14C14 14.738 13.598 15.382 13 15.728V19H11V15.728C10.402 15.382 10 14.738 10 14C10 12.895 10.895 12 12 12Z");
}

.register-trust-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  padding: 0 18px;
  border: 1px solid rgba(215, 232, 255, 0.16);
  border-radius: 999px;
  color: rgba(241, 247, 255, 0.92);
  background: rgba(255, 255, 255, 0.06);
  font-size: 0.86rem;
  font-weight: 700;
}

.register-shell {
  display: grid;
  grid-template-columns: minmax(310px, 0.7fr) minmax(420px, 1.3fr);
  gap: 24px;
  padding: 26px;
  border: 1px solid rgba(201, 217, 236, 0.7);
  border-top: 0;
  border-radius: 0 0 22px 22px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(246, 250, 255, 0.94));
  box-shadow: var(--shadow);
  align-items: start;
}

.register-visual,
.register-card {
  border-radius: 28px;
  background: var(--white);
  box-shadow: 0 16px 36px rgba(16, 40, 77, 0.08);
}

.register-visual {
  padding: 28px;
  background:
    radial-gradient(circle at 50% 10%, rgba(58, 145, 255, 0.14), transparent 20rem),
    linear-gradient(180deg, #fafdff 0%, #edf6ff 100%);
}

.register-visual-scene {
  position: relative;
  min-height: 580px;
  overflow: hidden;
  border-radius: 24px;
  background:
    linear-gradient(180deg, #eef7ff 0%, #dceeff 42%, #f9fcff 100%);
}

.scene-sky {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 14% 32%, rgba(255, 255, 255, 0.9), transparent 7rem),
    radial-gradient(circle at 82% 24%, rgba(255, 255, 255, 0.9), transparent 6rem),
    linear-gradient(180deg, rgba(255, 255, 255, 0.7), transparent 30%);
}

.scene-shield {
  position: absolute;
  top: 56px;
  left: 50%;
  width: 164px;
  height: 196px;
  transform: translateX(-50%);
  filter: drop-shadow(0 18px 22px rgba(15, 62, 136, 0.24));
}

.scene-shield::before,
.scene-shield::after,
.scene-shield span {
  position: absolute;
  inset: 0;
  clip-path: polygon(50% 0, 90% 16%, 84% 73%, 50% 100%, 16% 73%, 10% 16%);
}

.scene-shield::before {
  content: "";
  background: linear-gradient(145deg, #d8e7fb, #8ba9d4);
}

.scene-shield::after {
  content: "";
  inset: 12px;
  background: linear-gradient(145deg, #12346c, #0e2348);
}

.scene-shield span {
  inset: 50px 48px;
  background: #ffffff;
  clip-path: path("M12 0L24 11V24H0V11L12 0ZM7 13V22H17V13H7ZM10 14H14V18H10V14Z");
}

.scene-building {
  position: absolute;
  bottom: 120px;
  border-radius: 10px 10px 0 0;
  background: linear-gradient(180deg, #dae8f7, #bdcfe4);
  box-shadow: 0 16px 28px rgba(17, 52, 103, 0.14);
}

.building-main {
  right: 70px;
  width: 180px;
  height: 230px;
  transform: skewY(-8deg);
}

.building-main::before,
.building-main::after,
.building-side::before,
.building-side::after {
  content: "";
  position: absolute;
  background:
    linear-gradient(90deg, rgba(57, 94, 142, 0.18) 0 1px, transparent 1px),
    linear-gradient(rgba(57, 94, 142, 0.18) 0 1px, transparent 1px),
    #f4f8fd;
  background-size: 28px 100%, 100% 28px, auto;
}

.building-main::before {
  top: 24px;
  left: 22px;
  width: 46px;
  height: 148px;
}

.building-main::after {
  top: 24px;
  right: 22px;
  width: 88px;
  height: 148px;
}

.building-side {
  left: 32px;
  width: 110px;
  height: 150px;
}

.building-side::before {
  top: 20px;
  left: 18px;
  width: 26px;
  height: 70px;
}

.building-side::after {
  top: 20px;
  right: 18px;
  width: 42px;
  height: 70px;
}

.scene-gate {
  position: absolute;
  left: 78px;
  right: 110px;
  bottom: 128px;
  height: 14px;
  border-radius: 999px;
  background:
    repeating-linear-gradient(90deg, #ffffff 0 24px, #e23c39 24px 32px);
  box-shadow: 0 4px 12px rgba(10, 41, 92, 0.16);
}

.scene-gate::before,
.scene-gate::after {
  content: "";
  position: absolute;
  top: -18px;
  width: 12px;
  height: 48px;
  border-radius: 8px;
  background: linear-gradient(180deg, #294468, #173255);
}

.scene-gate::before {
  left: -6px;
}

.scene-gate::after {
  right: -6px;
}

.scene-road {
  position: absolute;
  left: 50%;
  bottom: -60px;
  width: 420px;
  height: 220px;
  border-radius: 50%;
  transform: translateX(-20%);
  background: radial-gradient(circle at 50% 0, #6f7d8d 0, #cfd9e5 58%, transparent 60%);
  opacity: 0.55;
}

.scene-tree {
  position: absolute;
  bottom: 120px;
  width: 84px;
  height: 150px;
}

.scene-tree::before {
  content: "";
  position: absolute;
  bottom: 0;
  left: 38px;
  width: 8px;
  height: 52px;
  border-radius: 8px;
  background: #71533d;
}

.scene-tree::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 84px;
  height: 104px;
  border-radius: 50% 50% 44% 44%;
  background:
    radial-gradient(circle at 30% 40%, #a6c48c 0 22px, transparent 23px),
    radial-gradient(circle at 64% 32%, #88b36b 0 26px, transparent 27px),
    radial-gradient(circle at 56% 66%, #6a9952 0 28px, transparent 29px),
    radial-gradient(circle at 24% 68%, #7fa960 0 24px, transparent 25px);
}

.tree-left {
  left: 18px;
}

.tree-right {
  right: 38px;
  transform: scale(0.9);
}

.register-visual-points {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.register-visual-points article {
  display: grid;
  gap: 8px;
  justify-items: center;
  padding: 14px 10px;
  text-align: center;
}

.register-visual-points strong {
  font-size: 0.92rem;
  font-weight: 800;
}

.register-visual-points span {
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.45;
}

.register-card {
  padding: 30px 28px;
  min-width: 0;
}

.register-card-head {
  display: flex;
  align-items: center;
  gap: 18px;
  padding-bottom: 20px;
  border-bottom: 1px solid #dfe8f4;
}

.register-head-icon {
  width: 82px;
  height: 82px;
  flex: 0 0 82px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 3px solid #1a71db;
  color: #1a71db;
}

.register-head-icon span {
  width: 34px;
  height: 34px;
  background: currentColor;
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M12 12a5 5 0 1 0 0-10 5 5 0 0 0 0 10Zm0 2c-4.418 0-8 2.239-8 5v1h16v-1c0-2.761-3.582-5-8-5Z'/%3E%3C/svg%3E");
  mask-repeat: no-repeat;
  mask-position: center;
  mask-size: contain;
}

.register-card-head h1,
.register-card-head p,
.register-intro p,
.register-step-title h2,
.register-step-title p {
  margin: 0;
}

.register-card-head h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.02;
  letter-spacing: -0.05em;
}

.register-card-head p {
  margin-top: 6px;
  color: #4a678a;
  font-size: 0.98rem;
  font-weight: 700;
}

.register-intro {
  margin-top: 22px;
  color: #415c7c;
  font-size: 0.98rem;
  line-height: 1.58;
}

.register-step {
  margin-top: 24px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: linear-gradient(180deg, #ffffff, #fbfdff);
  box-shadow: 0 10px 26px rgba(20, 53, 102, 0.05);
}

.register-step-primary {
  border-color: #bcd8fb;
}

.register-step-token {
  border-color: #d5c3ff;
  background: linear-gradient(180deg, #ffffff, #fbf8ff);
}

.register-step-success {
  border-color: #9fe0ce;
  background: linear-gradient(180deg, #ffffff, #f5fffb);
}

.register-step-title {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.register-step-title-success {
  align-items: center;
}

.step-number {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #ffffff;
  background: linear-gradient(135deg, #1a71db, #3b96ff);
  font-size: 1.15rem;
  font-weight: 800;
  box-shadow: 0 10px 18px rgba(26, 113, 219, 0.24);
}

.step-number.success {
  background: linear-gradient(135deg, #12b07d, #3ccf9f);
  box-shadow: 0 10px 18px rgba(18, 176, 125, 0.22);
}

.register-step-title h2 {
  font-size: 1.12rem;
  font-weight: 800;
}

.register-step-title p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.86rem;
}

.success-badge {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 16px;
  border: 1px solid #85dabf;
  border-radius: 999px;
  color: var(--green);
  background: var(--green-soft);
  font-size: 0.85rem;
  font-weight: 800;
}

.success-badge::before {
  content: "✓";
  margin-right: 9px;
}

.verify-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: end;
  margin-top: 18px;
}

.field-block {
  display: grid;
  gap: 10px;
}

.field-block > span {
  color: #1a2e48;
  font-size: 0.9rem;
  font-weight: 800;
}

.input-shell {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  align-items: center;
  min-height: 68px;
  overflow: hidden;
  border: 1px solid #cedced;
  border-radius: 16px;
  background: #ffffff;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.7);
}

.input-shell:focus-within {
  border-color: #5ca3ff;
  box-shadow: 0 0 0 4px rgba(22, 98, 216, 0.12);
}

.input-shell.readonly {
  background: #f9fcff;
}

.input-icon {
  height: 100%;
  display: grid;
  place-items: center;
  border-right: 1px solid #dce7f3;
  color: #6f8197;
}

.input-icon span {
  width: 26px;
  height: 26px;
  background: currentColor;
  mask-repeat: no-repeat;
  mask-position: center;
  mask-size: contain;
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M6.62 10.79a15.054 15.054 0 0 0 6.59 6.59l2.2-2.2c.27-.27.67-.36 1.02-.24 1.12.37 2.33.57 3.57.57.55 0 1 .45 1 1V20c0 .55-.45 1-1 1C10.07 21 3 13.93 3 5c0-.55.45-1 1-1h3.5c.55 0 1 .45 1 1 0 1.24.2 2.45.57 3.57.11.35.03.74-.25 1.02l-2.2 2.2Z'/%3E%3C/svg%3E");
}

.input-icon.user span {
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M12 12a5 5 0 1 0 0-10 5 5 0 0 0 0 10Zm0 2c-4.418 0-8 2.239-8 5v1h16v-1c0-2.761-3.582-5-8-5Z'/%3E%3C/svg%3E");
}

.input-icon.home span {
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M12 3 2 12h3v8h6v-5h2v5h6v-8h3L12 3Z'/%3E%3C/svg%3E");
}

.input-shell input {
  width: 100%;
  min-width: 0;
  height: 66px;
  border: 0;
  outline: 0;
  padding: 0 20px;
  color: var(--text);
  background: transparent;
  font-size: 1rem;
  font-weight: 700;
}

.input-shell select {
  width: 100%;
  min-width: 0;
  height: 66px;
  border: 0;
  outline: 0;
  padding: 0 52px 0 20px;
  color: var(--text);
  background:
    linear-gradient(45deg, transparent 50%, #5d7494 50%) calc(100% - 26px) calc(50% - 3px) / 8px 8px no-repeat,
    linear-gradient(135deg, #5d7494 50%, transparent 50%) calc(100% - 20px) calc(50% - 3px) / 8px 8px no-repeat,
    transparent;
  appearance: none;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
}

.input-shell-select {
  background: #ffffff;
}

.input-shell input::placeholder {
  color: #7f92aa;
  font-weight: 600;
}

.btn-primary,
.btn-register {
  border: 0;
  color: #ffffff;
  cursor: pointer;
}

.btn-primary {
  min-height: 68px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 0 24px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--blue-strong), #2678ff);
  box-shadow: 0 16px 28px rgba(22, 98, 216, 0.22);
  font-size: 0.98rem;
  font-weight: 800;
  white-space: nowrap;
}

.btn-primary:hover {
  filter: brightness(1.04);
}

.btn-primary:disabled {
  opacity: 0.75;
  cursor: wait;
}

.btn-icon {
  font-size: 1.2rem;
  line-height: 1;
}

.loading-message,
.status-message {
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: 14px;
  font-size: 0.88rem;
  font-weight: 800;
}

.loading-message {
  color: var(--blue);
  background: var(--blue-soft);
}

.status-message.is-success {
  color: var(--green);
  background: var(--green-soft);
}

.status-message.is-error {
  color: var(--red);
  background: var(--red-soft);
}

.readonly-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px 18px;
  margin-top: 18px;
}

.field-wide {
  grid-column: 1 / -1;
}

.btn-register {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  margin-top: 24px;
  padding: 20px 24px;
  border-radius: 18px;
  background: linear-gradient(135deg, var(--cyan), var(--teal));
  box-shadow: 0 18px 30px rgba(16, 181, 200, 0.24);
  text-align: left;
}

.btn-register:disabled {
  opacity: 0.5;
  filter: grayscale(0.2);
  cursor: not-allowed;
  box-shadow: none;
}

.btn-register-copy strong,
.btn-register-copy small {
  display: block;
}

.btn-register-copy strong {
  font-size: 1.45rem;
  font-weight: 800;
}

.btn-register-copy small {
  margin-top: 4px;
  color: rgba(241, 255, 252, 0.88);
  font-size: 0.82rem;
  font-weight: 700;
}

.btn-register-arrow {
  font-size: 3rem;
  line-height: 1;
  opacity: 0.95;
}

.register-footer {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  justify-content: center;
  width: 100%;
  margin-top: 18px;
  color: #4e6786;
  font-size: 0.92rem;
  font-weight: 700;
  text-align: center;
}

body.success-modal-open {
  overflow: hidden;
}

.registration-success-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  overflow: hidden;
  padding: 24px;
  background: rgba(7, 24, 48, 0.76);
  backdrop-filter: blur(8px);
}

.registration-success-modal[hidden] {
  display: none;
}

.registration-alert-modal {
  position: fixed;
  inset: 0;
  z-index: 1001;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(7, 24, 48, 0.76);
  backdrop-filter: blur(8px);
}

.registration-alert-modal[hidden] {
  display: none;
}

.registration-alert-card {
  width: min(460px, 100%);
  padding: 34px;
  border: 1px solid #ffd3da;
  border-radius: 26px;
  background:
    radial-gradient(circle at 50% 0, rgba(216, 59, 82, 0.12), transparent 14rem),
    #ffffff;
  box-shadow: 0 30px 80px rgba(1, 18, 42, 0.34);
  text-align: center;
  animation: success-card-in 0.35s ease-out both;
}

.registration-alert-icon {
  width: 74px;
  height: 74px;
  display: grid;
  place-items: center;
  margin: 0 auto 17px;
  border: 8px solid #ffe9ed;
  border-radius: 50%;
  color: #ffffff;
  background: linear-gradient(135deg, #d83b52, #ef6679);
  box-shadow: 0 15px 28px rgba(216, 59, 82, 0.25);
  font-size: 2rem;
  font-weight: 800;
}

.registration-alert-eyebrow {
  margin: 0 0 8px;
  color: var(--red);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.registration-alert-card h2 {
  margin: 0;
  color: var(--navy);
  font-size: 1.75rem;
}

.registration-alert-card > p:last-of-type {
  margin: 14px 0 22px;
  color: var(--muted);
  line-height: 1.55;
}

.registration-alert-button {
  width: 100%;
  min-height: 56px;
  border: 0;
  border-radius: 14px;
  color: #ffffff;
  background: linear-gradient(135deg, #c92f48, #e9576d);
  box-shadow: 0 14px 26px rgba(216, 59, 82, 0.22);
  font-weight: 800;
  cursor: pointer;
}

.registration-success-card {
  position: relative;
  z-index: 2;
  width: min(520px, 100%);
  padding: 38px;
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 28px;
  background:
    radial-gradient(circle at 50% 0, rgba(16, 181, 200, 0.16), transparent 15rem),
    #ffffff;
  box-shadow: 0 32px 90px rgba(1, 18, 42, 0.34);
  text-align: center;
  animation: success-card-in 0.45s ease-out both;
}

.success-celebration-icon {
  width: 82px;
  height: 82px;
  display: grid;
  place-items: center;
  margin: 0 auto 18px;
  border: 8px solid #dff9ef;
  border-radius: 50%;
  color: #ffffff;
  background: linear-gradient(135deg, #10a878, #24c993);
  box-shadow: 0 16px 30px rgba(16, 168, 120, 0.28);
  font-size: 2.4rem;
  font-weight: 800;
}

.success-eyebrow {
  margin: 0 0 8px;
  color: var(--green);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.registration-success-card h2 {
  margin: 0;
  color: var(--navy);
  font-size: clamp(1.65rem, 4vw, 2.25rem);
  line-height: 1.15;
}

.success-description,
.success-reminder {
  color: var(--muted);
}

.success-description {
  margin: 12px 0 22px;
}

.success-credentials {
  display: grid;
  gap: 12px;
  text-align: left;
}

.success-credentials div {
  padding: 15px 18px;
  border: 1px solid #cde1f5;
  border-radius: 15px;
  background: #f5faff;
}

.success-credentials span,
.success-credentials strong {
  display: block;
}

.success-credentials span {
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
}

.success-credentials strong {
  overflow-wrap: anywhere;
  color: var(--navy);
  font-size: 1.2rem;
}

.success-reminder {
  margin: 18px 0;
  font-size: 0.86rem;
  font-weight: 700;
}

.success-login-button {
  min-height: 58px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  border-radius: 15px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--blue-strong), #2678ff);
  box-shadow: 0 15px 28px rgba(22, 98, 216, 0.24);
  font-weight: 800;
  text-decoration: none;
}

.confetti-layer {
  position: absolute;
  inset: 0;
  z-index: 1;
  overflow: hidden;
  pointer-events: none;
}

.confetti-layer i {
  position: absolute;
  top: -24px;
  left: var(--x);
  width: 10px;
  height: 18px;
  border-radius: 2px;
  background: var(--color);
  animation: confetti-fall var(--duration) var(--delay) linear infinite;
}

@keyframes success-card-in {
  from {
    opacity: 0;
    transform: translateY(24px) scale(0.94);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes confetti-fall {
  from {
    transform: translate3d(0, -5vh, 0) rotate(0deg);
  }
  to {
    transform: translate3d(30px, 110vh, 0) rotate(var(--rotation));
  }
}

@media (prefers-reduced-motion: reduce) {
  .registration-success-card,
  .confetti-layer i {
    animation: none;
  }
}

@media (min-width: 1440px) {
  .resident-register-page {
    padding: 18px;
  }

  .register-shell {
    grid-template-columns: minmax(360px, 0.78fr) minmax(640px, 1.22fr);
    gap: 28px;
    padding: 30px;
  }

  .register-card {
    padding: 34px 34px 30px;
  }

  .verify-form {
    grid-template-columns: minmax(0, 1fr) 320px;
  }
}

@media (max-width: 1180px) {
  .register-topbar {
    flex-wrap: wrap;
  }

  .register-trust-pill {
    margin-left: auto;
  }

  .register-shell {
    grid-template-columns: 1fr;
  }

  .register-visual {
    order: 2;
  }

  .register-card {
    order: 1;
  }

  .register-visual-scene {
    min-height: 460px;
  }
  .register-card-head h1 {
    font-size: clamp(2rem, 5vw, 2.6rem);
  }
}

@media (max-width: 980px) {
  .register-shell {
    padding: 22px;
  }

  .register-visual-points {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .verify-form {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 820px) {
  .resident-register-page {
    padding: 8px;
  }

  .register-topbar,
  .register-shell {
    padding: 18px;
  }

  .register-topbar {
    flex-direction: column;
    align-items: flex-start;
  }

  .register-trust-pill {
    width: 100%;
    justify-content: center;
    margin-left: 0;
  }

  .register-visual-scene {
    min-height: 420px;
  }

  .register-card {
    padding: 22px 18px;
  }

  .register-card-head {
    align-items: flex-start;
  }

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

  .register-step-title-success {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .success-badge {
    margin-left: 56px;
  }

  .btn-register {
    grid-template-columns: 1fr;
  }

  .btn-register-arrow {
    justify-self: end;
  }
}

@media (max-width: 560px) {
  .resident-register-page {
    padding: 0;
  }

  .register-topbar {
    padding: 16px 14px;
    border-radius: 0;
  }

  .register-shell {
    gap: 14px;
    padding: 14px;
    border-radius: 0;
  }

  .register-brand-mark {
    width: 58px;
    height: 58px;
  }

  .register-card-head {
    flex-direction: column;
    gap: 12px;
  }

  .register-head-icon {
    width: 68px;
    height: 68px;
    flex-basis: 68px;
  }

  .register-card-head h1 {
    font-size: 2rem;
  }

  .register-step,
  .register-visual {
    padding: 16px;
  }

  .register-visual-scene {
    min-height: 320px;
  }

  .scene-shield {
    top: 34px;
    width: 118px;
    height: 146px;
  }

  .scene-shield span {
    inset: 34px 32px;
  }

  .building-main {
    right: 36px;
    width: 118px;
    height: 162px;
  }

  .building-side {
    left: 18px;
    width: 78px;
    height: 108px;
  }

  .scene-gate {
    left: 48px;
    right: 54px;
    bottom: 94px;
    height: 10px;
  }

  .scene-road {
    width: 260px;
    height: 150px;
    bottom: -34px;
  }

  .scene-tree {
    bottom: 90px;
    width: 58px;
    height: 106px;
  }

  .scene-tree::before {
    left: 26px;
    width: 6px;
    height: 36px;
  }

  .scene-tree::after {
    width: 58px;
    height: 72px;
  }

  .register-visual-points {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .register-step {
    margin-top: 18px;
    padding: 16px;
    border-radius: 18px;
  }

  .register-step-title {
    gap: 10px;
  }

  .step-number {
    width: 36px;
    height: 36px;
    flex-basis: 36px;
    font-size: 1rem;
  }

  .success-badge {
    min-height: 36px;
    margin-left: 46px;
    padding: 0 12px;
    font-size: 0.78rem;
  }

  .input-shell {
    grid-template-columns: 58px minmax(0, 1fr);
    min-height: 60px;
  }

  .input-shell input {
    height: 58px;
    padding: 0 14px;
    font-size: 0.95rem;
  }

  .input-shell select {
    height: 58px;
    padding: 0 44px 0 14px;
    font-size: 0.95rem;
  }

  .btn-primary {
    min-height: 58px;
  }

  .btn-register {
    padding: 16px 18px;
  }

  .btn-register-copy strong {
    font-size: 1.18rem;
  }

  .btn-register-arrow {
    font-size: 2.3rem;
  }

  .register-footer {
    padding: 0 14px 18px;
    font-size: 0.82rem;
    line-height: 1.45;
  }
}

@media (max-width: 400px) {
  .register-brand {
    gap: 10px;
  }

  .register-brand strong {
    font-size: 0.95rem;
  }

  .register-brand small,
  .register-trust-pill {
    font-size: 0.76rem;
  }

  .register-card-head h1 {
    font-size: 1.72rem;
  }

  .register-intro,
  .register-step-title p {
    font-size: 0.84rem;
  }

  .btn-primary,
  .btn-register-copy strong {
    font-size: 1rem;
  }
}
