/* Admin Panel Styles */

/* Enhanced Activity Log Styles */
.activity-item {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 8px;
    transition: all 0.2s ease;
}

.activity-item:hover {
    background: #ffffff;
    border-color: #007bff;
    box-shadow: 0 2px 4px rgba(0,123,255,0.1);
}

.activity-item.has-details {
    border-left: 4px solid #007bff;
}

.activity-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}

.activity-user {
    font-weight: 600;
    color: #495057;
    font-size: 0.9em;
}

.activity-time {
    font-size: 0.8em;
    color: #6c757d;
    background: #e9ecef;
    padding: 2px 8px;
    border-radius: 12px;
}

.activity-message {
    color: #212529;
    font-weight: 500;
    margin-bottom: 8px;
}

.activity-details {
    background: #ffffff;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    padding: 10px;
    margin-top: 8px;
}

.change-summary {
    font-size: 0.9em;
    color: #495057;
    margin-bottom: 8px;
    padding-bottom: 6px;
    border-bottom: 1px solid #e9ecef;
}

.changes-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.change-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85em;
    padding: 4px 0;
}

.change-field {
    font-weight: 600;
    color: #495057;
    min-width: 80px;
    flex-shrink: 0;
}

.change-before {
    background: #f8d7da;
    color: #721c24;
    padding: 2px 6px;
    border-radius: 4px;
    text-decoration: line-through;
    font-size: 0.9em;
}

.change-after {
    background: #d4edda;
    color: #155724;
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 500;
    font-size: 0.9em;
}

.no-activity {
    text-align: center;
    color: #6c757d;
    font-style: italic;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px dashed #dee2e6;
}

/* Discount Display Styles */
.original-price {
    text-decoration: line-through;
    color: #6c757d;
    font-size: 0.9em;
    margin-right: 8px;
}

.discounted-price {
    color: #28a745;
    font-weight: 600;
    margin-right: 8px;
}

.discount-badge {
    background: #dc3545;
    color: white;
    padding: 2px 6px;
    border-radius: 12px;
    font-size: 0.75em;
    font-weight: 600;
    text-transform: uppercase;
}

.status-badge.status-discount {
    background: #dc3545;
    color: white;
}

/* Form help text */
.form-help {
    display: block;
    margin-top: 4px;
    font-size: 0.8em;
    color: #6c757d;
    font-style: italic;
}

/* Responsive adjustments for activity log */
@media (max-width: 768px) {
    .change-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }
    
    .change-field {
        min-width: auto;
    }
    
    .activity-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }
}

:root {
    --primary-color: #d4af37;
    --primary-dark: #b8941f;
    --secondary-color: #2c3e50;
    --success-color: #27ae60;
    --danger-color: #e74c3c;
    --warning-color: #f39c12;
    --info-color: #3498db;
    --light-color: #ecf0f1;
    --dark-color: #2c3e50;
    --border-color: #ddd;
    --shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    --shadow-hover: 0 4px 20px rgba(0, 0, 0, 0.15);
    --border-radius: 8px;
    --transition: all 0.3s ease;
}

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

body {
    font-family: 'Outfit', sans-serif;
    background-color: #f8f9fa;
    color: #333;
    line-height: 1.6;
}

/* Login Screen */
.login-screen {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    padding: 20px;
}

.login-container {
    background: white;
    padding: 40px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-hover);
    width: 100%;
    max-width: 400px;
    text-align: center;
}

.login-header {
    margin-bottom: 30px;
}

.login-logo {
    width: 80px;
    height: auto;
    margin-bottom: 20px;
}

.login-header h1 {
    color: var(--secondary-color);
    margin-bottom: 10px;
    font-weight: 600;
}

.login-header p {
    color: #666;
    font-size: 14px;
}

.login-form {
    text-align: left;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: var(--secondary-color);
}

.form-group input {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 14px;
    transition: var(--transition);
}

.form-group input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.1);
}

.login-btn {
    width: 100%;
    padding: 12px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: var(--border-radius);
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.login-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

/* Admin Panel Layout */
.admin-panel {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    width: 100%;
}

/* Enhanced Header */
.admin-header {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.08);
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.admin-header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 20px;
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
}

.admin-logo {
    display: flex;
    align-items: center;
    gap: 15px;
    position: relative;
}

.admin-logo::after {
    content: '';
    position: absolute;
    right: -20px;
    top: 50%;
    transform: translateY(-50%);
    width: 1px;
    height: 30px;
    background: linear-gradient(to bottom, transparent, var(--border-color), transparent);
}

.admin-logo img {
    width: 45px;
    height: auto;
    filter: brightness(0.2) contrast(1.5) saturate(0.5);
    transition: filter 0.3s ease;
}

.admin-logo img:hover {
    filter: brightness(0.3) contrast(1.6) saturate(0.6);
}

