/* ==========================================
   eats PAY - Design System
   배달대행비 카드결제의 새로운 기준
   ========================================== */

@import url('https://fonts.googleapis.com/css2?family=Nanum+Square:wght@400;700;800;900&display=swap');
/* NanumSquare 보조 - CDN에서 로드하므로 @font-face 선언 제거 */

/* === CSS Variables === */
:root {
  --green-primary: #46b43a;
  --green-dark: #3a9430;
  --green-light: #eaf7e8;
  --green-btn: #46b43a;
  --green-accent: #5dc950;

  --text-primary: #1a1a1a;
  --text-secondary: #555555;
  --text-muted: #999999;
  --text-light: #bbbbbb;

  --border-color: #d8d8d8;
  --border-light: #eeeeee;
  --bg-white: #ffffff;
  --bg-light: #f7f7f7;
  --bg-gray: #f0f0f0;

  --font: 'NanumSquare', 'Nanum Square', 'Apple SD Gothic Neo', 'Noto Sans KR', system-ui, sans-serif;
  --radius: 8px;
  --radius-sm: 4px;
  --radius-lg: 12px;
  --shadow: 0 2px 12px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 20px rgba(0,0,0,0.12);

  --header-height: 80px;
  --bottom-nav-height: 60px;
}

/* === Reset === */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  width: 100%;
  height: 100%;
  font-family: var(--font);
  background: #e8e8e8;
  color: var(--text-primary);
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}

#app-shell,
#app-shell *,
.app-dialog,
.app-dialog *,
.photo-sheet,
.photo-sheet * {
  font-family: var(--font) !important;
}

input,
button,
select,
textarea {
  font-family: var(--font) !important;
}

input::placeholder,
textarea::placeholder {
  font-family: var(--font) !important;
}

/* === Unified Logo Component === */
.eatspay-logo {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1;
}
.eatspay-mark {
  width: 44px;
  margin-left: 1px;
  margin-bottom: -5px; /* Overlap with text */
  z-index: 1;
}
.eatspay-text {
  display: flex;
  align-items: baseline;
  gap: 3px;
  font-size: 26px;
}
/* Small variant for headers */
.eatspay-logo.sm .eatspay-mark {
  width: 34px;
  margin-bottom: -4px;
}
.eatspay-logo.sm .eatspay-text {
  font-size: 21px;
}
/* Medium variant for splash */
.eatspay-logo.md .eatspay-mark {
  width: 50px;
  margin-bottom: -6px;
}
.eatspay-logo.md .eatspay-text {
  font-size: 30px;
}

/* === App Shell === */
html, body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

#app-shell {
  position: fixed;
  inset: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  background: #d0d0d0;
  z-index: 0;
}

.phone-frame {
  width: 390px;
  height: min(844px, 100vh);
  background: var(--bg-white);
  border-radius: 40px;
  box-shadow: 0 30px 80px rgba(0,0,0,0.25), inset 0 0 0 1px rgba(0,0,0,0.15);
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
}

/* Status bar */
.status-bar {
  height: 44px;
  background: var(--bg-white);
  display: none;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
  flex-shrink: 0;
  z-index: 100;
}

.status-bar .time {
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.3px;
}

.status-bar .icons {
  display: flex;
  gap: 6px;
  align-items: center;
}

.status-bar .icons svg {
  height: 12px;
  width: auto;
}

html.native-app,
html.native-app body {
  background: var(--bg-white);
}

html.native-app #app-shell {
  display: block;
  background: var(--bg-white);
}

html.native-app .phone-frame {
  width: 100vw;
  width: 100dvw;
  height: 100vh;
  height: 100dvh;
  border-radius: 0;
  box-shadow: none;
}

html.native-app .status-bar {
  display: none;
}

html.native-app .screen-container {
  height: 100vh;
  height: 100dvh;
}

/* === Screen Container === */
.screen-container {
  flex: 1;
  overflow: hidden;
  position: relative;
}

