:root {
    /* Colores principales */
    --primary-color: #ff6900;
    --secondary-color: #555555;
    --text-color: #333333;
    --light-color: #ffffff;
    --bg-color: #f9f9f9;
    --border-color: #eeeeee;
    
    /* Estados */
    --open-color: #4caf50;
    --closed-color: #f44336;
    --favorite-color: #ff5e84;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    background-color: var(--bg-color);

}

.app-container {
    max-width: 480px;
    margin: 0 auto;
    min-height: 100vh;
    background-color: var(--light-color);
    position: relative;
    overflow-x: hidden;
}

/* Header */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background-color: var(--light-color);
    position: sticky;
    top: 0;
    z-index: 10;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.logo img {
    height: 40px;
}

.notification-icon {
    position: relative;
    cursor: pointer;
}

.notification-icon i {
    font-size: 20px;
    color: var(--secondary-color);
}

.notification-count {
    position: absolute;
    top: -5px;
    right: -5px;
    background-color: var(--primary-color);
    color: white;
    border-radius: 50%;
    width: 18px;
    height: 18px;
    font-size: 11px;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Contenido principal */
main {
    padding: 15px;
    padding-bottom: 70px; /* Espacio para la barra de navegación inferior */
}

/* Estilos comunes */
.section {
    margin-bottom: 25px;
}

.section-title {
    font-size: 17px;
    font-weight: 600;
    margin-bottom: 15px;
}

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 30px;
    text-align: center;
}

.empty-state img {
    width: 80px;
    margin-bottom: 15px;
    opacity: 0.5;
}

.empty-state p {
    color: var(--secondary-color);
    font-size: 14px;
}

/* Saludo */
.greeting {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 15px;
}

/* Búsqueda */
.search-container {
    margin-bottom: 20px;
}

.search-bar {
    position: relative;
}

.search-bar input {
    width: 100%;
    padding: 12px 40px 12px 15px;
    border: 1px solid var(--border-color);
    border-radius: 25px;
    font-size: 15px;
    outline: none;
}

.search-bar i {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--secondary-color);
}


/* Categorías scroll horizontal */
.categories-scroll {
    display: flex;
    overflow-x: auto;
    gap: 15px;
    padding-bottom: 5px;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE and Edge */
}

.categories-scroll::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Opera */
}

.category-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 70px;
    cursor: pointer;
}

.category-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: var(--bg-color);
    overflow: hidden;
    margin-bottom: 5px;
    border: 1px solid var(--border-color);
}

.category-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.category-name {
    font-size: 12px;
    text-align: center;
    max-width: 70px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Restaurantes */
.restaurant-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.restaurant-card {
    display: flex;
    background-color: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    cursor: pointer;
}

.restaurant-logo {
    width: 80px;
    height: 80px;
    background-color: var(--bg-color);
}

.restaurant-logo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.restaurant-info {
    flex: 1;
    padding: 15px;
    position: relative;
}

.restaurant-name {
    font-size: 16px;
    margin-bottom: 5px;
}

.restaurant-status {
    font-size: 12px;
    padding: 3px 8px;
    border-radius: 12px;
    display: inline-block;
}

.restaurant-status.open {
    background-color: rgba(76, 175, 80, 0.1);
    color: var(--open-color);
}

.restaurant-status.closed {
    background-color: rgba(244, 67, 54, 0.1);
    color: var(--closed-color);
}

.favorite-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    color: #ddd;
    cursor: pointer;
    font-size: 18px;
}

.favorite-btn.fas {
    color: var(--favorite-color);
}

/* Grid de categorías */
.categories-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.category-card, .subcategory-card {
    background-color: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    cursor: pointer;
}

.category-img, .subcategory-img {
    height: 100px;
    overflow: hidden;
}

.category-img img, .subcategory-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.category-card .category-name, .subcategory-card .subcategory-name {
    padding: 10px;
    text-align: center;
    font-size: 14px;
    font-weight: 500;
}

/* Back button en categorías */
.back-button {
    display: inline-block;
    padding: 8px 15px;
    background-color: var(--bg-color);
    border-radius: 20px;
    margin-bottom: 15px;
    font-size: 14px;
    cursor: pointer;
}

.back-button i {
    margin-right: 5px;
}

.selected-category, .selected-subcategory {
    margin-bottom: 15px;
    font-size: 18px;
    font-weight: 500;
}

/* Promociones */
.promotions-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.promotion-card {
    background-color: white;
    border-radius: 10px;
    padding: 15px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    cursor: pointer;
}

.promotion-title {
    font-size: 16px;
    margin-bottom: 5px;
}

.promotion-message {
    font-size: 14px;
    color: var(--secondary-color);
}

/* Modal de notificaciones */
.notifications-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 100;
}

.modal-content {
    background-color: white;
    border-radius: 10px;
    width: 90%;
    max-width: 400px;
    max-height: 80vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    border-bottom: 1px solid var(--border-color);
}

.modal-header h3 {
    font-size: 18px;
}

.modal-header i {
    cursor: pointer;
    font-size: 18px;
}

.modal-body {
    padding: 15px;
    overflow-y: auto;
    max-height: calc(80vh - 60px);
}

.notifications-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.notification-item {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border-color);
    cursor: pointer;
}

.notification-item i {
    background-color: rgba(255, 105, 0, 0.1);
    color: var(--primary-color);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 18px;
}

.notification-content {
    flex: 1;
}

.notification-content h4 {
    font-size: 16px;
    margin-bottom: 5px;
}

.notification-content p {
    font-size: 14px;
    color: var(--secondary-color);
}

.empty-notification {
    text-align: center;
    padding: 20px;
    color: var(--secondary-color);
}

/* Tab Bar */
.tab-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: white;
    display: flex;
    justify-content: space-around;
    padding: 10px 0;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.05);
    max-width: 480px;
    margin: 0 auto;
    z-index: 10;
}

.tab-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: 10px;
    color: var(--secondary-color);
    cursor: pointer;
}

.tab-item i {
    font-size: 20px;
    margin-bottom: 3px;
}

.tab-item.active {
    color: var(--primary-color);
}
