:root {
  --bg: #030012;
  --bg-alt: #0a0520;
  --card: rgba(255, 255, 255, 0.03);
  --card-hover: rgba(255, 255, 255, 0.06);
  --text: #f8fafc;
  --muted: #94a3b8;
  --accent: linear-gradient(135deg, #06b6d4 0%, #8b5cf6 50%, #d946ef 100%);
  --accent-solid: #8b5cf6;
  --accent-secondary: #06b6d4;
  --accent-glow: rgba(139, 92, 246, 0.4);
  --border: rgba(255, 255, 255, 0.06);
  --border-hover: rgba(255, 255, 255, 0.12);
  --success: #10b981;
  --danger: #ef4444;
  --warning: #f59e0b;
  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --radius-2xl: 36px;
  --shadow-glow: 0 0 100px rgba(139, 92, 246, 0.2), 0 0 200px rgba(6, 182, 212, 0.1);
  --shadow-card: 0 25px 50px -12px rgba(0, 0, 0, 0.6);
  --shadow-input: 0 4px 12px rgba(0, 0, 0, 0.15);
  --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  font-family: 'Outfit', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

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

/* ========== MODERN SCROLLBAR ========== */
* {
  scrollbar-width: thin;
  scrollbar-color: rgba(139, 92, 246, 0.4) transparent;
}

*::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

*::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.02);
  border-radius: 4px;
}

*::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, rgba(139, 92, 246, 0.5), rgba(6, 182, 212, 0.4));
  border-radius: 4px;
  border: 2px solid transparent;
  background-clip: padding-box;
}

*::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, rgba(139, 92, 246, 0.7), rgba(6, 182, 212, 0.6));
  background-clip: padding-box;
}

*::-webkit-scrollbar-corner {
  background: transparent;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.6;
  overflow-x: hidden;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  background: 
    radial-gradient(ellipse 100% 80% at 10% -20%, rgba(139, 92, 246, 0.25), transparent 50%),
    radial-gradient(ellipse 80% 60% at 90% -10%, rgba(6, 182, 212, 0.2), transparent 45%),
    radial-gradient(ellipse 60% 40% at 50% 110%, rgba(217, 70, 239, 0.12), transparent 40%);
  pointer-events: none;
  z-index: -1;
}

img, svg {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition);
}

a:hover {
  color: var(--accent-secondary);
}

h1, h2, h3, h4 {
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: -0.02em;
}

h1 {
  font-size: clamp(2.25rem, 5vw, 4rem);
  background: var(--accent);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

h2 {
  font-size: clamp(1.75rem, 3vw, 2.5rem);
}

.container {
  width: min(1320px, 94%);
  margin: 0 auto;
  padding: 0 1rem;
}

.flex {
  display: flex;
  gap: 1.5rem;
}

.align-center {
  align-items: center;
}

.between {
  justify-content: space-between;
}

.grid {
  display: grid;
  gap: 2rem;
}

.grid.two {
  grid-template-columns: repeat(2, 1fr);
}

.grid.three {
  grid-template-columns: repeat(3, 1fr);
}

.grid.four {
  grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 1024px) {
  .grid.two, .grid.three, .grid.four {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .grid.two, .grid.three, .grid.four {
    grid-template-columns: 1fr;
  }
}

/* ========== HEADER ========== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(24px) saturate(180%);
  background: rgba(3, 0, 18, 0.75);
  border-bottom: 1px solid var(--border);
  padding: 0.875rem 0;
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.brand img {
  width: 42px;
  height: 42px;
  filter: drop-shadow(0 0 16px rgba(139, 92, 246, 0.5));
}

.brand span {
  font-weight: 800;
  font-size: 1.35rem;
  background: var(--accent);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.02em;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 2.5rem;
}

.main-nav a {
  position: relative;
  font-weight: 500;
  color: var(--muted);
  padding: 0.5rem 0;
  font-size: 0.95rem;
}

.main-nav a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: width var(--transition);
}

.main-nav a:hover {
  color: var(--text);
}

.main-nav a:hover::after {
  width: 100%;
}

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  color: var(--text);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0.5rem;
}

@media (max-width: 768px) {
  .main-nav {
    position: fixed;
    top: 66px;
    left: 0;
    right: 0;
    background: rgba(3, 0, 18, 0.98);
    backdrop-filter: blur(24px);
    flex-direction: column;
    padding: 2rem;
    gap: 1.5rem;
    transform: translateY(-120%);
    opacity: 0;
    transition: all var(--transition);
    border-bottom: 1px solid var(--border);
  }

  .main-nav.is-open {
    transform: translateY(0);
    opacity: 1;
  }

  .mobile-menu-btn {
    display: block;
  }
  
  .brand span {
    font-size: 1.15rem;
  }
  
  .brand img {
    width: 36px;
    height: 36px;
  }
}

@media (max-width: 480px) {
  .site-header {
    padding: 0.75rem 0;
  }
  
  .site-header .container {
    gap: 1rem;
  }
  
  .brand span {
    font-size: 1rem;
  }
  
  .brand img {
    width: 32px;
    height: 32px;
  }
}

/* ========== BUTTONS ========== */
button, .btn {
  font: inherit;
  border: none;
  cursor: pointer;
  border-radius: var(--radius-lg);
  padding: 1rem 2rem;
  font-weight: 600;
  font-size: 0.95rem;
  transition: all var(--transition);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  letter-spacing: 0.01em;
}

button:disabled, .btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

button.primary, .btn.primary {
  background: var(--accent);
  color: #030012;
  box-shadow: 0 8px 32px var(--accent-glow), inset 0 1px 0 rgba(255,255,255,0.2);
  position: relative;
  overflow: hidden;
}

button.primary::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255,255,255,0.15), transparent 50%);
  opacity: 1;
}