.screen {
  position: absolute;
  inset: 0;
  overflow: hidden;
  background: var(--bg-white);
  display: none;
  flex-direction: column;
}

.scrollable-content {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: none;
  padding-bottom: 80px;
}

.scrollable-content::-webkit-scrollbar {
  display: none;
}

.screen::-webkit-scrollbar { display: none; }

.screen.active {
  display: flex;
}

/* === Transitions === */
.screen.slide-in-right {
  animation: slideInRight 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

.screen.slide-in-left {
  animation: slideInLeft 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

.screen.slide-out-right {
  animation: slideOutRight 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

@keyframes slideInRight {
  from { transform: translateX(100%); }
  to { transform: translateX(0); }
}

@keyframes slideInLeft {
  from { transform: translateX(-100%); }
  to { transform: translateX(0); }
}

@keyframes slideOutRight {
  from { transform: translateX(0); }
  to { transform: translateX(100%); }
}

/* ==========================================
   SPLASH SCREEN
   ========================================== */
#screen-splash {
  background: var(--bg-white);
  align-items: center;
  justify-content: center;
}

.splash-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  margin-bottom: 60px;
}

.splash-logo {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}

.logo-icon {
  width: 52px;
  height: 44px;
}

.logo-wordmark {
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.logo-wordmark .eats {
  font-size: 36px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -1px;
}

.logo-wordmark .pay {
  font-size: 36px;
  font-weight: 900;
  color: var(--text-primary);
  letter-spacing: -1px;
}

.splash-tagline {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.5;
  font-weight: 400;
}

.splash-brand {
  font-size: 18px;
  font-weight: 700;
  color: var(--green-primary);
  margin-top: 4px;
}

.splash-footer {
  position: absolute;
  bottom: 40px;
  font-size: 12px;
  color: var(--text-muted);
}

/* ==========================================
   COMMON HEADER (eats PAY header)
   ========================================== */
.app-header {
  padding: 20px 24px 16px;
  border-bottom: 1px solid var(--border-light);
  flex-shrink: 0;
}

.header-logo {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.header-logo .logo-row {
  display: flex;
  align-items: baseline;
  gap: 4px;
}

.header-logo .logo-row .eats {
  font-size: 22px;
  font-weight: 700;
  color: var(--text-primary);
}

.header-logo .logo-row .pay {
  font-size: 22px;
  font-weight: 900;
  color: var(--text-primary);
}

.header-logo .logo-icon-sm {
  width: 32px;
  height: 26px;
  margin-right: 4px;
}

.header-logo .tagline {
  font-size: 12px;
  color: var(--text-secondary);
  font-weight: 400;
}

/* Page header with back */
.page-header {
  display: flex;
  align-items: center;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-light);
  flex-shrink: 0;
}

.back-btn {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: none;
  cursor: pointer;
  border-radius: 50%;
  margin-right: 8px;
  color: var(--text-primary);
  transition: background 0.15s;
}

.back-btn:hover { background: var(--bg-gray); }

.page-title {
  font-size: 17px;
  font-weight: 600;
}

/* ==========================================
   HOME SCREEN
   ========================================== */
#screen-home {
  background: var(--bg-white);
}

.home-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px 12px;
  flex-shrink: 0;
}

.home-logo-row {
  display: flex;
  align-items: center;
  gap: 6px;
}

.home-logo-row .logo-icon-sm {
  width: 28px;
  height: 22px;
}

.home-logo-row .logo-text {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.5px;
}

.home-logo-row .logo-text .pay { font-weight: 900; }

