/* ===================
   1. Reset & Variables
   =================== */
:root {
  --gris-oscuro: #1a1a1a;
  --gris-claro: #ccc;
  --gris-medio: #ebebeb;
  --gris-texto: #333;
  --primario: #880877;
  --primario-hover: #c21a98;
  --azul-link: #003366;
  --azul-link-hover: #6a1b9a;
  --verde-acento: #00473d;
  --blanco: #ffffff;
}

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

html, body {
  margin: 0;
  padding: 0;
}

h2, h3, h4 {
    margin: 20px 0 10px;
    color: #00473e;
}

p, li {
    line-height: 1.6;
    margin-bottom: 10px;
}
 
ul {
    padding-left: 20px;
}


body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
}

.contenedor {
    padding: 20px 0;
    width: 100%;
    max-width: 1200px;
    margin: auto;
    overflow: hidden;
}

.imagen-indice {
  display: flex;
  justify-content: center; /* centra horizontal */
}

.imagen-indice .imagen img {
  margin-top: 5px;
  max-width: 100%;
  border-radius: 2%;
  height: auto;
  display: block;
}

/* ===================
   3. Header
   =================== */
header {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 9999;
  width: 100%;
  height: 100px;
  background: rgb(0, 71, 61);
  background-size: cover;
  background-attachment: fixed;
}

.nav-derecha {
  display: flex;
  align-items: center;
  gap: 15px; /* Espacio entre el botón y los íconos */
}

.social-icons {
  display: flex;
  align-items: center;
  gap: 10px; /* Espacio entre iconos */
}

.header-contents .nav-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 25px;
}

.logo {
  flex: 1 1 32%;
  width: auto;
  height: 55px;
  padding: 2px;
  border-radius: 15%;
  vertical-align: middle;
}

/* ==== Dropdown Menu ==== */
.dropdown {
  position: relative;
  display: inline-block;
  font-family: inherit;
  z-index: 10000;
}

.dropdown-btn {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 8px 14px;
  font-size: 14px;
  font-weight: 600;
  color: #fff;
  background-color: #1a1a1a;
  border: none;
  border-radius: 6px;
  cursor: pointer;
}

.dropdown-btn:hover {
  background-color: #292929;
}

.dropdown-content {
  position: absolute;
  top: calc(100% + 5px);
  left: 0;
  z-index: 99999;
  display: none;
  min-width: 180px;
  padding: 5px 0;
  background-color: #1a1a1a;
  border-radius: 6px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.dropdown-content a {
  display: block;
  padding: 10px 14px;
  font-size: 14px;
  color: #fff;
  text-decoration: none;
}

.dropdown-content a:hover {
  background-color: rgb(0, 71, 61);
}

/* Ocultar en pantallas de hasta 768px (tamaño típico de móvil y tablets pequeñas) */
@media (max-width: 768px) {
  .social-icons {
    display: none;
  }
}

/* ===================
   6. Footer
   =================== */

footer {
  background: var(--gris-oscuro);
  padding: 60px 0 30px 0;
  margin: auto;
  overflow: hidden;
  color: var(--blanco);
  font-family: Arial, sans-serif;
}
 
.footer-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  width: 60%;
  margin: auto;
  padding-bottom: 50px;
  border-bottom: 1px solid var(--gris-claro);
}

.footer-column {
  flex: 1;
  min-width: 200px;
  margin: 0 20px;
}

.footer-column h3 {
  color: var(--blanco);
  border-bottom: 3px solid var(--verde-acento);
  padding-bottom: 5px;
  margin-bottom: 15px;
  font-size: 18px;
}

.footer-column p,
.footer-column address {
  color: var(--gris-claro);
  font-style: normal;
  line-height: 1.6;
}

.footer-column a {
  color: var(--gris-claro);
  text-decoration: none;
}

.footer-column a:hover {
  color: var(--blanco);
  text-decoration: underline;
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 10px;
}

.social-icon {
  width: 32px;
  height: 32px;
  border-radius: 5px;
  transition: transform 0.3s ease;
}

.social-icon:hover {
  transform: scale(1.1);
}

.footer-bottom {
  text-align: center;
  margin-top: 30px;
  font-size: 14px;
  color: #9e9e9e;
  line-height: 1.6;
}

/********************************************
      Ticker Criptomonedas Loop Continuo
 ********************************************/
.ticker-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 35px;
  padding: 6px 10px;
  background-color: #f9f9f9;
  border-top: 4px solid #f39c12;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
  overflow: hidden;
}

.ticker {
  flex: 1;
  display: flex;
  align-items: center;
  white-space: nowrap;
  overflow: hidden;
}