button.primary:hover:not(:disabled) {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 16px 48px var(--accent-glow);
}

button.primary:disabled,
button.primary.is-disabled,
.converter-card button.primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
  background: linear-gradient(135deg, rgba(148, 163, 184, 0.25), rgba(71, 85, 105, 0.25));
  color: rgba(248, 250, 252, 0.7);
}

button.secondary, .btn.secondary {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  color: var(--text);
  backdrop-filter: blur(10px);
}

button.secondary:hover:not(:disabled) {
  border-color: var(--border-hover);
  background: rgba(255, 255, 255, 0.08);
  transform: translateY(-2px);
}

button.ghost, .btn.ghost {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  backdrop-filter: blur(10px);
}

button.ghost:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.1);
}

button.wide, .btn.wide {
  width: 100%;
}

button.icon-button {
  padding: 0.75rem;
  border-radius: 50%;
  width: 44px;
  height: 44px;
}

/* ========== HERO ========== */
.hero {
  padding: 6rem 0 5rem;
  position: relative;
}

.hero .container {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 5rem;
  align-items: center;
}

.hero-content {
  max-width: 620px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  background: rgba(139, 92, 246, 0.1);
  border: 1px solid rgba(139, 92, 246, 0.25);
  padding: 0.6rem 1.25rem;
  border-radius: var(--radius-xl);
  font-size: 0.85rem;
  font-weight: 600;
  color: #c4b5fd;
  margin-bottom: 1.75rem;
}

.badge::before {
  content: '';
  width: 8px;
  height: 8px;
  background: var(--success);
  border-radius: 50%;
  animation: pulse 2s infinite;
  box-shadow: 0 0 8px var(--success);
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.6; transform: scale(1.3); }
}

.hero h1 {
  margin-bottom: 1.5rem;
}

.lead {
  font-size: 1.2rem;
  color: var(--muted);
  margin-bottom: 2.25rem;
  line-height: 1.75;
}

.hero-points {
  list-style: none;
  margin-bottom: 2.5rem;
}

