/* ==========================================================================
   ITLCoin — Design tokens
   ========================================================================== */
:root {
  --bg: #030303;
  --bg-panel: #0a0a1c;
  --bg-panel-2: #0e121b;
  --border: rgba(255, 255, 255, 0.1);
  --border-soft: rgba(255, 255, 255, 0.06);

  --white: #ffffff;
  --text-primary: #ffffff;
  --text-secondary: rgba(255, 255, 255, 0.65);
  --text-tertiary: rgba(255, 255, 255, 0.42);

  --accent: #6962f1;
  --accent-2: #6365ed;
  --accent-3: #532cde;
  --accent-light: #a48fff;

  --success: #22c55e;

  --font-body: 'Inter', ui-sans-serif, system-ui, sans-serif;
  --font-display: 'Space Grotesk', 'Inter', ui-sans-serif, system-ui, sans-serif;

  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-pill: 999px;

  --shadow-glow: 0 8px 24px -6px rgba(99, 101, 237, 0.45);
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

/* ==========================================================================
   Reset
   ========================================================================== */
* { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
input { font-family: inherit; color: inherit; }
ul { list-style: none; }

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ==========================================================================
   Background effects
   ========================================================================== */
.bg-glow {
  position: fixed;
  border-radius: 50%;
  filter: blur(120px);
  pointer-events: none;
  z-index: 0;
  opacity: 0.55;
}
.bg-glow-1 {
  width: 640px;
  height: 640px;
  top: -220px;
  left: 50%;
  transform: translateX(-50%);
  background: radial-gradient(circle, #4428a9 0%, transparent 70%);
}
.bg-glow-2 {
  width: 520px;
  height: 520px;
  top: 900px;
  right: -160px;
  background: radial-gradient(circle, #31245e 0%, transparent 70%);
  opacity: 0.4;
}
.noise-overlay {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background: linear-gradient(180deg, transparent 0%, rgba(0,0,0,0.4) 100%);
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: none;
  border-radius: var(--radius-pill);
  font-family: var(--font-body);
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease), background 0.2s var(--ease), opacity 0.2s var(--ease);
  white-space: nowrap;
}
.btn svg { flex-shrink: 0; }

.btn-primary {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-3) 100%);
  color: #fff;
  box-shadow: 0 8px 16px -6px rgba(99, 101, 237, 0.48), inset 0 0 2px 0 rgba(255,255,255,0.4);
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 12px 24px -6px rgba(99, 101, 237, 0.6); }
.btn-primary:active { transform: translateY(0); }
.btn-primary:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

.btn-ghost {
  background: rgba(255,255,255,0.04);
  color: var(--text-primary);
  border: 1px solid var(--border);
}
.btn-ghost:hover { background: rgba(255,255,255,0.08); }

.btn-sm { padding: 9px 18px; font-size: 13.5px; }
.btn-lg { padding: 15px 28px; font-size: 15.5px; }
.btn-block { width: 100%; }

/* ==========================================================================
   Header
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  padding: 18px 0;
  transition: background 0.3s var(--ease), border-color 0.3s var(--ease), padding 0.3s var(--ease);
  border-bottom: 1px solid transparent;
}
.site-header.scrolled {
  background: rgba(3, 3, 3, 0.75);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom-color: var(--border-soft);
  padding: 12px 0;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
}
.logo-mark {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-3) 100%);
  font-size: 13px;
  font-weight: 700;
  box-shadow: var(--shadow-glow);
}
.logo-text {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.01em;
}
.logo-accent { color: var(--accent-light); }

.main-nav {
  display: flex;
  align-items: center;
  gap: 32px;
}
.main-nav a {
  font-size: 14.5px;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color 0.2s var(--ease);
}
.main-nav a:hover { color: var(--text-primary); }

.header-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.live-rate-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: var(--radius-pill);
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
}

.pulse-dot {
  position: relative;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--success);
  flex-shrink: 0;
}
.pulse-dot::after {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  background: var(--success);
  opacity: 0.5;
  animation: pulse-ring 2s cubic-bezier(0.4,0,0.6,1) infinite;
}
@keyframes pulse-ring {
  0% { transform: scale(0.8); opacity: 0.6; }
  70% { transform: scale(1.8); opacity: 0; }
  100% { transform: scale(1.8); opacity: 0; }
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 4px;
  background: none;
  border: none;
  padding: 6px;
}
.nav-toggle span {
  width: 20px;
  height: 1.6px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: transform 0.25s var(--ease), opacity 0.25s var(--ease);
}

/* ==========================================================================
   Hero
   ========================================================================== */
.hero {
  position: relative;
  z-index: 1;
  padding: 96px 0 64px;
  text-align: center;
}
.hero-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: var(--radius-pill);
  background: rgba(105, 98, 241, 0.12);
  border: 1px solid rgba(105, 98, 241, 0.3);
  font-size: 13px;
  font-weight: 600;
  color: var(--accent-light);
  margin-bottom: 28px;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.6rem, 6vw, 4.6rem);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin-bottom: 24px;
}
.text-gradient {
  background: linear-gradient(135deg, #fff 0%, var(--accent-light) 50%, var(--accent-2) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  max-width: 560px;
  font-size: 17px;
  line-height: 1.65;
  color: var(--text-secondary);
  margin-bottom: 40px;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: center;
  margin-bottom: 56px;
}

.hero-trust {
  display: flex;
  align-items: center;
  gap: 28px;
  flex-wrap: wrap;
  justify-content: center;
}
.trust-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--text-tertiary);
}
.trust-item svg { color: var(--accent-light); }

