/* ==========================================================================
   LA PICA DE LAS CHURRASCAS - DESIGN SYSTEM & STYLESHEET
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=Plus+Jakarta+Sans:wght@400;500;600;700&display=swap');

:root {
    --primary: #b91c1c;
    --primary-hover: #991b1b;
    --primary-light: #fef2f2;
    --secondary: #d97706;
    --secondary-hover: #b45309;
    --dark: #1e1b18;
    --dark-muted: #44403c;
    --light-bg: #fcfbf9;
    --card-bg: #ffffff;
    --border: #e7e5e4;
    --text: #292524;
    --text-muted: #78716c;
    --success: #15803d;
    --warning: #b45309;
    --danger: #dc2626;

    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Plus Jakarta Sans', sans-serif;

    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --radius-full: 9999px;

    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.04);
    --shadow-md: 0 4px 14px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.12);
    --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
    font-family: var(--font-body);
    background-color: var(--light-bg);
    color: var(--text);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    color: var(--dark);
    font-weight: 700;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: var(--transition);
}
a:hover {
    color: var(--primary-hover);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* --- HEADER & NAVBAR --- */
.navbar {
    background: linear-gradient(135deg, #991b1b 0%, #7f1d1d 100%);
    color: white;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    color: white;
    font-size: 1.5rem;
    font-weight: 800;
    font-family: var(--font-heading);
}

.brand-icon {
    font-size: 1.8rem;
    background: rgba(255, 255, 255, 0.15);
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-md);
    backdrop-filter: blur(4px);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* --- HERO BANNER --- */
.hero {
    background: linear-gradient(rgba(30, 27, 24, 0.8), rgba(30, 27, 24, 0.85)), url('https://images.unsplash.com/photo-1509722747041-616f39b57569?auto=format&fit=crop&q=80&w=1200') center/cover no-repeat;
    color: white;
    padding: 60px 20px;
    text-align: center;
    border-radius: 0 0 24px 24px;
    box-shadow: var(--shadow-md);
    margin-bottom: 30px;
}

.hero h1 {
    color: white;
    font-size: 2.8rem;
    margin-bottom: 12px;
    letter-spacing: -0.5px;
}

.hero p {
    font-size: 1.2rem;
    color: #e7e5e4;
    max-width: 600px;
    margin: 0 auto 20px;
}

.badge-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(217, 119, 6, 0.25);
    color: #fef3c7;
    border: 1px solid rgba(217, 119, 6, 0.5);
    padding: 6px 16px;
    border-radius: var(--radius-full);
    font-size: 0.9rem;
    font-weight: 600;
}

/* --- BUTTONS --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    font-size: 0.95rem;
    font-weight: 600;
    font-family: var(--font-body);
    border-radius: var(--radius-md);
    border: none;
    cursor: pointer;
    transition: var(--transition);
}

.btn-primary {
    background-color: var(--primary);
    color: white;
}
.btn-primary:hover {
    background-color: var(--primary-hover);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn-secondary {
    background-color: var(--secondary);
    color: white;
}
.btn-secondary:hover {
    background-color: var(--secondary-hover);
    transform: translateY(-1px);
}

.btn-outline {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.4);
    color: white;
}
.btn-outline:hover {
    background: rgba(255, 255, 255, 0.1);
}

.btn-light {
    background: #ffffff;
    color: var(--dark);
    border: 1px solid var(--border);
}
.btn-light:hover {
    background: #f5f5f4;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.85rem;
    border-radius: var(--radius-sm);
}

.btn-success {
    background-color: var(--success);
    color: white;
}

/* --- CATEGORIES FILTER --- */
.categories-nav {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding: 10px 0 20px;
    scrollbar-width: none;
}
.categories-nav::-webkit-scrollbar {
    display: none;
}

.cat-chip {
    padding: 10px 20px;
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--radius-full);
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    white-space: nowrap;
    transition: var(--transition);
}
.cat-chip:hover, .cat-chip.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    box-shadow: var(--shadow-sm);
}

