:root {
  --primary-color: #2563eb;
  --primary-strong: #1d4ed8;
  --text-dark: #222222;
  --text-gray: #666666;
  --surface-soft: #f8fafc;
  --warning-bg: #fff7ed;
  --warning-text: #9a3412;
  --shadow: 0 24px 60px rgba(15, 23, 42, 0.08);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; min-height: 100%; }

body {
  font-family: "Pretendard", "Pretendard Variable", sans-serif;
  color: var(--text-dark);
  background:
    radial-gradient(circle at top left, rgba(37, 99, 235, 0.14), transparent 28%),
    linear-gradient(180deg, #f7fbff 0%, #f8fafc 42%, #f1f5f9 100%);
}

button, input { font: inherit; }

.fund-app { padding: 48px 16px 96px; }
.fund-shell { width: min(100%, 680px); margin: 0 auto; }

.fund-recaptcha-slot {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.fund-app header {
  position: static;
  top: auto;
  width: auto;
  height: auto;
  display: block;
  align-items: initial;
  justify-content: initial;
  padding: 0;
  z-index: auto;
  transition: none;
  background: transparent;
  box-shadow: none;
  overflow: visible;
}

.fund-hero { display: grid; gap: 24px; margin-bottom: 28px; }
.fund-hero__eyebrow { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.fund-hero__badge {
  display: inline-flex;
  align-items: center;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.12);
  color: var(--primary-strong);
  font-size: 13px;
  font-weight: 800;
}
.fund-hero__meta { font-size: 13px; color: var(--text-gray); }
.fund-hero__media-frame {
  //padding: 12px;
  //border-radius: 32px;
  //background: linear-gradient(160deg, rgba(37, 99, 235, 0.18), rgba(255, 255, 255, 0.92));
  //box-shadow: var(--shadow);
  padding: 0;
  border-radius: 24px;
  background: transparent;
  box-shadow: none;
}
.fund-hero__media {
  position: relative;
  margin: 0;
  overflow: hidden;
//aspect-ratio: 4 / 5;
  aspect-ratio: 1 / 1;
  border-radius: 24px;
  background: linear-gradient(180deg, #dbeafe 0%, #eff6ff 60%, #ffffff 100%);
}
.fund-hero__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
}
.fund-hero__media::after {
  //content: "";
  //position: absolute;
  //inset: 0;
  //background: linear-gradient(180deg, rgba(15, 23, 42, 0.06) 0%, rgba(15, 23, 42, 0.38) 100%);
  content: none;
}
.fund-hero__media figcaption {
  //position: absolute;
  //left: 18px;
  //right: 18px;
  //bottom: 18px;
  //z-index: 1;
  //display: grid;
  //gap: 6px;
  //padding: 16px 18px;
  //border-radius: 18px;
  //background: rgba(15, 23, 42, 0.72);
  //color: #fff;
  display: none;
}
.fund-hero__media figcaption strong { font-size: 15px; font-weight: 800; }
.fund-hero__media figcaption span { font-size: 13px; color: rgba(255,255,255,0.78); }
.fund-hero__content { display: none; }
.fund-hero__notice {
  display: grid;
  gap: 8px;
  padding: 16px 18px;
  border: 1px solid rgba(37, 99, 235, 0.18);
  border-radius: 18px;
  background: rgba(255,255,255,0.78);
}
.fund-hero__notice strong { font-size: 15px; }
.fund-hero__notice span { font-size: 14px; color: var(--text-gray); line-height: 1.7; }

.fund-tabs { margin-bottom: 18px; }
.fund-tabs__list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.fund-tab {
  min-height: 52px;
  padding: 12px 16px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 18px;
  background: rgba(255,255,255,0.68);
  color: var(--text-gray);
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
}
.fund-tab.is-active {
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  color: #fff;
  border-color: transparent;
  box-shadow: 0 16px 30px rgba(37, 99, 235, 0.22);
}

.fund-panel { display: none; }
.fund-panel.is-active { display: block; }
.fund-card {
  padding: 28px;
  border-radius: 28px;
  background: rgba(255,255,255,0.9);
  border: 1px solid rgba(255,255,255,0.65);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.fund-progress { display: flex; align-items: center; margin-bottom: 28px; }
.fund-progress__step {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #dbe4ef;
  color: #64748b;
  font-size: 15px;
  font-weight: 900;
}
.fund-progress__step.is-current, .fund-progress__step.is-done { background: var(--primary-color); color: #fff; }
.fund-progress__line { flex: 1; height: 4px; margin: 0 10px; border-radius: 999px; background: #dbe4ef; }
.fund-progress__line.is-done { background: var(--primary-color); }

.fund-step { display: none; }
.fund-step.is-active { display: block; }
.fund-step__header {
  position: static;
  display: grid !important;
  gap: 8px;
  width: 100%;
  margin-bottom: 24px;
}
.fund-step__header h2 { margin: 8px 0 10px; font-size: clamp(24px, 4.5vw, 30px); line-height: 1.28; }
.fund-step__header p { margin: 0; color: var(--text-gray); font-size: 15px; line-height: 1.7; }
.fund-step__eyebrow { margin: 0; color: var(--primary-color); font-size: 13px; font-weight: 800; }

.fund-field, .fund-bank-picker, .fund-agreement, .fund-actions, .fund-status-result, .fund-status-card { margin-top: 18px; }
.fund-field label, .fund-bank-picker__header h3, .fund-agreement__title {
  display: block;
  margin-bottom: 10px;
  font-size: 15px;
  font-weight: 800;
}
.fund-field input, .fund-summary-grid input {
  width: 100%;
  min-height: 56px;
  padding: 14px 16px;
  border: 1px solid rgba(15, 23, 42, 0.1);
  border-radius: 16px;
  background: #fff;
  color: var(--text-dark);
  font-size: 17px;
}
.fund-summary-grid input[readonly] { background: #f1f5f9; color: #475569; }
.fund-inline { display: grid; grid-template-columns: 1fr auto; gap: 10px; }
.fund-inline .fund-button { min-width: 148px; }
.fund-button {
  min-height: 56px;
  padding: 14px 18px;
  border: none;
  border-radius: 16px;
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
}
.fund-button:disabled { cursor: not-allowed; opacity: 0.6; }
.fund-button--primary {
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  color: #fff;
  box-shadow: 0 14px 28px rgba(37, 99, 235, 0.2);
}
.fund-button--secondary {
  background: rgba(255,255,255,0.14);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.18);
}
.fund-button--ghost {
  background: #f8fafc;
  color: var(--text-dark);
  border: 1px solid rgba(15, 23, 42, 0.08);
}
.fund-button--wide { width: 100%; }

.fund-field__hint,
.fund-field__error {
  margin: 10px 0 0;
  font-size: 13px;
  line-height: 1.6;
}

.fund-field__hint { color: var(--text-gray); }

.fund-field__hint.is-warning {
  padding: 10px 12px;
  border-radius: 14px;
  background: var(--warning-bg);
  color: var(--warning-text);
}

.fund-field__error {
  color: #dc2626;
  font-weight: 700;
}

.fund-code-block {
  margin-top: 20px;
  padding: 18px;
  border-radius: 20px;
  background: #f8fbff;
  border: 1px solid rgba(37, 99, 235, 0.14);
}

.fund-resend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 8px;
}

.fund-resend span {
  font-size: 14px;
  color: var(--text-gray);
}

.fund-back-link {
  padding: 0;
  border: none;
  background: transparent;
  color: var(--primary-color);
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
}

.fund-summary-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.fund-bank-kind-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 18px;
}

.fund-bank-kind-tab {
  min-height: 52px;
  padding: 12px 16px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 16px;
  background: #fff;
  color: var(--text-gray);
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
}

.fund-bank-kind-tab.is-active {
  border-color: rgba(37, 99, 235, 0.62);
  background: rgba(37, 99, 235, 0.08);
  color: var(--primary-strong);
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, 0.12);
}

.fund-bank-kind-panel {
  display: none;
}

.fund-bank-kind-panel.is-active {
  display: block;
}

.fund-bank-section {
  margin-top: 18px;
}

.fund-bank-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.fund-bank-grid--bank {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.fund-bank-option {
  display: grid;
  grid-template-columns: 32px 1fr;
  align-items: center;
  gap: 8px;
  min-height: 50px;
  padding: 8px 10px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 13px;
  background: #fff;
  color: var(--text-dark);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: transform 120ms ease, border-color 120ms ease, box-shadow 120ms ease;
}

.fund-bank-option:hover {
  transform: translateY(-1px);
  border-color: rgba(37, 99, 235, 0.35);
}

.fund-bank-option.is-selected {
  border-color: rgba(37, 99, 235, 0.7);
  background: rgba(37, 99, 235, 0.08);
  color: var(--primary-strong);
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, 0.12);
}

.fund-bank-option__logo {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
}

.fund-bank-option__logo-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  padding: 4px;
  border-radius: 10px;
  background: #fff;
  border: 1px solid rgba(15, 23, 42, 0.06);
  object-fit: contain;
  opacity: 0;
}

.fund-bank-option__logo[data-logo-state="loaded"] .fund-bank-option__logo-image {
  opacity: 1;
}

.fund-bank-option__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--bank-color, #2563eb) 0%, rgba(15, 23, 42, 0.88) 100%);
  color: #fff;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: -0.02em;
  transition: opacity 120ms ease, transform 120ms ease;
}

