body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f5f5f5;
}

.store-header {
    position: relative;
    text-align: center;
    overflow: hidden;
    height: 170px;
}

.header-image {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
}

.header-content {
    position: absolute;
    top: 2px;
    left: 4px;
    z-index: 2;
    background: rgba(0, 0, 0, 0.5);
    color: white;
    height: 95%;
    width: 97%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border-style: ridge;
    border-color: #166fab;
    border-radius: 15px;
}

.shop-name {
    margin: 3px 2px;
    text-align: center;
    font-size: 1.8rem;
    font-weight: bold;
    font-family: 'Montserrat', sans-serif;
}

.status-container {
    margin-top: 4px;
    width: 80%;
    align-items: center;
    display: flex;
    height: 50px;
    margin-left: 160px;
}

.shop-status.open {
    color: #25D366;
    background-color: #111823;
    font-weight: bold;
    border-radius: 4px;
    width: 45%;
}

.shop-status.closed {
    color: #e74c3c;
    background-color: white;
    font-weight: bold;
    border-radius: 4px;
    width: 45%;
}

.shop-status.temp {
    color: red;
    background-color: white;
    font-weight: bold;
    border-radius: 4px;
    width: 45%;
}

.contact-btn {
    padding: 0.5rem;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: opacity 0.2s;
}

.phone-btn { background-color: blue; color: white; }
.whatsapp-btn { background-color: #25D366; color: white; }
.location-btn { background-color: #f70101; color: white; }

.icon-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: 1.30rem;
    color: white;
    text-decoration: none;
}

.header-icons {
    display: flex;
    gap: 25px;
    position: absolute;
    right: 15px;
    top: 70px;
}

.form-container {
    max-width: 1200px;
    margin: 2px auto;
    padding: 2px;
    background-color: #ffffff;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
    padding-bottom: 80px;
}

.categories-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
}

.category-card {
    position: relative;
    overflow: hidden;
    min-height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    border-style: ridge;
    cursor: pointer;
}

.category-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: 1;
}

.category-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.category-card h3 {
    position: relative;
    z-index: 2;
    color: white;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
    font-weight: bold;
    font-family: 'Lora', serif;
    font-size: 25px;
}

.category-title {
    text-align: center;
    margin: 5px 0;
    color: black;
    font-size: 1.4rem;
    font-family: 'Courier New', Courier, monospace;
}

.products-section {
    display: none;
}

.back-to-categories {
 display: flex;
 margin: 2px 0;
 padding: 0px 0px;
 background: #ebebeb;
 border: 1px solid #b2bcd7;
 border-radius: 5px;
 border-width: 2px;
 cursor: pointer;
 width: 95%;
 margin-left: 8px;
 text-align: center;
 font-weight: bold;
 align-items: center;
}						    }


.back-to-categories:hover {
    background: #e9ecef;
}

.products-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 80px;
    padding: 4px 10px;
}

.product-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    border: 1px solid #ddd;
    border-radius: 8px;
    background-color: #ffffff;
    overflow: hidden;
    padding: 10px;
    height: auto;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.product-header {
    width: 100%;
    margin-bottom: 8px;
    border-bottom: 1px solid #ddd;
    padding-bottom: 13px;
}

.product-title {
    font-family: 'Times New Roman', Times, serif;
    font-size: 1.1rem;
    font-weight: 600;
    margin: -15px;
    color: #ffffff;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.product-body {
    display: flex;
    width: 100%;
}

.product-image {
    flex: 0 0 50px;
    height: 100px;
    margin-right: 0px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f9f9f9;
    border-radius: 6px;
    cursor: pointer;
}

.product-image img {
    max-width: 115px;
    max-height: 115px;
    object-fit: cover;
    border-radius: 4px;
}

.product-details {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 85px;
    margin-left: 65px;
    margin-right: 12px;
    justify-content: center;
}

.product-info {
    align-items: center;
    width: 70%;
    gap: 15px;
    margin-top: 14px;
}

.product-price {
    font-size: 1.2rem;
    margin-bottom: 12px;
    background: #a3cae3;
    width: 100%;
    text-align: center;
    border-radius: 4px;
}

.available-stock {
   color: green;
   font-size: small;
   width: 70px;
   font-weight: bold;
   margin-left: 30px;
   margin-top: -10px;
}

.out-of-stock {
    color: red;
    font-size: small;
}

.quantity-controls {
    display: flex;
    align-items: center;
    gap: 0px;
    margin-top: auto;
    width: 117%;
    margin-left: 0px;
}

.quantity-btn {
    width: 30px;
    height: 30px;
    border: none;
    background: #5355da;
    color: white;
    font-size: 1.2rem;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
    justify-content: center;
}

.quantity-btn:active {
    transform: scale(0.95);
    background: #45a049;
}

.quantity-input {
    width: 30px;
    height: 30px;
    text-align: center;
    padding: 5px;
    font-size: 1.1rem;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-weight: bold;
    -webkit-appearance: none;
    margin: 0 5px;
}

.details-button {
    display: inline-block;
    width: 35px;
    height: 40px;
    padding: 0px 10px;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
}

.details-button:hover {
    background-color: #2980b9;
}

.success-message {
    color: #4CAF50;
    text-align: center;
    margin: 20px 0;
    padding: 15px;
    border: 1px solid #4CAF50;
    border-radius: 4px;
}

.shop-message {
    text-align: center;
    padding: 2rem;
    font-size: 1.2rem;
    color: #666;
    border: 2px dashed #ddd;
    border-radius: 8px;
    margin: 20px 0;
    width: 85%;
    margin-left: 10px;
}

