/**
 * MEATIOWA Farmer Dashboard - Stylesheet
 * Mobile-first responsive design
 */

/* ============================================
   CSS VARIABLES
   ============================================ */
:root {
    /* Primary Colors */
    --barn-red: #8B2323;
    --barn-red-dark: #6B1A1A;
    --barn-red-light: #A52A2A;
    --cream: #FDF5E6;
    --cream-dark: #F5ECD5;
    --hay: #D4A84B;
    --hay-dark: #B8923F;
    --sage: #6B8E6B;
    --sage-dark: #5A7A5A;
    --wood-brown: #654321;

    /* Neutral Colors */
    --charcoal: #2C2C2C;
    --slate: #4A4A4A;
    --medium-gray: #6B6B6B;
    --light-gray: #E8E8E8;
    --off-white: #FAFAFA;
    --white: #FFFFFF;

    /* Status Colors */
    --success: #4A7C4A;
    --warning: #D4A84B;
    --danger: #C53030;
    --info: #3182CE;

    /* Typography */
    --font-heading: 'Bitter', Georgia, serif;
    --font-body: 'Source Sans Pro', -apple-system, sans-serif;

    /* Spacing */
    --space-xs: 0.25rem;
    --space-sm: 0.5rem;
    --space-md: 1rem;
    --space-lg: 1.5rem;
    --space-xl: 2rem;
    --space-2xl: 3rem;

    /* Border Radius */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;

    /* Shadows */
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.1);
    --shadow-md: 0 4px 6px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 20px rgba(0,0,0,0.15);

    /* Sidebar */
    --sidebar-width: 260px;
    --sidebar-collapsed: 70px;
}

/* ============================================
   RESET & BASE
   ============================================ */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-body);
    font-size: 1rem;
    line-height: 1.5;
    color: var(--charcoal);
    background-color: var(--cream);
    min-height: 100vh;
}

/* ============================================
   LOGIN SCREEN
   ============================================ */
.login-screen {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--sage) 0%, var(--sage-dark) 100%);
    z-index: 9999;
    justify-content: center;
    align-items: center;
}

.login-screen.active {
    display: flex;
}

.login-container {
    background: var(--white);
    padding: var(--space-2xl);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    width: 100%;
    max-width: 400px;
    margin: var(--space-md);
}

.login-header {
    text-align: center;
    margin-bottom: var(--space-xl);
}

.login-header .logo-text {
    font-family: var(--font-heading);
    font-size: 2rem;
    color: var(--sage-dark);
    margin: 0;
}

.login-header .logo-tagline {
    color: var(--medium-gray);
    margin-top: var(--space-xs);
}

.login-form .form-group {
    margin-bottom: var(--space-md);
}

.login-form label {
    display: block;
    font-weight: 600;
    margin-bottom: var(--space-xs);
    color: var(--charcoal);
}

.login-form input {
    width: 100%;
    padding: var(--space-sm) var(--space-md);
    border: 2px solid var(--light-gray);
    border-radius: var(--radius-md);
    font-size: 1rem;
    transition: border-color 0.2s;
}

.login-form input:focus {
    outline: none;
    border-color: var(--sage);
}

.login-help {
    text-align: center;
    margin-top: var(--space-md);
    color: var(--medium-gray);
}

.login-links {
    text-align: center;
    margin-top: var(--space-lg);
    padding-top: var(--space-md);
    border-top: 1px solid var(--light-gray);
}

.login-links a {
    color: var(--sage-dark);
    text-decoration: none;
    font-size: 0.875rem;
}