.ticker-items {
  display: inline-block;
  margin: 5px 0;
  animation: scroll-left 180s linear infinite;
  backface-visibility: hidden;
  transform: translateZ(0);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.ticker-items:hover {
  animation-play-state: paused;
}

@keyframes scroll-left {
  0% {
    transform: translateX(0%);
  }
  100% {
    transform: translateX(-50%);
  }
}

.coin {
  display: inline-block;
  margin-right: 20px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", sans-serif;
  font-size: 15px;
  white-space: nowrap;
}

.coin-symbol {
  font-weight: bold;
  color: #000;
}

.coin-price {
  font-weight: normal;
  color: #000;
}

.up {
  color: green;
}

.down {
  color: red;
}

.currency-selector {
  padding: 2px;
  font-size: 14px;
  font-weight: 500;
  background-color: #fff;
  border: 1px solid #ccc;
  border-radius: 4px;
}


/******************
   MANEJO DE ADS
*******************/

.adsbygoogle {
    min-width: 250px;
}

/* ===================
   FIX SCROLL LATERAL EN MÓVIL
   =================== */
html, body {
  overflow-x: hidden;
}

/* Imágenes responsivas */
img {
  max-width: 100%;
  height: auto;
  display: block;
}


/* ===== Sidebar Ads ===== */
.sidebar-ads {
  position: fixed;
  top: 160px; /* distancia desde arriba */
  bottom: 600px;
  right: 10px; /* pegado al borde derecho */
  width: 300px; /* ancho estándar de ad de Google */
  z-index: 9999;
}

.sidebar-ads ins {
  width: 100% !important;
  height: auto !important;
}

/* En móviles, ocultamos el ad lateral */
@media (max-width: 1024px) {
  .sidebar-ads {
    display: none;
  }
}

.ads-in-article {
  max-height: 20px;
  margin: 20px auto;  /* centrado y con espacio alrededor */
}

.ads-in-article ins {
  display: block !important;
  margin: 0 auto;
}


/* ===================
   5. Want to know more?
   =================== */

.titulo1{
  margin: auto;
  display: flex;
  justify-content: center;
  margin-bottom: 20px;
}

.cards-guides {
  margin: auto;
  max-width: 80%;
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

.card-guide {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card-guide:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.15);
}

.card-guide img {
  object-fit: contain;
  max-width: 100%;
  height: auto;
  display: block;
}

.card-text {
  padding: 12px 15px;
  color: #333;
}

.card-text h3 {
  font-size: 16px;
  margin-bottom: 5px;
  color: #111;
}

.card-text p {
  font-size: 14px;
  margin-bottom: 8px;
  color: #666;
}

.card-date {
  font-size: 12px;
  color: #999;
}

@media (max-width: 1200px) {
  .cards-guides {
    grid-template-columns: repeat(3, 1fr); /* 3 columnas en pantallas medianas */
  }
}

@media (max-width: 900px) {
  .cards-guides {
    grid-template-columns: repeat(2, 1fr); /* 2 columnas en tablets */
  }
}

@media (max-width: 600px) {
  .cards-guides {
    grid-template-columns: 1fr; /* 1 columna en móviles */
  }
}


/* ===================
   8. Layout 2 Columnas
   =================== */
.news-layout {
  display: grid;
  grid-template-columns: 70% 30%;
  gap: 20px;
  max-width: 1200px;
  margin: auto;
}

.main-articles {
  background: #fff;
  padding: 20px;
  border-radius: 8px;
}

.sidebar {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-top: 19px;
}

.related-articles,
.ad-section {
  background: #fff;
  padding: 15px;
  border-radius: 8px;
  box-shadow: 0 0 6px rgba(0,0,0,0.1);
}

.related-articles h3,
.ad-section h3 {
  font-size: 18px;
  margin-bottom: 10px;
  border-bottom: 2px solid #f39c12;
  padding-bottom: 5px;
}

.related-articles ul { list-style: none; }
.related-articles li { margin-bottom: 10px; }

.related-articles a {
  text-decoration: none;
  color: var(--azul-link);
  font-size: 14px;
}

.related-articles a:hover { color: var(--azul-link-hover); }
    
.related-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 15px;
}

.related-item img {
  width: 100px;
  height: auto;
  object-fit: contain;
  border-radius: 8px;
  flex-shrink: 0;
}

.related-info { display: flex; flex-direction: column; }

.related-category {
  font-size: 14px;
  font-weight: bold;
  color: var(--verde-acento);
  margin-bottom: 4px;
}

.related-info a {
  font-size: 15px;
  text-decoration: none;
  color: var(--gris-texto);
  line-height: 1.3;
}

.related-info a:hover { color: var(--verde-acento); }

/* ===== Ocultar sidebar en móviles ===== */
@media (max-width: 768px) {
  .sidebar {
    display: none;
  }

  .news-layout {
    grid-template-columns: 1fr; /* El artículo ocupa todo el ancho */
  }
}


/*Diseño Calculadora*/
        .formulario {
            background-color: #003049;
            padding: 30px;
            border-radius: 10px;
            color: white;
            max-width: 700px;
            margin: 0 auto 50px;
        }

        .formulario h3 {
            background-color: #15827b;
            padding: 10px;
            border-radius: 5px;
            margin-top: 20px;
            color: white;
        }

        label {
            display: block;
            margin: 15px 0 5px;
            font-weight: bold;
        }

        input, select {
            width: 100%;
            padding: 10px;
            border-radius: 5px;
            border: none;
        }

        .botones {
            margin-top: 20px;
            display: flex;
            gap: 10px;
        }

        .botones button {
            padding: 10px 20px;
            border: none;
            border-radius: 5px;
            font-weight: bold;
            cursor: pointer;
        }

        .calcular {
            background-color: #e63946;
            color: white;
        }

        .restablecer {
            background-color: #06d6a0;
            color: #003049;
        }

        .resultado {
            background-color: #f3f3f3;
            padding: 20px;
            margin-top: 20px;
            border-left: 4px solid #00473e;
            color: #00473e;
        }