.hero-points li {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  padding: 0.65rem 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.hero-points li::before {
  content: '✓';
  display: flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  background: rgba(16, 185, 129, 0.12);
  color: var(--success);
  border-radius: 50%;
  font-size: 0.8rem;
  font-weight: 700;
}

.cta-group {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

@media (max-width: 1024px) {
  .hero .container {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .hero-content {
    max-width: 100%;
    order: 1;
  }

  .converter-card {
    order: 0;
    max-width: 500px;
    margin: 0 auto;
  }

  .hero-points {
    display: inline-flex;
    flex-direction: column;
    align-items: flex-start;
  }

  .cta-group {
    justify-content: center;
  }
}

@media (max-width: 768px) {
  .hero {
    padding: 3rem 0 2.5rem;
  }
  
  .hero .container {
    gap: 2.5rem;
  }
  
  .lead {
    font-size: 1.05rem;
    margin-bottom: 1.5rem;
  }
  
  .hero-points li {
    font-size: 0.95rem;
    padding: 0.5rem 0;
  }
  
  .badge {
    font-size: 0.75rem;
    padding: 0.5rem 1rem;
  }
}

@media (max-width: 480px) {
  .hero {
    padding: 2rem 0;
  }
  
  .hero .container {
    gap: 2rem;
  }
  
  .cta-group {
    flex-direction: column;
    width: 100%;
  }
  
  .cta-group button,
  .cta-group .btn {
    width: 100%;
  }
  
  .hero-points {
    width: 100%;
  }
  
  .hero-points li {
    font-size: 0.9rem;
  }
  
  .hero-points li::before {
    width: 22px;
    height: 22px;
    font-size: 0.7rem;
  }

  .wallet-connect-grid {
    grid-template-columns: 1fr;
  }
}

/* ========== CONVERTER CARD ========== */
.converter-card {
  background: linear-gradient(145deg, rgba(30, 20, 61, 0.95), rgba(12, 7, 26, 0.92));
  backdrop-filter: blur(40px) saturate(160%);
  border-radius: var(--radius-2xl);
  padding: 2.25rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 20px 45px rgba(4, 4, 19, 0.65), var(--shadow-glow);
  position: relative;
  overflow: hidden;
}

.converter-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 10%, rgba(255,255,255,0.2) 50%, transparent 90%);
}

.converter-card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 20% 0%, rgba(139, 92, 246, 0.18), transparent 55%);
  pointer-events: none;
}

.card-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.875rem;
}

.card-head span {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text);
}

.card-head small {
  color: var(--muted);
  font-size: 0.8rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.card-head small::before {
  content: '';
  width: 6px;
  height: 6px;
  background: var(--success);
  border-radius: 50%;
  animation: pulse 2s infinite;
}

/* Modern Input Group */
.input-group {
  display: flex;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 1.5rem;
  transition: all var(--transition);
  position: relative;
}

.input-group:focus-within {
  border-color: var(--accent-solid);
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.15);
}

.input-group input {
  flex: 1;
  padding: 1.125rem 1.25rem;
  background: transparent;
  border: none;
  color: var(--text);
  font-size: 1.5rem;
  font-weight: 600;
  min-width: 0;
}

.input-group input:focus {
  outline: none;
}

.input-group input::placeholder {
  color: var(--muted);
  opacity: 0.5;
}

/* Modern Custom Select */
.custom-select {
  position: relative;
  min-width: 160px;
  border-left: 1px solid var(--border);
}

.custom-select select {
  appearance: none;
  width: 100%;
  height: 100%;
  padding: 1rem 2.75rem 1rem 1.25rem;
  background: rgba(139, 92, 246, 0.08);
  border: none;
  color: var(--text);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
}

.custom-select select:hover {
  background: rgba(139, 92, 246, 0.15);
}

.custom-select select:focus {
  outline: none;
  background: rgba(139, 92, 246, 0.2);
}

.custom-select::after {
  content: '';
  position: absolute;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 6px solid var(--muted);
  pointer-events: none;
  transition: transform var(--transition);
}

.custom-select:hover::after {
  border-top-color: var(--text);
}

.custom-select select option {
  background: #0a0520;
  color: var(--text);
  padding: 0.75rem;
}

/* Receive Input */
.receive-group {
  display: flex;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 1.5rem;
}

.receive-group input {
  flex: 1;
  padding: 1.125rem 1.25rem;
  background: transparent;
  border: none;
  color: var(--text);
  font-size: 1.5rem;
  font-weight: 600;
  min-width: 0;
}

.receive-group input:focus {
  outline: none;
}

.currency-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 1.5rem;
  background: linear-gradient(135deg, rgba(6, 182, 212, 0.15), rgba(139, 92, 246, 0.15));
  border-left: 1px solid var(--border);
  font-weight: 700;
  font-size: 1rem;
  color: var(--text);
  letter-spacing: 0.05em;
}

/* Quote Breakdown */
.quote-breakdown {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  margin: 1.5rem 0;
}

.quote-breakdown div {
  background: rgba(255, 255, 255, 0.05);
  padding: 1rem;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.12);
  text-align: center;
  transition: all var(--transition);
}

.quote-breakdown div:hover {
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(255, 255, 255, 0.2);
}

