/* style.css */
:root {
  --navy: #191941;
  --royal: #273B7F;
  --steel: #4D578C;
  --red: #CD2028;
  --bg: #F5F6FA;
  --surface: #FFFFFF;
  --line: #E7E9F2;
  --ink: #191941;
  --muted: #6A6F8C;
  --soft: #9498B2;
  --green: #1F9D62;
  --shadow: 0 1px 2px rgba(25, 25, 65, .04), 0 8px 30px rgba(25, 25, 65, .06);
  --shadow-lg: 0 12px 40px rgba(25, 25, 65, .10);
  --radius: 18px;
  --maxw: 1080px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Vazirmatn', system-ui, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

.wrap {
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: 22px;
}

/* Logo */
.logo-img {
  height: 44px;
  width: auto;
  display: block;
}

.logo-img.footer-logo {
  height: 58px;
}

.logo-slot {
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px dashed var(--steel);
  border-radius: 12px;
  color: var(--steel);
  background: rgba(77, 87, 140, .05);
  font-size: 11px;
  font-weight: 600;
  text-align: center;
}

.logo-slot.brand {
  width: 52px;
  height: 52px;
}

.logo-slot.footer {
  width: 64px;
  height: 64px;
}

/* Header */
header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(245, 246, 250, .82);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.nav {
  display: flex;
  align-items: center;
  gap: 16px;
  height: 72px;
}

.brand-lockup {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-name {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -.3px;
}

.brand-name span {
  color: var(--red);
}

.nav-links {
  display: flex;
  gap: 26px;
  margin-inline-start: auto;
  align-items: center;
}

.nav-links a {
  color: var(--muted);
  font-weight: 500;
  font-size: 15px;
  transition: color .2s;
}

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

.nav .btn {
  margin-inline-start: 8px;
}

.menu-toggle {
  display: none;
  margin-inline-start: auto;
  background: none;
  border: none;
  color: var(--navy);
  cursor: pointer;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 12px;
  font-family: inherit;
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
  border: none;
  transition: transform .15s, box-shadow .2s, background .2s;
}

.btn-primary {
  background: var(--red);
  color: #fff;
  box-shadow: 0 6px 18px rgba(205, 32, 40, .28);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 26px rgba(205, 32, 40, .34);
}

.btn-ghost {
  background: var(--surface);
  color: var(--navy);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.btn-ghost:hover {
  border-color: var(--steel);
  transform: translateY(-2px);
}

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

.hero-inner {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: 48px;
  align-items: center;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  font-weight: 600;
  color: var(--royal);
  background: rgba(39, 59, 127, .08);
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 20px;
}

.hero h1 {
  font-size: 44px;
  line-height: 1.25;
  font-weight: 800;
  letter-spacing: -.6px;
  margin-bottom: 18px;
}

.hero h1 .accent {
  color: var(--royal);
}

.hero p.lead {
  font-size: 18px;
  color: var(--muted);
  margin-bottom: 28px;
  max-width: 44ch;
}

.hero-cta {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.trust {
  display: flex;
  gap: 26px;
  margin-top: 34px;
  flex-wrap: wrap;
}

.trust-item {
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 500;
}

.trust-item svg {
  color: var(--royal);
  flex-shrink: 0;
}

.lead-points {
  list-style: none;
  margin: 0 0 26px;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.lead-points li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 16px;
  color: var(--ink);
  font-weight: 500;
  line-height: 1.6;
}

.lead-points li::before {
  content: "";
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  margin-top: 2px;
  border-radius: 7px;
  background: rgba(39, 59, 127, .09) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23273B7F' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6L9 17l-5-5'/%3E%3C/svg%3E") center/14px no-repeat;
}

.cta-hint {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
  font-size: 14px;
  color: var(--muted);
  font-weight: 600;
}

.cta-hint svg {
  color: var(--green);
  flex-shrink: 0;
}

/* Rate Card */
.rate-card {
  background: var(--surface);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--line);
  padding: 26px;
  position: relative;
  overflow: hidden;
}

.rate-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(39, 59, 127, .04), transparent 55%);
  pointer-events: none;
}

.rate-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}

.rate-flag {
  display: flex;
  align-items: center;
  gap: 10px;
}

.rate-flag .flag {
  font-size: 26px;
}