.fund-bank-option__logo[data-logo-state="loaded"] .fund-bank-option__icon {
  opacity: 0;
  transform: scale(0.8);
}

.fund-bank-option__label {
  display: block;
  text-align: left;
  line-height: 1.2;
}

.fund-agreement {
  padding: 18px;
  border-radius: 20px;
  background: #f8fafc;
  border: 1px solid rgba(15, 23, 42, 0.06);
}

.fund-agreement--compact {
  padding-top: 16px;
  padding-bottom: 16px;
}

.fund-agreement__panel {
  margin-top: 12px;
  padding: 14px 16px;
  border-radius: 16px;
  background: #ffffff;
  border: 1px solid rgba(37, 99, 235, 0.12);
}

.fund-agreement__body {
  display: grid;
  gap: 6px;
}

.fund-agreement__body p {
  margin: 0;
  color: var(--text-gray);
  font-size: 14px;
  line-height: 1.65;
}

.fund-agreement__list {
  margin: 0;
  padding-left: 18px;
  color: var(--text-gray);
  display: grid;
  gap: 8px;
  font-size: 14px;
  line-height: 1.65;
}

.fund-check {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 15px;
  line-height: 1.7;
}

.fund-check input {
  width: 20px;
  height: 20px;
  margin-top: 2px;
  accent-color: var(--primary-color);
}