/* ==========================================================================
   Stats
   ========================================================================== */
.stats { position: relative; z-index: 1; padding: 0 0 80px; }
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.stat-card {
  padding: 24px;
  border-radius: var(--radius-md);
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border-soft);
  text-align: left;
}
.stat-label {
  font-size: 13px;
  color: var(--text-tertiary);
  font-weight: 500;
  margin-bottom: 10px;
}
.stat-value {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.01em;
}
.stat-unit { font-size: 15px; color: var(--text-tertiary); font-weight: 500; }
.stat-sub { font-size: 12.5px; color: var(--text-tertiary); margin-top: 6px; }

/* ==========================================================================
   Section head
   ========================================================================== */
.section-head {
  text-align: center;
  max-width: 560px;
  margin: 0 auto 48px;
}
.eyebrow {
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent-light);
  margin-bottom: 14px;
}
.section-head h2 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3.5vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-bottom: 12px;
}
.section-head p { color: var(--text-secondary); font-size: 15.5px; line-height: 1.6; }
.section-head p strong { color: var(--text-primary); }

/* ==========================================================================
   Glass panel
   ========================================================================== */
.glass-panel {
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

/* ==========================================================================
   Sell section
   ========================================================================== */
.sell-section { position: relative; z-index: 1; padding: 40px 0 100px; }

.sell-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 24px;
  align-items: start;
}

.sell-card {
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  position: relative;
  overflow: hidden;
}
.sell-card::before {
  content: '';
  position: absolute;
  top: -80px;
  right: -80px;
  width: 220px;
  height: 220px;
  background: radial-gradient(circle, rgba(105,98,241,0.25) 0%, transparent 70%);
  pointer-events: none;
}

#sellForm {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Stepper */
.stepper {
  display: flex;
  align-items: center;
  gap: 8px;
}
.step-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.step-circle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border);
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  color: var(--text-tertiary);
  transition: background 0.25s var(--ease), border-color 0.25s var(--ease), color 0.25s var(--ease);
}
.step-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-tertiary);
  white-space: nowrap;
  display: none;
}
.step-item.active .step-circle {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-3) 100%);
  border-color: transparent;
  color: #fff;
  box-shadow: var(--shadow-glow);
}
.step-item.active .step-label { color: var(--text-primary); }
.step-item.done .step-circle {
  background: rgba(34, 197, 94, 0.15);
  border-color: rgba(34, 197, 94, 0.4);
  color: #86efac;
}
.step-line {
  flex: 1;
  height: 1px;
  background: var(--border-soft);
}

