/* General Styles */
body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background: linear-gradient(-45deg, #1a1a1a, #2c3e50, #34495e, #1a1a1a);
    background-size: 400% 400%;
    animation: gradientBG 15s ease infinite;
    overflow: hidden;
}

@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Floating Bubbles */
.bubbles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    overflow: hidden;
}

.bubbles span {
    position: absolute;
    bottom: -100px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    animation: float 10s linear infinite;
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.2);
    width: 20px;
    height: 20px;
}

@keyframes float {
    0% { transform: translateY(0) scale(0); opacity: 0; }
    20% { opacity: 1; }
    100% { transform: translateY(-100vh) scale(1); opacity: 0; }
}

/* Containers */
.home-container, .container, .admin-container, .user-container {
    background: rgba(255, 255, 255, 0.9);
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    z-index: 1;
    width: 90%;
    max-width: 800px;
    max-height: 80vh; /* Added scrollbar */
    overflow-y: auto; /* Added scrollbar */
    margin: 20px auto;
}

/* Login Wrapper */
.login-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    position: relative;
    z-index: 1;
    width: 100%;
}

/* Login Container */
.login-container {
    background: rgba(255, 255, 255, 0.9);
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    width: 90%;
    max-width: 400px;
    margin: 20px auto; /* Center the container */
    max-height: 80vh; /* Added scrollbar */
    overflow-y: auto; /* Added scrollbar */
}

/* Form Elements */
.form-group {
    position: relative;
    top: 10px;
    margin-bottom: 20px;
}

.form-group i {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #666;
    font-size: 18px;
    z-index: 1;
}

.form-group input, .form-group select {
    width: 90%;
    padding: 12px 12px 12px 40px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 16px;
    transition: all 0.3s ease;
}

.form-group input:focus, .form-group select:focus {
    border-color: #3498db;
    box-shadow: 0 0 8px rgba(52, 152, 219, 0.2);
}

/* Buttons */
.animated-button, .login-btn {
    background: #3498db;
    color: white;
    padding: 15px 30px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    font-size: 18px;
    width: 100%;
    margin: 10px;
}

.animated-button:hover, .login-btn:hover {
    background: #2980b9;
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

/* Food Cards */
.food-card {
    width: 200px;
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 15px;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    animation: fadeIn 0.5s ease-out;
}

.food-card img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 8px;
}

.food-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Cart System */
#cart {
    background: #f9f9f9;
    padding: 20px;
    border-radius: 8px;
    margin-top: 20px;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    border-bottom: 1px solid #ddd;
}

.remove-btn {
    background: #e74c3c;
    color: white;
    padding: 5px 10px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

/* Bill Modal */
.bill-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.2);
    z-index: 1000;
    max-width: 500px;
    width: 90%;
}

.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
}

@keyframes slideIn {
    from { transform: translate(-50%, 100%); opacity: 0; }
    to { transform: translate(-50%, -50%); opacity: 1; }
}

.bill-item {
    animation: itemAppear 0.3s ease-out;
}

@keyframes itemAppear {
    from { opacity: 0; transform: translateX(-20px); }
    to { opacity: 1; transform: translateX(0); }
}

/* Payment Notification */
.payment-notification {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: #4CAF50;
    color: white;
    padding: 15px 25px;
    border-radius: 5px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 1001;
    animation: slideDown 0.5s ease-out, fadeOut 1s ease 2.5s;
}

@keyframes slideDown {
    from { top: -100px; }
    to { top: 20px; }
}

@keyframes fadeOut {
    from { opacity: 1; }
    to { opacity: 0; }
}

.payment-notification i {
    font-size: 24px;
}

/* Payment Success */
.payment-success {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    animation: slideDown 0.5s ease-out;
    z-index: 1001;
}

.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 999;
}

/* Print Styles */
.print-btn {
    background: #2196F3 !important;
    margin-left: 10px;
}

.payment-btn {
    background: #4CAF50 !important;
    margin-top: 20px;
}

/* File Upload */
.file-input-wrapper {
    position: relative;
}

.file-label {
    display: block;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    cursor: pointer;
}

/* Icons */
i {
    font-size: 20px;
}

/* Bill Header */
.bill-header {
    text-align: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #eee;
}

.item-row {
    display: flex;
    justify-content: space-between;
    margin: 15px 0;
    padding: 10px;
    background: #f9f9f9;
    border-radius: 5px;
}

@keyframes scaleUp {
    from { transform: scale(0.9); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

/* Background Graphic */
.graphic {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: url('https://www.transparenttextures.com/patterns/food.png'); /* Food-themed background */
    opacity: 0.1;
}

/* Custom Scrollbar */
.home-container::-webkit-scrollbar,
.container::-webkit-scrollbar,
.admin-container::-webkit-scrollbar,
.user-container::-webkit-scrollbar,
.login-container::-webkit-scrollbar {
    width: 8px;
}

.home-container::-webkit-scrollbar-track,
.container::-webkit-scrollbar-track,
.admin-container::-webkit-scrollbar-track,
.user-container::-webkit-scrollbar-track,
.login-container::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.home-container::-webkit-scrollbar-thumb,
.container::-webkit-scrollbar-thumb,
.admin-container::-webkit-scrollbar-thumb,
.user-container::-webkit-scrollbar-thumb,
.login-container::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

.home-container::-webkit-scrollbar-thumb:hover,
.container::-webkit-scrollbar-thumb:hover,
.admin-container::-webkit-scrollbar-thumb:hover,
.user-container::-webkit-scrollbar-thumb:hover,
.login-container::-webkit-scrollbar-thumb:hover {
    background: #555;
}