.rate-flag .name {
  font-weight: 700;
  font-size: 17px;
}

.rate-flag .code {
  font-size: 12px;
  color: var(--soft);
  font-weight: 600;
}

.flag-img {
  height: 1em;
  width: auto;
  border-radius: 3px;
  vertical-align: -.15em;
  display: inline-block;
}

.rate-live {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--muted);
  font-weight: 600;
}

.rate-live .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(31, 157, 98, .45);
  }
  70% {
    box-shadow: 0 0 0 8px rgba(31, 157, 98, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(31, 157, 98, 0);
  }
}

.rate-big {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin: 10px 0 2px;
}

.rate-value {
  font-size: 52px;
  font-weight: 900;
  letter-spacing: -1.5px;
  line-height: 1;
  color: var(--navy);
  font-variant-numeric: tabular-nums;
}

.rate-unit {
  font-size: 16px;
  color: var(--muted);
  font-weight: 600;
}

.rate-sub {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 18px;
  flex-wrap: wrap;
}

.change {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 8px;
  font-size: 13px;
}

.change.up {
  color: var(--green);
  background: rgba(31, 157, 98, .1);
}

.change.down {
  color: var(--red);
  background: rgba(205, 32, 40, .09);
}

.range-toggle {
  display: inline-flex;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 3px;
  gap: 2px;
}

.range-toggle button {
  border: none;
  background: none;
  font-family: inherit;
  font-weight: 600;
  font-size: 13px;
  color: var(--muted);
  padding: 6px 14px;
  border-radius: 8px;
  cursor: pointer;
  transition: .18s;
}

.range-toggle button.active {
  background: var(--surface);
  color: var(--royal);
  box-shadow: var(--shadow);
}

.chart-box {
  margin-top: 16px;
  position: relative;
}

#sekChart {
  width: 100%;
  height: 180px;
  display: block;
  overflow: visible;
}

.tooltip {
  position: absolute;
  pointer-events: none;
  opacity: 0;
  transform: translateX(-50%);
  background: var(--navy);
  color: #fff;
  padding: 7px 11px;
  border-radius: 9px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  transition: opacity .12s;
  z-index: 5;
  box-shadow: var(--shadow-lg);
}

.tooltip .t-date {
  color: #B9BEDD;
  font-size: 11px;
}

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

.sec-head {
  margin-bottom: 34px;
  max-width: 640px;
}

.sec-eyebrow {
  font-size: 13px;
  font-weight: 700;
  color: var(--red);
  letter-spacing: .5px;
  margin-bottom: 8px;
}

.sec-title {
  font-size: 30px;
  font-weight: 800;
  letter-spacing: -.4px;
  margin-bottom: 10px;
}

.sec-desc {
  color: var(--muted);
  font-size: 16px;
}

/* Rates Table */
.rates-table {
  background: var(--surface);
  border-radius: var(--radius);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.rt-row {
  display: grid;
  grid-template-columns: 1.4fr 1fr auto;
  align-items: center;
  gap: 14px;
  padding: 18px 24px;
  border-bottom: 1px solid var(--line);
}

.rt-row:last-child {
  border-bottom: none;
}

.rt-head {
  background: var(--bg);
  font-size: 13px;
  font-weight: 700;
  color: var(--soft);
}

.rt-cur {
  display: flex;
  align-items: center;
  gap: 12px;
}

.rt-cur .flag {
  font-size: 22px;
}

.rt-cur .nm {
  font-weight: 700;
  font-size: 16px;
}

.rt-cur .cd {
  font-size: 12px;
  color: var(--soft);
  font-weight: 600;
}

.rt-price {
  font-weight: 800;
  font-size: 18px;
  font-variant-numeric: tabular-nums;
  color: var(--navy);
}

.rt-price small {
  font-size: 12px;
  color: var(--muted);
  font-weight: 500;
  margin-inline-start: 4px;
}

.rt-tag {
  justify-self: end;
  font-size: 12px;
  font-weight: 600;
  color: var(--steel);
  background: rgba(77, 87, 140, .09);
  padding: 5px 11px;
  border-radius: 999px;
}

.rt-note {
  font-size: 13px;
  color: var(--soft);
  margin-top: 12px;
  text-align: center;
}

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

.feature {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px;
  box-shadow: var(--shadow);
  transition: transform .2s, box-shadow .2s;
}

.feature:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.feature .ic {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(39, 59, 127, .08);
  color: var(--royal);
  margin-bottom: 16px;
}

.feature h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
}

