/* =========================
   NAVBAR CLEAN INLINE (NO DROPDOWN)
========================= */

.navbar {
    background: #ffffff;
    border-bottom: 1px solid #e5e7eb;
    box-shadow: 0 4px 20px rgba(0,0,0,0.05);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-container {
    max-width: 1200px;
    margin: auto;
    padding: 12px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Logo */
.logo {
    font-size: 22px;
    font-weight: 700;
    color: #2563eb;
    text-decoration: none;
}

/* ICON CONTAINER */
.nav-links {
    display: flex;
    align-items: center;
    gap: 18px;              /* Space between icons */
}

/* ICON BUTTON */
.nav-icon,
.user-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all .25s ease;
}

/* SVG */
.nav-icon svg,
.user-icon svg {
    width: 22px;
    height: 22px;
    stroke: #334155;
    stroke-width: 1.8;
    fill: none;
    transition: .25s ease;
}

/* Hover */
.nav-icon:hover,
.user-icon:hover {
    background: rgba(37,99,235,0.08);
    transform: translateY(-2px);
}

.nav-icon:hover svg,
.user-icon:hover svg {
    stroke: #2563eb;
}

/* Active */
.nav-icon.active svg,
.user-icon.active svg {
    stroke: #2563eb;
}

/* REMOVE HAMBURGER COMPLETELY */
.hamburger {
    display: none !important;
}

/* =========================
   MOBILE — STILL INLINE
========================= */
@media (max-width: 768px) {

    .nav-container {
        padding: 10px 15px;
    }

    .nav-links {
        gap: 12px;
        flex-direction: row;      /* 🔒 FORCE INLINE */
        position: static;         /* 🔒 REMOVE DROPDOWN */
        display: flex !important; /* 🔒 ALWAYS VISIBLE */
        background: transparent;
        width: auto;
        padding: 0;
        box-shadow: none;
    }

    .nav-icon,
    .user-icon {
        width: 38px;
        height: 38px;
    }

    .nav-icon svg,
    .user-icon svg {
        width: 20px;
        height: 20px;
    }
}


/* =========================
   RESET & BASE
========================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Segoe UI", Roboto, Arial, sans-serif;
    background: #f4f6f9;
    color: #1f2937;
}

a {
    text-decoration: none;
    color: inherit;
}

.container {
    max-width: 1200px;
    margin: auto;
    padding: 20px;
}

/* User dropdown */
.user-dropdown {
    position: relative;
}

.user-name {
    font-weight: 600;
    cursor: pointer;
}

.dropdown-menu {
    position: absolute;
    top: 36px;
    right: 0;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.08);
    display: none;
    min-width: 150px;
}

.dropdown-menu a {
    display: block;
    padding: 10px 14px;
}

.dropdown-menu a:hover {
    background: #f3f4f6;
}

.user-dropdown:hover .dropdown-menu {
    display: block;
}

/* =========================
   FILTERS (INDEX PAGE)
========================= */
.filters-row {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    background: #fff;
    padding: 15px;
    border-radius: 12px;
    box-shadow: 0 6px 18px rgba(0,0,0,0.06);
    margin-bottom: 20px;
}

.filter {
    flex: 1;
    min-width: 200px;
}

.filter input,
.filter select {
    width: 100%;
    padding: 12px;
    border-radius: 8px;
    border: 1px solid #d1d5db;
}


/* =========================
   MODERN PRICE RANGE SLIDER
========================= */
/*.price-slider-wrapper {
    position: relative;
    width: 100%;
}

input[type="range"] {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 8px;
    border-radius: 10px;
    background: linear-gradient(
        to right,
        #2563eb 0%,
        #2563eb var(--range-percent, 100%),
        #e5e7eb var(--range-percent, 100%),
        #e5e7eb 100%
    );
    outline: none;
    transition: background 0.2s ease;
}

input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #ffffff;
    border: 4px solid #2563eb;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #ffffff;
    border: 4px solid #2563eb;
    cursor: pointer;
}

#priceTooltip {
    position: absolute;
    top: -36px;
    transform: translateX(-50%);
    background: #2563eb;
    color: #fff;
    padding: 5px 10px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
    pointer-events: none;
}

input[type="range"]:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}
*/
.price-slider-wrapper {
    position: relative;
    width: 100%;
    padding: 15px 0;
}