.quote-breakdown dt {
  font-size: 0.75rem;
  color: var(--muted);
  margin-bottom: 0.4rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.quote-breakdown dd {
  font-weight: 700;
  font-size: 1rem;
  margin: 0;
  color: var(--text);
}

.total-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem 0;
  border-top: 1px solid var(--border);
  margin-top: 0.75rem;
}

.total-line > div p {
  font-weight: 600;
  font-size: 1rem;
  margin: 0;
}

.total-line > div small {
  color: var(--muted);
  font-size: 0.8rem;
}

.total-line > p {
  font-size: 1.75rem;
  font-weight: 800;
  background: var(--accent);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin: 0;
  transition: all var(--transition);
}

.total-line > p.is-warning {
  font-size: 1rem;
  background: var(--warning);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: pulse-warning 1.5s ease-in-out infinite;
}

@keyframes pulse-warning {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

.converter-card > button.primary {
  margin-top: 0.5rem;
}

.converter-card .note {
  text-align: center;
  color: var(--muted);
  font-size: 0.85rem;
  margin-top: 1.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.converter-card .note::before {
  content: '🔒';
  font-size: 0.9rem;
}

.converter-card .note.is-warning {
  color: var(--warning);
  font-weight: 600;
}

.converter-card .note.is-warning::before {
  content: '⚠️';
}

/* Legacy support for dual-input */
.dual-input {
  display: none;
}

.badge-pill {
  display: none;
}

@media (max-width: 520px) {
  .converter-card {
    padding: 1.75rem;
  }

  .input-group {
    flex-direction: column;
  }

  .custom-select {
    border-left: none;
    border-top: 1px solid var(--border);
  }

  .receive-group {
    flex-direction: column;
  }

  .currency-badge {
    border-left: none;
    border-top: 1px solid var(--border);
    padding: 1rem;
  }

  .quote-breakdown {
    grid-template-columns: 1fr;
  }

  .input-group input,
  .receive-group input {
    font-size: 1.25rem;
  }
  
  .total-line {
    flex-direction: column;
    gap: 0.75rem;
    text-align: center;
  }
  
  .total-line > p {
    font-size: 1.5rem;
  }
  
  .total-line > p.is-warning {
    font-size: 0.9rem;
  }
}

/* Extra small devices */
@media (max-width: 380px) {
  .converter-card {
    padding: 1.25rem;
  }
  
  .input-group input,
  .receive-group input {
    font-size: 1.1rem;
    padding: 1rem;
  }
  
  .custom-select select {
    padding: 0.875rem 2.5rem 0.875rem 1rem;
    font-size: 0.9rem;
  }
  
  .quote-breakdown div {
    padding: 0.75rem;
  }
  
  .quote-breakdown dd {
    font-size: 0.9rem;
  }
}

/* ========== SECTIONS ========== */
section {
  padding: 6rem 0;
}

@media (max-width: 768px) {
  section {
    padding: 4rem 0;
  }
}

@media (max-width: 480px) {
  section {
    padding: 3rem 0;
  }
}

.section-header {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 4rem;
}

@media (max-width: 768px) {
  .section-header {
    margin-bottom: 2.5rem;
  }
  
  .section-lead {
    font-size: 1rem;
  }
}

.section-header h2 {
  margin-bottom: 1rem;
}

.section-lead {
  color: var(--muted);
  font-size: 1.15rem;
  line-height: 1.7;
}

/* ========== PHASES ========== */
.strip {
  background: rgba(255, 255, 255, 0.015);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.phase-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}

.phase-grid article {
  background: var(--card);
  border-radius: var(--radius-xl);
  padding: 2rem;
  border: 1px solid var(--border);
  transition: all var(--transition-slow);
  position: relative;
  overflow: hidden;
}

.phase-grid article::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--transition-slow);
}

.phase-grid article:hover {
  background: var(--card-hover);
  border-color: var(--border-hover);
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.phase-grid article:hover::before {
  transform: scaleX(1);
}

.phase-grid h3 {
  font-size: 1.1rem;
  margin-bottom: 0.875rem;
  color: var(--text);
}

.phase-grid p {
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.65;
}

@media (max-width: 1024px) {
  .phase-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .phase-grid {
    grid-template-columns: 1fr;
  }
}

/* ========== FEATURES ========== */
.features {
  background: transparent;
}

.features .container > .grid {
  gap: 1.5rem;
}

.features article {
  background: var(--card);
  border-radius: var(--radius-xl);
  padding: 2.25rem;
  border: 1px solid var(--border);
  transition: all var(--transition-slow);
}

.features article:hover {
  background: var(--card-hover);
  transform: translateY(-6px);
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.3);
}

