/* ==== BASE DEL HEADER ==== */

  #cabecera {
    width: 100%;
    /*background: linear-gradient(180deg,#f7a821 0%,#282015 70%);*/
    background: linear-gradient(180deg, #c9b387, #1b1c24 70%);
    border-bottom: 1px solid #ddd;                  /* Línea sutil inferior */
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    position: sticky;                                 /* Se queda arriba al hacer scroll */
    top: 0 !important;
    z-index: 1000;
    font-family: "Lato", sans-serif;
  }

  .tile {
    --header-height-desktop: 60;
    --header-height-mobile: 60;
  }
     
  /* Contenedor principal enlaces */

  .header__row {
        display: flex;
        align-items: center;
        justify-content: space-between;
        max-width: 1800px;
        margin: 0 auto;
        padding: 0.5rem 1rem;
      }

  /* ==== LOGO ==== */

  .header__logo img {
        max-height: 50px;
        height: auto;
        width: auto;
        display: block;
        border-radius: 12px;
      }

  .header__logo {
        border: 2px solid #ffffff;
        border-radius: 12px;
      }

  .header__logo:hover {
        transform: scale(1.05);
      }

  /* === BLOQUES === */

  /* Izquierda: logo */

  .header__left {
        flex: 0 0 auto;
        display: flex;
        align-items: left;
      }

  /* Centro: menú */
  .header__center {
        flex: 1;
        display: flex;
        justify-content: center;
      }

  /* Derecha: carrito + banderas */
  .header__right {
        flex: 0 0 auto;
        display: flex;
        align-items: right;
        gap: 3rem;         
      }

  /* === MENÚ PRINCIPAL === */

  .header__menu-inner {
        display: flex;
        gap: 3rem;
      }

  .header__menu-link-title {
        text-decoration: none;
        color: #ffffff;
        font-weight: 700;
        transition: color 0.3s;
        position: relative;
        display: inline-block;
        padding-bottom: 4px;
        text-transform: uppercase;
      }

  .header__menu-link-title:hover {
        color: #d4b483;
      }

  /* barrita decorativa desde el centro */
  .header__menu-link-title::before {
        content: "";
        position: absolute;
        bottom: 0;
        left: 50%;                          /* punto de referencia en el centro */
        width: 0;
        height: 2px;
        background-color: #ffcc00;
        transform: translateX(-50%);      /* coloca el centro justo en el texto */
        transition: width 0.3s ease;
      }

  .header__menu-link-title:hover::before {
        width: 100%;                      /* se expande hacia ambos lados */
      }

  /* ==== CARRITO ==== */

  .header__icon--cart {
        text-decoration: none;
        font-weight: 600;
        color: #ffffff;
        transition: background 0.3s ease, color 0.3s ease;
      }

      .header__icon--cart:hover {
        color: #7b5b3e;
      }

  .header__icon-text {
        text-decoration: none;
        color: #ffffff;
        font-weight: 700;
        transition: color 0.3s;
        position: relative;
        display: inline-block;
        padding-bottom: 4px;
        text-transform: uppercase;
      }

  .header__icon-text:hover {
        color: #d4b483;
      }

  .header__icon-text::before {
        content: "";
        position: absolute;
        bottom: 0;
        left: 50%;                
        width: 0;
        height: 2px;
        background-color: #ffcc00;
        transform: translateX(-50%);      
        transition: width 0.3s ease;
      }

  .header__icon-text:hover::before {
        width: 100%;                      
      }

  /* ==== BANDERAS ==== */

  .header-languages {
        display: flex;
        justify-content: center;
        gap: 20px;
        align-items: center;
      }

  .header-languages a img {
        height: 15px;
        width: auto;
        transition: transform 0.2s ease;
      }

  .header-languages a:hover img {
        transform: scale(1.15);
      }

  /* ==== RESPONSIVE ==== */

  @media (max-width: 768px) {
        .header__row {
          flex-wrap: wrap;
          justify-content: center;
          padding: 15px;
        }

        .header__menu-inner {
          flex-wrap: wrap;
          gap: 1rem;
          margin-top: 10px;
        }

        .header__icon--cart {
          margin-top: 10px;
        }
      }

  /* Botón hamburguesa */

  .menu-toggle {
      display: none;
      font-size: 2rem;
      background: none;
      border: none;
      cursor: pointer;
      color: #4e412a;
    }

  /* Móvil */
  @media (max-width: 768px) {
    .menu-toggle {
      display: block;
      position: absolute;
      top: 1rem;
      right: 1rem;
      z-index: 1001;
    }

    .header__menu-inner {
      display: none;
      flex-direction: column;
      background-color: #fff;
      position: absolute;
      top: 60px;
      right: 0;
      width: 200px;
      box-shadow: 0 4px 8px rgba(0,0,0,0.2);
      padding: 1rem;
    }

    .header__menu-inner.open {
      display: flex;
    }

    /* Cambiar icono al abrir */
    .menu-toggle.active::after {
      content: "✕";
      position: absolute;
      top: 0;
      left: 0;
      right: 0;
      text-align: center;
    }

    .menu-toggle.active {
      color: #4e412a;
    }
  }
