:root {
    /* Paleta Oficial Mamá Clara */
    --terracota: #A55A3B;
    --beige-base: #EDE5DD;
    --oliva: #8A8A67;
    --cafe-profundo: #56493F;
    --arena: #DCCDBD;
    
    --font-titulos: 'Cormorant Garamond', serif;
    --font-textos: 'Montserrat', sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-textos);
    background-color: var(--beige-base);
    color: var(--cafe-profundo);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    padding: 3rem 1rem 1rem;
}

/* ========================================= */
/* PANEL CLIENTES (INDEX) */
/* ========================================= */
.layout-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    max-width: 1100px;
    width: 100%;
    align-items: start;
    margin: 0 auto;
}

.info-panel {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.brand-logo {
    max-width: 220px;
    margin-bottom: 0.5rem;
}

.main-title {
    font-family: var(--font-titulos);
    font-size: 2.8rem;
    line-height: 1.1;
    color: var(--terracota);
    font-weight: 600;
}

.description {
    font-size: 1.05rem;
    line-height: 1.6;
    color: var(--cafe-profundo);
}

.description strong {
    color: var(--terracota);
    font-weight: 500;
}

.image-wrapper {
    width: 100%;
    max-width: 280px;
    margin: 1rem auto 0;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 20px rgba(86, 73, 63, 0.1);
    aspect-ratio: 4 / 5; 
}

.hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* FOOTER GLOBAL */
.site-footer {
    text-align: center;
    margin-top: 4rem;
    padding-bottom: 2rem;
    font-size: 0.95rem;
    color: var(--cafe-profundo);
    opacity: 0.8;
}

.site-footer a {
    color: var(--terracota);
    text-decoration: none;
    font-weight: 600;
    display: block;
    margin-top: 0.5rem;
}

/* PANEL DE AGENDA */
.booking-panel {
    background-color: #FFFFFF;
    border-radius: 24px;
    padding: 3rem;
    box-shadow: 0 20px 40px rgba(86, 73, 63, 0.08);
}

.section-title {
    font-family: var(--font-titulos);
    font-size: 2rem;
    color: var(--terracota);
    margin-bottom: 0.5rem;
}

.section-subtitle {
    font-size: 0.95rem;
    color: var(--oliva);
    margin-bottom: 2rem;
}

/* Calendario */
.calendar-card {
    border: 1px solid var(--arena);
    border-radius: 16px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.calendar-header h3 {
    font-family: var(--font-titulos);
    font-size: 1.4rem;
    color: var(--cafe-profundo);
}

.cal-nav {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--cafe-profundo);
    cursor: pointer;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    transition: background 0.2s;
}

.cal-nav:hover {
    background-color: var(--beige-base);
}

.calendar-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
    font-weight: 600;
    font-size: 0.85rem;
    color: var(--oliva);
    margin-bottom: 1rem;
}

.calendar-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 0.5rem;
    text-align: center;
}

.day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    cursor: pointer;
    border-radius: 12px;
    color: #999;
    transition: all 0.2s;
}

.day.has-hours {
    background-color: var(--beige-base);
    color: var(--cafe-profundo);
    font-weight: 500;
}

.day.has-hours:hover {
    background-color: var(--arena);
}

.day.selected {
    background-color: var(--terracota) !important;
    color: #FFF !important;
    font-weight: 600;
    box-shadow: 0 4px 12px rgba(165, 90, 59, 0.3);
}

.day.disabled {
    pointer-events: none;
    opacity: 0.3;
}

/* Horarios */
.slots-title {
    font-family: var(--font-titulos);
    font-size: 1.4rem;
    color: var(--cafe-profundo);
    margin-bottom: 1rem;
}

.slots-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.8rem;
    margin-bottom: 2rem;
}

.slot-btn {
    background-color: #FFF;
    border: 1px solid var(--oliva);
    color: var(--cafe-profundo);
    padding: 0.8rem;
    border-radius: 12px;
    font-family: var(--font-textos);
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.2s;
}

.slot-btn:hover {
    background-color: var(--beige-base);
}

.slot-btn.selected {
    background-color: var(--oliva);
    border-color: var(--oliva);
    color: #FFF;
}

/* Formulario */
#booking-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

input {
    width: 100%;
    padding: 1rem;
    border: 1px solid var(--arena);
    border-radius: 12px;
    font-family: var(--font-textos);
    color: var(--cafe-profundo);
    background-color: #FAFAFA;
}

input:focus {
    outline: none;
    border-color: var(--terracota);
    background-color: #FFF;
}

