/* Nutreichen – tema claro, blanco/gris, verde y azul */

*,
*::before,
*::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: "DM Sans", system-ui, -apple-system, sans-serif;
    background: linear-gradient(180deg, #f0f4f8 0%, #e8eef4 100%);
    color: #1a2332;
    line-height: 1.5;
}

a {
    color: #0d9488;
    text-decoration: none;
}

a:hover {
    color: #0f766e;
    text-decoration: underline;
}

.site-root {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Topbar */
.topbar {

}

.topbar__caja {
    max-width: 1100px;
    margin: 0 auto;
    padding: 14px 35px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}

.brand {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: #0f766e;
}

.brand:hover {
    text-decoration: none;
    color: #0d9488;
}

.busca-form {
    display: flex;
    gap: 8px;
}

.busca-input {
    padding: 10px 14px;
    border-radius: 10px;
    border: 1px solid #cbd5e1;
    min-width: 220px;
    font-size: 0.9375rem;
    background: #f8fafc;
}

.busca-input:focus {
    outline: none;
    border-color: #0d9488;
    background: #fff;
}

.busca-btn {
    padding: 10px 18px;
    border-radius: 10px;
    border: none;
    background: linear-gradient(135deg, #0d9488 0%, #0f766e 100%);
    color: #fff;
    font-weight: 600;
    cursor: pointer;
    font-size: 0.9375rem;
}

.busca-btn:hover {
    background: linear-gradient(135deg, #0f766e 0%, #115e59 100%);
}

/* Main area */
.area {
    flex: 1;
    padding: 24px 0 32px;
}

.box {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

.dos-columnas {
    display: flex;
    gap: 28px;
    align-items: flex-start;
}

.col-principal {
    flex: 1;
    min-width: 0;
}

/* Panel (card) */
.panel {
    background: #ffffff;
    border-radius: 16px;
    padding: 24px 26px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 20px rgba(15, 118, 110, 0.06);
}

.panel--destacado {
    box-shadow: 0 4px 24px rgba(13, 148, 136, 0.08);
}

.panel--formulario {
    max-width: 560px;
}

.panel__titulo {
    font-size: 1.625rem;
    margin: 0 0 8px;
    color: #0f766e;
}

.panel__subtitulo {
    font-size: 1.25rem;
    margin-top: 24px;
    margin-bottom: 12px;
    color: #1e293b;
}

.panel__meta {
    font-size: 0.875rem;
    color: #64748b;
    margin: 0 0 16px;
}

.panel__texto {
    margin-bottom: 16px;
    color: #334155;
}

.panel__encabezado {
    margin-bottom: 16px;
}

.panel__imagen {
    margin: 16px 0;
}

.panel__imagen img {
    max-width: 260px;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
}

.panel__campos {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 16px 0;
}

.campo-texto {
    padding: 12px 14px;
    border-radius: 10px;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    font-size: 0.9375rem;
}

.panel__html {
    margin-top: 20px;
    font-size: 1rem;
    line-height: 1.65;
}

.panel__cta,
.panel__accion {
    margin-top: 20px;
}

/* Bloque para HTML personalizado en home */
.bloque-html {
    margin: 20px 0 24px;
    min-height: 40px;
}

/* Badge rating */
.badge-rating {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 999px;
    background: linear-gradient(135deg, #ccfbf1 0%, #99f6e4 100%);
    color: #0f766e;
    font-size: 0.875rem;
    font-weight: 600;
}

.badge-rating__estrella {
    color: #d97706;
}

.resumen-estrellas {
    margin: 14px 0;
    padding: 12px 16px;
    border-radius: 12px;
    background: #f0fdfa;
    border: 1px solid #99f6e4;
    font-size: 0.875rem;
}

.resumen-estrellas__fila {
    display: flex;
    justify-content: space-between;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 20px;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    font-size: 0.9375rem;
    border: none;
    text-decoration: none;
}

.btn--gradiente {
    background: linear-gradient(135deg, #0d9488 0%, #0891b2 100%);
    color: #fff;
}

.btn--gradiente:hover {
    background: linear-gradient(135deg, #0f766e 0%, #0e7490 100%);
    text-decoration: none;
    color: #fff;
}

.btn--secundario {
    background: #f1f5f9;
    color: #475569;
    border: 1px solid #cbd5e1;
    margin-left: 10px;
}

.btn--secundario:hover {
    background: #e2e8f0;
    color: #334155;
    text-decoration: none;
}

/* Listas */
.lista-enlaces {
    list-style: none;
    margin: 0;
    padding: 0;
    font-size: 0.9375rem;
}

.lista-enlaces li {
    padding: 8px 0;
    border-bottom: 1px solid #f1f5f9;
}

.lista-enlaces li:last-child {
    border-bottom: none;
}

/* Grid de productos (categoría y portada) */
.grid-productos {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 16px;
    margin-top: 16px;
}

.item-producto {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 14px 12px;
    border-radius: 14px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    text-decoration: none;
    color: inherit;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.item-producto:hover {
    border-color: #0d9488;
    box-shadow: 0 4px 16px rgba(13, 148, 136, 0.12);
    text-decoration: none;
    color: #0f766e;
}

.item-producto__img-wrap {
    width: 100px;
    height: 100px;
    flex-shrink: 0;
    border-radius: 12px;
    overflow: hidden;
    background: #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.item-producto__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.item-producto__placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #cbd5e1 0%, #94a3b8 100%);
}

.item-producto__titulo {
    margin-top: 10px;
    font-size: 0.9375rem;
    font-weight: 500;
    text-align: center;
    line-height: 1.3;
    color: #1e293b;
}

.item-producto:hover .item-producto__titulo {
    color: #0f766e;
}

@media (max-width: 480px) {
    .grid-productos {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }

    .item-producto {
        padding: 12px 10px;
    }

    .item-producto__img-wrap {
        width: 80px;
        height: 80px;
    }

    .item-producto__img {
        width: 80px;
        height: 80px;
    }
}

/* Reseñas */
.listado-resenas {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-top: 18px;
}

.entrada-resena {
    display: flex;
    gap: 14px;
    padding: 16px 18px;
    border-radius: 12px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
}

.entrada-resena__foto {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid #e2e8f0;
}

.entrada-resena__cuerpo {
    flex: 1;
}

.entrada-resena__cabecera,
.entrada-resena__titulo {
    font-weight: 600;
    margin-bottom: 4px;
}

.entrada-resena__meta {
    font-size: 0.8125rem;
    color: #64748b;
    margin-bottom: 6px;
}

.entrada-resena__texto {
    font-size: 0.9375rem;
    white-space: pre-line;
}

.estrellas {
    color: #d97706;
    font-size: 0.875rem;
}

/* Relacionados */
.relacionados {
    margin-top: 28px;
}

.grid-relacionados {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 14px;
}

.item-relacionado {
    padding: 12px 14px;
    border-radius: 12px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    font-size: 0.9375rem;
}

.item-relacionado__img {
    width: 100%;
    height: 110px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 8px;
}

/* Sidebar */
.lateral {
    flex: 0 0 280px;
}

.lateral__panel {
    background: #ffffff;
    border-radius: 14px;
    padding: 18px 20px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 16px rgba(0,0,0,0.04);
}

.lateral__titulo {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 12px;
    color: #0f766e;
}

.lateral__lista {
    list-style: none;
    margin: 0;
    padding: 0;
    font-size: 0.9375rem;
}

.lateral__lista li {
    padding: 6px 0;
}

.lateral__lista a:hover {
    color: #0f766e;
}

/* Formulario */
.formulario__grupo {
    margin-bottom: 16px;
}

.formulario__grupo label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 6px;
    color: #334155;
}

.formulario__input,
.formulario__textarea,
.formulario__select {
    width: 100%;
    padding: 10px 14px;
    border-radius: 10px;
    border: 1px solid #cbd5e1;
    font-size: 0.9375rem;
    background: #f8fafc;
}

.formulario__input:focus,
.formulario__textarea:focus,
.formulario__select:focus {
    outline: none;
    border-color: #0d9488;
    background: #fff;
}

.formulario__textarea {
    min-height: 120px;
    resize: vertical;
}

.formulario__botones {
    margin-top: 20px;
}

.mensaje {
    padding: 12px 14px;
    border-radius: 10px;
    margin-bottom: 16px;
    font-size: 0.9375rem;
}

.mensaje--error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #b91c1c;
}

.mensaje--ok {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #166534;
}

/* Footer */
.pie {
    border-top: 1px solid #e2e8f0;
    background: #ffffff;
    padding: 16px 0;
    font-size: 0.8125rem;
    color: #64748b;
}

.pie__caja {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

@media (max-width: 768px) {
    .topbar__caja {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
    }

    .busca-form {
        width: 100%;
    }

    .busca-input {
        min-width: 0;
        flex: 1;
    }

    .dos-columnas {
        flex-direction: column;
    }

    .lateral {
        flex: none;
    }
}