.admin-logo h1 {
    color: var(--secondary-color);
    font-size: 26px;
    font-weight: 700;
    background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin: 0;
}

.admin-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

.admin-actions .btn {
    position: relative;
    overflow: hidden;
    font-weight: 500;
    letter-spacing: 0.5px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid transparent;
}

.admin-actions .btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.admin-actions .btn:hover::before {
    left: 100%;
}

.admin-actions .btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    box-shadow: 0 4px 15px rgba(212, 175, 55, 0.3);
    border-color: var(--primary-dark);
}

.admin-actions .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(212, 175, 55, 0.4);
}

.admin-actions .btn-secondary {
    background: linear-gradient(135deg, #6c757d, #5a6268);
    box-shadow: 0 4px 15px rgba(108, 117, 125, 0.3);
    border-color: #5a6268;
}

.admin-actions .btn-secondary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(108, 117, 125, 0.4);
}

.admin-actions .btn-danger {
    background: linear-gradient(135deg, var(--danger-color), #c0392b);
    box-shadow: 0 4px 15px rgba(231, 76, 60, 0.3);
    border-color: #c0392b;
}

.admin-actions .btn-danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(231, 76, 60, 0.4);
}

/* Header Status Indicator */
.admin-header-content::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--info-color), var(--success-color));
    opacity: 0.6;
}

/* Buttons */
.btn {
    padding: 8px 16px;
    border: none;
    border-radius: var(--border-radius);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
}

/* Compact header buttons */
.admin-actions .btn {
    padding: 6px 12px;
    font-size: 12px;
    min-height: 32px;
}

.admin-actions .btn i {
    font-size: 14px;
}

/* User Menu */
.user-menu {
    position: relative;
}

.user-menu-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: var(--transition);
    font-size: 14px;
    color: var(--secondary-color);
}

.user-menu-toggle:hover {
    background: #f8f9fa;
    border-color: var(--primary-color);
}

.user-menu-toggle i:first-child {
    font-size: 18px;
    color: var(--primary-color);
}

.user-menu-toggle i:last-child {
    font-size: 12px;
    transition: transform 0.3s ease;
}

.user-menu-toggle.active i:last-child {
    transform: rotate(180deg);
}

.user-menu-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-hover);
    min-width: 180px;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

.user-menu-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    color: var(--secondary-color);
    font-weight: 500;
}

.user-info i {
    color: var(--primary-color);
}

.user-menu-dropdown hr {
    margin: 0;
    border: none;
    border-top: 1px solid var(--border-color);
}

.user-menu-item {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 12px 16px;
    background: none;
    border: none;
    text-align: left;
    cursor: pointer;
    transition: var(--transition);
    color: var(--secondary-color);
    font-size: 14px;
}

.user-menu-item:hover {
    background: #f8f9fa;
    color: var(--danger-color);
}

.user-menu-item i {
    width: 16px;
    text-align: center;
}

/* Floating Action Buttons */
.floating-save-btn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 1000;
    animation: fadeInUp 0.3s ease;
}

.floating-add-buttons {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 999;
    display: flex;
    flex-direction: column;
    gap: 8px;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.floating-add-buttons.save-visible {
    transform: translateX(-70px);
}

.floating-add-btn {
    animation: fadeInUp 0.3s ease;
}

.fab-btn {
    position: relative;
    width: 56px;
    height: 56px;
    background: var(--primary-color);
    border: none;
    border-radius: 50%;
    color: white;
    font-size: 20px;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(212, 175, 55, 0.4);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.fab-btn.fab-primary {
    background: var(--primary-color);
    box-shadow: 0 4px 20px rgba(212, 175, 55, 0.4);
}

.fab-btn.fab-secondary {
    background: var(--info-color);
    box-shadow: 0 4px 20px rgba(52, 152, 219, 0.4);
}

.fab-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 25px rgba(0, 0, 0, 0.3);
}

.fab-btn.fab-primary:hover {
    background: var(--primary-dark);
    box-shadow: 0 6px 25px rgba(212, 175, 55, 0.5);
}

.fab-btn.fab-secondary:hover {
    background: #2980b9;
    box-shadow: 0 6px 25px rgba(52, 152, 219, 0.5);
}

.fab-btn:active {
    transform: scale(0.95);
}

.fab-tooltip {
    position: absolute;
    right: 70px;
    top: 50%;
    transform: translateY(-50%);
    background: var(--secondary-color);
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    pointer-events: none;
}

.fab-tooltip::after {
    content: '';
    position: absolute;
    left: 100%;
    top: 50%;
    transform: translateY(-50%);
    border: 6px solid transparent;
    border-left-color: var(--secondary-color);
}

.fab-btn:hover .fab-tooltip {
    opacity: 1;
    visibility: visible;
}

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

/* Mobile adjustments */
@media (max-width: 768px) {
    .floating-save-btn {
        bottom: 90px; /* Above bottom navigation */
        right: 20px;
    }
    
    .floating-add-buttons {
        bottom: 90px; /* Above bottom navigation */
        right: 20px;
        gap: 6px;
    }
    
    .floating-add-buttons.save-visible {
        transform: translateX(-60px);
    }
    
    .fab-btn {
        width: 48px;
        height: 48px;
        font-size: 18px;
    }
    
    .fab-tooltip {
        right: 60px;
        font-size: 11px;
        padding: 6px 10px;
    }
    
    .user-menu-dropdown {
        right: -10px;
        min-width: 160px;
    }
}

/* Staggered animation for multiple FABs */
.floating-add-btn:nth-child(1) {
    animation-delay: 0.1s;
}

.floating-add-btn:nth-child(2) {
    animation-delay: 0.2s;
}

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

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #5a6268;
    transform: translateY(-2px);
}

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

