/* ========================================
   GP MEMBERS SECTION FIX
   Grid layout for Home Page (Rows layout)
   ======================================== */

/* Replaces old marquee with a Grid */
.home-members-grid,
.members-grid-home {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 2rem;
    padding: 1rem 0;
    justify-content: center;
}

/* Member Card styling for Home Page Grid */
.member-card-home {
    background: white;
    border-radius: 16px;
    padding: 2rem 1.5rem;
    box-shadow: 0 4px 16px rgba(74, 93, 78, 0.12);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid rgba(197, 160, 89, 0.1);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.member-card-home:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 32px rgba(74, 93, 78, 0.2);
    border-color: var(--accent-gold);
}

/* Profile Frame */
.profile-frame-home {
    width: 110px;
    height: 110px;
    border-radius: 50%;
    margin: 0 auto 1.2rem;
    border: 4px solid var(--accent-gold);
    padding: 3px;
    background: white;
    box-shadow: 0 4px 12px rgba(197, 160, 89, 0.2);
}

.profile-img-home {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

.profile-info-home h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--nav-dark-green);
    margin-bottom: 0.5rem;
    line-height: 1.3;
}

.profile-info-home p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 0;
}

/* Inner Page Spacer Fix */
.inner-page-spacer {
    height: 140px;
    /* Adjusted space below fixed header */
    width: 100%;
    display: block;
}

/* Section Headings Styling */
.section-heading {
    position: relative;
    display: inline-block;
    padding-bottom: 10px;
    margin-bottom: 20px;
}

.heading-underline {
    width: 60px;
    height: 4px;
    background: var(--accent-gold);
    margin: 0 auto 30px;
    border-radius: 2px;
}

/* Emergency Helpline Cards - Refined */
.emergency-ref-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.emergency-item-ref {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border-top: 5px solid #ef4444;
    /* Red top border */
    transition: transform 0.3s ease;
}

.emergency-item-ref:hover {
    transform: translateY(-5px);
}

.em-icon {
    font-size: 3rem;
    margin-bottom: 15px;
    display: inline-block;
}

.em-number {
    font-size: 2rem;
    font-weight: 800;
    color: #b91c1c;
    margin-top: 5px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .home-members-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }

    .inner-page-spacer {
        height: 160px;
    }
}

/* Global Mobile Fixes */
img {
    max-width: 100%;
    height: auto;
}

@media (max-width: 768px) {
    .section-heading {
        font-size: 1.5rem;
    }

    .container,
    .max-w-container {
        padding-left: 1rem;
        padding-right: 1rem;
    }
}