.features h3 {
  font-size: 1.2rem;
  margin-bottom: 0.875rem;
}

.features p {
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.65;
}

/* ========== FAQ ========== */
.faq {
  background: transparent;
}

.faq .container {
  max-width: 820px;
}

.faq h2 {
  text-align: center;
  margin-bottom: 2.5rem;
}

.faq details {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  margin-bottom: 1rem;
  overflow: hidden;
  transition: all var(--transition);
}

.faq details[open] {
  background: var(--card-hover);
  border-color: var(--border-hover);
}

.faq summary {
  cursor: pointer;
  padding: 1.35rem 1.75rem;
  font-weight: 600;
  font-size: 1.05rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  list-style: none;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: '+';
  font-size: 1.5rem;
  color: var(--muted);
  transition: all var(--transition);
  font-weight: 300;
}

.faq details[open] summary::after {
  transform: rotate(45deg);
  color: var(--accent-solid);
}

.faq details p {
  padding: 0 1.75rem 1.35rem;
  color: var(--muted);
  line-height: 1.75;
  margin: 0;
}

@media (max-width: 640px) {
  .faq summary {
    padding: 1rem 1.25rem;
    font-size: 0.95rem;
  }
  
  .faq details p {
    padding: 0 1.25rem 1rem;
    font-size: 0.9rem;
  }
  
  .faq h2 {
    margin-bottom: 1.5rem;
  }
}

/* ========== FOOTER ========== */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 2.5rem 0;
  background: rgba(0, 0, 0, 0.2);
}

.site-footer .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.site-footer p {
  color: var(--muted);
  font-size: 0.9rem;
  margin: 0;
}

.site-footer a {
  color: var(--accent-solid);
  font-weight: 500;
}

.site-footer a:hover {
  color: var(--accent-secondary);
}

@media (max-width: 640px) {
  .site-footer {
    padding: 1.5rem 0;
  }
  
  .site-footer .container {
    flex-direction: column;
    text-align: center;
  }
  
  .site-footer p {
    font-size: 0.8rem;
  }
}

/* ========== MODAL ========== */
.flow-modal {
  position: fixed;
  inset: 0;
  background: rgba(3, 0, 18, 0.9);
  backdrop-filter: blur(24px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  z-index: 200;
  overflow-y: auto;
}

.flow-modal.is-open {
  display: flex;
}

.modal-panel {
  background: linear-gradient(180deg, rgba(15, 10, 35, 0.98), rgba(8, 4, 20, 0.99));
  border-radius: var(--radius-2xl);
  padding: 2.75rem;
  width: min(560px, 100%);
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: var(--shadow-card), 0 0 120px rgba(139, 92, 246, 0.15);
}

.modal-panel::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 10%, rgba(255,255,255,0.25) 50%, transparent 90%);
}

.modal-panel > .icon-button {
  position: absolute;
  top: 1.25rem;
  right: 1.25rem;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 50%;
  width: 42px;
  height: 42px;
  font-size: 1.35rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  transition: all var(--transition);
}

.modal-panel > .icon-button:hover {
  background: rgba(255, 255, 255, 0.12);
  color: var(--text);
}

.icon-button {
  padding: 0;
}

.modal-badge {
  display: inline-block;
  text-transform: uppercase;
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  color: var(--muted);
  margin-bottom: 0.5rem;
  font-weight: 600;
}

#flowTitle {
  font-size: 1.6rem;
  margin-bottom: 2rem;
}

/* Modern Stepper */
.stepper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  list-style: none;
  margin-bottom: 2.5rem;
  position: relative;
  padding: 0;
}

.stepper::before {
  content: '';
  position: absolute;
  top: 20px;
  left: 40px;
  right: 40px;
  height: 2px;
  background: var(--border);
  z-index: 0;
}

.stepper li {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--muted);
  transition: all var(--transition);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.stepper li::before {
  content: attr(data-num);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid var(--border);
  font-size: 0.95rem;
  font-weight: 700;
  transition: all var(--transition);
}