/* Login banner */
.login-banner {
  margin: 0 16px 12px;
  padding: 14px 16px;
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.login-banner-text {
  flex: 1;
}

.login-banner-text .main {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.login-banner-text .sub {
  font-size: 12px;
  color: var(--text-muted);
}

.promo-card {
  margin: 0 16px 12px;
  padding: 10px 14px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--bg-white);
}

.promo-badge {
  background: #1a1a5e;
  color: white;
  font-size: 10px;
  padding: 4px 8px;
  border-radius: 4px;
  font-weight: 600;
  white-space: nowrap;
}

.promo-text {
  flex: 1;
  font-size: 13px;
  color: var(--text-secondary);
}

.btn-promo {
  background: var(--green-primary);
  color: white;
  border: none;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  font-family: var(--font);
  white-space: nowrap;
}

/* Quick menu */
.quick-menu {
  display: flex;
  justify-content: space-around;
  padding: 12px 8px 16px;
  border-bottom: 6px solid var(--bg-light);
}

.quick-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  cursor: pointer;
}

.quick-icon {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 1.5px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  transition: all 0.2s;
  background: var(--bg-white);
}

.quick-item:hover .quick-icon {
  background: var(--green-light);
  border-color: var(--green-primary);
}

.quick-label {
  font-size: 11px;
  color: var(--text-secondary);
  font-weight: 500;
}

/* Banner */
.home-banner {
  margin: 16px 16px 0;
  border-radius: var(--radius);
  overflow: hidden;
  height: 100px;
  background: linear-gradient(135deg, #ff6b35, #f7c59f);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  cursor: pointer;
  position: relative;
}

.banner-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  background: rgba(255,255,255,0.9);
  color: #e53935;
  font-size: 12px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 20px;
}

.banner-text {
  color: white;
}

.banner-text .logo {
  font-size: 12px;
  font-weight: 700;
  background: rgba(255,255,255,0.25);
  padding: 2px 8px;
  border-radius: 4px;
  margin-bottom: 4px;
  display: inline-block;
}

.banner-text .main {
  font-size: 15px;
  font-weight: 700;
}

@keyframes eatspay-shine {
  0% { transform: translateX(-80%) rotate(18deg); opacity: 0; }
  35% { opacity: .8; }
  65% { opacity: .8; }
  100% { transform: translateX(340%) rotate(18deg); opacity: 0; }
}

.metal-benefit-banner {
  border: 1.5px solid rgba(106, 184, 124, .58);
  background:
    linear-gradient(118deg, rgba(255,255,255,.16) 0%, rgba(255,255,255,.82) 12%, rgba(255,255,255,.18) 24%, transparent 36%),
    linear-gradient(135deg, #eefaf1 0%, #ffffff 34%, #e7f3ff 67%, #f5fff7 100%);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.95),
    inset 0 -1px 0 rgba(95, 150, 110, .12),
    0 5px 16px rgba(30, 95, 52, .08);
}

.metal-benefit-glow {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, transparent, rgba(255,255,255,.36), transparent),
    radial-gradient(circle at 18% 0%, rgba(255,255,255,.78), transparent 32%),
    radial-gradient(circle at 88% 100%, rgba(170,211,255,.35), transparent 36%);
  opacity: .82;
  pointer-events: none;
}

.metal-benefit-sheen {
  position: absolute;
  inset: -45% auto auto -42%;
  width: 46%;
  height: 190%;
  background: linear-gradient(105deg, transparent 15%, rgba(255,255,255,.25) 32%, rgba(255,255,255,.92) 48%, rgba(194,218,255,.38) 58%, transparent 78%);
  filter: blur(.2px);
  transform: rotate(17deg);
  animation: metallicSweep 3.4s ease-in-out infinite;
  pointer-events: none;
}

@keyframes metallicSweep {
  0% { transform: translateX(-60%) rotate(17deg); opacity: 0; }
  18% { opacity: .9; }
  58% { opacity: .9; }
  100% { transform: translateX(370%) rotate(17deg); opacity: 0; }
}

.installment-slide-enter {
  animation: installmentSlideIn .42s ease both;
}

