/* ===== CSS Reset & Variables ===== */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --primary: #e67e22;
    --primary-dark: #cf6d17;
    --primary-light: #f39c4f;
    --secondary: #2c3e50;
    --secondary-light: #34495e;
    --accent: #27ae60;
    --danger: #e74c3c;
    --warning: #f39c12;
    --info: #3498db;
    --bg: #f5f6fa;
    --bg-white: #ffffff;
    --text: #2c3e50;
    --text-light: #7f8c8d;
    --text-muted: #95a5a6;
    --border: #dcdde1;
    --border-light: #ecf0f1;
    --shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.12);
    --radius: 8px;
    --radius-lg: 12px;
    --transition: all 0.2s ease;
    --font: 'Segoe UI', -apple-system, BlinkMacSystemFont, Roboto, 'Helvetica Neue', sans-serif;
}

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
}

body {
    font-family: var(--font);
    background-color: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
}

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

a:hover {
    color: var(--primary-dark);
}

img {
    max-width: 100%;
    height: auto;
}

/* ===== Typography ===== */
h1, h2, h3, h4 {
    font-weight: 600;
    line-height: 1.3;
    color: var(--secondary);
}

h1 { font-size: 1.75rem; }
h2 { font-size: 1.5rem; }
h3 { font-size: 1.25rem; }

/* ===== Buttons ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.625rem 1.25rem;
    font-size: 0.9rem;
    font-weight: 500;
    border: none;
    border-radius: var(--radius);
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    line-height: 1.4;
    font-family: var(--font);
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow);
}

.btn-primary {
    background: var(--primary);
    color: #fff;
}

.btn-primary:hover {
    background: var(--primary-dark);
    color: #fff;
}

.btn-secondary {
    background: var(--secondary);
    color: #fff;
}

.btn-secondary:hover {
    background: var(--secondary-light);
    color: #fff;
}

.btn-danger {
    background: var(--danger);
    color: #fff;
}

.btn-danger:hover {
    background: #c0392b;
    color: #fff;
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--border);
    color: var(--text);
}

.btn-outline:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.btn-sm {
    padding: 0.375rem 0.75rem;
    font-size: 0.8rem;
}

.btn-lg {
    padding: 0.875rem 2rem;
    font-size: 1rem;
}

.btn-block {
    display: flex;
    width: 100%;
}

/* ===== Forms ===== */
.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.375rem;
    font-weight: 500;
    font-size: 0.9rem;
    color: var(--secondary);
}

.form-control {
    width: 100%;
    padding: 0.625rem 0.875rem;
    font-size: 0.95rem;
    font-family: var(--font);
    border: 2px solid var(--border);
    border-radius: var(--radius);
    background: var(--bg-white);
    color: var(--text);
    transition: var(--transition);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(230, 126, 34, 0.15);
}

textarea.form-control {
    resize: vertical;
    min-height: 100px;
}

/* ===== Flash Messages ===== */
.flash-messages {
    margin-bottom: 1.5rem;
}

.flash {
    padding: 0.875rem 1.25rem;
    border-radius: var(--radius);
    font-size: 0.9rem;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.flash-success {
    background: #d5f5e3;
    color: #1e8449;
    border-left: 4px solid var(--accent);
}

.flash-error {
    background: #fadbd8;
    color: #c0392b;
    border-left: 4px solid var(--danger);
}

.flash-info {
    background: #d6eaf8;
    color: #2471a3;
    border-left: 4px solid var(--info);
}

.flash-warning {
    background: #fdebd0;
    color: #b9770e;
    border-left: 4px solid var(--warning);
}

/* ===== Cards ===== */
.card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: var(--transition);
}

.card:hover {
    box-shadow: var(--shadow-lg);
}

.card-body {
    padding: 1.5rem;
}

/* ===== Tags / Badges ===== */
.tag {
    display: inline-block;
    padding: 0.2rem 0.6rem;
    font-size: 0.75rem;
    font-weight: 500;
    border-radius: 20px;
    background: var(--border-light);
    color: var(--text-light);
    white-space: nowrap;
}