.btn-danger:hover {
    background: #c0392b;
    transform: translateY(-2px);
}

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

.btn-success:hover {
    background: #229954;
    transform: translateY(-2px);
}

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

.btn-warning:hover {
    background: #e67e22;
    transform: translateY(-2px);
}

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

.btn-info:hover {
    background: #2980b9;
    transform: translateY(-2px);
}

/* Main Content */
.admin-main {
    display: flex;
    flex: 1;
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
}

/* Sidebar - Desktop Only */
.admin-sidebar {
    display: none; /* Hidden by default (mobile) */
}

/* Content Area */
.admin-content {
    flex: 1;
    padding: 30px;
    background: #f8f9fa;
    min-height: calc(100vh - 120px);
}

/* Desktop Sidebar Styles */
@media (min-width: 769px) {
    .admin-sidebar {
        display: block;
        width: 250px;
        background: white;
        border-right: 1px solid var(--border-color);
        padding: 20px 0;
        position: sticky;
        top: 80px;
        height: calc(100vh - 80px);
        overflow-y: auto;
    }

    .admin-nav .nav-list {
        list-style: none;
    }

    .nav-item {
        margin-bottom: 5px;
    }

    .nav-link {
        display: flex;
        align-items: center;
        gap: 12px;
        padding: 12px 20px;
        color: #666;
        text-decoration: none;
        transition: var(--transition);
        border-right: 3px solid transparent;
    }

    .nav-link:hover {
        background: #f8f9fa;
        color: var(--primary-color);
    }

    .nav-link.active {
        background: rgba(212, 175, 55, 0.1);
        color: var(--primary-color);
        border-right-color: var(--primary-color);
    }

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

.content-section {
    display: none;
}

.content-section.active {
    display: block;
}

.section-header {
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 15px;
}

.section-header h2 {
    color: var(--secondary-color);
    font-size: 24px;
    font-weight: 600;
    margin: 0;
}

.section-header p {
    color: #666;
    margin: 0;
    font-size: 14px;
}

.section-actions {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

/* Compact search and filter controls */
.search-filter-controls {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 15px;
}

.search-filter-controls .form-input,
.search-filter-controls .form-select {
    padding: 8px 12px;
    font-size: 13px;
    min-height: 36px;
    border-radius: 6px;
}

.search-filter-controls .form-input {
    min-width: 200px;
    flex: 1;
}

.search-filter-controls .form-select {
    min-width: 150px;
}

.search-filter-controls .btn {
    padding: 8px 14px;
    font-size: 13px;
    min-height: 36px;
}

/* Mobile-friendly search and filter controls */
@media (max-width: 768px) {
    .search-filter-controls {
        flex-direction: column;
        gap: 12px;
        align-items: stretch;
        margin-bottom: 20px;
    }
    
    .search-filter-controls .form-input,
    .search-filter-controls .form-select {
        min-height: 44px;
        padding: 12px 16px;
        font-size: 16px; /* Prevents zoom on iOS */
        border-radius: 8px;
        min-width: auto;
        width: 100%;
    }
    
    .search-filter-controls .btn {
        min-height: 44px;
        padding: 12px 20px;
        font-size: 14px;
        border-radius: 8px;
        font-weight: 600;
    }
}

/* Dashboard Stats */
.dashboard-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.stat-card {
    background: white;
    padding: 25px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 20px;
    transition: var(--transition);
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: white;
}

.stat-card:nth-child(1) .stat-icon {
    background: var(--primary-color);
}

.stat-card:nth-child(2) .stat-icon {
    background: var(--info-color);
}

.stat-card:nth-child(3) .stat-icon {
    background: var(--warning-color);
}

.stat-card:nth-child(4) .stat-icon {
    background: var(--success-color);
}

.stat-info h3 {
    font-size: 32px;
    font-weight: 700;
    color: var(--secondary-color);
    margin-bottom: 5px;
}

.stat-info p {
    color: #666;
    font-size: 14px;
}

/* Recent Activity */
.recent-activity {
    background: white;
    padding: 25px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
}

.recent-activity h3 {
    color: var(--secondary-color);
    margin-bottom: 20px;
    font-size: 20px;
}

.activity-log {
    max-height: 300px;
    overflow-y: auto;
}

.no-activity {
    color: #666;
    text-align: center;
    padding: 20px;
}

/* Categories Grid */
.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.category-card {
    background: white;
    padding: 25px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.category-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 15px;
}

.category-title {
    color: var(--secondary-color);
    font-size: 18px;
    font-weight: 600;
}

.category-actions {
    display: flex;
    gap: 10px;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 12px;
}

/* Enhanced Action Buttons for Tables */
.table-actions {
    display: flex;
    gap: 4px;
    align-items: center;
    justify-content: center;
}

.action-btn {
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 14px;
    position: relative;
    overflow: hidden;
}

.action-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.2);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.action-btn:hover::before {
    opacity: 1;
}

.action-btn.edit-btn {
    background: linear-gradient(135deg, #6c757d, #5a6268);
    color: white;
    box-shadow: 0 2px 8px rgba(108, 117, 125, 0.3);
}

.action-btn.edit-btn:hover {
    background: linear-gradient(135deg, #5a6268, #495057);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(108, 117, 125, 0.4);
}

.action-btn.delete-btn {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    color: white;
    box-shadow: 0 2px 8px rgba(231, 76, 60, 0.3);
}

.action-btn.delete-btn:hover {
    background: linear-gradient(135deg, #c0392b, #a93226);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(231, 76, 60, 0.4);
}

.action-btn:active {
    transform: translateY(0) scale(0.95);
}

/* Category Actions Enhancement */
.category-actions {
    display: flex;
    gap: 4px;
    align-items: center;
}

.category-actions .action-btn {
    width: 28px;
    height: 28px;
    font-size: 12px;
}

/* Mobile optimizations for action buttons */
@media (max-width: 768px) {
    .action-btn {
        width: 36px;
        height: 36px;
        font-size: 15px;
        border-radius: 10px;
    }
    
    .category-actions .action-btn {
        width: 32px;
        height: 32px;
        font-size: 13px;
    }
    
    .table-actions {
        gap: 6px;
    }
    
    .category-actions {
        gap: 6px;
    }
}

/* Tooltip for action buttons */
.action-btn[title] {
    position: relative;
}

.action-btn[title]:hover::after {
    content: attr(title);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: var(--secondary-color);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    white-space: nowrap;
    z-index: 1000;
    margin-bottom: 4px;
    opacity: 0;
    animation: tooltipFadeIn 0.2s ease forwards;
}

@keyframes tooltipFadeIn {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(4px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

.category-description {
    color: #666;
    margin-bottom: 15px;
    line-height: 1.5;
}

.category-stats {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 15px;
    border-top: 1px solid var(--border-color);
}

.item-count {
    color: var(--primary-color);
    font-weight: 600;
}

/* Items Table */
.items-table-container {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.items-table {
    width: 100%;
    border-collapse: collapse;
}

.items-table th,
.items-table td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.items-table th {
    background: #f8f9fa;
    font-weight: 600;
    color: var(--secondary-color);
}

.items-table tbody tr:hover {
    background: #f8f9fa;
}

.clickable-row {
    cursor: pointer;
    transition: all 0.2s ease;
}

.clickable-row:hover {
    background: #f8f9fa !important;
    transform: scale(1.01);
}

.clickable-row:active {
    background: #e9ecef !important;
    transform: scale(1);
}

/* Mobile-friendly items table */
@media (max-width: 768px) {
    .items-table-container {
        border-radius: 12px;
        overflow: hidden;
    }
    
    .items-table {
        font-size: 14px;
    }
    
    .items-table th,
    .items-table td {
        padding: 16px 12px;
        vertical-align: top;
    }
    
    .items-table th {
        font-size: 13px;
        font-weight: 600;
        text-transform: uppercase;
        letter-spacing: 0.5px;
    }
    
    .clickable-row {
        min-height: 60px;
    }
    
    .clickable-row:active {
        transform: scale(0.98);
        transition: transform 0.1s ease;
    }
    
    /* Make action buttons more touch-friendly */
    .items-table .btn {
        min-height: 40px;
        min-width: 40px;
        padding: 10px;
        margin: 2px;
        border-radius: 8px;
    }
    
    /* Better spacing for status badges */
    .status-badge {
        padding: 6px 12px;
        border-radius: 16px;
        font-size: 11px;
        font-weight: 600;
        margin: 2px 0;
        display: inline-block;
    }
}

.status-badge {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
}

.status-featured {
    background: rgba(243, 156, 18, 0.1);
    color: var(--warning-color);
}

.status-vegetarian {
    background: rgba(39, 174, 96, 0.1);
    color: var(--success-color);
}

.status-regular {
    background: rgba(108, 117, 125, 0.1);
    color: #6c757d;
}

/* Forms */
.form-input,
.form-select {
    padding: 10px;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 14px;
    transition: var(--transition);
}

.form-input:focus,
.form-select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.1);
}

.restaurant-form {
    background: white;
    padding: 30px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--secondary-color);
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 14px;
    transition: var(--transition);
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.1);
}

.form-group small {
    color: #666;
    font-size: 12px;
    margin-top: 5px;
    display: block;
}

/* Checkbox Group */
.checkbox-group {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-weight: 500;
}

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

.checkmark {
    width: 20px;
    height: 20px;
    border: 2px solid var(--border-color);
    border-radius: 4px;
    position: relative;
    transition: var(--transition);
}

.checkbox-label input[type="checkbox"]:checked + .checkmark {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.checkbox-label input[type="checkbox"]:checked + .checkmark::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 12px;
    font-weight: bold;
}

/* Enhanced Dietary Options */
.dietary-options {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.dietary-option {
    position: relative;
}

.dietary-option input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.dietary-label {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
    min-width: 180px;
    position: relative;
    overflow: hidden;
}

.dietary-label::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: left 0.5s;
}

.dietary-label:hover::before {
    left: 100%;
}

.dietary-label:hover {
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(212, 175, 55, 0.2);
}

.dietary-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    transition: all 0.3s ease;
}

.vegetarian-label .dietary-icon {
    background: rgba(39, 174, 96, 0.1);
    color: var(--success-color);
}

.featured-label .dietary-icon {
    background: rgba(243, 156, 18, 0.1);
    color: var(--warning-color);
}

.dietary-text {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.dietary-title {
    font-weight: 600;
    color: var(--secondary-color);
    font-size: 14px;
}

.dietary-desc {
    font-size: 12px;
    color: #666;
}

.dietary-check {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 24px;
    height: 24px;
    border: 2px solid var(--border-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    color: white;
    background: transparent;
    transition: all 0.3s ease;
}

/* Checked state */
.dietary-option input[type="checkbox"]:checked + .dietary-label {
    border-color: var(--primary-color);
    background: rgba(212, 175, 55, 0.05);
    box-shadow: 0 4px 12px rgba(212, 175, 55, 0.15);
}

.dietary-option input[type="checkbox"]:checked + .dietary-label .dietary-check {
    background: var(--primary-color);
    border-color: var(--primary-color);
    transform: scale(1.1);
}

.dietary-option input[type="checkbox"]:checked + .vegetarian-label .dietary-icon {
    background: var(--success-color);
    color: white;
    transform: scale(1.1);
}

.dietary-option input[type="checkbox"]:checked + .featured-label .dietary-icon {
    background: var(--warning-color);
    color: white;
    transform: scale(1.1);
}

.dietary-option input[type="checkbox"]:checked + .dietary-label .dietary-title {
    color: var(--primary-color);
    font-weight: 700;
}

/* Mobile optimizations for dietary options */
@media (max-width: 768px) {
    .dietary-options {
        flex-direction: column;
        gap: 12px;
    }
    
    .dietary-label {
        min-width: auto;
        width: 100%;
        padding: 16px;
    }
    
    .dietary-icon {
        width: 44px;
        height: 44px;
        font-size: 20px;
    }
    
    .dietary-title {
        font-size: 15px;
    }
    
    .dietary-desc {
        font-size: 13px;
    }
    
    .dietary-check {
        width: 28px;
        height: 28px;
        font-size: 14px;
    }
}

/* Backup Actions */
.backup-actions {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.backup-card {
    background: white;
    padding: 30px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    text-align: center;
}

.backup-card h3 {
    color: var(--secondary-color);
    margin-bottom: 10px;
    font-size: 20px;
}

.backup-card p {
    color: #666;
    margin-bottom: 20px;
    line-height: 1.5;
}

/* Modals */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    animation: fadeIn 0.3s ease;
}

.modal.show {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding: 0;
}

.modal-content {
    background: white;
    border-radius: 16px 16px 0 0;
    box-shadow: var(--shadow-hover);
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    animation: slideUpFromBottom 0.3s ease;
    margin: 0;
}

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

.modal-header h3 {
    color: var(--secondary-color);
    font-size: 20px;
    font-weight: 600;
}

.modal-close {
    background: none;
    border: none;
    font-size: 20px;
    color: #666;
    cursor: pointer;
    padding: 5px;
    border-radius: 50%;
    transition: var(--transition);
}

.modal-close:hover {
    background: #f8f9fa;
    color: var(--danger-color);
}

.modal-form {
    padding: 30px;
}

.modal-body {
    padding: 30px;
}

.modal-actions {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
    padding: 20px 30px;
    border-top: 1px solid var(--border-color);
    background: #f8f9fa;
}

/* Sticky Modal Actions */
.sticky-actions {
    position: sticky;
    bottom: 0;
    z-index: 10;
    margin-top: auto;
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    background: rgba(248, 249, 250, 0.95);
}

/* Adjust modal content to accommodate sticky actions */
.modal-content {
    display: flex;
    flex-direction: column;
    max-height: 90vh;
}

.modal-form {
    flex: 1;
    overflow-y: auto;
    padding-bottom: 10px;
}

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}

.loading-spinner {
    text-align: center;
    color: var(--primary-color);
}

.loading-spinner i {
    font-size: 48px;
    margin-bottom: 20px;
}

.loading-spinner p {
    font-size: 16px;
    font-weight: 500;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 3000;
}

.toast {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-hover);
    padding: 15px 20px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 15px;
    min-width: 300px;
    animation: slideInRight 0.3s ease;
    border-left: 4px solid var(--success-color);
}

.toast.error {
    border-left-color: var(--danger-color);
}

.toast.warning {
    border-left-color: var(--warning-color);
}

.toast.info {
    border-left-color: var(--info-color);
}

.toast-icon {
    font-size: 20px;
}

.toast.success .toast-icon {
    color: var(--success-color);
}

.toast.error .toast-icon {
    color: var(--danger-color);
}

.toast.warning .toast-icon {
    color: var(--warning-color);
}

.toast.info .toast-icon {
    color: var(--info-color);
}

.toast-message {
    flex: 1;
    font-weight: 500;
}

.toast-close {
    background: none;
    border: none;
    font-size: 16px;
    color: #666;
    cursor: pointer;
    padding: 5px;
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

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

/* Bottom Navigation for Mobile */
.admin-bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    border-top: 1px solid var(--border-color);
    padding: 8px 0;
    z-index: 100;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
}

.admin-bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #666;
    padding: 8px 4px;
    transition: var(--transition);
    flex: 1;
    min-height: 60px;
    position: relative;
}

.admin-bottom-nav-item:hover {
    color: var(--primary-color);
    background: rgba(212, 175, 55, 0.1);
}

.admin-bottom-nav-item.active {
    color: var(--primary-color);
    background: rgba(212, 175, 55, 0.1);
}

.admin-bottom-nav-item.active::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 3px;
    background: var(--primary-color);
    border-radius: 0 0 3px 3px;
}