/* Form steps */
.form-step { display: none; flex-direction: column; gap: 20px; }
.form-step.active { display: flex; }

.step-actions {
  display: flex;
  gap: 12px;
}
.step-actions .btn { flex: 1; padding: 15px 28px; font-size: 15.5px; }

.payout-preview {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 18px;
  border-radius: var(--radius-md);
  background: rgba(105, 98, 241, 0.08);
  border: 1px solid rgba(105, 98, 241, 0.25);
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
}
.payout-preview span:last-child {
  font-family: var(--font-display);
  font-size: 18px;
  color: var(--text-primary);
}

/* Address box */
.address-box {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border-radius: var(--radius-md);
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border);
}
.address-box span {
  flex: 1;
  font-family: var(--font-display);
  font-size: 13.5px;
  color: var(--text-primary);
  word-break: break-all;
}
.copy-btn {
  flex-shrink: 0;
  padding: 7px 14px;
  border-radius: var(--radius-pill);
  background: rgba(105, 98, 241, 0.16);
  border: 1px solid rgba(105, 98, 241, 0.4);
  color: var(--accent-light);
  font-size: 12.5px;
  font-weight: 700;
  transition: background 0.2s var(--ease), color 0.2s var(--ease);
}
.copy-btn:hover { background: rgba(105, 98, 241, 0.28); }
.copy-btn.copied { background: rgba(34, 197, 94, 0.16); border-color: rgba(34, 197, 94, 0.4); color: #86efac; }

.warning-box {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 14px 16px;
  border-radius: var(--radius-md);
  background: rgba(251, 191, 36, 0.08);
  border: 1px solid rgba(251, 191, 36, 0.25);
  color: #fcd34d;
}
.warning-box svg { flex-shrink: 0; margin-top: 1px; }
.warning-box p { font-size: 13px; line-height: 1.5; color: #fde68a; }

/* File upload */
.upload-shell {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 28px 16px;
  border-radius: var(--radius-md);
  background: rgba(255,255,255,0.03);
  border: 1.5px dashed var(--border);
  color: var(--text-tertiary);
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s var(--ease), background 0.2s var(--ease), color 0.2s var(--ease);
}
.upload-shell:hover { border-color: rgba(105, 98, 241, 0.5); color: var(--text-secondary); }
.upload-shell span { font-size: 13.5px; font-weight: 500; }

.upload-preview {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: var(--radius-md);
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border);
}
.upload-preview img {
  width: 44px;
  height: 44px;
  object-fit: cover;
  border-radius: 8px;
  flex-shrink: 0;
}
.upload-preview span {
  flex: 1;
  font-size: 13px;
  color: var(--text-secondary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.remove-file-btn {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(255,255,255,0.06);
  border: none;
  color: var(--text-secondary);
}
.remove-file-btn:hover { background: rgba(255,255,255,0.12); color: #fff; }

/* Confirm checkbox */
.confirm-checkbox {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 14px 16px;
  border-radius: var(--radius-md);
  background: rgba(255,255,255,0.025);
  border: 1px solid var(--border-soft);
  cursor: pointer;
}
.confirm-checkbox input {
  margin-top: 2px;
  width: 16px;
  height: 16px;
  accent-color: var(--accent);
  flex-shrink: 0;
}
.confirm-checkbox span {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
}

.field-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.field-group label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-tertiary);
}

.input-shell {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  border-radius: var(--radius-md);
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border);
  transition: border-color 0.2s var(--ease), background 0.2s var(--ease);
}
.input-shell:focus-within {
  border-color: rgba(105, 98, 241, 0.6);
  background: rgba(255,255,255,0.06);
}
.input-shell input {
  flex: 1;
  background: none;
  border: none;
  outline: none;
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 600;
  color: var(--text-primary);
  min-width: 0;
}
.input-shell input::placeholder { color: var(--text-tertiary); }
.input-shell input[type="text"] { font-family: var(--font-body); font-size: 15px; font-weight: 500; }
.input-shell input::-webkit-outer-spin-button,
.input-shell input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.input-shell input[type=number] { -moz-appearance: textfield; }

.input-suffix {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--accent-light);
  padding: 5px 10px;
  border-radius: var(--radius-pill);
  background: rgba(105, 98, 241, 0.14);
  flex-shrink: 0;
}

