/* =========================
   INDIAN MARKETPLACE THEME
========================= */

:root {
    --primary: #2874f0;     /* Flipkart Blue */
    --accent: #ff9f00;      /* Indian Orange */
    --success: #138808;     /* India Green */
    --bg-light: #f1f3f6;
}

body {
    background: var(--bg-light);
    font-family: "Segoe UI", Roboto, Arial, sans-serif;
}

/* =========================
   HEADER
========================= */

.navbar {
    background: var(--primary) !important;
}

.navbar-brand {
    color: #fff !important;
    font-weight: 600;
}

.navbar a.btn {
    border-color: #fff;
    color: #fff;
}

/* =========================
   CATEGORY CARDS
========================= */

.category-box {
    border-radius: 12px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.category-box:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.12);
}

.category-box img {
    max-height: 48px;
}

/* =========================
   PRODUCT CARD
========================= */

.product-card {
    border-radius: 14px;
    overflow: hidden;
    transition: 0.3s;
    background: #fff;
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.12);
}

.product-card img {
    height: 180px;
    object-fit: contain;
    padding: 10px;
}

.price {
    font-size: 18px;
    font-weight: bold;
    color: var(--success);
}

.mrp {
    text-decoration: line-through;
    font-size: 13px;
    color: #777;
}

.discount-badge {
    background: #e53935;
    color: #fff;
    font-size: 12px;
    padding: 2px 6px;
    border-radius: 4px;
}

.add-btn {
    background: var(--accent);
    color: #000;
    font-weight: 600;
    border-radius: 8px;
}

.add-btn:hover {
    background: #fb8c00;
}

/* =========================
   CART / CHECKOUT
========================= */

.table th {
    background: #fafafa;
}

.checkout-box {
    background: #fff;
    padding: 20px;
    border-radius: 14px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

/* =========================
   BUTTONS
========================= */

.btn-primary {
    background: var(--primary);
    border: none;
}

.btn-success {
    background: var(--success);
    border: none;
}

/* =========================
   FOOTER
========================= */

footer {
    background: #fff;
    padding: 15px;
    text-align: center;
    box-shadow: 0 -2px 8px rgba(0,0,0,0.08);
}

#searchBox {
    border-radius: 2px;
}

#searchResults .list-group-item:hover {
    background: #f1f3f6;
}

.error-text {
    color: #d93025;
    font-size: 13px;
    margin-top: 4px;
}

/* =========================
   CHECKOUT POLISH
========================= */

/* Checkout container */
<div class="checkout-container">

}

/* Section cards */
.section {
    background: #fff;
    padding: 18px;
    border-radius: 12px;
    margin-bottom: 16px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.06);
}

/* Section headings */
.section h4 {
    font-size: 16px;
    margin-bottom: 12px;
    color: #0A1F44;
    font-weight: 600;
}

/* Inputs */
.section input,
.section select,
.section textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
}

.section input:focus,
.section select:focus {
    border-color: var(--primary);
    outline: none;
    box-shadow: 0 0 0 2px rgba(40,116,240,0.1);
}

/* Radio buttons spacing */
.section label {
    display: block;
    margin-bottom: 8px;
    cursor: pointer;
}

/* Order summary rows */
<div class="section">
<h4>Order Summary</h4>

<?php foreach ($items as $i): ?>
<div class="order-row">
    <span><?= htmlspecialchars($i['name']) ?> × <?= $i['quantity'] ?></span>
    <span class="price">₹<?= number_format($i['price']*$i['quantity'],2) ?></span>
</div>
<?php endforeach; ?>

<div class="order-row">
    <span>GST</span>
    <span class="price">₹<?= number_format($gst_total,2) ?></span>
</div>

<div class="order-row order-total">
    <span>Total</span>
    <span class="price">₹<?= number_format($total_amount,2) ?></span>
</div>
</div>


/* Place order button */
.place-order-btn {
    width: 100%;
    padding: 14px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 10px;
    background: var(--accent);
    border: none;
    color: #000;
}

.place-order-btn:hover {
    background: #fb8c00;
}

/* Mobile fix */
@media (max-width: 576px) {
    .section {
        padding: 14px;
    }
}
.place-order-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}
/* =========================
   SLIDE ANIMATION
========================= */

.slide-section {
    overflow: hidden;
    max-height: 0;
    transition: max-height 0.35s ease, opacity 0.25s ease;
    opacity: 0;
}

.slide-section.active {
    max-height: 600px; /* enough for address form */
    opacity: 1;
}

/* Slight motion feel */
.slide-section .section {
    transform: translateY(-8px);
    transition: transform 0.3s ease;
}

.slide-section.active .section {
    transform: translateY(0);
}

<div id="addressWrap" class="slide-section">
    <div class="section" id="addressBox">
        <h4>Delivery Address</h4>

        <input type="text" name="name" placeholder="Full Name" required>

        <input type="tel" name="mobile" id="mobile" placeholder="Mobile Number"
               maxlength="10" oninput="validateMobile(this)" required>

        <div id="mobileError" class="error-text"></div>

        <input type="text" name="address" placeholder="Address" required>

        <input type="text" name="city" id="city" placeholder="City" readonly required>

        <input type="tel" name="pincode" id="pincode" placeholder="Pincode"
               maxlength="6" oninput="validatePincode(this)" required>

        <div id="pincodeError" class="error-text"></div>
    </div>
</div>
<div id="pickupWrap" class="slide-section">
    <div class="section" id="pickupBox">
        <h4>Pickup Slot</h4>
        <select name="pickup_slot">
            <option value="">Select Pickup Slot</option>
            <?php foreach ($slots as $s): ?>
            <option value="<?= htmlspecialchars($s) ?>">
                <?= htmlspecialchars($s) ?>
            </option>
            <?php endforeach; ?>
        </select>
    </div>
</div>