.admin-bottom-nav-icon {
    font-size: 18px;
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
}

.admin-bottom-nav-text {
    font-size: 11px;
    font-weight: 500;
    text-align: center;
    line-height: 1.2;
}

/* Enhanced Mobile Navigation Toggle */
.mobile-nav-toggle {
    display: none;
    background: linear-gradient(135deg, #ffffff, #f8f9fa);
    border: 2px solid var(--border-color);
    font-size: 20px;
    color: var(--secondary-color);
    cursor: pointer;
    padding: 12px;
    border-radius: 12px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
}

.mobile-nav-toggle::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(212, 175, 55, 0.1), transparent);
    transition: left 0.5s;
}

.mobile-nav-toggle:hover {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(212, 175, 55, 0.3);
}

.mobile-nav-toggle:hover::before {
    left: 100%;
}

.mobile-nav-toggle:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(212, 175, 55, 0.2);
}

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

.mobile-nav-overlay.active {
    display: block;
}

/* Enhanced Mobile-First Responsive Design */

/* Touch-friendly interactions */
.btn, .nav-link, .admin-bottom-nav-item, .modal-close, .toast-close {
    min-height: 44px; /* Apple's recommended touch target size */
    min-width: 44px;
    touch-action: manipulation; /* Prevents double-tap zoom */
}