.fund-check__content {
  flex: 1;
  min-width: 0;
}

.fund-check__toggle {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  font: inherit;
  cursor: pointer;
}

.fund-check__label {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.fund-check__required {
  color: var(--primary-color);
  font-weight: 800;
}

.fund-check__toggle i {
  color: var(--primary-color);
  transition: transform 0.2s ease;
}

.fund-check__toggle[aria-expanded="true"] i {
  transform: rotate(180deg);
}

.fund-check__toggle:hover .fund-check__label,
.fund-check__toggle:focus-visible .fund-check__label {
  opacity: 0.9;
}

@keyframes fund-notice-pulse {
  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.06);
  }
}

.fund-complete-card {
  display: grid;
  gap: 8px;
  padding: 0;
  border-radius: 0;
  background: transparent;
  color: inherit;
  width: 100%;
  max-width: 660px;
  margin-inline: auto;
  justify-items: center;
}

.fund-step[data-step="3"] {
  margin-inline: 0;
}

.fund-complete-card__notice {
  display: flex;
  flex-direction: column;
  gap: 4px;
  width: 100%;
  align-items: center;
  justify-content: center;
  padding: 0;
  color: #fde047;
  font-size: clamp(26px, 4.6vw, 32px);
  font-weight: 900;
  line-height: 1.15;
  text-align: center;
  justify-self: center;
  text-shadow:
    -1px -1px 0 #dc2626,
    1px -1px 0 #dc2626,
    -1px 1px 0 #dc2626,
    1px 1px 0 #dc2626;
  animation: fund-notice-pulse 1.8s ease-in-out infinite;
}

.fund-complete-card__overlay-hint {
  position: relative;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  justify-self: center;
  width: fit-content;
  max-width: calc(100% - 24px);
  min-height: 36px;
  margin: -4px auto -10px;
  padding: 0;
  color: #fde047;
  font-size: clamp(22px, 4vw, 28px);
  font-weight: 900;
  line-height: 1.05;
  text-align: center;
  text-shadow:
    -1px -1px 0 #dc2626,
    1px -1px 0 #dc2626,
    -1px 1px 0 #dc2626,
    1px 1px 0 #dc2626,
    0 8px 18px rgba(220, 38, 38, 0.28);
  animation: fund-notice-pulse 1.8s ease-in-out infinite;
  opacity: 0;
  transform: translateY(10px) scale(0.98);
  transition: opacity 0.24s ease, transform 0.24s ease;
  pointer-events: none;
}

.fund-complete-card__overlay-hint.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.fund-complete-card__heart {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  font-size: 24px;
}