@keyframes installmentSlideIn {
  0% {
    opacity: 0;
    transform: translateX(18px);
  }
  100% {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Talk section */
.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 16px 8px;
}

.section-title {
  font-size: 15px;
  font-weight: 700;
}

.section-more {
  font-size: 12px;
  color: var(--text-muted);
  cursor: pointer;
  text-decoration: none;
  border: none;
  background: none;
  font-family: var(--font);
}

.btn-back {
  display: inline-flex !important;
  align-items: center !important;
  gap: 4px !important;
  font-size: 13px !important;
  font-weight: 800 !important;
}

.bottom-nav {
  z-index: 30;
}

.talk-list {
  padding: 0 16px;
  border-bottom: 6px solid var(--bg-light);
}

.talk-item {
  padding: 8px 0;
  border-bottom: 1px solid var(--border-light);
  cursor: pointer;
}

.talk-item:last-child { border-bottom: none; }

.talk-item .talk-title {
  font-size: 13px;
  color: var(--text-primary);
  margin-bottom: 2px;
  font-weight: 400;
}

.talk-item .talk-meta {
  font-size: 11px;
  color: var(--text-muted);
}

/* Product section */
.product-section {
  padding-bottom: 8px;
  border-bottom: 6px solid var(--bg-light);
}

.product-list {
  display: flex;
  gap: 10px;
  padding: 8px 16px;
  overflow-x: auto;
  scrollbar-width: none;
}

.product-list::-webkit-scrollbar { display: none; }

.product-card {
  flex-shrink: 0;
  width: 100px;
  cursor: pointer;
}

.product-img {
  width: 100px;
  height: 90px;
  border-radius: var(--radius-sm);
  background: var(--bg-gray);
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  overflow: hidden;
  border: 1px solid var(--border-light);
}

.product-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-name {
  font-size: 11px;
  color: var(--text-secondary);
  line-height: 1.4;
  margin-bottom: 4px;
}

.product-price {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-primary);
}

.product-original {
  font-size: 11px;
  color: var(--text-muted);
  text-decoration: line-through;
}

/* ==========================================
   BOTTOM NAVIGATION
   ========================================== */
.bottom-nav {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--bottom-nav-height);
  border-top: 1px solid var(--border-light);
  display: flex;
  background: var(--bg-white);
  z-index: 50;
}

.nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  cursor: pointer;
  border: none;
  background: none;
  font-family: var(--font);
  color: var(--text-muted);
  transition: color 0.2s;
  pointer-events: auto;
}

.nav-item.active { color: var(--green-primary); }
.nav-item:hover { color: var(--green-primary); }

.nav-item svg { width: 22px; height: 22px; pointer-events: none; }

.nav-label {
  font-size: 10px;
  font-weight: 500;
  pointer-events: none;
}

.agency-summary-card {
  min-height: 78px;
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius);
  background: linear-gradient(135deg, #ffffff 0%, #f3fbf2 100%);
  padding: 13px 14px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 1px 1px 6px rgba(70, 180, 58, 0.06);
}

.agency-summary-card span {
  color: var(--text-secondary);
  font-size: 11px;
  font-weight: 800;
}

.agency-summary-card strong {
  color: var(--green-dark);
  font-size: 17px;
  font-weight: 900;
}

.agency-settlement-card {
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius);
  background: var(--bg-white);
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.agency-settlement-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 12px;
  font-weight: 800;
  color: var(--text-secondary);
}

.agency-settlement-row strong {
  color: var(--text-primary);
  text-align: right;
}

.agency-table-wrap {
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius);
  background: var(--bg-white);
  overflow-x: auto;
  box-shadow: 1px 1px 6px rgba(70, 180, 58, 0.05);
}

.agency-settlement-table {
  width: 100%;
  min-width: 520px;
  border-collapse: collapse;
  font-size: 11px;
}

.agency-settlement-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #f0faf0;
  color: var(--green-dark);
  font-weight: 900;
  text-align: left;
  padding: 10px 8px;
  border-bottom: 1.5px solid var(--border-color);
  white-space: nowrap;
}

.agency-settlement-table td {
  padding: 10px 8px;
  border-bottom: 1px solid var(--border-light);
  color: var(--text-primary);
  font-weight: 800;
  vertical-align: top;
}

.agency-settlement-table tbody tr:last-child td { border-bottom: none; }