/* Improved touch feedback */
.btn:active, .nav-link:active, .admin-bottom-nav-item:active {
    transform: scale(0.98);
    transition: transform 0.1s ease;
}

/* Swipe gesture support for mobile navigation */
.admin-sidebar {
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.admin-sidebar.mobile-active {
    transform: translateX(0);
}

/* Enhanced mobile navigation */
.mobile-nav-toggle {
    position: relative;
    z-index: 1001;
}


/* Improved scrolling for mobile */
.admin-content, .modal-content, .items-table-container {
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
}

/* Enhanced bottom navigation with better touch targets */
.admin-bottom-nav {
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.95);
}

.admin-bottom-nav-item {
    position: relative;
    overflow: hidden;
}

.admin-bottom-nav-item::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(212, 175, 55, 0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.3s ease, height 0.3s ease;
}

.admin-bottom-nav-item:active::before {
    width: 100px;
    height: 100px;
}

/* Responsive breakpoints with mobile-first approach */
@media (max-width: 480px) {
    /* Extra small devices */
    .admin-header-content {
        padding: 8px 12px;
        gap: 8px;
    }

    .admin-logo h1 {
        font-size: 18px;
    }

    .admin-actions {
        gap: 6px;
    }

    .btn {
        padding: 10px 14px;
        font-size: 14px;
        border-radius: 6px;
    }

    .section-header h2 {
        font-size: 22px;
    }

    .stat-card {
        padding: 16px;
        border-radius: 12px;
    }

    .category-card, .backup-card {
        padding: 16px;
        border-radius: 12px;
    }

    .modal-content {
        border-radius: 16px 16px 0 0;
        position: fixed;
        bottom: 0;
        max-height: 90vh;
    }

    .modal-header, .modal-form, .modal-body, .modal-actions {
        padding: 12px 16px;
    }
}