.tag-vegan { background: #d5f5e3; color: #1e8449; }
.tag-vegetarian { background: #d5f5e3; color: #27ae60; }
.tag-gluten-free { background: #fdebd0; color: #b9770e; }
.tag-spicy { background: #fadbd8; color: #c0392b; }
.tag-dairy-free { background: #d6eaf8; color: #2471a3; }
.tag-nut-free { background: #f5eef8; color: #7d3c98; }
.tag-halal { background: #e8f8f5; color: #148f77; }
.tag-kosher { background: #e8f8f5; color: #117a65; }
.tag-organic { background: #eafaf1; color: #239b56; }
.tag-keto { background: #f9ebea; color: #922b21; }
.tag-low-carb { background: #fef9e7; color: #9a7d0a; }
.tag-sugar-free { background: #f2f4f4; color: #566573; }
.tag-seafood { background: #d4efdf; color: #1a5276; }
.tag-chef-special { background: #fdebd0; color: #ca6f1e; }

/* ===== Navbar ===== */
.navbar {
    background: var(--bg-white);
    border-bottom: 1px solid var(--border-light);
    padding: 0 1.5rem;
    min-height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
    position: sticky;
    top: 0;
    z-index: 100;
}

.navbar-brand {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
}

.navbar-brand:hover {
    color: var(--primary-dark);
}

.navbar-nav {
    display: flex;
    align-items: center;
    gap: 1rem;
    list-style: none;
}

.navbar-nav a {
    color: var(--text-light);
    font-weight: 500;
    font-size: 0.9rem;
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius);
}

.navbar-nav a:hover,
.navbar-nav a.active {
    color: var(--primary);
    background: rgba(230, 126, 34, 0.08);
}

/* ===== Nav overlay (mobile) ===== */
.nav-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: 90;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.nav-overlay.open {
    display: block;
    opacity: 1;
}

/* ===== Layout ===== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

/* ===== Utilities ===== */
.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }

/* ===== Navbar Toggle (mobile) ===== */
.navbar-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    border-radius: var(--radius);
    width: 44px;
    height: 44px;
    flex-shrink: 0;
    -webkit-tap-highlight-color: transparent;
    position: relative;
}

.navbar-toggle:hover {
    background: var(--border-light);
}

.hamburger-line {
    position: absolute;
    left: 50%;
    width: 22px;
    height: 3px;
    margin-left: -11px;
    background: var(--secondary);
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease;
    pointer-events: none;
}

.hamburger-line:nth-child(1) { top: 13px; }
.hamburger-line:nth-child(2) { top: 21px; }
.hamburger-line:nth-child(3) { top: 29px; }

.navbar-toggle.open .hamburger-line:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.navbar-toggle.open .hamburger-line:nth-child(2) {
    opacity: 0;
}

.navbar-toggle.open .hamburger-line:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
    .navbar {
        padding: 0 1rem;
        flex-wrap: wrap;
    }

    .navbar-toggle {
        display: block;
    }

    .navbar-nav {
        display: flex;
        width: 100%;
        flex-direction: column;
        padding: 0;
        gap: 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.35s ease, padding 0.35s ease;
    }

    .navbar-nav.open {
        max-height: 320px;
        padding: 0.5rem 0 0.75rem;
    }

    .navbar-nav li {
        opacity: 0;
        transform: translateY(-8px);
        transition: opacity 0.25s ease, transform 0.25s ease;
    }

    .navbar-nav.open li {
        opacity: 1;
        transform: translateY(0);
    }

    .navbar-nav.open li:nth-child(1) { transition-delay: 0.05s; }
    .navbar-nav.open li:nth-child(2) { transition-delay: 0.1s; }
    .navbar-nav.open li:nth-child(3) { transition-delay: 0.15s; }
    .navbar-nav.open li:nth-child(4) { transition-delay: 0.2s; }
    .navbar-nav.open li:nth-child(5) { transition-delay: 0.25s; }

    .navbar-nav a {
        display: block;
        padding: 0.75rem 0.5rem;
        font-size: 0.95rem;
        border-radius: var(--radius);
    }

    .navbar-nav a:active {
        background: rgba(230, 126, 34, 0.12);
    }

    body.nav-open {
        overflow: hidden;
    }

    .container {
        padding: 1.5rem 1rem;
    }

    .page-header {
        flex-direction: column;
        align-items: flex-start;
    }

    h1 { font-size: 1.5rem; }
}