.stepper li.is-completed::before {
  background: var(--success);
  border-color: var(--success);
  color: #030012;
  content: '✓';
  font-size: 1rem;
}

.stepper li.is-completed {
  color: var(--success);
}

.stepper li.is-active {
  color: var(--text);
}

.stepper li.is-active::before {
  background: var(--accent);
  border-color: transparent;
  color: #030012;
  box-shadow: 0 0 24px rgba(139, 92, 246, 0.5), 0 0 48px rgba(139, 92, 246, 0.25);
}

/* Flow Steps */
.flow-step {
  display: none;
  flex-direction: column;
  gap: 1.25rem;
  animation: fadeInStep 0.35s ease-out;
}

.flow-step.is-active {
  display: flex;
}

@keyframes fadeInStep {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.flow-step label {
  font-size: 0.85rem;
  color: var(--muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.flow-step input {
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  padding: 1rem 1.25rem;
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  font-size: 1rem;
  transition: all var(--transition);
}

.flow-step input:focus {
  outline: none;
  border-color: var(--accent-solid);
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.15);
  background: rgba(255, 255, 255, 0.05);
}

.receive-group {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.currency-badge {
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.06);
  display: inline-flex;
  align-items: center;
  padding: 0.15rem 0.65rem;
  position: relative;
}

.currency-badge select {
  background: transparent;
  border: none;
  color: var(--text);
  font-weight: 600;
  font-size: 0.9rem;
  text-transform: uppercase;
  appearance: none;
  padding-right: 1.2rem;
  cursor: pointer;
}

.currency-badge select:focus {
  outline: none;
}

.currency-badge::after {
  content: '▾';
  position: absolute;
  right: 0.45rem;
  font-size: 0.7rem;
  color: var(--muted);
  pointer-events: none;
}

.transfer-actions {
  margin: 1.5rem 0 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.transfer-status {
  font-size: 0.85rem;
  color: var(--muted);
  line-height: 1.4;
}

.transfer-status.is-success {
  color: #34d399;
}

.transfer-status.is-error {
  color: #f87171;
}

.transfer-status.is-warning {
  color: #facc15;
}

.flow-step input::placeholder {
  color: var(--muted);
  opacity: 0.5;
}

.flow-step .step-info {
  color: var(--muted);
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
  line-height: 1.6;
}

.flow-step > div {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

/* Wallet Grid */
.wallet-grid {
  display: grid;
  gap: 0.875rem;
}

.wallet-connect-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin: 1.25rem 0 0.5rem;
}

.wallet-connect-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1rem;
  background: rgba(255, 255, 255, 0.02);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  min-height: 170px;
}

.wallet-connect-card h4 {
  margin: 0;
  font-size: 1rem;
}

.wallet-connect-card small {
  color: var(--muted);
}

.wallet-status {
  font-size: 0.85rem;
  color: var(--muted);
  margin: 0;
}

.wallet-status.is-connected {
  color: var(--success);
  font-weight: 600;
}

.wallet-connect-card button.secondary {
  width: 100%;
  justify-content: center;
}

.wallet-connect-card button.secondary.is-connected {
  border-color: rgba(16, 185, 129, 0.4);
  color: var(--success);
}

.wallet-card {
  display: block;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  cursor: pointer;
  transition: all var(--transition);
  background: rgba(255, 255, 255, 0.02);
  position: relative;
  overflow: hidden;
}

.wallet-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 100%;
  background: var(--accent);
  transform: scaleY(0);
  transition: transform var(--transition);
}

.wallet-card:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--border-hover);
}

.wallet-card:hover::before {
  transform: scaleY(1);
}

.wallet-card input {
  display: none;
}

.wallet-card p {
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 0.25rem;
}

.wallet-card small {
  color: var(--muted);
  font-size: 0.85rem;
}

.wallet-card code {
  display: block;
  margin-top: 0.875rem;
  color: var(--muted);
  font-size: 0.75rem;
  background: rgba(0, 0, 0, 0.3);
  padding: 0.6rem 0.875rem;
  border-radius: var(--radius-sm);
  word-break: break-all;
  font-family: 'SF Mono', 'Fira Code', monospace;
}

.wallet-card.is-disabled {
  opacity: 0.55;
  cursor: not-allowed;
  border-color: rgba(255, 255, 255, 0.04);
  background: rgba(255, 255, 255, 0.01);
}