.feature p {
  color: var(--muted);
  font-size: 15px;
}

/* Steps */
.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.step {
  padding: 24px 20px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.step .num {
  font-size: 15px;
  font-weight: 800;
  color: #fff;
  background: var(--royal);
  width: 32px;
  height: 32px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
}

.step h4 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 6px;
}

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

/* Payment Methods */
.methods {
  margin-top: 26px;
}

.methods-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--soft);
  text-align: center;
  margin-bottom: 16px;
}

.method-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}

.method-slot {
  min-width: 110px;
  height: 52px;
  border: 1px solid var(--line);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-weight: 600;
  font-size: 14px;
  background: var(--surface);
}

.method-slot img {
  max-height: 30px;
  max-width: 88px;
  width: auto;
  display: block;
}

/* CTA Band */
.cta-band {
  background: linear-gradient(135deg, var(--navy), var(--royal));
  border-radius: 24px;
  padding: 48px 40px;
  text-align: center;
  color: #fff;
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
}

.cta-band::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 80% -20%, rgba(77, 87, 140, .5), transparent 60%);
  pointer-events: none;
}

.cta-band h2 {
  font-size: 30px;
  font-weight: 800;
  margin-bottom: 12px;
  position: relative;
}

.cta-band p {
  color: #C7CBE6;
  font-size: 16px;
  margin-bottom: 26px;
  position: relative;
}

.cta-band .btn-primary {
  position: relative;
}

.contact-row {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 22px;
  position: relative;
}

.contact-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, .1);
  border: 1px solid rgba(255, 255, 255, .18);
  padding: 10px 18px;
  border-radius: 12px;
  font-weight: 600;
  font-size: 14px;
  transition: .2s;
}

.contact-chip:hover {
  background: rgba(255, 255, 255, .18);
}

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

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 30px;
  flex-wrap: wrap;
}

.footer-brand {
  max-width: 320px;
}

.footer-brand .brand-name {
  margin-bottom: 10px;
}

.footer-brand p {
  color: var(--muted);
  font-size: 14px;
}

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

.footer-col h5 {
  font-size: 13px;
  color: var(--soft);
  font-weight: 700;
  margin-bottom: 12px;
}

.footer-col a {
  display: block;
  color: var(--muted);
  font-size: 14px;
  padding: 4px 0;
  transition: color .2s;
}

.footer-col a:hover {
  color: var(--royal);
}

.footer-bottom {
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  text-align: center;
  color: var(--soft);
  font-size: 13px;
}

/* Reveal Animation */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .6s ease, transform .6s ease;
}

.reveal.in {
  opacity: 1;
  transform: none;
}

/* Responsive */
@media (max-width: 960px) {
  .hero-inner {
    grid-template-columns: 1fr;
    gap: 36px;
  }
  .hero h1 {
    font-size: 34px;
  }
  .features {
    grid-template-columns: 1fr;
  }
  .steps {
    grid-template-columns: 1fr 1fr;
  }
  .nav-links {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    inset-inline-end: 22px;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    margin: 0;
    min-width: 200px;
    max-width: calc(100vw - 44px);
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 14px;
    box-shadow: var(--shadow-lg);
    padding: 8px;
  }
  .nav-links.open {
    display: flex;
  }
  .nav-links a {
    padding: 11px 14px;
    font-size: 15px;
    border-radius: 9px;
  }
  .nav-links a:hover {
    background: var(--bg);
  }
  .nav .btn-primary {
    margin-inline-start: auto;
  }
  .menu-toggle {
    display: block;
  }
  .footer-inner {
    flex-direction: column;
  }
}

@media (max-width: 520px) {
  .wrap {
    padding-inline: 26px;
  }
  .steps {
    grid-template-columns: 1fr;
  }
  .rate-value {
    font-size: 42px;
  }
  .rt-row {
    grid-template-columns: 1fr auto;
    gap: 10px;
  }
  .rt-tag {
    grid-column: 1 / -1;
    justify-self: start;
  }
  .cta-band {
    padding: 36px 22px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    transition: none;
    opacity: 1;
    transform: none;
  }
  .rate-live .dot {
    animation: none;
  }
  * {
    scroll-behavior: auto;
  }
}