.fund-complete-card h3 {
  margin: 18px 0 10px;
  font-size: clamp(24px, 4vw, 30px);
  line-height: 1.3;
}

.fund-complete-card > p {
  margin: 0;
  color: rgba(255, 255, 255, 0.74);
  line-height: 1.7;
}

.fund-account-card {
  margin-top: 0;
  width: 100%;
  padding: 16px 18px 14px;
  border-radius: 24px;
  background:
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.22), transparent 24%),
    linear-gradient(160deg, #2563eb 0%, #1e40af 48%, #0f172a 100%);
  box-shadow: 0 18px 34px rgba(15, 23, 42, 0.22);
}

.fund-account-card__label {
  color: rgba(255, 255, 255, 0.84);
  font-size: 14px;
}

.fund-account-card__number-wrap {
  margin-top: 4px;
}

.fund-account-card__number {
  font-size: 24px;
  font-weight: 900;
  letter-spacing: -0.03em;
  line-height: 1.35;
  color: #f2dd4f;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.fund-account-card__number,
.fund-account-card__number span {
  color: #f2dd4f;
}

.fund-account-card__holder-line {
  margin: 8px 0 0;
  color: #ffffff;
  font-size: 15px;
  font-weight: 800;
  line-height: 1.6;
}

.fund-account-card__holder-line,
.fund-account-card__holder-line span {
  color: #ffffff;
  font-weight: 800;
}

.fund-account-card__actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.fund-account-card__actions .fund-button {
  min-height: 32px;
  padding: 6px 14px;
}

.fund-deposit-hint {
  display: grid;
  gap: 12px;
  width: 100%;
  margin-top: 0;
  justify-items: stretch;
  padding: 0;
  border-radius: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
}

.fund-deposit-hint__cards {
  display: grid;
  gap: 0;
  width: 100%;
}

.fund-deposit-hint__header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.fund-deposit-hint__header strong {
  margin: 0;
}

.fund-deposit-hint strong {
  font-size: 22px;
  line-height: 1.35;
  color: #0f172a;
}

.fund-deposit-hint p,
.fund-deposit-hint span {
  margin: 0;
  color: rgba(15, 23, 42, 0.82);
  line-height: 1.7;
}

.fund-step[data-step="3"] .fund-account-card__number,
.fund-step[data-step="3"] .fund-account-card__number span {
  color: #f2dd4f;
}

.fund-step[data-step="3"] .fund-account-card__holder-line,
.fund-step[data-step="3"] .fund-account-card__holder-line span {
  color: #ffffff;
  font-weight: 800;
}

.fund-deposit-hint__highlight {
  display: grid;
  gap: 4px;
  width: 100%;
  padding: 14px 18px;
  border-radius: 18px;
  background: linear-gradient(160deg, #1e3a8a 0%, #0f172a 100%);
}

.fund-deposit-hint__highlight span {
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
  line-height: 1.2;
}

.fund-deposit-hint__highlight b {
  font-size: clamp(28px, 6vw, 38px);
  font-weight: 900;
  letter-spacing: -0.03em;
  color: #ffffff;
  word-break: break-all;
  line-height: 1.06;
}

.fund-deposit-hint__tips {
  display: grid;
  gap: 0;
  margin-top: 2px;
}

.fund-deposit-hint__tips > div {
  display: grid;
  grid-template-columns: 14px minmax(0, 1fr);
  align-items: start;
  gap: 8px;
  padding: 2px 0;
  border-radius: 0;
  background: transparent;
  color: rgba(15, 23, 42, 0.84);
  font-size: 14px;
  line-height: 1.45;
}

.fund-deposit-hint__bullet {
  flex: 0 0 auto;
  color: rgba(15, 23, 42, 0.72);
  font-size: 15px;
  font-weight: 900;
  line-height: 1.55;
  transform: translateY(0);
}

.fund-deposit-hint__bullet--check {
  color: var(--primary-color);
  font-size: 14px;
}

.fund-deposit-hint__tip-text {
  display: block;
  flex: 1 1 auto;
  min-width: 0;
  line-height: 1.5;
}

.fund-deposit-hint__tip-text--contacts,
.fund-save-card__hint-tip-text--contacts {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
}

.fund-deposit-hint__tip-text--contacts span,
.fund-save-card__hint-tip-text--contacts span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.fund-deposit-hint__tip-text--contacts i,
.fund-save-card__hint-tip-text--contacts i {
  color: var(--primary-color);
}

.fund-deposit-hint .fund-deposit-hint__accent,
.fund-save-card .fund-deposit-hint__accent {
  color: var(--primary-color);
  font-weight: 900;
  white-space: nowrap;
}

.fund-save-card {
  margin-top: 20px;
  padding: 22px;
  border-radius: 26px;
  background: #ffffff;
  color: #0f172a;
  box-shadow: 0 18px 36px rgba(15, 23, 42, 0.14);
}

.fund-save-card__caption {
  margin: 18px 0 10px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 14px;
  font-weight: 700;
}

.fund-save-card__header,
.fund-save-card__body {
  display: grid;
  gap: 8px;
}

.fund-save-card__header span {
  color: rgba(15, 23, 42, 0.62);
  font-size: 13px;
}

.fund-save-card__header strong {
  font-size: 24px;
  line-height: 1.25;
  color: #111827;
}

.fund-save-card__body {
  margin-top: 18px;
}

.fund-save-card__body p,
.fund-save-card__depositor-card,
.fund-save-card__hint-tips {
  margin: 0;
}

.fund-save-card__account {
  font-size: 24px;
  font-weight: 900;
  line-height: 1.35;
  color: #f2c94c;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.fund-save-card__account-card {
  display: grid;
  gap: 8px;
  padding: 16px 18px 14px;
  border-radius: 24px;
  background:
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.22), transparent 24%),
    linear-gradient(160deg, #2563eb 0%, #1e40af 48%, #0f172a 100%);
  box-shadow: 0 16px 28px rgba(15, 23, 42, 0.2);
}

.fund-save-card__holder {
  color: rgba(255, 255, 255, 0.92);
  font-size: 15px;
  font-weight: 800;
}

.fund-save-card__depositor-card {
  margin-top: 18px;
  padding: 16px 20px;
  border-radius: 20px;
  background: linear-gradient(160deg, #1e3a8a 0%, #0f172a 100%);
  box-shadow: 0 16px 28px rgba(15, 23, 42, 0.18);
  display: grid;
  gap: 4px;
}

.fund-save-card__hint-label {
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.2;
}

.fund-save-card__hint-tips {
  margin-top: 14px;
  display: grid;
  gap: 6px;
  color: rgba(15, 23, 42, 0.88);
  font-size: 14px;
  line-height: 1.45;
}

.fund-save-card__hint-tips > div {
  display: grid;
  grid-template-columns: 14px minmax(0, 1fr);
  align-items: start;
  gap: 8px;
  padding: 2px 0;
}

.fund-save-card__hint-tip-text {
  display: block;
  flex: 1 1 auto;
  min-width: 0;
  line-height: 1.5;
}

.fund-save-card__hint-tips i {
  color: var(--primary-color);
}

.fund-save-card__depositor-card b {
  font-size: clamp(32px, 6.2vw, 40px);
  font-weight: 900;
  letter-spacing: -0.03em;
  color: #ffffff;
  word-break: break-all;
  line-height: 1.06;
}

.fund-status-result,
.fund-status-card {
  padding: 20px;
  border-radius: 22px;
  background: #f8fafc;
  border: 1px solid rgba(15, 23, 42, 0.06);
}

.fund-status-result p {
  margin: 0;
  color: var(--text-gray);
  line-height: 1.7;
}

.fund-status-result.is-error {
  background: #fef2f2;
  border-color: rgba(220, 38, 38, 0.16);
  color: #991b1b;
}

.fund-status-card__header h3 {
  margin: 0;
  font-size: 24px;
  line-height: 1.35;
}

.fund-status-card__header p {
  margin: 8px 0 0;
  color: var(--text-gray);
  font-size: 14px;
}

.fund-status-timeline {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.fund-status-step {
  position: relative;
  display: grid;
  grid-template-columns: 32px 1fr;
  gap: 12px;
  align-items: flex-start;
}

.fund-status-step:not(:last-child) {
  padding-bottom: 14px;
}

.fund-status-step__icon {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 999px;
  background: #dbe4ef;
  color: #64748b;
  font-size: 14px;
  font-weight: 900;
}

.fund-status-step:not(:last-child) .fund-status-step__icon::after {
  content: "";
  position: absolute;
  top: calc(100% + 6px);
  left: 50%;
  width: 2px;
  height: 22px;
  border-radius: 999px;
  transform: translateX(-50%);
  background: rgba(148, 163, 184, 0.56);
}

.fund-status-step.is-complete .fund-status-step__icon {
  background: rgba(37, 99, 235, 0.16);
  color: var(--primary-strong);
}

.fund-status-step.is-current .fund-status-step__icon {
  background: var(--primary-color);
  color: #fff;
}

.fund-status-step.is-warning .fund-status-step__icon {
  background: #fef3c7;
  color: #b45309;
}

.fund-status-step__content {
  padding-top: 2px;
}

.fund-status-step__title-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
}

.fund-status-step__title {
  display: block;
  font-size: 15px;
  font-weight: 800;
}

.fund-status-step__button {
  appearance: none;
  border: 0;
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.12);
  color: var(--primary-strong);
  font-size: 13px;
  font-weight: 800;
  line-height: 1;
  padding: 9px 14px;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease, opacity 0.2s ease;
}

.fund-status-step__button:hover {
  background: rgba(37, 99, 235, 0.18);
}

.fund-status-step__button:disabled {
  background: rgba(148, 163, 184, 0.18);
  color: #94a3b8;
  cursor: not-allowed;
}

.fund-status-step__description {
  margin: 4px 0 0;
  color: var(--text-gray);
  font-size: 14px;
  line-height: 1.65;
}

.fund-status-contact-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  margin-top: 18px;
}