@media (max-width: 768px) {
    /* Tablet and mobile devices */
    .admin-header-content {
        padding: 10px 15px;
        flex-wrap: wrap;
        gap: 10px;
    }

    .admin-logo h1 {
        font-size: 20px;
    }

    .admin-actions {
        flex-wrap: wrap;
        gap: 8px;
    }

    .btn {
        padding: 12px 16px;
        font-size: 14px;
        border-radius: 8px;
    }

    .admin-main {
        padding-bottom: 80px; /* Space for bottom navigation */
    }

    .admin-content {
        padding: 20px 15px;
        width: 100%;
        margin-left: 0;
    }

    .admin-bottom-nav {
        display: flex;
    }

    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
        margin-bottom: 20px;
    }

    .section-header h2 {
        font-size: 24px;
    }

    .section-actions {
        width: 100%;
        flex-wrap: wrap;
        gap: 10px;
    }

    .form-input, .form-select {
        font-size: 16px; /* Prevents zoom on iOS */
        padding: 14px 12px;
        border-radius: 8px;
    }

    .dashboard-stats {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: 15px;
    }

    .stat-card {
        padding: 20px;
        border-radius: 12px;
    }

    .stat-icon {
        width: 50px;
        height: 50px;
        font-size: 20px;
    }

    .stat-info h3 {
        font-size: 24px;
    }

    .categories-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .category-card {
        padding: 20px;
        border-radius: 12px;
    }

    .form-row {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .backup-actions {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .backup-card {
        padding: 20px;
        border-radius: 12px;
    }

    .modal {
        padding: 10px;
        align-items: flex-end;
    }

    .modal-content {
        max-width: none;
        width: 100%;
        max-height: 90vh;
        margin: 0;
        border-radius: 16px 16px 0 0;
    }

    .modal-header, .modal-form, .modal-body, .modal-actions {
        padding: 15px 20px;
    }

    .checkbox-group {
        flex-direction: column;
        gap: 12px;
    }

    .items-table-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        border-radius: 12px;
    }

    .items-table {
        min-width: 600px;
        font-size: 14px;
    }

    .items-table th, .items-table td {
        padding: 12px 10px;
    }

    .toast-container {
        top: 10px;
        right: 10px;
        left: 10px;
    }

    .toast {
        min-width: auto;
        width: 100%;
        margin-bottom: 8px;
        border-radius: 12px;
    }
}