.btn-submit {
    background-color: var(--terracota);
    color: #FFF;
    border: none;
    padding: 1.2rem;
    border-radius: 12px;
    font-family: var(--font-titulos);
    font-size: 1.2rem;
    cursor: pointer;
    transition: background 0.3s;
    margin-top: 0.5rem;
}

.btn-submit:hover {
    background-color: var(--cafe-profundo);
}

.btn-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.hidden {
    display: none !important;
}

/* ========================================= */
/* VENTANA EMERGENTE (MODAL) */
/* ========================================= */
.modal {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(86, 73, 63, 0.4);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    backdrop-filter: blur(5px);
}

.modal-content {
    background: #FFFFFF;
    padding: 3rem;
    border-radius: 24px;
    text-align: center;
    max-width: 450px;
    width: 90%;
    box-shadow: 0 25px 50px rgba(0,0,0,0.1);
    border: 1px solid var(--arena);
}

.modal-title {
    font-family: var(--font-titulos);
    color: var(--terracota);
    font-size: 2.2rem;
    margin-bottom: 1rem;
}

#modal-message {
    color: var(--cafe-profundo);
    font-size: 1.05rem;
    line-height: 1.5;
}

/* ========================================= */
/* PANEL DE ADMINISTRADOR */
/* ========================================= */
.admin-body {
    background-color: #F8F6F4;
    display: block; 
    padding: 3rem 1rem;
}

.admin-container {
    max-width: 1000px;
    margin: 0 auto;
}

.admin-header {
    text-align: center;
    margin-bottom: 3rem;
}

.admin-logo {
    max-width: 200px;
    margin-bottom: 1rem;
}

.admin-title {
    font-family: var(--font-titulos);
    font-size: 2.5rem;
    color: var(--cafe-profundo);
}

.admin-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    align-items: start;
}

.admin-card {
    background-color: #FFFFFF;
    border-radius: 20px;
    padding: 2.5rem;
    box-shadow: 0 10px 30px rgba(86, 73, 63, 0.05);
    border: 1px solid var(--arena);
}

.list-container {
    margin-top: 1.5rem;
    list-style: none;
}

.appointment-item, .blocked-item {
    border-bottom: 1px solid var(--arena);
    padding: 1.5rem 0;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.appointment-item:last-child, .blocked-item:last-child {
    border-bottom: none;
}

.appointment-item strong {
    color: var(--terracota);
    font-size: 1.1rem;
    display: block;
    margin-bottom: 0.3rem;
}

.appointment-item p {
    font-size: 0.95rem;
    color: var(--cafe-profundo);
    margin: 0.2rem 0;
}

.admin-form label {
    display: block;
    margin-bottom: 0.5rem;
    margin-top: 1.5rem;
    font-weight: 500;
    color: var(--cafe-profundo);
}

/* ETIQUETAS DE ESTADO Y BOTONES ADMIN */
.status-badge {
    display: inline-block;
    padding: 0.3rem 0.8rem;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 0.8rem;
}

.status-pendiente { background-color: #FFF3CD; color: #856404; }
.status-atendido { background-color: #D4EDDA; color: #155724; }
.status-no-asistio { background-color: #F8D7DA; color: #721C24; }

.admin-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
    align-items: center;
}

.btn-small {
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    font-weight: 500;
    font-family: var(--font-textos);
    transition: background 0.2s;
}

.btn-edit { background-color: var(--oliva); color: #FFF; }
.btn-edit:hover { background-color: #6e6e52; }

.btn-remind { background-color: var(--arena); color: var(--cafe-profundo); }
.btn-remind:hover { background-color: #c9b9a7; }

.select-status {
    padding: 0.4rem;
    border-radius: 8px;
    border: 1px solid var(--arena);
    font-family: var(--font-textos);
    font-size: 0.85rem;
    color: var(--cafe-profundo);
    background-color: #FAFAFA;
    cursor: pointer;
}

/* ========================================= */
/* RESPONSIVE (ADAPTACIÓN A CELULAR) */
/* ========================================= */
@media (max-width: 900px) {
    body {
        padding: 0;
        background-color: var(--beige-base);
    }

    .layout-container {
        grid-template-columns: 1fr;
        gap: 0;
        padding: 0;
    }

    .info-panel {
        padding: 2.5rem 1.5rem 1rem;
        text-align: center;
    }

    .brand-logo {
        margin: 0 auto 1.5rem;
    }

    .booking-panel {
        margin: 1rem;
        padding: 2rem 1.5rem;
        border-radius: 24px;
    }
    
    .slots-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .site-footer {
        margin-top: 2rem;
        padding: 2rem;
    }

    /* Ajustes admin en celular */
    .admin-grid {
        grid-template-columns: 1fr;
    }
}