.agency-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 6px;
  padding: 14px 0 4px;
  flex-wrap: wrap;
}

.agency-page-btn {
  min-width: 30px;
  height: 30px;
  border: 1.5px solid var(--border-color);
  border-radius: 8px;
  background: var(--bg-white);
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.agency-page-btn.active {
  background: var(--green-primary);
  border-color: var(--green-primary);
  color: #fff;
}

/* ==========================================
   AUTH PAGES (Login, Find ID, Reset PW)
   ========================================== */
.auth-page {
  display: flex;
  flex-direction: column;
  flex: 1;
  overflow-y: auto;
  padding-bottom: 80px;
}

.auth-content {
  flex: 1;
  padding: 28px 24px;
}

.auth-headline {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.4;
  margin-bottom: 28px;
}

/* Form elements */
.form-group {
  margin-bottom: 12px;
}

.form-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 6px;
  display: block;
}

.form-input {
  width: 100%;
  height: 48px;
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 0 14px;
  font-size: 14px;
  font-family: var(--font);
  color: #111827;
  -webkit-text-fill-color: #111827;
  caret-color: #111827;
  background: var(--bg-white);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-input:-webkit-autofill,
.form-input:-webkit-autofill:hover,
.form-input:-webkit-autofill:focus {
  -webkit-text-fill-color: #111827;
  caret-color: #111827;
  box-shadow: 0 0 0 1000px var(--bg-white) inset;
}

.form-input::placeholder {
  color: #9ca3af;
  -webkit-text-fill-color: #9ca3af;
  opacity: 1;
}

.form-input:focus {
  border-color: var(--green-primary);
  box-shadow: 0 0 0 3px rgba(58, 125, 68, 0.12);
}

.password-field {
  position: relative;
}

.password-field .form-input {
  padding-right: 58px;
}

.password-toggle {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  min-width: 40px;
  height: 30px;
  border: 0;
  border-radius: 6px;
  background: #eef8e8;
  color: var(--green-primary);
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.input-row {
  display: flex;
  gap: 8px;
}

.input-row .form-input { flex: 1; }

.char-count {
  text-align: right;
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 4px;
}

/* Checkbox */
.checkbox-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 4px 0 20px;
  cursor: pointer;
}

.custom-checkbox {
  width: 18px;
  height: 18px;
  border: 1.5px solid var(--border-color);
  border-radius: 3px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  flex-shrink: 0;
  cursor: pointer;
}

.custom-checkbox.checked {
  background: var(--green-primary);
  border-color: var(--green-primary);
}

.custom-checkbox.checked::after {
  content: '';
  width: 10px;
  height: 6px;
  border-left: 2px solid white;
  border-bottom: 2px solid white;
  transform: rotate(-45deg) translateY(-1px);
  display: block;
}

.checkbox-label {
  font-size: 13px;
  color: var(--text-secondary);
}

/* Buttons */
.btn-primary {
  width: 100%;
  height: 50px;
  background: var(--green-primary);
  color: white;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 16px;
  font-weight: 600;
  font-family: var(--font);
  cursor: pointer;
  letter-spacing: -0.3px;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-primary:hover {
  background: var(--green-dark);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(58, 125, 68, 0.3);
}

.btn-primary:active { transform: translateY(0); }

.btn-primary:disabled {
  background: var(--border-color);
  color: var(--text-muted);
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.btn-secondary {
  height: 50px;
  background: var(--bg-white);
  color: var(--green-primary);
  border: 1.5px solid var(--green-primary);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  font-family: var(--font);
  cursor: pointer;
  padding: 0 16px;
  white-space: nowrap;
  transition: all 0.2s;
}

.btn-secondary:hover {
  background: var(--green-light);
}

.btn-send {
  height: 48px;
  background: var(--green-dark);
  color: white;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  font-family: var(--font);
  cursor: pointer;
  padding: 0 14px;
  white-space: nowrap;
  transition: all 0.2s;
  min-width: 90px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.btn-send:hover { background: var(--green-primary); }

.btn-send.sent {
  background: var(--text-muted);
  cursor: default;
}

/* Auth links */
.auth-links {
  display: flex;
  justify-content: center;
  gap: 0;
  margin: 16px 0;
}

.auth-link {
  font-size: 13px;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 4px 14px;
  background: none;
  border: none;
  font-family: var(--font);
  position: relative;
  transition: color 0.2s;
}

.auth-link:hover { color: var(--green-primary); }

.auth-link + .auth-link::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 1px;
  height: 12px;
  background: var(--border-color);
}

/* Social login */
.social-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
}

.social-divider::before,
.social-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border-light);
}