/* ===== Expanded multi-currency homepage ===== */
.hero-description {
  color: var(--muted);
  font-size: 17px;
  line-height: 1.95;
  max-width: 58ch;
  margin-bottom: 26px;
}

.home-hero {
  padding-top: 78px;
}

.hero-panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 22px;
  box-shadow: var(--shadow-lg);
}

.hero-panel-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 14px;
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--green);
}

.status i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--green);
}

.mini-currency-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.mini-currency-grid a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 15px 13px;
  border: 1px solid var(--line);
  border-radius: 14px;
  transition: .2s;
  background: var(--bg);
}

.mini-currency-grid a:hover {
  transform: translateY(-2px);
  border-color: rgba(39,59,127,.25);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.mini-currency-grid a:last-child {
  grid-column: 1 / -1;
}

.mini-currency-grid b {
  font-size: 25px;
}

.mini-currency-grid span {
  font-size: 14px;
  font-weight: 700;
  display: flex;
  flex-direction: column;
}

.mini-currency-grid small {
  color: var(--soft);
  font-size: 11px;
  margin-top: 2px;
}

.mini-currency-grid strong {
  margin-inline-start: auto;
  color: var(--royal);
  font-size: 20px;
}

.panel-note {
  color: var(--soft);
  font-size: 12px;
  margin-top: 14px;
  text-align: center;
}

.currency-cards {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
}

.currency-cards.compact {
  grid-template-columns: repeat(5, 1fr);
}

.currency-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 190px;
  padding: 22px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  transition: transform .2s, box-shadow .2s, border-color .2s;
}

.currency-card:hover {
  transform: translateY(-5px);
  border-color: rgba(39,59,127,.25);
  box-shadow: var(--shadow-lg);
}

.currency-flag {
  font-size: 34px;
  margin-bottom: 18px;
}

.currency-name {
  font-size: 17px;
  font-weight: 800;
}

.currency-code {
  color: var(--soft);
  font-size: 12px;
  font-weight: 700;
  margin-top: 3px;
}

.currency-action {
  margin-top: auto;
  color: var(--royal);
  font-size: 13px;
  font-weight: 700;
  padding-top: 16px;
}

.currency-action b {
  margin-inline-start: 4px;
}

.surface-section {
  background: var(--surface);
  border-block: 1px solid var(--line);
}

.currency-hero {
  padding: 52px 0 64px;
  background:
    radial-gradient(circle at 12% 10%, rgba(39,59,127,.09), transparent 35%),
    var(--bg);
}

.back-link {
  display: inline-flex;
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 34px;
}

.back-link:hover {
  color: var(--royal);
}

.currency-hero-grid {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: 48px;
  align-items: center;
}

.currency-hero h1 {
  font-size: 43px;
  line-height: 1.3;
  font-weight: 850;
  margin-bottom: 18px;
}

.big-flag {
  font-size: 29px !important;
}

.currency-rate-card {
  min-height: 310px;
}

.rate-placeholder {
  margin-top: 12px;
  padding: 12px 14px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 11px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.8;
}

.rate-actions {
  margin-top: 18px;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.info-box {
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.info-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: rgba(39,59,127,.08);
  color: var(--royal);
  font-weight: 800;
  margin-bottom: 15px;
}

.info-box h3 {
  font-size: 18px;
  margin-bottom: 7px;
}

.info-box p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.9;
}

@media (max-width: 1000px) {
  .currency-cards,
  .currency-cards.compact {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 760px) {
  .home-hero {
    padding-top: 50px;
  }

  .currency-hero-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .info-grid {
    grid-template-columns: 1fr;
  }

  .currency-cards,
  .currency-cards.compact {
    grid-template-columns: 1fr 1fr;
  }

  .mini-currency-grid {
    grid-template-columns: 1fr;
  }

  .mini-currency-grid a:last-child {
    grid-column: auto;
  }
}

@media (max-width: 520px) {
  .currency-cards,
  .currency-cards.compact {
    grid-template-columns: 1fr;
  }

  .currency-card {
    min-height: 145px;
  }

  .currency-hero h1 {
    font-size: 32px;
  }

  .hero-description {
    font-size: 15px;
  }
}