.login-links span {
    color: var(--light-gray);
    margin: 0 var(--space-sm);
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    gap: var(--space-sm);
    padding: var(--space-sm) var(--space-md);
    border: none;
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

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

.btn-primary:hover {
    background: var(--sage-dark);
}

.btn-block {
    width: 100%;
    justify-content: center;
    padding: var(--space-md);
}

.btn-link {
    background: none;
    color: var(--sage);
    padding: 0;
    font-weight: 600;
    text-decoration: none;
}

.btn-logout {
    background: none;
    border: none;
    color: var(--medium-gray);
    font-size: 0.875rem;
    cursor: pointer;
}

.btn-logout:hover {
    color: var(--danger);
}

/* ============================================
   DASHBOARD LAYOUT
   ============================================ */
.dashboard-wrapper {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    position: fixed;
    left: 0;
    top: 0;
    width: var(--sidebar-width);
    height: 100vh;
    background: var(--white);
    border-right: 1px solid var(--light-gray);
    display: flex;
    flex-direction: column;
    z-index: 100;
    transition: transform 0.3s;
}

.sidebar-header {
    padding: var(--space-lg);
    border-bottom: 1px solid var(--light-gray);
}

.sidebar-header .logo-text {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    color: var(--sage-dark);
}

.sidebar-header .logo-tagline {
    font-size: 0.75rem;
    color: var(--medium-gray);
}

.sidebar-toggle {
    display: none;
}

.sidebar-nav {
    flex: 1;
    padding: var(--space-md);
    overflow-y: auto;
}

.sidebar-nav ul {
    list-style: none;
}

.nav-item a {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    padding: var(--space-sm) var(--space-md);
    border-radius: var(--radius-md);
    color: var(--slate);
    text-decoration: none;
    transition: all 0.2s;
}

.nav-item a:hover {
    background: var(--cream);
}

.nav-item.active a {
    background: var(--sage);
    color: var(--white);
}

.nav-item i {
    width: 20px;
    text-align: center;
}

.nav-item .badge {
    margin-left: auto;
    background: var(--danger);
    color: var(--white);
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 0.75rem;
}

.nav-section {
    margin-top: var(--space-lg);
    padding-top: var(--space-md);
    border-top: 1px solid var(--light-gray);
}

.nav-section-title {
    display: block;
    padding: var(--space-sm) var(--space-md);
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--medium-gray);
    text-transform: uppercase;
}

.sidebar-footer {
    padding: var(--space-md);
    border-top: 1px solid var(--light-gray);
}

.user-profile {
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

.user-avatar {
    width: 40px;
    height: 40px;
    background: var(--sage);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
}

.user-info {
    flex: 1;
}

.user-name {
    display: block;
    font-weight: 600;
    color: var(--charcoal);
}

/* Main Content */
.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    min-height: 100vh;
}

.top-header {
    position: sticky;
    top: 0;
    background: var(--white);
    padding: var(--space-md) var(--space-xl);
    border-bottom: 1px solid var(--light-gray);
    display: flex;
    align-items: center;
    gap: var(--space-md);
    z-index: 50;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
}

.page-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    color: var(--charcoal);
}

.header-actions {
    margin-left: auto;
}

.farm-name {
    font-weight: 600;
    color: var(--sage-dark);
}

/* Pages */
.page {
    display: none;
    padding: var(--space-xl);
}

.page.active {
    display: block;
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-xl);
}

.page-header h2 {
    font-family: var(--font-heading);
    color: var(--charcoal);
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: var(--space-lg);
    margin-bottom: var(--space-xl);
}

.stat-card {
    background: var(--white);
    padding: var(--space-lg);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

.stat-icon {
    width: 50px;
    height: 50px;
    background: var(--sage);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 1.25rem;
}

.stat-value {
    display: block;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--charcoal);
}

.stat-label {
    font-size: 0.875rem;
    color: var(--medium-gray);
}

/* Content Grid */
.content-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--space-lg);
}

/* Cards */
.card {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
}

.card-header {
    padding: var(--space-md) var(--space-lg);
    border-bottom: 1px solid var(--light-gray);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card-header h3 {
    font-size: 1rem;
    color: var(--charcoal);
}

.card-body {
    padding: var(--space-lg);
}

/* Empty State */
.empty-state {
    text-align: center;
    color: var(--medium-gray);
    padding: var(--space-xl);
}

/* Grids */
.animals-grid,
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: var(--space-lg);
}

/* Toast */
.toast-container {
    position: fixed;
    bottom: var(--space-lg);
    right: var(--space-lg);
    z-index: 9999;
}

.toast {
    background: var(--white);
    padding: var(--space-md) var(--space-lg);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    margin-bottom: var(--space-sm);
    display: flex;
    align-items: center;
    gap: var(--space-md);
    animation: slideIn 0.3s ease;
}

.toast.success { border-left: 4px solid var(--success); }
.toast.error { border-left: 4px solid var(--danger); }
.toast.warning { border-left: 4px solid var(--warning); }
.toast.info { border-left: 4px solid var(--info); }

@keyframes slideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

