/* ESTILOS CRÍTICOS - Carregamento acima da dobra */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont,
    sans-serif;
  background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 50%, #1e40af 100%);
  min-height: 100vh;
}

.hero {
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
}

.container {
  background: white;
  border-radius: 20px;
  padding: 40px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  max-width: 600px;
  width: 100%;
}

h1 {
  color: #333;
  font-size: clamp(20px, 4vw, 28px);
  margin-bottom: 30px;
  text-align: center;
  font-weight: 700;
  line-height: 1.2;
}

.converter {
  display: flex;
  gap: 15px;
  margin-bottom: 20px;
}

.input-group {
  flex: 1;
}

label {
  display: block;
  color: #666;
  font-size: 14px;
  margin-bottom: 8px;
  font-weight: 500;
}

input {
  width: 100%;
  padding: 15px;
  border: 2px solid #e0e0e0;
  border-radius: 10px;
  font-size: 18px;
  font-weight: 600;
  font-family: inherit;
}

.exchange-info {
  background: #dbeafe;
  padding: 15px;
  border-radius: 10px;
  text-align: center;
  color: #1e3a8a;
  font-size: 14px;
  font-weight: 500;
}

.exchange-value {
  font-size: 24px;
  font-weight: 700;
  margin-top: 5px;
  color: #333;
}

/* Estilos otimizados para carregamento não crítico abaixo */
.non-critical {
  display: none;
}

/* Loading skeleton */
.skeleton {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: loading 1.5s infinite;
  border-radius: 4px;
}

@keyframes loading {
  0% {
    background-position: 200% 0;
  }

  100% {
    background-position: -200% 0;
  }
}

/* Banners Adsense */
.adsense-top {
  width: 100%;
  max-width: 728px;
  height: 90px;
  margin: 0 auto 30px;
  background: #f5f5f5;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #999;
  font-size: 14px;
  overflow: hidden;
}

.adsense-sidebar {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  width: 160px;
  height: 600px;
  background: #f5f5f5;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #999;
  z-index: 999;
}

.adsense-left {
  left: 20px;
}

.adsense-right {
  right: 20px;
}

.adsense-bottom {
  width: 100%;
  max-width: 728px;
  height: 90px;
  margin: 40px auto 0;
  background: #f5f5f5;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #999;
  font-size: 14px;
  overflow: hidden;
}

/* Responsividade para banners laterais */
@media (max-width: 1200px) {
  .adsense-sidebar {
    display: none;
  }
}

@media (max-width: 768px) {
  .adsense-top {
    height: 100px;
    max-width: 320px;
    margin-bottom: 20px;
  }

  .adsense-bottom {
    height: 100px;
    max-width: 320px;
  }
}

/* Para telas muito pequenas, ocultar alguns banners */
@media (max-width: 480px) {
  .adsense-top {
    height: 50px;
    max-width: 300px;
  }

  .adsense-bottom {
    height: 50px;
    max-width: 300px;
  }
}

/* CONTEÚDO APÓS SCROLL - ESTILOS NÃO CRÍTICOS */
.content {
  background: #eff6ff;
  padding: 60px 20px;
  display: flex;
  justify-content: center;
}

.content-inner {
  max-width: 900px;
  width: 100%;
  background: white;
  border-radius: 20px;
  padding: 40px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
}

.history-table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0 40px;
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(30, 58, 138, 0.1);
}

.history-table th,
.history-table td {
  padding: 16px 20px;
  text-align: center;
  border-bottom: 1px solid #dbeafe;
}

.history-table th {
  background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 100%);
  color: white;
  font-weight: 600;
  font-size: 16px;
  letter-spacing: 0.5px;
}

.history-table tr:last-child td {
  border-bottom: none;
}

.history-table tr:hover {
  background-color: #dbeafe;
  transition: background-color 0.3s ease;
}

.history-table td {
  color: #555;
  font-size: 15px;
}

.history-table td:first-child {
  font-weight: 500;
  color: #444;
}

.history-table td:last-child {
  font-weight: 600;
  color: #1e3a8a;
  font-size: 16px;
}

/* ESTILOS PARA AS SEÇÕES DE INFORMAÇÃO */
.info-section {
  margin-top: 40px;
}

.section-title {
  font-size: 24px;
  margin-bottom: 25px;
  color: #333;
  position: relative;
  padding-bottom: 12px;
  font-weight: 700;
  line-height: 1.3;
}

.section-title::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 60px;
  height: 4px;
  background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%);
  border-radius: 2px;
}