.slider-container {
    position: relative;
    width: 100%;
    height: 8px;
    display: flex;
    align-items: center;
}

.slider-container input[type="range"] {
    -webkit-appearance: none;
    position: absolute;
    width: 100%;
    height: 8px;
    border-radius: 4px;
    background: transparent;
    pointer-events: all;
    z-index: 2;
}

.slider-container input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #ffffff;
    border: 4px solid #2563eb;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
    position: relative;
    z-index: 3;
    transition: transform 0.2s;
}

.slider-container input[type="range"]::-moz-range-thumb {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #ffffff;
    border: 4px solid #2563eb;
    cursor: pointer;
    transition: transform 0.2s;
}

.range-highlight {
    position: absolute;
    height: 8px;
    border-radius: 4px;
    background: #2563eb;
    top: 0;
    z-index: 1;
    transition: left 0.2s ease, width 0.2s ease;
}

.price-values {
    margin-top: 8px;
    text-align: center;
    font-weight: 600;
    color: #2563eb;
}


/* =========================
   PROFILE PAGE
========================= */
.profile-container {
    display: flex;
    gap: 30px;
    padding: 20px;
    height: calc(100vh - 80px);
}

.profile-left, .profile-right {
    flex: 1;
    background: #f9f9f9;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    overflow-y: auto;
}

.profile-left h2, .profile-right h2 {
    margin-bottom: 20px;
    font-size: 24px;
    color: #007BFF;
}

.form-group {
    margin-bottom: 15px;
    display: flex;
    flex-direction: column;
}

.form-group label {
    margin-bottom: 5px;
    font-weight: 500;
    color: #333;
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 10px;
    border-radius: 8px;
    border: 1px solid #ccc;
    outline: none;
    font-size: 14px;
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

.btn-upload {
    background: #007BFF;
    color: #fff;
    font-size: 16px;
    padding: 12px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    width: 100%;
    margin-top: 10px;
    transition: background 0.3s ease;
}

.btn-upload:hover {
    background: #0056b3;
}

/* User products grid */
.profile-right .products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill,minmax(200px,1fr));
    gap: 20px;
}


/* =========================
   RESPONSIVE
========================= */
@media (max-width: 768px) {
    .filters-row {
        flex-direction: column;
    }

    .form-row {
        flex-direction: column;
    }

    .profile-container {
        flex-direction: column;
        padding: 15px;
    }

    .profile-left, .profile-right {
        max-height: unset;
    }

    .profile-left h2, .profile-right h2 {
        font-size: 20px;
    }

    .profile-right .products-grid {
        grid-template-columns: repeat(auto-fill,minmax(140px,1fr));
        gap: 12px;
    }
}