.social-divider span {
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
}

.social-btns {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-bottom: 8px;
}

.social-btn {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 1px solid var(--border-light);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  font-weight: 800;
  transition: all 0.2s;
  background: var(--bg-white);
}

.social-btn:hover {
  transform: scale(1.05);
  box-shadow: var(--shadow);
}

.social-naver {
  background: #03c75a;
  color: white;
  border-color: #03c75a;
  font-size: 20px;
}

.social-kakao {
  background: #fee500;
  color: #3c1e1e;
  border-color: #fee500;
  font-size: 14px;
  font-weight: 700;
}

.social-google {
  background: #fff;
  border-color: var(--border-color);
}

/* ==========================================
   REGISTER FLOW
   ========================================== */
.register-page {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}

.register-content {
  flex: 1;
  padding: 28px 24px 20px;
}

.register-section {
  margin-bottom: 24px;
}

.register-section-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 14px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--green-primary);
}

/* Upload button */
.upload-btn {
  width: 100%;
  height: 48px;
  border: 1.5px dashed var(--green-primary);
  border-radius: var(--radius-sm);
  background: var(--green-light);
  color: var(--green-primary);
  font-size: 14px;
  font-weight: 600;
  font-family: var(--font);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.2s;
}

.upload-btn:hover {
  background: #d0ebd4;
  border-color: var(--green-dark);
}

/* Terms */
.terms-group {
  margin-bottom: 16px;
}

.terms-check-all {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 14px;
  background: var(--bg-light);
  border-radius: var(--radius-sm);
  cursor: pointer;
  margin-bottom: 8px;
}

.terms-check-all .label {
  font-size: 15px;
  font-weight: 700;
}

.terms-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  margin-bottom: 8px;
  cursor: pointer;
}

.terms-item .label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.terms-item .content {
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.6;
  max-height: 60px;
  overflow-y: auto;
}

/* Step indicator */
.step-indicator {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  padding: 16px 24px 0;
}

.step-dot {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 2px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--bg-white);
  flex-shrink: 0;
}

.step-dot.active {
  border-color: var(--green-primary);
  color: var(--green-primary);
  background: var(--green-light);
}

.step-dot.done {
  border-color: var(--green-primary);
  background: var(--green-primary);
  color: white;
}

.step-line {
  height: 2px;
  flex: 1;
  background: var(--border-color);
  max-width: 40px;
}

.step-line.done {
  background: var(--green-primary);
}

/* Address */
.address-row {
  display: flex;
  gap: 8px;
  margin-bottom: 8px;
}

/* ==========================================
   TOAST / SNACKBAR
   ========================================== */
.toast {
  position: absolute;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: rgba(30, 30, 30, 0.9);
  color: white;
  padding: 10px 20px;
  border-radius: 24px;
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
  opacity: 0;
  transition: all 0.3s;
  z-index: 1000;
  backdrop-filter: blur(8px);
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* === Photo Picker Sheet === */
.photo-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
  z-index: 1100;
}

.photo-backdrop.show {
  opacity: 1;
  pointer-events: auto;
}

.photo-sheet {
  position: fixed;
  left: 50%;
  bottom: 18px;
  width: min(390px - 24px, calc(100vw - 24px));
  max-width: 366px;
  transform: translateX(-50%) translateY(120%);
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.28);
  padding: 12px;
  transition: transform 0.22s ease;
  z-index: 1200;
}