@media (min-width: 769px) {
    /* Desktop and larger tablets */
    .admin-bottom-nav {
        display: none;
    }

    .admin-main {
        padding-bottom: 0;
    }
}

/* Landscape orientation optimizations */
@media (max-width: 768px) and (orientation: landscape) {
    .admin-header-content {
        padding: 8px 15px;
    }

    .admin-content {
        padding: 15px;
    }

    .dashboard-stats {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }

    .stat-card {
        padding: 15px;
    }

    .modal-content {
        max-height: 85vh;
    }
}

/* High DPI displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .btn, .nav-link, .admin-bottom-nav-item {
        border-width: 0.5px;
    }
}

/* Reduced motion preferences */
@media (prefers-reduced-motion: reduce) {
    .admin-sidebar, .modal, .toast, .btn, .nav-link, .admin-bottom-nav-item {
        transition: none;
    }

    .admin-bottom-nav-item::before {
        transition: none;
    }
}

@media (max-width: 480px) {
    .login-container {
        padding: 30px 20px;
    }

    .admin-logo h1 {
        font-size: 20px;
    }

    .section-header h2 {
        font-size: 24px;
    }

    .btn {
        padding: 8px 16px;
        font-size: 13px;
    }

    .stat-card {
        padding: 20px;
    }

    .stat-icon {
        width: 50px;
        height: 50px;
        font-size: 20px;
    }

    .stat-info h3 {
        font-size: 24px;
    }

    .toast {
        min-width: 250px;
    }
}

/* Image Upload Styles */
.image-upload-section {
    margin-bottom: 20px;
}

.image-upload-tabs {
    display: flex;
    border-bottom: 2px solid var(--border-color);
    margin-bottom: 20px;
}