.fund-status-contact-links span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: rgba(15, 23, 42, 0.84);
  font-size: 14px;
  line-height: 1.5;
}

.fund-status-contact-links i {
  color: var(--primary-color);
}

.fund-status-note {
  margin-top: 16px;
  padding: 15px 16px;
  border-radius: 18px;
  background: #fef3c7;
  color: #92400e;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.7;
}

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

.fund-status-summary > div {
  padding: 16px;
  border-radius: 18px;
  background: #fff;
  border: 1px solid rgba(15, 23, 42, 0.06);
}

.fund-status-summary span {
  display: block;
  color: var(--text-gray);
  font-size: 13px;
}

.fund-status-summary strong {
  display: block;
  margin-top: 8px;
  font-size: 17px;
  line-height: 1.45;
  word-break: break-all;
}

@media (max-width: 640px) {
  .fund-app {
    padding: 76px 12px 72px;
  }

  .fund-card,
  .fund-complete-card,
  .fund-save-card,
  .fund-status-card,
  .fund-status-result {
    padding: 20px;
  }

  .fund-step[data-step="3"] {
    margin-inline: 0;
  }

  .fund-complete-card {
    width: 100%;
    max-width: none;
    margin-inline: auto;
  }

  .fund-step[data-step="3"] .fund-deposit-hint,
  .fund-step[data-step="3"] .fund-save-card {
    width: calc(100% + 24px);
    margin-inline: -12px;
  }

  .fund-step[data-step="3"] .fund-deposit-hint__header,
  .fund-step[data-step="3"] .fund-account-card,
  .fund-step[data-step="3"] .fund-deposit-hint__highlight,
  .fund-step[data-step="3"] .fund-deposit-hint__tips {
    width: 100%;
    max-width: none;
  }

  .fund-complete-card__notice {
    font-size: clamp(24px, 7vw, 30px);
  }

  .fund-complete-card__overlay-hint {
    max-width: 100%;
    margin: -2px auto -8px;
    font-size: clamp(20px, 6.4vw, 26px);
  }

  .fund-inline,
  .fund-summary-grid,
  .fund-status-summary {
    grid-template-columns: 1fr;
  }

  .fund-account-card__actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .fund-account-card__actions .fund-button {
    min-height: 34px;
    padding: 7px 12px;
  }

  .fund-inline .fund-button {
    width: 100%;
    min-width: 0;
  }

  .fund-tabs__list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .fund-progress__line {
    margin: 0 6px;
  }

  .fund-progress__step {
    width: 36px;
    height: 36px;
  }

  .fund-account-card__number,
  .fund-save-card__account {
    font-size: 24px;
  }
}

/* ── Certificate Modal ── */

.cert-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

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

.cert-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
}

.cert-modal__dialog {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  max-width: 400px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
}

.cert-modal__card {
  position: relative;
  width: 100%;
  aspect-ratio: 1191 / 1684;
  overflow: hidden;
  border-radius: 8px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
}

.cert-modal__bg {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
  user-select: none;
}

.cert-field {
  position: absolute;
  font-family: "Nanum Gothic Coding", monospace;
  font-weight: 700;
  color: #222;
  white-space: nowrap;
  pointer-events: none;
}

.cert-modal__actions {
  display: flex;
  gap: 10px;
  width: 100%;
  max-width: 320px;
}

.cert-modal__actions .fund-button {
  flex: 1;
  min-height: 44px;
}