/* --- MENU GRID & CARDS --- */
.menu-section {
    margin-bottom: 40px;
}

.section-title {
    font-size: 1.6rem;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--border);
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.product-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
}
.product-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
    border-color: #fca5a5;
}

.product-info h3 {
    font-size: 1.15rem;
    margin-bottom: 6px;
    color: var(--dark);
}

.product-info p {
    font-size: 0.88rem;
    color: var(--text-muted);
    margin-bottom: 16px;
    line-height: 1.4;
}

.product-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
    padding-top: 12px;
    border-top: 1px dashed var(--border);
}

.product-price {
    font-family: var(--font-heading);
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--primary);
}

/* --- CART FLOATING BAR (MOBILE) & DRAWER --- */
.cart-floating-btn {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: var(--primary);
    color: white;
    padding: 14px 24px;
    border-radius: var(--radius-full);
    box-shadow: 0 10px 30px rgba(185, 28, 28, 0.4);
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 700;
    cursor: pointer;
    z-index: 90;
    transition: var(--transition);
}
.cart-floating-btn:hover {
    transform: scale(1.05);
}

.cart-count-badge {
    background: var(--secondary);
    color: white;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
}

/* --- MODALS --- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: var(--transition);
}
.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-card {
    background: white;
    border-radius: var(--radius-lg);
    width: 90%;
    max-width: 540px;
    max-height: 90vh;
    overflow-y: auto;
    padding: 28px;
    box-shadow: var(--shadow-lg);
    transform: translateY(20px);
    transition: var(--transition);
}
.modal-overlay.active .modal-card {
    transform: translateY(0);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}

.modal-close {
    background: transparent;
    border: none;
    font-size: 1.5rem;
    color: var(--text-muted);
    cursor: pointer;
}

/* --- FORMS --- */
.form-group {
    margin-bottom: 16px;
}
.form-group label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 6px;
    color: var(--dark-muted);
}
.form-control {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    font-family: var(--font-body);
    font-size: 0.95rem;
    transition: var(--transition);
}
.form-control:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(185, 28, 28, 0.12);
}

/* --- ADMIN STYLES --- */
.admin-header {
    background: white;
    border-bottom: 1px solid var(--border);
    padding: 24px 0;
    margin-bottom: 30px;
}

.kpi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.kpi-card {
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 20px;
    box-shadow: var(--shadow-sm);
}
.kpi-card h4 {
    font-size: 0.85rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}
.kpi-card .value {
    font-size: 1.8rem;
    font-weight: 800;
    font-family: var(--font-heading);
    color: var(--dark);
}

.consolidated-box {
    background: #fffbe8;
    border: 1px solid #fef08a;
    border-radius: var(--radius-lg);
    padding: 24px;
    margin-bottom: 30px;
}
.consolidated-box h3 {
    color: #854d0e;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.consolidated-item {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px dashed #fef08a;
}
.consolidated-item:last-child {
    border-bottom: none;
}

/* STATUS BADGES */
.status-badge {
    padding: 4px 12px;
    border-radius: var(--radius-full);
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
}
.status-pendiente { background: #fef3c7; color: #92400e; }
.status-en_preparacion { background: #dbeafe; color: #1e40af; }
.status-completado { background: #dcfce7; color: #166534; }
.status-cancelado { background: #fee2e2; color: #991b1b; }

/* CART ITEM IN MODAL */
.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
}
.cart-item-title {
    font-weight: 600;
    font-size: 0.95rem;
}
.cart-item-sub {
    font-size: 0.8rem;
    color: var(--text-muted);
}
.qty-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}
.qty-btn {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 1px solid var(--border);
    background: #f5f5f4;
    cursor: pointer;
    font-weight: 700;
}

@media (max-width: 768px) {
    .hero h1 { font-size: 2rem; }
    .hero p { font-size: 1rem; }
    .nav-container { padding: 12px 16px; }
}