.wallet-card.is-disabled::before {
  display: none;
}

.wallet-card.is-disabled:hover {
  background: rgba(255, 255, 255, 0.01);
  border-color: rgba(255, 255, 255, 0.04);
}

.wallet-card:has(input:checked) {
  border-color: var(--success);
  background: rgba(16, 185, 129, 0.08);
}

.wallet-card:has(input:checked)::before {
  background: var(--success);
  transform: scaleY(1);
}

/* Flow Summary */
.flow-summary {
  margin-top: 2rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  background: rgba(255, 255, 255, 0.02);
  text-align: center;
}

.flow-summary p {
  color: var(--muted);
  font-size: 0.95rem;
  margin: 0;
}

.flow-summary strong {
  color: var(--success);
  font-size: 1.2rem;
  font-weight: 700;
}

@media (max-width: 640px) {
  .modal-panel {
    padding: 1.75rem;
    border-radius: var(--radius-xl);
    max-height: 95vh;
  }

  .stepper li {
    font-size: 0.65rem;
  }

  .stepper li::before {
    width: 36px;
    height: 36px;
    font-size: 0.85rem;
  }

  .stepper::before {
    left: 30px;
    right: 30px;
    top: 18px;
  }

  #flowTitle {
    font-size: 1.35rem;
  }
  
  .flow-step input {
    padding: 0.875rem 1rem;
    font-size: 0.95rem;
  }
  
  .wallet-card {
    padding: 1rem;
  }
  
  .wallet-card code {
    font-size: 0.7rem;
    padding: 0.5rem 0.75rem;
  }
  
  .flow-summary {
    padding: 1rem;
    margin-top: 1.5rem;
  }
  
  .flow-summary strong {
    font-size: 1.1rem;
  }
}

@media (max-width: 400px) {
  .flow-modal {
    padding: 0.5rem;
  }
  
  .modal-panel {
    padding: 1.25rem;
    border-radius: var(--radius-lg);
  }
  
  .stepper {
    margin-bottom: 1.75rem;
  }
  
  .stepper li {
    font-size: 0.55rem;
    gap: 0.4rem;
  }
  
  .stepper li::before {
    width: 30px;
    height: 30px;
    font-size: 0.75rem;
  }
  
  .stepper::before {
    left: 22px;
    right: 22px;
    top: 15px;
  }
  
  #flowTitle {
    font-size: 1.15rem;
    margin-bottom: 1.5rem;
  }
  
  .modal-badge {
    font-size: 0.6rem;
  }
  
  .flow-step label {
    font-size: 0.75rem;
  }
}

/* ========== TOAST ========== */
#toast {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  left: 2rem;
  max-width: 420px;
  margin-left: auto;
  padding: 1rem 1.5rem;
  border-radius: var(--radius-lg);
  background: rgba(8, 4, 20, 0.98);
  backdrop-filter: blur(24px);
  border: 1px solid var(--border);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.5);
  opacity: 0;
  transform: translateY(20px);
  transition: all var(--transition);
  pointer-events: none;
  z-index: 300;
  font-weight: 500;
}

#toast.show {
  opacity: 1;
  transform: translateY(0);
}

#toast.error {
  background: rgba(239, 68, 68, 0.95);
  border-color: rgba(239, 68, 68, 0.5);
  color: #fff;
}

@media (max-width: 640px) {
  #toast {
    bottom: 1rem;
    right: 1rem;
    left: 1rem;
    max-width: none;
    padding: 0.875rem 1.25rem;
    font-size: 0.9rem;
  }
}

/* ========== ANIMATIONS ========== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-content {
  animation: fadeInUp 0.7s ease-out both;
}

.converter-card {
  animation: fadeInUp 0.7s ease-out 0.15s both;
}

/* ========== UTILITIES ========== */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

/* Hidden utility class */
.hidden {
  display: none !important;
}

/* Transfer note styling */
.transfer-note {
  font-size: 0.8rem;
  color: var(--muted);
  text-align: center;
  margin: 1rem 0;
  padding: 0.75rem 1rem;
  background: rgba(139, 92, 246, 0.08);
  border-radius: var(--radius-sm);
  border: 1px solid rgba(139, 92, 246, 0.15);
}

/* Manual TX input wrapper */
.manual-tx-input {
  margin-top: 1rem;
}

.manual-tx-input label {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 0.85rem;
  color: var(--muted);
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