.media-grid {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

.media-thumb {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 6px;
}

.media-upload input {
    margin-top: 5px;
}


.media-preview-grid {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 10px;
}

.preview-thumb {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 6px;
    border: 1px solid #ddd;
}
.preview-thumb video { object-fit: cover; }

.product-card {
    background: #fff;
    padding: 12px;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 6px 15px rgba(0,0,0,0.05);
}

.product-card img,
.product-card video {
    width: 100%;
    height: 140px;
    object-fit: cover;
    border-radius: 6px;
}

.product-card button {
    margin-top: 6px;
    padding: 6px 10px;
    border-radius: 6px;
    border: none;
    cursor: pointer;
}

.btn-edit { background: #2563eb; color: #fff; }
.btn-edit:hover { background: #1e40af; }

.btn-delete { background: #ef4444; color: #fff; margin-left:5px; }
.btn-delete:hover { background: #b91c1c; }


/* =========================
   AUTH CONTAINER
========================= */
.auth-container {
    min-height: calc(100vh - 70px);
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f4f6f9;
    padding: 20px;
}

.auth-card {
    background: #fff;
    width: 100%;
    max-width: 480px;
    padding: 40px 30px;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.08);
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.auth-card h2 {
    text-align: center;
    font-size: 28px;
    margin-bottom: 10px;
    color: #2563eb;
}

.auth-card form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.form-row {
    display: flex;
    gap: 15px;
}

.form-row input {
    flex: 1;
}

.auth-card input {
    padding: 12px;
    border-radius: 8px;
    border: 1px solid #d1d5db;
    font-size: 14px;
    outline: none;
    transition: all 0.2s ease;
}

.auth-card input:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37,99,235,0.15);
}

/* Buttons */
.btn-primary {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 18px rgba(37,99,235,0.3);
}

.btn-primary:active {
    transform: scale(0.98);
}

/* Auth links */
.auth-link {
    text-align: center;
    font-size: 14px;
    color: #555;
}

.auth-link a {
    color: #2563eb;
    font-weight: 600;
    text-decoration: none;
}

.auth-link a:hover {
    text-decoration: underline;
}

/* Error / Success Alerts */
.alert {
    padding: 12px 15px;
    border-radius: 8px;
    font-size: 14px;
}

.alert.error {
    background: #fee2e2;
    color: #b91c1c;
}

.alert.success {
    background: #dcfce7;
    color: #166534;
}

/* Responsive */
@media (max-width: 500px) {
    .auth-card {
        padding: 30px 20px;
    }
    .auth-card h2 {
        font-size: 24px;
    }
    .form-row {
        flex-direction: column;
    }
}
.modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.6);
    justify-content: center;
    align-items: center;
    z-index: 999;
}

.modal-box {
    background: white;
    padding: 20px;
    width: 420px;
    border-radius: 12px;
}

/* ===============================
   LOGIN REQUIRED MODAL
=============================== */
.login-required-box {
    text-align: center;
    padding: 30px;
    border-radius: 16px;
    max-width: 420px;
}

.login-required-box h2 {
    margin-bottom: 10px;
    font-size: 22px;
}

.login-required-box p {
    color: #6b7280;
    margin-bottom: 20px;
}

.login-actions {
    display: flex;
    justify-content: center;
    gap: 15px;
}

.btn-secondary {
    background: #e5e7eb;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
}

.btn-secondary:hover {
    background: #d1d5db;
}


.close {
    float: right;
    cursor: pointer;
    font-size: 20px;
}

.media-preview {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.media-thumb {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 6px;
}


.upload-form input,
.upload-form select,
.upload-form textarea {
    width: 100%;
    padding: 10px;
    margin-bottom: 10px;
    border-radius: 8px;
    border: 1px solid #ddd;
}

.btn-upload {
    background: #2563eb;
    color: #fff;
    padding: 10px;
    border-radius: 8px;
    border: none;
    cursor: pointer;
}

.card-buttons {
    display: flex;
    gap: 10px;
}

.edit-btn {
    background: #facc15;
    border: none;
    padding: 6px 10px;
    border-radius: 6px;
    cursor: pointer;
}

.delete-btn {
    background: #ef4444;
    color: white;
    border: none;
    padding: 6px 10px;
    border-radius: 6px;
    cursor: pointer;
}

.modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.6);
    justify-content: center;
    align-items: center;
    z-index: 999;
}

.modal-box {
    background: white;
    padding: 20px;
    width: 420px;
    border-radius: 12px;
}

.media-thumb {
    width: 80px;
    height: 80px;
    object-fit: cover;
    margin: 5px;
    border-radius: 6px;
}

input:disabled,
select:disabled {
    background-color: #e0e0e0;
    color: #777;
    cursor: not-allowed;
}