.field-hint {
  font-size: 12px;
  color: var(--text-tertiary);
}

.order-summary {
  padding: 16px 18px;
  border-radius: var(--radius-md);
  background: rgba(255,255,255,0.025);
  border: 1px solid var(--border-soft);
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.order-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13.5px;
  color: var(--text-secondary);
}
.order-total {
  padding-top: 10px;
  border-top: 1px solid var(--border-soft);
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
}
.form-disclaimer {
  font-size: 12px;
  color: var(--text-tertiary);
  text-align: center;
  line-height: 1.5;
}

/* Side panel */
.sell-side { display: flex; flex-direction: column; gap: 20px; }
.side-panel { padding: 26px; text-align: center; }
.side-panel h3 {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 8px;
}
.side-copy {
  font-size: 13px;
  color: var(--text-tertiary);
  margin-bottom: 20px;
  line-height: 1.5;
}
.sell-side .side-panel:first-child { text-align: center; }

.timer-ring-wrap {
  position: relative;
  width: 88px;
  height: 88px;
  margin: 0 auto 18px;
}
.timer-ring { transform: rotate(-90deg); }
.timer-track {
  fill: none;
  stroke: rgba(255,255,255,0.08);
  stroke-width: 5;
}
.timer-progress {
  fill: none;
  stroke: url(#none);
  stroke: var(--accent);
  stroke-width: 5;
  stroke-linecap: round;
  stroke-dasharray: 238.76;
  stroke-dashoffset: 0;
  transition: stroke-dashoffset 1s linear;
}
.timer-value {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
}
.side-rate {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--accent-light);
}

.feature-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  text-align: left;
}
.feature-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13.5px;
  color: var(--text-secondary);
}
.feature-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 9px;
  background: rgba(105, 98, 241, 0.12);
  color: var(--accent-light);
  flex-shrink: 0;
}

/* ==========================================================================
   How it works
   ========================================================================== */
.how-it-works { position: relative; z-index: 1; padding: 20px 0 100px; }
.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.step-card { padding: 28px; }
.step-number {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  color: var(--accent-light);
  margin-bottom: 16px;
}
.step-card h3 {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 10px;
}
.step-card p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ==========================================================================
   FAQ
   ========================================================================== */
.faq { position: relative; z-index: 1; padding: 20px 0 110px; }
.faq-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 720px;
  margin: 0 auto;
}
.faq-item { overflow: hidden; }
.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
  background: none;
  border: none;
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 600;
  text-align: left;
}
.faq-chevron { color: var(--text-tertiary); transition: transform 0.3s var(--ease); flex-shrink: 0; }
.faq-item.open .faq-chevron { transform: rotate(180deg); color: var(--accent-light); }
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s var(--ease);
}
.faq-item.open .faq-answer { max-height: 200px; }
.faq-answer p {
  padding: 0 24px 20px;
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
  position: relative;
  z-index: 1;
  border-top: 1px solid var(--border-soft);
  padding: 56px 0 28px;
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 40px;
  flex-wrap: wrap;
  margin-bottom: 40px;
}
.footer-brand { max-width: 280px; }
.footer-brand .logo { margin-bottom: 14px; }
.footer-brand p { font-size: 13.5px; color: var(--text-tertiary); line-height: 1.6; }