.disabled-field {
    opacity: 0.7;
    cursor: not-allowed;
}

.search-container {
    margin: 6px 8px;
    display: flex;
    gap: 7px;
    height: 44px; 
}

.search-box {
    flex: 1;
    padding: 12px 15px;
    border: 2px solid #ddd;
    border-radius: 30px;
    font-size: 16px;
    background-color: #f8f8f8;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.1);
}

.search-button {
    padding: 12px 20px;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 30px;
    cursor: pointer;
    font-weight: bold;
}

.search-button:hover {
    background-color: #2980b9;
}

.no-results {
    text-align: center;
    padding: 20px;
    font-size: 18px;
    color: #777;
}

.floating-total {
	position: fixed;
    bottom: 20px;
    color: white;
    left: 25px;
    width: 20%;
    background-color: #0d6efd;
    padding: 10px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    display: block;
    align-items: center;
    z-index: 999;
    height: 45px;
}

.total-amount {
    font-family: 'Arial', sans-serif;
    font-size: 18px;
    font-weight: bold;
    color: white;
}

.cart-icon-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
    background: #0d6efd;
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    cursor: pointer;
}

.cart-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background-color: #dc3545;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
}

.cart-popup {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 95%;
    max-width: 500px;
    max-height: 80vh;
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    z-index: 1001;
    overflow: hidden;
    flex-direction: column;
}

.cart-popup-header {
    padding: 4px 20px;
    background-color: #0d6efd;
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 35px;
}

.cart-popup-close {
    background: none;
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
}

.cart-popup-body {
    padding: 15px;
    overflow-y: auto;
    flex-grow: 1;
}

.cart-popup-footer {
    padding: 6px;
    border-top: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cart-item {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #000000;
}

.cart-item-image {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 5px;
    margin-right: 15px;
}

.cart-item-details {
    flex-grow: 1;
}

.cart-item-name {
    font-weight: bold;
    margin-bottom: 5px;
}

.cart-item-price {
    color: #0d6efd;
    font-weight: bold;
}

.cart-item-controls {
    display: flex;
    align-items: center;
}

.cart-quantity-btn {
    width: 25px;
    height: 25px;
    border: 1px solid #ddd;
    background-color: #f8f9fa;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.cart-quantity-input {
    width: 25px;
    height: 21px;
    text-align: center;
    border: 1px solid #ddd;
    margin: 0 5px;
    border-radius: 4px;
}

.cart-item-remove {
    margin-left: 15px;
    color: #dc3545;
    cursor: pointer;
}

.cart-empty-message {
    text-align: center;
    padding: 20px;
    color: #6c757d;
}

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

.checkout-btn {
    background-color: #0d6efd;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
}

.checkout-btn:disabled {
    background-color: #6c757d;
    cursor: not-allowed;
}

.image-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    z-index: 1001;
    align-items: center;
    justify-content: center;
}

.image-modal-content {
    max-width: 90%;
    max-height: 90%;
    position: relative;
    text-align: center;
}

.image-modal-content img {
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 5px;
}

.image-modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 40px;
    cursor: pointer;
    color: white;
    z-index: 1002;
}

.image-modal-caption {
    color: white;
    font-size: 1.2rem;
    margin-top: 15px;
    text-align: center;
}

.product-details-content {
    white-space: pre-line;
    line-height: 1.6;
    font-size: 1rem;
    color: #333;
    font-family: inherit;
}

.modal-content {
    border-radius: 15px;
    border: none;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.modal-header {
    background: linear-gradient(135deg, #4361ee, #3f37c9);
    color: white;
    border-top-left-radius: 15px !important;
    border-top-right-radius: 15px !important;
    border: none;
    padding: 1rem 1.5rem;
}

.modal-body {
    padding: 1.5rem;
    max-height: 60vh;
    overflow-y: auto;
    line-height: 1.6;
    font-size: 1rem;
    color: #333;
}

.modal-footer {
    border-top: 1px solid #dee2e6;
    padding: 1rem 1.5rem;
}

.btn-close-white {
    filter: invert(1) grayscale(100%) brightness(200%);
}

@media (max-width: 480px) {
    .product-card {
        padding: 10px;
        border-width: medium;
        border-color: #769796;
        border-style: inset;
    }

    .product-image {
        flex: 0 0 50px;
        height: 100px;
    }

    .product-title {
        font-size: 1.0rem;
        background: #07526d;
        border-radius: 5px;
        padding: 4px;
    }

    .product-price {
        font-size: 1.1rem;
        margin-bottom: 12px;
        font-family: 'Times New Roman', Times, serif;
        font-weight: bold;
    }

    .quantity-btn {
        font-size: 0.85rem;
        padding: 4px 8px;
    }

    .quantity-input {
        width: 35px;
        padding: 4px;
        font-size: 0.85rem;
    }

    .header-icons {
        position: static;
        justify-content: center;
        margin-top: 18px;
        margin-bottom: 16px;
        gap: 25px;
    }

    .shop-name {
        font-size: 1.4rem;
        font-family: 'Times New Roman', Times, serif;
        background-color: #2b2e31;
        border-width: 2px;
        border-radius: 10px;
        border-style: outset;
        margin-top:20px;
        width: 95%;
    }

    .form-container {
        padding-bottom: 2px;
    }
    
    .status-container {
        margin-left: 0;
        width: 100%;
        justify-content: center;
    }

    .floating-total {
        width: 22%;
        padding: 20px;
        height: 25px;
    }

    .categories-container {
    /*    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); */
        gap: 20px;
    }
    
    .category-card h3 {
        font-size: 20px;
    }
}