.photo-sheet.show {
  transform: translateX(-50%) translateY(0);
}

.photo-sheet-handle {
  width: 42px;
  height: 4px;
  border-radius: 999px;
  background: #d8d8d8;
  margin: 0 auto 10px;
}

.photo-sheet-title {
  font-size: 15px;
  font-weight: 800;
  color: var(--text-primary);
  text-align: center;
  margin-bottom: 10px;
}

.photo-sheet-option,
.photo-sheet-cancel {
  width: 100%;
  height: 44px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  border: 1.5px solid var(--border-color);
  background: #fff;
  color: var(--text-primary);
}

.photo-sheet-option + .photo-sheet-option {
  margin-top: 8px;
}

.photo-sheet-cancel {
  margin-top: 10px;
  background: #f7f7f7;
  color: var(--text-secondary);
}

/* ==========================================
   APP DIALOG
   ========================================== */
.app-dialog-backdrop {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: none;
  background: rgba(0, 0, 0, 0.42);
}

.app-dialog-backdrop.show {
  display: block;
}

.app-dialog {
  position: fixed;
  left: 50%;
  top: 50%;
  z-index: 10001;
  width: min(340px, calc(100vw - 48px));
  display: none;
  transform: translate(-50%, -50%);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  background: var(--bg-white);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.22);
  padding: 20px;
}

.app-dialog.show {
  display: block;
}

.app-dialog-title {
  color: var(--text-primary);
  font-size: 16px;
  font-weight: 900;
  margin-bottom: 10px;
}

.app-dialog-message {
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.55;
  white-space: pre-line;
}

.app-dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 18px;
}

.app-dialog-btn {
  min-width: 76px;
  height: 40px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
}

.app-dialog-btn-cancel {
  border: 1.5px solid var(--border-color);
  background: var(--bg-white);
  color: var(--text-secondary);
}

.app-dialog-btn-confirm {
  border: 1.5px solid var(--green-primary);
  background: var(--green-primary);
  color: #fff;
}

/* ==========================================
   COUNTDOWN TIMER
   ========================================== */
.countdown {
  font-size: 13px;
  color: #e53935;
  font-weight: 600;
  margin-top: 6px;
  height: 18px;
}

/* ==========================================
   LOADING SPINNER
   ========================================== */
.spinner {
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255,255,255,0.4);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ==========================================
   RESPONSIVE (Full screen on small devices)
   ========================================== */

/* 모바일 기기에서는 완전히 전체화면으로 */
@media (max-width: 480px) {
  #app-shell {
    position: fixed;
    inset: 0;
    background: var(--bg-white);
    display: block;
  }

  .phone-frame {
    width: 100vw;
    width: 100dvw;
    height: 100vh;
    height: 100dvh;
    border-radius: 0;
    box-shadow: none;
  }
}

/* ==========================================
   SPLASH PREMIUM ANIMATIONS
   ========================================== */
.splash-brand-premium {
  animation: splashScaleIn 1.5s cubic-bezier(0.19, 1, 0.22, 1) forwards;
}

.splash-img-premium {
  animation: splashFloat 3s ease-in-out infinite, splashFadeIn 1.2s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

.splash-tagline-premium {
  opacity: 0;
  animation: splashFadeInUp 1.2s cubic-bezier(0.19, 1, 0.22, 1) 0.5s forwards;
}

@keyframes splashScaleIn {
  0% {
    opacity: 0;
    transform: scale(0.7) translateY(10px);
  }
  100% {
    opacity: 1;
    transform: scale(1.05) translateY(0);
  }
}

@keyframes splashFadeIn {
  0% {
    opacity: 0;
    transform: scale(0.72);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes splashFadeInUp {
  0% {
    opacity: 0;
    transform: translateY(15px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes splashFloat {
  0%, 100% {
    transform: translateY(0) scale(1);
  }
  50% {
    transform: translateY(-6px) scale(1);
  }
}