.footer-cols {
  display: flex;
  gap: 56px;
  flex-wrap: wrap;
}
.footer-col { display: flex; flex-direction: column; gap: 12px; }
.footer-col h4 {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 4px;
}
.footer-col a {
  font-size: 14px;
  color: var(--text-secondary);
  transition: color 0.2s var(--ease);
}
.footer-col a:hover { color: var(--text-primary); }

.footer-bottom {
  padding-top: 24px;
  border-top: 1px solid var(--border-soft);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.footer-bottom p { font-size: 12.5px; color: var(--text-tertiary); }
.footer-legal {
  display: flex;
  align-items: center;
  gap: 20px;
}
.footer-legal a {
  font-size: 12.5px;
  color: var(--text-tertiary);
  transition: color 0.2s var(--ease);
}
.footer-legal a:hover { color: var(--text-primary); }

/* ==========================================================================
   Modal
   ========================================================================== */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(0,0,0,0.6);
  backdrop-filter: blur(6px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s var(--ease);
}
.modal-overlay.visible { opacity: 1; pointer-events: auto; }

.modal-panel {
  position: relative;
  width: 100%;
  max-width: 400px;
  padding: 36px 32px 32px;
  text-align: center;
  background: #0a0a14;
  transform: translateY(12px) scale(0.98);
  transition: transform 0.25s var(--ease);
}
.modal-overlay.visible .modal-panel { transform: translateY(0) scale(1); }

.modal-close {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(255,255,255,0.05);
  border: none;
  color: var(--text-secondary);
}
.modal-close:hover { background: rgba(255,255,255,0.1); color: var(--white); }

.modal-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(34, 197, 94, 0.12);
  color: #4ade80;
}
.modal-panel h3 {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 6px;
}
.modal-sub {
  font-size: 13px;
  color: var(--text-tertiary);
  margin-bottom: 24px;
}
.modal-summary {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 16px 18px;
  border-radius: var(--radius-md);
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border-soft);
  margin-bottom: 24px;
  text-align: left;
}
.modal-summary .order-row span:last-child { color: var(--text-primary); font-weight: 600; }

/* ==========================================================================
   Legal pages
   ========================================================================== */
.legal-page { position: relative; z-index: 1; padding: 140px 0 100px; }
.legal-content { max-width: 720px; margin: 0 auto; }
.legal-content h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 14px 0 10px;
}
.legal-updated { font-size: 13.5px; color: var(--text-tertiary); margin-bottom: 28px; }
.legal-content .warning-box { margin-bottom: 40px; }
.legal-content h2 {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  margin: 40px 0 14px;
}
.legal-content p {
  font-size: 15px;
  line-height: 1.7;
  color: var(--text-secondary);
  margin-bottom: 14px;
}
.legal-content ul {
  list-style: disc;
  padding-left: 22px;
  margin-bottom: 14px;
}
.legal-content li {
  font-size: 15px;
  line-height: 1.7;
  color: var(--text-secondary);
  margin-bottom: 8px;
}
.legal-content strong { color: var(--text-primary); }
.legal-content a { color: var(--accent-light); text-decoration: underline; }

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 900px) {
  .sell-grid { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .steps-grid { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  .main-nav { display: none; }
  .nav-toggle { display: flex; }
  .live-rate-chip { display: none; }

  .main-nav.mobile-open {
    display: flex;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    background: rgba(3,3,3,0.98);
    border-bottom: 1px solid var(--border-soft);
    padding: 8px 24px 20px;
  }
  .main-nav.mobile-open a { padding: 12px 0; border-bottom: 1px solid var(--border-soft); width: 100%; }

  .hero { padding: 64px 0 48px; }
  .legal-page { padding: 100px 0 64px; }
  .hero-actions { flex-direction: column; width: 100%; }
  .hero-actions .btn { width: 100%; }
  .hero-trust { gap: 16px; }

  .stats-grid { grid-template-columns: 1fr 1fr; }
  .sell-card { padding: 24px 20px; }
  .step-actions { flex-wrap: wrap; }
}
