/* ======================================================================= */
/*                         PRODUCT CARD STANDARD LAYOUT                    */
/* ======================================================================= */

/* 
Goals for this revision:
- All product cards should be exactly the same width and height regardless of content.
- Card elements (image, main text, features, button) must always remain visible; nothing should be cut off or overlapped.
- Cards remain vertically and horizontally visually balanced.
- Clean, readable layout for desktop and mobile.
- Consistent spacing and alignment for all cards.
- Feature list always visible, never overflows or is trimmed.
*/

.product-card {
    background-color: var(--background-color);
    border: 1.5px solid var(--border-color);
    border-radius: 12px;
    padding: 0;
    text-align: center;
    transition: transform 0.3s cubic-bezier(.4,1.3,0.6,1), box-shadow 0.3s;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-sizing: border-box;
    position: relative; 
    overflow: hidden;
    min-height: 520px; /* Set a fixed minimum height */
    max-height: 520px; /* Set a fixed maximum height */
}

.uniform-card-size {
    background-color: var(--background-color);
    border: 1.5px solid var(--border-color);
    border-radius: 12px;
    padding: 0; /* Remove padding, will be handled by inner containers */
    text-align: center; /* Changed from left to center for consistency */
    transition: transform 0.3s cubic-bezier(.4,1.3,0.6,1), box-shadow 0.3s;
    display: flex;
    flex-direction: column;
    justify-content: space-between; /* space-between to push button to bottom */
    box-sizing: border-box;
    position: relative; 
    overflow: hidden;
}

.product-card-content {
    padding: 1.5rem 1.2rem;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    flex-grow: 1;
    gap: 1rem;
    min-width: 0;
    min-height: 0;
}

.product-card:hover {
    transform: translateY(-8px) scale(1.01);
    box-shadow: 0 12px 32px rgba(0,0,0,0.13);
}

.uniform-card-size:hover {
    transform: translateY(-8px) scale(1.01);
    box-shadow: 0 12px 32px rgba(0,0,0,0.13);
}

.product-logo {
    max-height: 54px;
    max-width: 80%;
    width: auto !important;
    height: auto;
    object-fit: contain;
    margin: 0 auto 0.2rem auto;
    display: block;
    flex-shrink: 0;
}

.product-card p {
    color: var(--text-muted-color);
    font-size: clamp(1rem, 2.5vw, 1.1rem);
    margin: 0;
    text-align: center;
    line-height: 1.5;
    flex-shrink: 0;
    min-height: 44px;
    max-width: 99%;
    word-break: break-word;
}

.uniform-card-size p {
    color: var(--text-muted-color);
    font-size: clamp(1rem, 2.5vw, 1.1rem);
    margin: 0;
    text-align: center;
    line-height: 1.5;
    flex-shrink: 0;
    min-height: 44px;
    max-width: 99%;
    word-break: break-word;
}

.features-list {
    list-style: none;
    padding: 0;
    margin: 0;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    width: 100%;
    min-width: 0;
    overflow-y: auto; /* Allow scrolling for overflow on small cards */
}

.features-list li {
    text-align: left;
    padding-left: 30px;
    position: relative;
    font-size: clamp(0.95rem, 2vw, 1.05rem);
    line-height: 1.4;
    font-weight: 500;
    color: var(--text-color);
    word-break: break-word;
    min-width: 0;
}

.features-list li::before {
    content: '✔';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    color: #00aaff;
    font-size: 1.14em;
    font-weight: bold;
}

.learn-more-btn {
    padding: 1rem 1.5rem;
    margin: 1.2rem auto;
    width: 85%;
    font-size: clamp(1rem, 2.5vw, 1.1rem);
    background-color: var(--primary-color);
    color: #fff;
    border-radius: 8px;
    border: none;
    font-family: inherit;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 4px 23px 0 #00aaff18;
    outline: none;
    display: block;
    text-align: center;
    text-decoration: none; /* Ensure no underline for links */
    flex-shrink: 0;
    transition: background 0.22s, transform 0.11s;
}

.learn-more-btn:focus,
.learn-more-btn:hover {
    background-color: #0077b6;
    transform: translateY(-2px) scale(1.025);
    color: #fff; /* Ensure text stays white on hover */
    text-decoration: none; /* Prevent underline on hover */
}

/* Responsive adjustments */
@media (max-width: 1200px) {
    .product-card {
       min-height: 500px;
       max-height: 500px;
    }
    
    .product-card-content {
        padding: 1.1rem 0.8rem 1.15rem 0.8rem;
        gap: 0.8rem;
    }
    
    .learn-more-btn {
        width: 90%;
        margin: 1rem auto;
    }
}

@media (max-width: 992px) {
    .product-card {
        min-height: 480px;
        max-height: 480px;
    }
    
    .product-card-content {
        padding: 1rem 0.7rem;
        gap: 0.7rem;
    }
    
    .learn-more-btn {
        width: 95%;
        padding: 0.9rem 1.2rem;
    }
}

@media (max-width: 768px) {
    .product-card {
        min-height: 450px;
        max-height: 450px;
    }
    
    .product-card-content {
        padding: 0.9rem 0.5rem;
        gap: 0.6rem;
    }
    
    .learn-more-btn {
        width: 98%;
        margin: 0.8rem auto;
        font-size: 16px; /* Prevent zoom on iPhone */
        min-height: 44px; /* iOS touch target */
    }
    
    .features-list {
        gap: 0.5rem;
    }
    
    .features-list li {
        font-size: 14px;
        line-height: 1.3;
    }
}

/* iPhone optimizations */
@media (max-width: 480px) {
    .product-card {
        min-height: auto;
        max-height: none;
        margin-bottom: 1rem;
    }
    .features-list{overflow: visible;}
    .product-card-content {
        font-size: 16px;
        padding: 0.8rem 0.4rem;
        gap: 0.5rem;
    }
    
    .product-logo {
        max-height: 48px;
        margin-bottom: 0.5rem;
    }
    
    .product-card p {
        font-size: 16px;
        line-height: 1.4;
        min-height: 40px;
    }
    
    .learn-more-btn {
        width: 100%;
        padding: 1rem;
        margin: 0.6rem auto;
        font-size: 16px;
        min-height: 48px;
        border-radius: 8px;
    }
    
    .features-list {
        gap: 0.4rem;
    }
    
    .features-list li {
        padding-left: 25px;
    }
    
    .features-list li::before {
        font-size: 1rem;
        left: 2px;
    }
}

/* iPhone SE and smaller */
@media (max-width: 375px) {
    .product-card {
        min-height: 400px;
        max-height: 400px;
    }
    
    .product-card-content {
        padding: 0.7rem 0.3rem;
        gap: 0.4rem;
    }
    
    .product-logo {
        max-height: 42px;
    }
    
    .product-card p {
        font-size: 13px;
        min-height: 36px;
    }
    
    .features-list li {
        font-size: 12px;
        padding-left: 22px;
    }
    
    .learn-more-btn {
        padding: 0.9rem;
        font-size: 15px;
    }
}

/* Product card themes */
#product-globforce { border-top: 6px solid #00aaff; }
#product-ontime { border-top: 6px solid #00aaff; }
#product-gcc-connect { border-top: 6px solid #00aaff; }
#product-globpos { border-top: 6px solid #28a745; }
#product-keyshare { border-top: 6px solid #6f42c1; }
#product-idaglob { border-top: 6px solid #fd7e14; }