input:disabled::placeholder {
    color: #aaa;
}
.notifications-link {
    position: relative;
    display: inline-block;
    color: #1f2937;
    font-weight: 600;
    text-decoration: none;
}

.notification-badge {
    position: absolute;
    top: -6px;
    right: -10px;
    background: #ef4444;
    color: #fff;
    font-size: 12px;
    font-weight: bold;
    border-radius: 50%;
    padding: 2px 6px;
    min-width: 18px;
    text-align: center;
}
 
 
 /* Small Clean Modal */
.edit-modal-small {
    width: 450px;
    max-height: 85vh;
    overflow-y: auto;
    background: #fff;
    padding: 20px;
    border-radius: 12px;
    animation: popIn .25s ease-out;
}

@keyframes popIn {
    from { transform: scale(.9); opacity: 0; }
    to   { transform: scale(1); opacity: 1; }
}

/* Carousel */
.carousel-container {
    position: relative;
    width: 100%;
    height: 230px;
    overflow: hidden;
    margin-bottom: 15px;
    border-radius: 10px;
    background: #f4f4f4;
}

.carousel {
    display: flex;
    gap: 10px;
    transition: transform 0.3s ease-in-out;
}

.carousel img,
.carousel video {
    height: 220px;
    border-radius: 10px;
    object-fit: cover;
}

/* Buttons */
.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: #00000066;
    color: white;
    border: none;
    font-size: 22px;
    padding: 6px 10px;
    cursor: pointer;
    border-radius: 50%;
}

.carousel-btn.left { left: 10px; }
.carousel-btn.right { right: 10px; }


/* =====================================================
   FIXED EDIT MODAL — NEVER RESIZES
===================================================== */
#editProductModal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.6);
    justify-content: center;
    align-items: center;
    z-index: 999;
}

#editProductModal .modal-content {
    width: 480px;
    height: 600px;              /* 🔒 FIXED HEIGHT */
    max-height: 600px;
    background: #fff;
    border-radius: 14px;
    padding: 20px;
    overflow: hidden;           /* 🔒 PREVENT GROW */
    display: flex;
    flex-direction: column;
}

/* Keep content scrollable, not modal */
#editProductModal form {
    flex: 1;
    overflow-y: auto;
    padding-right: 6px;
}

/* =====================================================
   CAROUSEL — SMALL & FIXED
===================================================== */
.carousel-container {
    position: relative;
    width: 100%;
    height: 180px;              /* 🔒 FIXED */
    overflow: hidden;
    border-radius: 10px;
    background: #f3f4f6;
}

.carousel {
    display: flex;
    gap: 10px;
    transition: transform 0.3s ease-in-out;
}

.carousel-item {
    width: 160px;
    height: 160px;              /* 🔒 FIXED */
    flex-shrink: 0;
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
    position: relative;
}

/* Images & videos NEVER affect layout */
.carousel-item img,
.carousel-item video {
    width: 100%;
    height: 100%;
    object-fit: cover;          /* 🔒 KEY */
}

/* =====================================================
   MEDIA DELETE BUTTON
===================================================== */
.media-delete {
    position: absolute;
    top: 6px;
    right: 6px;
    background: rgba(0,0,0,.7);
    color: #fff;
    font-size: 16px;
    padding: 4px 7px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 5;
}

/* =====================================================
   NEW MEDIA PREVIEW — SMALL & FIXED
===================================================== */
.media-preview {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.media-preview .media-item {
    width: 90px;
    height: 90px;
    position: relative;
}

.media-preview img,
.media-preview video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
}

.new-media-delete {
    position: absolute;
    top: 4px;
    right: 4px;
    background: #ef4444;
    color: #fff;
    font-size: 14px;
    padding: 2px 6px;
    border-radius: 50%;
    cursor: pointer;
}

/* =====================================================
   CLOSE BUTTON FIXED
===================================================== */
#closeModal {
    position: absolute;
    top: 12px;
    right: 14px;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
}

