body {
    font-family: Arial, sans-serif;
    margin: 0;
    background: #f9f9f9;
}

.page-title {
    text-align: center;
    padding: 25px 0;
    font-size: 32px;
    font-weight: bold;
}

/* ===============================
   PRODUCT GRID LAYOUT
================================== */
/* ============================================
   PRODUCT GRID (DESKTOP)
=============================================== */
.product-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(260px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

/* ============================================
   PRODUCT CARD
=============================================== */
.product-card {
    background: #fff;
    border-radius: 5px;
    padding: 15px;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transition: 0.3s ease;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.15);
}

/* PRODUCT IMAGE */
.product-card img {
    width: 220px;
    height: 150px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 12px;
}

/* TITLE */
.product-card h3 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 6px;
}

/* DESCRIPTION */
.product-card p {
    font-size: 14px;
    color: #444;
    margin-bottom: 12px;
}

/* READ MORE BUTTON */
.product-card .btn {
    background: #f17e01;
    color: #fff;
    padding: 10px 14px;
    border-radius: 6px;
    border: none;
    font-size: 14px;
    cursor: pointer;
    transition: 0.25s;
}

.product-card .btn:hover {
    background: #630188;
}
/* Prevent full card click issue */
.product-card {
    pointer-events: auto;
}

.product-card * {
    pointer-events: auto;
}

/* ONLY Read More button should trigger popup */
.read-more {
    pointer-events: auto !important;
}


/* ===================================================
    📱 MOBILE RESPONSIVE VIEW  
    430×932 | 414×896 | 412×915 | 390×844 | 375×812 | 360×744
====================================================== */
@media (max-width: 1024px) {
    .product-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 18px;
    }
}

@media (max-width: 768px) {
    .product-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }

    .product-card img {
        width: 180px;
        height: 130px;
    }
}

@media (max-width: 480px) {
    .product-grid {
        grid-template-columns: 2fr; /* SINGLE COLUMN */
        gap: 14px;
    }

    .product-card {
        padding: 10px;
        border-radius: 6px;
    }

    .product-card img {
        width: 100%;
        max-width: 280px;
        height: 150px;
        margin: 0 auto 12px;
    }

    .product-card h3 {
        font-size: 18px;
    }

    .product-card p {
        font-size: 13px;
    }

    .product-card .btn {
        font-size: 14px;
        padding: 10px 12px;
        width: 100%;
    }
}

/* ULTRA SMALL DEVICES - 360px, 375px, 390px */
@media (max-width: 390px) {
    .product-card img {
        height: 140px;
    }

    .product-card {
        padding: 8px;
    }

    .product-grid {
        gap: 12px;
    }
}

/* VERY SMALL DEVICES - 320px */
@media (max-width: 340px) {
    .product-card img {
        height: 130px;
    }

    .product-card h3 {
        font-size: 16px;
    }
}

/* ===========================
   OVERLAY (CENTER FIXED)
=========================== */
/* Hide modal by default */
#productModal {
    display: none !important;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

/* When JS adds .show, modal becomes visible */
#productModal.show {
    display: flex !important;
}


#productModal {
    display: none !important;
}
.modal.show {
    display: flex !important;
}



.modal {
    display: none;               /* JS will set to flex */
    position: fixed;
    top: 0; 
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.4);

    /* Center Popup */
    display: flex;
    justify-content: center;
    align-items: center;

    padding: 0;
    z-index: 1000;
}

/* ===========================
   POPUP BOX
=========================== */
.modal-box {
    width: 95%;
    max-width: 420px;       /* Wider */
    max-height: 70vh;       /* Shorter */
    overflow-y: auto;
    background: #fff;
    padding: 12px;
    border-radius: 12px;
    animation: popup 0.25s ease-out;
}

/* Close (X) Button */
.close {
    font-size: 20px;
    float: right;
    cursor: pointer;
    margin-bottom: 10px;
}

/* ===========================
   HEADER – Horizontal
=========================== */
.modal-header {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.modal-header img {
    width: 85px;
    height: 85px;
    border-radius: 10px;
    object-fit: cover;
}

.modal-text {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.modal-text h2 {
    font-size: 50px;
    text-align: center;
}


/* ===========================
   FEATURES SECTION
=========================== */
.features-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr); /* 2 items per row */
    gap: 6px;
    font-size: 12px;
    margin-top: 12px;
}

.features-grid li {
    list-style: none;
    background: #f4f4f4;
    padding: 5px 8px;
    border-radius: 6px;
}

/* ===========================
   TECH + SPEC ROW
=========================== */
.spec-wrapper {
    display: flex;
    justify-content: space-between;
    gap: 15px;
    margin-top: 14px;
}

.spec-box {
    width: 50%;
}

.spec-box h3 {
    font-size: 13px;
    margin-bottom: 4px;
}

.spec-table {
    width: 100%;
    font-size: 12px;
}

.spec-table td {
    padding: 4px 0;
    color: #444;
}

/* ===========================
   PACKAGING
=========================== */
#modalPackDetails {
    font-size: 12px;
    margin-top: 8px;
}

/* ===========================
   BUTTONS
=========================== */
/* Container */
.action-buttons {
    margin-top: 16px;
    display: flex;
    justify-content: center;
    gap: 18px;
}

/* Base Button Style */
.btn {
    padding: 12px 24px;        /* Medium size */
    font-size: 15px; 
    font-weight: 600;
    border-radius: 8px;
    text-decoration: none;
    display: inline-block;
    cursor: pointer;
    color: #fff;
    transition: 0.25s ease;
}

/* Red Button */
.btn.red {
    background: #f10707;
}

/* WhatsApp Green Button */
.btn.whatsapp {
    background: #25d366;
}

/* Hover Effect */
.btn:hover {
    opacity: 0.85;
    transform: translateY(-2px);
    color: #fff;
}

/* Click Effect */
.btn:active {
    transform: scale(0.96);
}

/* ===========================
   POPUP ANIMATION
=========================== */
@keyframes popup {
    from { transform: scale(0.8); opacity: 0; }
    to   { transform: scale(1);   opacity: 1; }
}

/* ===========================
   MOBILE RESPONSIVE
=========================== */
@media (max-width: 480px) {

    .modal-box {
        max-width: 96%;
        max-height: 75vh;
        padding: 10px;
    }

    /* Image top - text below */
    .modal-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .modal-header img {
        width: 120px;
        height: 120px;
    }

    .modal-text h2 {
        font-size: 16px;
        margin-top: 6px;
    }

    .action-buttons {
        flex-direction: column;
    }

    /* Tech + Spec vertical on mobile */
    .spec-wrapper {
        flex-direction: column;
        gap: 10px;
    }

    .spec-box {
        width: 100%;
    }
}
