:root {
  --bg: #0a0d14;
  --bg-soft: #10141d;
  --surface: #141926;
  --surface-2: #1b2130;
  --border: #242c3d;
  --border-soft: #1c2331;
  --text: #eef2f9;
  --muted: #8b95ab;
  --accent: #22d3a6;
  --accent-2: #16b98f;
  --accent-soft: rgba(34, 211, 166, 0.12);
  --danger: #f87171;
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  background-image:
    radial-gradient(900px 500px at 85% -10%, rgba(34, 211, 166, 0.14), transparent 60%),
    radial-gradient(700px 400px at 5% 5%, rgba(56, 132, 255, 0.1), transparent 55%);
  background-attachment: fixed;
}

.container {
  width: min(1140px, 100% - 40px);
  margin-inline: auto;
}

h1, h2, h3 {
  margin: 0;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

p {
  margin: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

.accent {
  color: var(--accent);
}

/* ---------- Topbar ---------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(14px);
  background: rgba(10, 13, 20, 0.78);
  border-bottom: 1px solid var(--border-soft);
}

.topbar__inner {
  display: flex;
  align-items: center;
  gap: 28px;
  height: 68px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.15rem;
}

.brand__mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #04110d;
  font-weight: 800;
}

.nav {
  display: flex;
  gap: 22px;
  margin-left: auto;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 500;
}

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

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  padding: 11px 18px;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.2s ease, border-color 0.2s ease;
}

.btn:active {
  transform: translateY(1px);
}

.btn--primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #04110d;
}

.btn--primary:hover {
  filter: brightness(1.06);
}

.btn--ghost {
  background: transparent;
  border-color: var(--border);
  color: var(--text);
}

.btn--ghost:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.btn--block {
  width: 100%;
}

/* ---------- Cards ---------- */
.card {
  background: linear-gradient(180deg, var(--surface), var(--bg-soft));
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

/* ---------- Hero ---------- */
.hero {
  padding: 76px 0 40px;
}

.hero__grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 48px;
  align-items: center;
}

.pill {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  margin-bottom: 20px;
}

.hero h1 {
  font-size: clamp(2.1rem, 4.4vw, 3.4rem);
  font-weight: 800;
  margin-bottom: 18px;
}

.lead {
  color: var(--muted);
  font-size: 1.05rem;
  max-width: 46ch;
}

.hero__stats {
  display: flex;
  gap: 34px;
  margin-top: 34px;
}

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

.stat__value {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent);
}

.stat__label {
  font-size: 0.82rem;
  color: var(--muted);
}

/* ---------- Converter ---------- */
.converter {
  padding: 26px;
  box-shadow: var(--shadow);
}

.converter__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 22px;
}

.converter__head h2 {
  font-size: 1.25rem;
}

.badge {
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 600;
  white-space: nowrap;
}

.converter__form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.field label {
  display: block;
  font-size: 0.82rem;
  color: var(--muted);
  margin-bottom: 8px;
  font-weight: 500;
}

.input-group {
  display: flex;
  align-items: stretch;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  transition: border-color 0.2s ease;
}

.input-group:focus-within {
  border-color: var(--accent);
}

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

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

.input-group--result input {
  color: var(--accent);
}

.input-group input.pulse {
  animation: pulse 0.3s ease;
}

@keyframes pulse {
  0% {
    opacity: 0.4;
    transform: translateY(-2px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.input-group select {
  background: var(--surface-2);
  border: none;
  border-left: 1px solid var(--border);
  color: var(--text);
  font: inherit;
  font-weight: 600;
  padding: 0 16px;
  cursor: pointer;
}

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

.hint {
  display: block;
  margin-top: 6px;
  font-size: 0.76rem;
  color: var(--muted);
}

.swap {
  align-self: center;
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--accent);
  cursor: pointer;
  transition: transform 0.25s ease, border-color 0.2s ease;
}

.swap:hover {
  border-color: var(--accent);
  transform: rotate(180deg);
}

.summary {
  background: var(--bg);
  border: 1px dashed var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.summary__row {
  display: flex;
  justify-content: space-between;
  font-size: 0.88rem;
  color: var(--muted);
}

.summary__row strong {
  color: var(--text);
  font-weight: 600;
}

.disclaimer {
  text-align: center;
  font-size: 0.74rem;
  color: var(--muted);
}

/* ---------- Sections ---------- */
.section {
  padding: 64px 0;
}

.section__head {
  margin-bottom: 32px;
}

.section__head h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  margin-bottom: 8px;
}

.section__head p {
  color: var(--muted);
}

/* ---------- Rates ---------- */
.rates {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.rate-card {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.rate-card:hover {
  transform: translateY(-3px);
  border-color: var(--accent);
}

.rate-card--muted:hover {
  border-color: var(--border);
}

.rate-card__top {
  display: flex;
  align-items: center;
  gap: 14px;
}

.rate-card__flag {
  font-size: 1.6rem;
}

.rate-card__top h3 {
  font-size: 1rem;
}

.rate-card__top p {
  font-size: 0.8rem;
  color: var(--muted);
}

.rate-card__value {
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent);
}

.rate-card--muted .rate-card__value {
  color: var(--text);
}

.rate-card__note {
  font-size: 0.78rem;
  color: var(--muted);
}

/* ---------- Features ---------- */
.features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.feature {
  padding: 28px 24px;
}

.feature__icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: var(--accent-soft);
  font-size: 1.3rem;
  margin-bottom: 16px;
}

.feature h3 {
  font-size: 1.05rem;
  margin-bottom: 8px;
}

.feature p {
  color: var(--muted);
  font-size: 0.9rem;
}

/* ---------- Footer ---------- */
.footer {
  border-top: 1px solid var(--border-soft);
  padding: 30px 0;
  margin-top: 40px;
}

.footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.footer p {
  color: var(--muted);
  font-size: 0.84rem;
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero__grid {
    grid-template-columns: 1fr;
    gap: 36px;
  }

  .rates,
  .features {
    grid-template-columns: 1fr;
  }

  .nav {
    display: none;
  }
}

@media (max-width: 520px) {
  .hero {
    padding-top: 48px;
  }

  .hero__stats {
    gap: 22px;
  }

  .topbar__inner .btn--ghost {
    display: none;
  }
}