/* ===============================
   EXPIRED PRODUCT
================================ */
.product-card.expired {
    opacity: 0.45;
    filter: grayscale(100%);
    pointer-events: none;
    position: relative;
}

.product-card.expired::after {
    content: "Expired";
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.65);
    color: #fff;
    font-size: 18px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
}

/* =========================
   GLASS LOGIN MODAL
========================= */
.glass-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    backdrop-filter: blur(6px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    animation: fadeIn 0.3s ease forwards;
}

.glass-modal-content {
    background: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 18px;
    padding: 28px 32px;
    width: 90%;
    max-width: 380px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.35);
    text-align: center;
    color: #fff;
    animation: scaleIn 0.3s ease forwards;
}

.glass-modal-content h2 {
    margin-bottom: 10px;
    font-size: 22px;
    font-weight: 600;
}

.glass-modal-content p {
    font-size: 15px;
    opacity: 0.9;
    margin-bottom: 22px;
}

/* Buttons */
.glass-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
}

.glass-btn {
    padding: 10px 18px;
    border-radius: 12px;
    border: none;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.25s ease;
}

.glass-btn.primary {
    background: linear-gradient(135deg, #4f8cff, #6fa8ff);
    color: #fff;
}

.glass-btn.primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 20px rgba(79, 140, 255, 0.45);
}

.glass-btn.secondary {
    background: rgba(255,255,255,0.2);
    color: #fff;
}

.glass-btn.secondary:hover {
    background: rgba(255,255,255,0.28);
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0 }
    to { opacity: 1 }
}



.form-error{
    color:#dc2626;
    font-size:13px;
    display:block;
    margin-top:4px;
}


.info-btn{
background:#2563eb;
color:white;
border:none;
border-radius:50%;
width:22px;
height:22px;
cursor:pointer;
font-size:14px;
}

.info-popup{
position:fixed;
inset:0;
background:rgba(0,0,0,.6);
display:none;
align-items:center;
justify-content:center;
z-index:3000;
}

.info-content{
background:white;
padding:30px;
border-radius:16px;
width:400px;
max-width:90%;
position:relative;
}

.close-info{
position:absolute;
top:10px;
right:15px;
border:none;
background:none;
font-size:22px;
cursor:pointer;
}

