* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  color: #182230;
  background: #f6f8fb;
  line-height: 1.6;
}

.container {
  width: min(1100px, 92%);
  margin: 0 auto;
}

/* Header */
.site-header {
  background: #ffffff;
  border-bottom: 1px solid #e7ebf0;
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-wrap {
  width: min(1100px, 92%);
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  padding: 18px 0;
}

.site-header .brand {
  color: #182230;
  font-size: 1.05rem;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}

.site-header nav {
  display: flex;
  gap: 22px;
  flex-wrap: wrap;
  align-items: center;
}

.site-header nav a {
  color: #475569;
  text-decoration: none;
  font-size: 0.95rem;
  transition: color 0.2s ease;
}

.site-header nav a:hover {
  color: #2f5bea;
}

/* Hero */
.hero {
  padding: 76px 0 58px;
  background: linear-gradient(135deg, #eef4ff 0%, #f7f9fc 100%);
}

.eyebrow {
  margin: 0 0 12px;
  color: #2f5bea;
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.hero h1 {
  margin: 0 0 18px;
  color: #172033;
  font-size: clamp(2.2rem, 5vw, 4rem);
  line-height: 1.08;
}

.lead {
  max-width: 720px;
  margin: 0 0 28px;
  color: #596579;
  font-size: 1.1rem;
}

/* Converter */
.converter-card {
  background: #ffffff;
  border: 1px solid #e0e6ee;
  border-radius: 18px;
  padding: 30px;
  box-shadow: 0 18px 45px rgba(25, 45, 80, 0.08);
}

.field {
  margin-bottom: 18px;
}

.field label {
  display: block;
  margin-bottom: 8px;
  color: #182230;
  font-weight: 700;
}

.field input,
.field select {
  width: 100%;
  padding: 14px 15px;
  border: 1px solid #cfd8e5;
  border-radius: 10px;
  background: #ffffff;
  color: #182230;
  font: inherit;
  font-size: 1rem;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.field input:focus,
.field select:focus {
  border-color: #2f5bea;
  box-shadow: 0 0 0 3px rgba(47, 91, 234, 0.12);
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 14px;
  align-items: end;
}

.swap {
  width: 42px;
  height: 42px;
  margin-bottom: 0;
  border: 1px solid #cfd8e5;
  border-radius: 50%;
  background: #ffffff;
  color: #182230;
  font-size: 1.1rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.swap:hover {
  border-color: #2f5bea;
  color: #2f5bea;
  transform: rotate(180deg);
}

.primary-btn {
  border: 0;
  border-radius: 10px;
  background: #2f5bea;
  color: #ffffff;
  padding: 14px 20px;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

.primary-btn:hover {
  background: #244bd0;
  transform: translateY(-1px);
}

.status {
  min-height: 24px;
  margin-top: 16px;
  color: #64748b;
  font-size: 0.95rem;
}

.result {
  margin-top: 4px;
  color: #14213a;
  font-size: 1.55rem;
  font-weight: 800;
}

/* Information sections */
.info-section,
.faq-section {
  padding: 58px 0;
}

.content-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.content-grid article,
.content-grid details {
  background: #ffffff;
  border: 1px solid #e0e6ee;
  border-radius: 14px;
  padding: 24px;
}

.content-grid h2 {
  margin-top: 0;
  color: #172033;
  font-size: 1.25rem;
  line-height: 1.35;
}

.content-grid p {
  margin-bottom: 0;
  color: #4d5b70;
}

/* FAQ */
.faq-section h2 {
  margin-top: 0;
  color: #172033;
  font-size: 1.8rem;
}

.faq-section details {
  margin-bottom: 12px;
}

.faq-section summary {
  color: #182230;
  font-weight: 700;
  cursor: pointer;
}

.faq-section details p {
  margin-bottom: 0;
  color: #4d5b70;
}

/* Footer */
footer {
  margin-top: 40px;
  background: #172033;
  color: #d4d9e2;
}

.footer-wrap {
  width: min(1100px, 92%);
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  padding: 28px 0;
}

.footer-wrap p {
  margin: 0;
}

.footer-wrap div {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
}

.footer-wrap a {
  color: #d4d9e2;
  text-decoration: none;
}

.footer-wrap a:hover {
  color: #ffffff;
}

/* Tablet */
@media (max-width: 800px) {
  .hero {
    padding: 58px 0 42px;
  }

  .grid-2 {
    grid-template-columns: 1fr 1fr;
  }

  .swap {
    grid-column: 1 / -1;
    grid-row: 2;
    justify-self: center;
    margin: 2px 0;
  }

  .content-grid {
    grid-template-columns: 1fr;
  }

  .footer-wrap {
    align-items: flex-start;
    flex-direction: column;
  }
}

/* Mobile */
@media (max-width: 600px) {
  .nav-wrap {
    padding: 15px 0;
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }

  .site-header nav {
    width: 100%;
    gap: 14px;
  }

  .site-header nav a {
    font-size: 0.9rem;
  }

  .hero {
    padding: 46px 0 32px;
  }

  .hero h1 {
    font-size: 2.25rem;
  }

  .lead {
    font-size: 1rem;
  }

  .converter-card {
    padding: 20px;
    border-radius: 14px;
  }

  .grid-2 {
    display: flex;
    flex-direction: column;
    gap: 8px;
  }

  .grid-2 .field {
    width: 100%;
  }

  .swap {
    order: 2;
    margin: 2px auto 4px;
  }

  .grid-2 .field:last-child {
    order: 3;
  }

  .primary-btn {
    width: 100%;
  }

  .result {
    font-size: 1.25rem;
    word-break: break-word;
  }

  .info-section,
  .faq-section {
    padding: 42px 0;
  }

  .content-grid article,
  .content-grid details {
    padding: 20px;
  }

  .footer-wrap {
    padding: 24px 0;
  }
}