/* ============================================
   MOBILE STYLES
   ============================================ */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }

    .sidebar.open {
        transform: translateX(0);
    }

    .sidebar-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0,0,0,0.5);
        z-index: 99;
    }

    .sidebar-overlay.active {
        display: block;
    }

    .main-content {
        margin-left: 0;
    }

    .mobile-menu-btn {
        display: block;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .page {
        padding: var(--space-md);
    }
}

/* ============================================
   LIST ITEMS
   ============================================ */
.list-item {
    display: flex;
    align-items: flex-start;
    gap: var(--space-md);
    padding: var(--space-md);
    border-bottom: 1px solid var(--light-gray);
}

.list-item:last-child {
    border-bottom: none;
}

.list-item-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--sage);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.list-item-icon.warning {
    background: var(--warning);
}

.list-item-content {
    flex: 1;
    min-width: 0;
}

.list-item-content strong {
    display: block;
    font-weight: 600;
}

.list-item-content .text-muted {
    color: var(--medium-gray);
    font-size: 0.875rem;
}

.list-item-content p {
    margin-top: var(--space-xs);
    color: var(--slate);
    font-size: 0.9375rem;
}

.list-item-content small {
    display: block;
    margin-top: var(--space-xs);
    color: var(--medium-gray);
    font-size: 0.8125rem;
}

.list-item-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: var(--space-xs);
    flex-shrink: 0;
}

.list-item-meta .date {
    font-size: 0.8125rem;
    color: var(--medium-gray);
}

.list-item-meta .cost {
    font-weight: 600;
    color: var(--sage-dark);
}

/* ============================================
   ALERTS
   ============================================ */
.alerts-section {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
}

.alert {
    display: flex;
    align-items: flex-start;
    gap: var(--space-md);
    padding: var(--space-md);
    border-radius: var(--radius-md);
    background: var(--cream-dark);
    border-left: 4px solid;
}

.alert-warning {
    border-color: var(--warning);
    background: rgba(212, 168, 75, 0.1);
}

.alert-success {
    border-color: var(--success);
    background: rgba(74, 124, 74, 0.1);
}

.alert-info {
    border-color: var(--info);
    background: rgba(49, 130, 206, 0.1);
}

.alert i {
    font-size: 1.25rem;
    margin-top: 2px;
}

.alert-warning i { color: var(--warning); }
.alert-success i { color: var(--success); }
.alert-info i { color: var(--info); }

.alert div {
    flex: 1;
}

.alert strong {
    display: inline;
}

.alert small {
    display: block;
    margin-top: var(--space-xs);
    color: var(--medium-gray);
    font-size: 0.8125rem;
}

/* ============================================
   BUTTON GROUPS & FILTERS
   ============================================ */
.btn-group {
    display: flex;
    gap: var(--space-sm);
}

.btn-secondary {
    background: var(--light-gray);
    color: var(--charcoal);
}

.btn-secondary:hover {
    background: #d0d0d0;
}

.filter-group {
    display: flex;
    gap: var(--space-sm);
}

.filter-group select {
    padding: var(--space-sm) var(--space-md);
    border: 1px solid var(--light-gray);
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 0.875rem;
    background: var(--white);
}

/* ============================================
   BADGES
   ============================================ */
.badge.warning {
    background: var(--warning);
    color: var(--charcoal);
    font-size: 0.75rem;
    padding: 2px 8px;
    border-radius: 10px;
    display: inline-block;
    margin-top: var(--space-xs);
}

/* ============================================
   MODALS
   ============================================ */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    justify-content: center;
    align-items: center;
    padding: var(--space-md);
}

.modal.open {
    display: flex;
}

.modal-content {
    background: var(--white);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-lg);
}

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

.modal-header h2 {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    color: var(--charcoal);
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.25rem;
    color: var(--medium-gray);
    cursor: pointer;
    padding: var(--space-sm);
    min-width: 44px;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    color: var(--charcoal);
}

.modal-body {
    padding: var(--space-lg);
}

.modal-footer {
    padding: var(--space-lg);
    border-top: 1px solid var(--light-gray);
    display: flex;
    justify-content: flex-end;
    gap: var(--space-sm);
}

/* Form Styles */
.form-group {
    margin-bottom: var(--space-md);
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: var(--space-xs);
    color: var(--charcoal);
    font-size: 0.875rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: var(--space-sm) var(--space-md);
    border: 2px solid var(--light-gray);
    border-radius: var(--radius-md);
    font-family: inherit;
    font-size: 1rem;
    transition: border-color 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--sage);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-md);
}