.btn-modern{
background:linear-gradient(135deg,#2563eb,#1d4ed8);
color:white;
border:none;
padding:14px;
border-radius:12px;
font-weight:600;
cursor:pointer;
transition:.3s;
}

.btn-modern:hover{
transform:translateY(-2px);
box-shadow:0 10px 25px rgba(0,0,0,.2);
}

.auth-container {
    display:flex;
    justify-content:center;
    align-items:center;
    min-height:80vh;
    background:#f4f6f9;
}

.auth-card {
    background:#fff;
    padding:30px;
    width:400px;
    border-radius:10px;
    box-shadow:0 5px 20px rgba(0,0,0,0.08);
}

.auth-card h2 {
    margin-bottom:20px;
}

.auth-card input {
    width:100%;
    padding:12px;
    margin-bottom:15px;
    border:1px solid #ddd;
    border-radius:5px;
}

.btn-primary {
    width:100%;
    padding:12px;
    background:#007bff;
    border:none;
    color:#fff;
    border-radius:5px;
    cursor:pointer;
}

.btn-primary:hover {
    background:#0056b3;
}

.forgot-password {
    text-align:right;
    margin-bottom:10px;
}

.alert {
    padding:10px;
    margin-bottom:15px;
    border-radius:5px;
}

.alert.error { background:#ffe5e5; color:#b30000; }
.alert.success { background:#e6ffed; color:#006600; }

.forgot-password {
    margin: 10px 0;
    text-align: right;
}

.forgot-password a {
    color: #007BFF;
    text-decoration: none;
}

.forgot-password a:hover {
    text-decoration: underline;
}


.category-badge {
    position: absolute;
    top: 14px;
    left: 14px;
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 600;
    border-radius: 30px;
    color: white;
}

.badge-sale {
    background: #2563eb;
}

.badge-lease {
    background: #16a34a;
}


.location-text {
    text-align: center;
    font-size: 14px;
    color: #777;
    margin-top: 6px;
}

.price-text {
    text-align: center;
    font-weight: bold;
    font-size: 16px;
}

.range-highlight {
    transition: left 0.2s ease, width 0.2s ease;
}

/* =========================================
   PRODUCTS GRID
========================================= */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 20px;
}

/* =========================================
   PRODUCT CARD (CLEANED & FIXED)
========================================= */
.product-card {
    background: #ffffff;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0,0,0,0.08);
    transition: all .25s ease;
    position: relative;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 40px rgba(0,0,0,0.15);
}

/* =========================================
   IMAGE FIX (NO STRETCH EVER)
========================================= */
.product-thumb,
.product-card img,
.product-card video {
    width: 100%;
    aspect-ratio: 4 / 3;     /* Desktop ratio */
    object-fit: cover;       /* Prevent stretch */
    object-position: center;
    display: block;
}

/* =========================================
   CARD TEXT
========================================= */
.product-card h3 {
    font-size: 18px;
    margin: 12px 16px 6px;
    font-weight: 600;
}

.location-text {
    text-align: center;
    font-size: 14px;
    color: #777;
    margin-top: 6px;
}

.location-text::before {
    content: "📍 ";
}

.price-text {
    text-align: center;
    font-weight: bold;
    font-size: 16px;
    color: #2563eb;
    margin-bottom: 12px;
}

/* =========================================
   CATEGORY BADGE
========================================= */
.category-badge {
    position: absolute;
    top: 14px;
    left: 14px;
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 600;
    border-radius: 30px;
    color: white;
}

.badge-sale { background: #2563eb; }
.badge-lease { background: #16a34a; }

/* =========================================
   EXPIRED PRODUCT
========================================= */
.product-card.expired {
    opacity: 0.45;
    filter: grayscale(100%);
    pointer-events: none;
}

.product-card.expired::after {
    content: "Expired";
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.65);
    color: #fff;
    font-size: 18px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 18px;
}

/* =========================================
   MOBILE OPTIMIZATION
========================================= */
@media (max-width: 768px) {

    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
        gap: 14px;
    }

    .product-thumb,
    .product-card img,
    .product-card video {
        aspect-ratio: 1 / 1;   /* Square on mobile */
    }

    .product-card h3 {
        font-size: 15px;
        margin: 10px 12px 4px;
    }

    .location-text {
        font-size: 12px;
    }

    .price-text {
        font-size: 14px;
    }
}

/* Extra small phones */
@media (max-width: 420px) {
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
.duration-box{
    background:#f8f9fb;
    padding:15px;
    border-radius:10px;
    margin:15px 0;
    border:1px solid #e3e6ef;
}

.duration-box select{
    width:100%;
    padding:10px;
    border-radius:6px;
    border:1px solid #ccc;
}

.expiry-display{
    margin-top:10px;
    font-weight:600;
    color:#2b5cff;
}

.expiry-inline{
    color:#de5119;
    font-size:14px;
    font-weight:500;
}

/* EXPIRED CARD */
.product-card.expired {
    opacity: 0.55;
    filter: grayscale(80%);
    pointer-events: none;
    position: relative;
}

/* Optional expired label */
.product-card.expired::after {
    content: "EXPIRED";
    position: absolute;
    top: 10px;
    right: 10px;
    background: #c0392b;
    color: #fff;
    font-size: 12px;
    padding: 4px 8px;
    border-radius: 4px;
}

.sale-label {
    color: #27ae60;
    font-weight: 600;
}

.product-card.expired {
    opacity: 0.6;
    filter: grayscale(40%);
}

.expiry-text {
    margin-top: 4px;
}