.info-section p {
  margin-bottom: 20px;
  color: #555;
  line-height: 1.7;
  font-size: 16px;
  text-align: justify;
}

.info-section strong {
  color: #1e3a8a;
  font-weight: 600;
}

.info-section ul {
  margin: 15px 0 25px 25px;
  padding-left: 0;
}

.info-section li {
  margin-bottom: 12px;
  color: #555;
  line-height: 1.6;
  position: relative;
  padding-left: 8px;
}

.info-section li::before {
  content: "•";
  color: #1e3a8a;
  font-weight: bold;
  display: inline-block;
  width: 1em;
  margin-left: -1em;
}

.info-card {
  background: linear-gradient(135deg, #dbeafe 0%, #ffffff 100%);
  border-radius: 15px;
  padding: 25px;
  margin-bottom: 25px;
  border-left: 4px solid #1e3a8a;
  box-shadow: 0 5px 15px rgba(30, 58, 138, 0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.info-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(30, 58, 138, 0.12);
}

.card-title {
  font-size: 18px;
  color: #1e3a8a;
  margin-bottom: 15px;
  font-weight: 700;
  display: flex;
  align-items: center;
  line-height: 1.4;
}

.card-title::before {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  background: #2563eb;
  border-radius: 50%;
  margin-right: 10px;
}

.highlight-box {
  background: linear-gradient(
    135deg,
    rgba(30, 58, 138, 0.08) 0%,
    rgba(37, 99, 235, 0.08) 100%
  );
  border-radius: 12px;
  padding: 25px;
  margin: 25px 0;
  border: 1px solid rgba(30, 58, 138, 0.1);
}

.highlight-box strong {
  font-size: 17px;
  color: #333;
  display: block;
  margin-bottom: 10px;
}

.currency-facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  margin: 30px 0;
}

.fact-item {
  background: white;
  padding: 20px;
  border-radius: 12px;
  border: 1px solid #dbeafe;
  transition: all 0.3s ease;
}

.fact-item:hover {
  border-color: #1e3a8a;
  box-shadow: 0 5px 15px rgba(30, 58, 138, 0.1);
}

.fact-item h4 {
  color: #1e3a8a;
  margin-bottom: 10px;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.4;
}

.note-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 15px;
  margin: 20px 0;
}

.note-item {
  background: #dbeafe;
  padding: 15px;
  border-radius: 10px;
  border-left: 3px solid #1e3a8a;
}

.note-item strong {
  color: #333;
  font-size: 15px;
  display: block;
  margin-bottom: 5px;
}

.note-value {
  font-size: 14px;
  color: #666;
  line-height: 1.4;
}

.impact-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 15px;
  margin: 20px 0;
}

.impact-item {
  background: white;
  padding: 15px;
  border-radius: 10px;
  text-align: center;
  border: 1px solid #dbeafe;
  transition: all 0.3s ease;
}

.impact-item:hover {
  border-color: #1e3a8a;
  transform: translateY(-3px);
}

.impact-item strong {
  color: #1e3a8a;
  display: block;
  margin-bottom: 8px;
  font-size: 15px;
  line-height: 1.3;
}

.conclusion-box {
  background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%);
  color: white;
  padding: 30px;
  border-radius: 15px;
  margin-top: 40px;
  text-align: center;
}

.conclusion-box p {
  color: white;
  font-size: 17px;
  line-height: 1.8;
  margin-bottom: 0;
}

/* Responsividade adicional */
@media (max-width: 768px) {
  .content-inner {
    padding: 25px 20px;
  }

  .section-title {
    font-size: 20px;
  }

  .currency-facts,
  .note-grid,
  .impact-list {
    grid-template-columns: 1fr;
    gap: 15px;
  }

  .info-card {
    padding: 20px;
  }

  .history-table th,
  .history-table td {
    padding: 12px 15px;
    font-size: 14px;
  }
}

@media (max-width: 480px) {
  .converter {
    flex-direction: column;
  }

  .container {
    padding: 25px;
  }

  h1 {
    font-size: 22px;
  }

  input {
    padding: 12px;
    font-size: 16px;
  }
}

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

/* Print styles */
@media print {
  .hero {
    min-height: auto;
    padding: 0;
  }

  .container {
    box-shadow: none;
    border: 1px solid #ddd;
  }

  .content {
    background: white;
  }

  .info-card {
    break-inside: avoid;
  }

  a {
    text-decoration: none;
    color: #333;
  }

  .no-print {
    display: none;
  }
}