.form-check {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

.form-check input[type="checkbox"] {
    width: auto;
}

.form-check label {
    margin: 0;
    font-weight: normal;
}

/* ============================================
   SLAUGHTER LISTINGS (BULK MEAT SALES)
   ============================================ */
.slaughter-listings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: var(--space-md);
}

.listing-card {
    background: white;
    border-radius: var(--radius-md);
    padding: var(--space-md);
    border: 1px solid var(--border-light);
    transition: box-shadow 0.2s;
}

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

.listing-card.listing-draft {
    border-left: 4px solid var(--gray-400);
}

.listing-card.listing-active {
    border-left: 4px solid var(--success-color);
}

.listing-card.listing-sold-out {
    border-left: 4px solid var(--primary-color);
}

.listing-card.listing-processing {
    border-left: 4px solid var(--warning-color);
}

.listing-card.listing-ready {
    border-left: 4px solid var(--info-color);
}

.listing-card.listing-completed {
    border-left: 4px solid var(--gray-500);
    opacity: 0.8;
}

.listing-card.listing-closed {
    border-left: 4px solid var(--danger-color);
    opacity: 0.7;
}

.listing-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: var(--space-sm);
}

.listing-header h4 {
    margin: 0;
    font-size: 1rem;
    color: var(--text-primary);
}

.listing-details {
    margin-bottom: var(--space-md);
}

.listing-details p {
    margin: var(--space-xs) 0;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.listing-details i {
    width: 20px;
    color: var(--gray-500);
}

.listing-actions {
    display: flex;
    gap: var(--space-xs);
    flex-wrap: wrap;
}

/* Allocations Grid */
.allocations-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-md);
    padding-bottom: var(--space-md);
    border-bottom: 1px solid var(--border-light);
}

.listing-summary h4 {
    margin: 0 0 var(--space-xs) 0;
}

.listing-summary p {
    margin: 0;
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.allocations-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: var(--space-md);
}

.allocation-card {
    background: var(--bg-light);
    border-radius: var(--radius-md);
    padding: var(--space-md);
    text-align: center;
    position: relative;
}

.allocation-card.allocation-available {
    border: 2px dashed var(--success-color);
    background: #f0fff4;
}

.allocation-card.allocation-reserved {
    border: 2px solid var(--warning-color);
    background: #fffbeb;
}

.allocation-card.allocation-sold {
    border: 2px solid var(--primary-color);
    background: #fef3c7;
}

.allocation-card.allocation-processing {
    border: 2px solid var(--info-color);
    background: #e0f2fe;
}

.allocation-card.allocation-ready {
    border: 2px solid var(--success-color);
    background: #dcfce7;
}

.allocation-card.allocation-picked_up {
    border: 2px solid var(--gray-400);
    background: var(--gray-100);
    opacity: 0.7;
}

.allocation-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-sm);
}

.portion-type {
    font-weight: 600;
    color: var(--text-primary);
}

.allocation-details p {
    margin: var(--space-xs) 0;
    font-size: 0.875rem;
}

.allocation-buyer {
    margin-top: var(--space-sm);
    padding-top: var(--space-sm);
    border-top: 1px solid var(--border-light);
    font-size: 0.8rem;
    color: var(--text-secondary);
}

/* Ready Animals */
.ready-animal-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--space-sm);
    background: var(--bg-light);
    border-radius: var(--radius-sm);
    margin-bottom: var(--space-sm);
}

.animal-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.animal-type, .animal-weight {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

/* Status badges */
.status-draft { background: var(--gray-200); color: var(--gray-700); }
.status-active { background: var(--success-light); color: var(--success-color); }
.status-sold_out { background: var(--primary-light); color: var(--primary-color); }
.status-processing { background: var(--warning-light); color: var(--warning-dark); }
.status-ready { background: var(--info-light); color: var(--info-color); }
.status-completed { background: var(--gray-200); color: var(--gray-600); }
.status-closed { background: var(--danger-light); color: var(--danger-color); }
.status-available { background: var(--success-light); color: var(--success-color); }
.status-reserved { background: var(--warning-light); color: var(--warning-dark); }
.status-sold { background: var(--primary-light); color: var(--primary-color); }
.status-picked_up { background: var(--gray-200); color: var(--gray-600); }

/* Modal large size */
.modal-lg {
    max-width: 700px;
}

/* Checkbox label */
.checkbox-label {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    width: auto;
}

/* ============================================
   BREADCRUMBS
   ============================================ */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: var(--space-xs);
    font-size: 0.875rem;
    color: var(--medium-gray);
}

