/* swapped.com/trade — design reference replica (non-functional) */
:root {
  --bg: #050507;
  --violet: #3E1CFF;
  --violet-deep: #3D0DFF;
  --badge: #4A2BFF;
  --card: #101014;
  --field: #17171C;
  --field-border: #26262C;
  --quick: #1D1D23;
  --label: #A0A0AB;
  --link: #C4C4CE;
  --muted: #77777F;
  --white: #ffffff;
}

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

html, body { height: 100%; }

body {
  font-family: "Poppins", -apple-system, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--white);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}

/* ambient violet glow behind the widget */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(ellipse 55% 45% at 50% 42%, rgba(61, 13, 255, 0.55) 0%, rgba(75, 29, 255, 0.22) 40%, transparent 70%);
}

/* ---------- header ---------- */
.site-header {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 40px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--white);
}

.logo-icon {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: linear-gradient(135deg, #5A2DFF, var(--violet));
  display: flex;
  align-items: center;
  justify-content: center;
}

.logo-word {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.3px;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 30px;
}

.main-nav a {
  color: var(--white);
  text-decoration: none;
  font-size: 15px;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 6px;
  opacity: 0.95;
}

.main-nav a:hover { opacity: 1; }

.chev {
  width: 7px;
  height: 7px;
  border-right: 1.8px solid var(--white);
  border-bottom: 1.8px solid var(--white);
  transform: rotate(45deg) translateY(-2px);
  display: inline-block;
}

.chev.sm {
  width: 6px;
  height: 6px;
  border-right-width: 1.6px;
  border-bottom-width: 1.6px;
  border-color: var(--label);
}

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

.header-cta {
  background: var(--violet);
  color: var(--white);
  text-decoration: none;
  font-size: 16px;
  font-weight: 600;
  padding: 12px 20px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: filter 0.15s ease;
}

.header-cta:hover { filter: brightness(1.12); }

.nav-toggle {
  display: none;
  background: transparent;
  border: 0;
  cursor: pointer;
  flex-direction: column;
  gap: 5px;
  padding: 6px;
}

.nav-toggle span {
  width: 22px;
  height: 2px;
  background: var(--white);
  border-radius: 2px;
  display: block;
}

/* ---------- stage / widget ---------- */
.stage {
  position: relative;
  z-index: 1;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 20px 60px;
}

.widget {
  width: 384px;
  max-width: 100%;
  background: var(--card);
  border-radius: 20px;
  border: 1px solid #1B1B21;
  padding: 18px 18px 20px;
}

.widget-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 2px 4px 14px;
}

.widget-brand {
  font-size: 14px;
  font-weight: 600;
  color: var(--white);
}

.mini-menu {
  background: transparent;
  border: 0;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 6px 2px;
}

.mini-menu span {
  width: 18px;
  height: 2px;
  background: var(--white);
  border-radius: 2px;
  display: block;
}

.field {
  background: var(--field);
  border: 1px solid var(--field-border);
  border-radius: 16px;
  padding: 13px 16px 15px;
  margin-bottom: 10px;
}

.field-label {
  display: block;
  font-size: 13px;
  color: var(--label);
  margin-bottom: 8px;
  font-weight: 400;
}

.field-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.amount {
  font-size: 32px;
  font-weight: 700;
  letter-spacing: -0.5px;
  line-height: 1.1;
}

.pill {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #232329;
  border: 0;
  color: var(--white);
  font-family: inherit;
  font-size: 15px;
  font-weight: 600;
  border-radius: 999px;
  padding: 8px 13px;
  cursor: pointer;
  white-space: nowrap;
}

.flag {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: inline-block;
  flex: none;
}

.flag-cad {
  background: linear-gradient(90deg, #EB2D2D 0 28%, #ffffff 28% 72%, #EB2D2D 72% 100%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.25);
}

.btc {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #F7931A;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
}

.quick-row {
  display: flex;
  gap: 10px;
  margin: 2px 0 12px;
}

.quick {
  flex: 1;
  background: var(--quick);
  border: 0;
  color: var(--white);
  font-family: inherit;
  font-size: 15px;
  font-weight: 500;
  border-radius: 12px;
  padding: 11px 0;
  cursor: pointer;
  transition: background 0.15s ease;
}

.quick:hover { background: #26262E; }
.quick.active { background: #2E2E38; }

.paywith { position: relative; }

.popular-badge {
  position: absolute;
  top: -11px;
  right: 14px;
  background: var(--badge);
  color: var(--white);
  font-size: 12px;
  font-weight: 600;
  border-radius: 999px;
  padding: 4px 11px;
  line-height: 1.4;
}

.method, .fee {
  display: flex;
  align-items: center;
  gap: 10px;
  background: transparent;
  border: 0;
  color: var(--white);
  font-family: inherit;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  padding: 2px 0;
}

.fee { color: var(--label); font-size: 14px; font-weight: 400; gap: 6px; }

.card-icon {
  width: 28px;
  height: 20px;
  border: 1.6px solid #8E8E99;
  border-radius: 5px;
  position: relative;
  display: inline-block;
  flex: none;
}

.card-icon .chip {
  position: absolute;
  left: 4px;
  top: 4px;
  width: 8px;
  height: 8px;
  border: 1.2px solid #8E8E99;
  border-radius: 2px;
}

.buy-cta {
  width: 100%;
  background: var(--violet);
  border: 0;
  color: var(--white);
  font-family: inherit;
  font-size: 16px;
  font-weight: 600;
  border-radius: 14px;
  padding: 16px;
  margin-top: 6px;
  cursor: pointer;
  transition: filter 0.15s ease, transform 0.05s ease;
}

.buy-cta:hover { filter: brightness(1.12); }
.buy-cta:active { transform: scale(0.99); }

/* ---------- footer ---------- */
.site-footer {
  position: relative;
  z-index: 1;
  border-top: 1px solid var(--field-border);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 18px 40px;
}

.footer-links { display: flex; gap: 26px; flex-wrap: wrap; }

.footer-links a {
  color: var(--link);
  text-decoration: none;
  font-size: 14px;
}

.footer-links a:hover { color: var(--white); }

.copyright {
  color: var(--muted);
  font-size: 14px;
}

/* ---------- floating bits ---------- */
.cookie-btn {
  position: fixed;
  left: 20px;
  bottom: 20px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--violet);
  border: 0;
  font-size: 22px;
  cursor: pointer;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: filter 0.15s ease;
}

.cookie-btn:hover { filter: brightness(1.12); }

.toast {
  position: fixed;
  left: 50%;
  bottom: 26px;
  transform: translateX(-50%) translateY(12px);
  background: var(--quick);
  border: 1px solid var(--field-border);
  color: var(--white);
  font-size: 14px;
  padding: 12px 22px;
  border-radius: 12px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
  z-index: 10;
  white-space: nowrap;
}

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

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .main-nav {
    display: none;
    position: absolute;
    top: 100%;
    right: 16px;
    background: #141419;
    border: 1px solid var(--field-border);
    border-radius: 14px;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px;
    min-width: 200px;
    z-index: 20;
  }

  .main-nav.open { display: flex; }

  .main-nav a { padding: 10px 14px; border-radius: 8px; }
  .main-nav a:hover { background: #1D1D24; }

  .nav-toggle { display: flex; }
  .site-header { padding: 16px 20px; position: relative; }
  .header-cta { font-size: 14px; padding: 10px 14px; }
}

@media (max-width: 480px) {
  .stage { padding: 24px 16px 48px; align-items: flex-start; }
  .widget { width: 100%; }
  .footer-inner { padding: 16px 20px; }
  .amount { font-size: 28px; }
}