.image-tab {
    flex: 1;
    padding: 12px 20px;
    background: #f8f9fa;
    border: none;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: #666;
    transition: all 0.3s ease;
    border-bottom: 3px solid transparent;
}

.image-tab:first-child {
    border-radius: 8px 0 0 0;
}

.image-tab:last-child {
    border-radius: 0 8px 0 0;
}

.image-tab.active {
    background: white;
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

.image-tab:hover:not(.active) {
    background: #e9ecef;
    color: var(--secondary-color);
}

.image-tab-content {
    display: none;
    padding: 20px;
    background: white;
    border-radius: 0 0 8px 8px;
    border: 1px solid var(--border-color);
    border-top: none;
}

.image-tab-content.active {
    display: block;
}

/* URL Input Tab */
.url-input-group {
    display: flex;
    gap: 10px;
    align-items: flex-end;
}

.url-input-group .form-group {
    flex: 1;
    margin-bottom: 0;
}

.url-preview-btn {
    padding: 12px 20px;
    background: var(--info-color);
    color: white;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: var(--transition);
    white-space: nowrap;
}

.url-preview-btn:hover {
    background: #2980b9;
    transform: translateY(-1px);
}

/* File Upload Tab */
.file-upload-area {
    border: 2px dashed var(--border-color);
    border-radius: var(--border-radius);
    padding: 40px 20px;
    text-align: center;
    background: #f8f9fa;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
}

.file-upload-area:hover {
    border-color: var(--primary-color);
    background: rgba(212, 175, 55, 0.05);
}

.file-upload-area.dragover {
    border-color: var(--primary-color);
    background: rgba(212, 175, 55, 0.1);
    transform: scale(1.02);
}

.file-upload-icon {
    font-size: 48px;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.file-upload-text {
    color: var(--secondary-color);
    font-size: 16px;
    font-weight: 500;
    margin-bottom: 8px;
}

.file-upload-hint {
    color: #666;
    font-size: 14px;
    margin-bottom: 15px;
}

.file-upload-input {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.file-select-btn {
    padding: 10px 20px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: var(--transition);
}

.file-select-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

/* Image Preview */
.image-preview-container {
    margin-top: 20px;
    display: none;
}

.image-preview-container.show {
    display: block;
}

.image-preview {
    position: relative;
    display: inline-block;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    background: white;
    padding: 10px;
}

.image-preview img {
    max-width: 200px;
    max-height: 200px;
    width: auto;
    height: auto;
    border-radius: 6px;
    display: block;
}

.image-preview-overlay {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.7);
    border-radius: 50%;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.image-preview-overlay:hover {
    background: var(--danger-color);
}

.image-preview-overlay i {
    color: white;
    font-size: 14px;
}

.image-info {
    margin-top: 10px;
    padding: 8px 12px;
    background: #f8f9fa;
    border-radius: 6px;
    font-size: 12px;
    color: #666;
}

.image-info strong {
    color: var(--secondary-color);
}

/* Loading states */
.image-loading {
    display: none;
    text-align: center;
    padding: 20px;
    color: var(--primary-color);
}

.image-loading.show {
    display: block;
}

.image-loading i {
    font-size: 24px;
    margin-bottom: 10px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Error states */
.image-error {
    display: none;
    padding: 15px;
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
    border-radius: var(--border-radius);
    margin-top: 15px;
}

.image-error.show {
    display: block;
}

.image-error i {
    margin-right: 8px;
}

/* Mobile optimizations */
@media (max-width: 768px) {
    .image-upload-tabs {
        flex-direction: column;
        border-bottom: none;
    }
    
    .image-tab {
        border-radius: 0;
        border-bottom: 1px solid var(--border-color);
    }
    
    .image-tab:first-child {
        border-radius: 8px 8px 0 0;
    }
    
    .image-tab:last-child {
        border-radius: 0 0 8px 8px;
        border-bottom: none;
    }
    
    .image-tab.active {
        border-bottom: 1px solid var(--border-color);
        border-left: 4px solid var(--primary-color);
    }
    
    .image-tab-content {
        border-radius: 8px;
        border: 1px solid var(--border-color);
        margin-top: 10px;
    }
    
    .url-input-group {
        flex-direction: column;
        gap: 15px;
    }
    
    .url-input-group .form-group {
        margin-bottom: 0;
    }
    
    .url-preview-btn {
        width: 100%;
        padding: 14px 20px;
    }
    
    .file-upload-area {
        padding: 30px 15px;
    }
    
    .file-upload-icon {
        font-size: 36px;
    }
    
    .file-upload-text {
        font-size: 15px;
    }
    
    .file-select-btn {
        width: 100%;
        padding: 12px 20px;
    }
    
    .image-preview img {
        max-width: 150px;
        max-height: 150px;
    }
}