.breadcrumb a {
    color: var(--sage);
    text-decoration: none;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.breadcrumb span {
    color: var(--charcoal);
    font-weight: 500;
}

/* ============================================
   TAB NAVIGATION
   ============================================ */
.tab-nav {
    display: flex;
    gap: var(--space-xs);
    background: var(--white);
    padding: var(--space-sm);
    border-radius: var(--radius-md);
    margin-bottom: var(--space-lg);
    overflow-x: auto;
    box-shadow: var(--shadow-sm);
}

.tab-btn {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    padding: var(--space-sm) var(--space-md);
    border: none;
    background: transparent;
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--slate);
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s;
}

.tab-btn:hover {
    background: var(--cream);
    color: var(--charcoal);
}

.tab-btn.active {
    background: var(--sage);
    color: var(--white);
}

.tab-btn i {
    font-size: 1rem;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ============================================
   WIZARD STEPS
   ============================================ */
.wizard-steps {
    display: flex;
    justify-content: space-between;
    padding: var(--space-lg) var(--space-md);
    border-bottom: 1px solid var(--light-gray);
    background: var(--cream);
}

.wizard-step {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    color: var(--medium-gray);
}

.wizard-step .step-number {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--light-gray);
    color: var(--slate);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.875rem;
    font-weight: 600;
}

.wizard-step .step-label {
    font-size: 0.875rem;
    font-weight: 500;
}

.wizard-step.active .step-number {
    background: var(--sage);
    color: var(--white);
}

.wizard-step.active .step-label {
    color: var(--charcoal);
    font-weight: 600;
}

.wizard-step.completed .step-number {
    background: var(--success);
    color: var(--white);
}

.wizard-step.completed .step-number::after {
    content: '\f00c';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 0.75rem;
}

.wizard-panel {
    display: none;
    padding: var(--space-lg);
}

.wizard-panel.active {
    display: block;
}

.wizard-footer {
    display: flex;
    justify-content: space-between;
    padding: var(--space-lg);
    border-top: 1px solid var(--light-gray);
}

/* ============================================
   STATS ROW (Mini Stats)
   ============================================ */
.stats-row {
    display: flex;
    gap: var(--space-md);
    margin-bottom: var(--space-lg);
    flex-wrap: wrap;
}

.stat-mini {
    background: var(--white);
    padding: var(--space-md) var(--space-lg);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    gap: var(--space-md);
    flex: 1;
    min-width: 150px;
}

.stat-mini i {
    width: 36px;
    height: 36px;
    background: var(--sage);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
}

.stat-mini .stat-content {
    display: flex;
    flex-direction: column;
}

.stat-mini .stat-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--charcoal);
    line-height: 1.2;
}

.stat-mini .stat-label {
    font-size: 0.75rem;
    color: var(--medium-gray);
}

/* ============================================
   INFO BANNER
   ============================================ */
.info-banner {
    display: flex;
    align-items: flex-start;
    gap: var(--space-md);
    padding: var(--space-md);
    background: rgba(107, 142, 107, 0.1);
    border-radius: var(--radius-md);
    margin-bottom: var(--space-lg);
    border-left: 4px solid var(--sage);
}

.info-banner i {
    color: var(--sage);
    font-size: 1.25rem;
    margin-top: 2px;
}

.info-banner p {
    margin: 0;
    color: var(--slate);
    font-size: 0.9375rem;
}

/* ============================================
   EMPTY STATE (Enhanced)
   ============================================ */
.empty-state {
    text-align: center;
    padding: var(--space-2xl);
    color: var(--medium-gray);
}

.empty-state i {
    font-size: 3rem;
    color: var(--light-gray);
    margin-bottom: var(--space-md);
    display: block;
}

.empty-state h4 {
    margin: 0 0 var(--space-sm) 0;
    color: var(--slate);
    font-family: var(--font-heading);
}

.empty-state p {
    margin: 0 0 var(--space-lg) 0;
    font-size: 0.9375rem;
}

/* ============================================
   REVIEW CARDS (For Wizard Review Step)
   ============================================ */
.review-card {
    background: var(--cream);
    border-radius: var(--radius-md);
    padding: var(--space-md);
    margin-bottom: var(--space-md);
}

.review-card h5 {
    margin: 0 0 var(--space-sm) 0;
    font-size: 0.875rem;
    color: var(--medium-gray);
    font-weight: 600;
    text-transform: uppercase;
}

.review-card p {
    margin: var(--space-xs) 0;
    color: var(--charcoal);
}

.review-card strong {
    color: var(--sage-dark);
}

/* ============================================
   ANIMAL SELECTION CARDS (Wizard)
   ============================================ */
.animal-select-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: var(--space-md);
}

.animal-select-card {
    border: 2px solid var(--light-gray);
    border-radius: var(--radius-md);
    padding: var(--space-md);
    cursor: pointer;
    transition: all 0.2s;
    background: var(--white);
}

.animal-select-card:hover {
    border-color: var(--sage);
    box-shadow: var(--shadow-sm);
}

.animal-select-card.selected {
    border-color: var(--sage);
    background: rgba(107, 142, 107, 0.1);
}

.animal-select-card h5 {
    margin: 0 0 var(--space-xs) 0;
    color: var(--charcoal);
}

.animal-select-card p {
    margin: 0;
    font-size: 0.875rem;
    color: var(--medium-gray);
}

/* ============================================
   PORTION GRID (Wizard)
   ============================================ */
.portion-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: var(--space-md);
}

.portion-card {
    border: 2px solid var(--light-gray);
    border-radius: var(--radius-md);
    padding: var(--space-md);
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    background: var(--white);
}

.portion-card:hover {
    border-color: var(--sage);
}

.portion-card.selected {
    border-color: var(--sage);
    background: rgba(107, 142, 107, 0.1);
}

.portion-card i {
    font-size: 1.5rem;
    color: var(--sage);
    display: block;
    margin-bottom: var(--space-sm);
}

.portion-card span {
    display: block;
    font-weight: 600;
    color: var(--charcoal);
}

.portion-card small {
    color: var(--medium-gray);
    font-size: 0.75rem;
}

/* ============================================
   FORM SECTION HEADERS
   ============================================ */
.form-section-header {
    margin-bottom: var(--space-md);
}

.form-section-header h4 {
    margin: 0 0 var(--space-xs) 0;
    color: var(--charcoal);
    font-family: var(--font-heading);
}

.form-section-header p {
    margin: 0;
    color: var(--medium-gray);
    font-size: 0.875rem;
}

/* ============================================
   TOGGLE SWITCH
   ============================================ */
.toggle-group {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-md) 0;
    border-bottom: 1px solid var(--light-gray);
}

.toggle-group:last-child {
    border-bottom: none;
}

.toggle-label {
    display: flex;
    flex-direction: column;
}

.toggle-label span:first-child {
    font-weight: 500;
    color: var(--charcoal);
}

.toggle-label span:last-child {
    font-size: 0.8125rem;
    color: var(--medium-gray);
}

.toggle-switch {
    position: relative;
    width: 48px;
    height: 26px;
    background: var(--light-gray);
    border-radius: 13px;
    cursor: pointer;
    transition: background 0.2s;
}

.toggle-switch.active {
    background: var(--sage);
}

.toggle-switch::after {
    content: '';
    position: absolute;
    width: 22px;
    height: 22px;
    background: var(--white);
    border-radius: 50%;
    top: 2px;
    left: 2px;
    transition: transform 0.2s;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

.toggle-switch.active::after {
    transform: translateX(22px);
}

/* ============================================
   RESPONSIVE ADJUSTMENTS
   ============================================ */
@media (max-width: 768px) {
    .tab-nav {
        padding: var(--space-xs);
    }

    .tab-btn {
        padding: var(--space-xs) var(--space-sm);
        font-size: 0.8125rem;
    }

    .tab-btn span {
        display: none;
    }

    .wizard-steps {
        gap: var(--space-sm);
    }

    .wizard-step .step-label {
        display: none;
    }

    .stats-row {
        flex-direction: column;
    }

    .stat-mini {
        min-width: unset;
    }
}

@media (max-width: 600px) {
    .list-item {
        flex-wrap: wrap;
    }

    .list-item-meta {
        width: 100%;
        flex-direction: row;
        justify-content: space-between;
        margin-top: var(--space-sm);
    }

    .btn-group {
        flex-direction: column;
    }

    .filter-group {
        flex-direction: column;
        width: 100%;
    }

    .filter-group select {
        width: 100%;
    }

    .breadcrumb {
        font-size: 0.75rem;
    }
}
