:root {
    --main-color: #d4af37;
    --text-color: black;
}

/* ==================== */
/* RESET & BASE STYLES */
/* ==================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    line-height: 1.6;
    color: var(--text-color);
    font-family: "Ubuntu", sans-serif;
}

/* ==================== */
/* HERO SECTION */
/* ==================== */
.hero {
    background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url("assets/mainBg.jpg");
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    color: white;
    padding: 120px 20px;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 10px;
    min-height: 500px;
}

.rabatLogo {
    width: 100%;
    max-width: 700px;
}

.rabatLogo img {
    width: 100%;
}

.hero h1 {
    font-size: clamp(2rem, 5vw, 3.5rem);
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.hero p {
    font-size: clamp(1rem, 2vw, 1.3rem);
    max-width: 800px;
    margin: 0 auto 2rem;
    padding: 0 15px;
}

.cta-button {
    background: var(--text-color);
    color: var(--main-color);
    padding: 15px 40px;
    border: none;
    border-radius: 30px;
    font-size: clamp(0.9rem, 2vw, 1.1rem);
    font-weight: bold;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
}

.cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(255, 215, 0, 0.4);
}

/* ==================== */
/* CONTAINER & WELCOME */
/* ==================== */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 30px 20px;
    background: linear-gradient(rgba(0, 0, 0, 0.226), rgba(0, 0, 0, 0.13)), url(assets/aboutSectionData/shariah-complaint-banner-bg\ \(1\).webp);
    color: white;
    background-attachment: fixed;
}

.welcome {
    text-align: center;
}

.welcome h2 {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    margin-bottom: 1rem;
}

.welcome p {
    font-size: clamp(1rem, 2vw, 1.1rem);
    max-width: 900px;
    margin: 0 auto;
    line-height: 25px;
}

/* ==================== */
/* INVESTMENT CARDS */
/* ==================== */
.investment_cards {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 50px 20px;
    flex-wrap: wrap;
    gap: 30px;
}

.investment_cards .card {
    width: 100%;
    max-width: 600px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    line-height: 31px;
    box-shadow: 0 0 15px;
    padding: 12px;
    border-radius: 15px;
}

.investment_cards .card img {
    max-width: 335px;
    width: 100%;
    height: auto;
}

.investment_cards .card_edit img {
    max-width: 250px;
    width: 100%;
    height: auto;
}

.investment_cards .card h2 {
    font-size: clamp(1.5rem, 3vw, 2rem);
    margin: 15px 0;
}

.investment_cards .card p {
    font-weight: 700;
    font-size: clamp(1rem, 2vw, 1.2rem);
    text-align: center;
    padding: 0 15px;
    margin-bottom: 15px;
}

.investment_cards .card button {
    background-color: var(--main-color);
    color: var(--text-color);
    padding: 15px 25px;
    font-size: clamp(1rem, 2vw, 1.1rem);
    font-weight: 700;
    border-radius: 8px;
    margin: 10px 0;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
    max-width: 200px;
}

.investment_cards .card button:hover {
    color: #fff;
    background: linear-gradient(90deg, #aa9209 45%, #88650d);
}

/* ==================== */
/* WHY Ribat Enterprises SECTION */
/* ==================== */
.why-mb {
    background: white;
    padding: 60px 20px;
}

.section-title {
    text-align: center;
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    color: var(--text-color);
    margin-bottom: 3rem;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.feature-card {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-10px);
}

.feature-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    font-size: 2rem;
    color: var(--text-color);
}

.feature-icon img {
    width: 100px;
    max-width: 100%;
    height: auto;
}

.feature-card h3 {
    margin-bottom: 0.5rem;
    font-size: clamp(1.2rem, 2.5vw, 1.5rem);
}

.feature-card p {
    font-weight: 700;
    line-height: 1.6;
    font-size: clamp(0.9rem, 1.8vw, 1rem);
}

/* ==================== */
/* POPUP STYLES */
/* ==================== */
.popup-content {
    display: none;
}

.popup-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 999;
}

.popup-center {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 1000;
    background: black;
    color: #d4af37;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.3);
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    border: 2px solid #007b5e;
}

.popup-center .popup-close {
    position: absolute;
    top: 10px;
    right: 15px;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #666;
    line-height: 1;
}

.popup-center .popup-close:hover {
    color: #000;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* ==================== */
/* BOARD OF DIRECTORS */
/* ==================== */
.ceo-message {
    padding: 60px 20px;
    background: #f8f9fa;
    text-align: center;
}

.message-container {
    display: flex;
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
    flex-wrap: wrap;
    justify-content: center;
}

.messagesDiv {
    flex: 1;
    min-width: 300px;
    max-width: 500px;
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.messagesDiv:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);
}

.ceoImage {
    position: relative;
    width: 100%;
    height: 500px;
    overflow: hidden;
}

.ceoImage img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.directorImage img {
    width: 100%;
    height: 95%;
    object-fit: contain;
    background-color: #FFFFFF;
}

.messagesDiv:hover .ceoImage img {
    transform: scale(1.05);
}

.message-card {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.95), rgba(0, 0, 0, 0.85));
    color: white;
    padding: 30px;
    display: none;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.messagesDiv:hover .message-card {
    display: block;
    opacity: 1;
    animation: slideUp 0.4s ease forwards;
}

@keyframes slideUp {
    from {
        transform: translateY(20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.message-card h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: #ffc107;
    font-weight: 600;
}

.message-card h4 {
    font-size: 1.2rem;
    margin-bottom: 15px;
    color: #fff;
    font-weight: 500;
}

.message-card p {
    font-size: 0.95rem;
    line-height: 1.6;
    color: #e0e0e0;
}
.staff-images{
    background-color: #aa9209;
    display: inline-block;
    padding: 10px;
    border-radius: 8px;
    font-weight: 700;
    /* color: black; */
    text-align: center;
    position: static;
    margin: 20px;
}
.staff-images a{
    color: black;
    text-decoration: none;
}
.staff-images a:hover{
    color: white;
}
.staff-images:hover{
    background-color: #c8ac11;
    transition: 0.3s ;
    transform: scale(1.05);
}
/* ==================== */
/* VALUES SECTION */
/* ==================== */
.values {
    color: var(--text-color);
    padding: 60px 20px;
}

.values-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0px 20px;
}

.value-card {
    padding: 2rem;
    border-radius: 10px;
    text-align: left;
    position: relative;
}

.value-card img {
    width: 100px;
    max-width: 100%;
    height: auto;
    margin-bottom: 1rem;
}

.value-card .circle {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: var(--main-color);
    position: absolute;
    z-index: -1;
}

.value-card h3 {
    font-size: clamp(1.2rem, 2.5vw, 1.5rem);
    margin-bottom: 1rem;
    color: var(--text-color);
}

.value-card p {
    line-height: 1.8;
    font-size: clamp(0.9rem, 1.8vw, 1rem);
}

/* ==================== */
/* CONTACT SECTION */
/* ==================== */
.contact {
    background: var(--main-color);
    padding: 60px 20px;
    text-align: center;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    flex-wrap: wrap;
    gap: 40px;
}

form {
    display: flex;
    flex-direction: column;
    text-align: left;
    width: 100%;
    max-width: 500px;
}

form .inputs {
    width: 100%;
    padding: 20px;
    border-radius: 20px;
    border: none;
    box-shadow: 0px 0px 15px rgba(211, 211, 211, 0.562);
    margin-bottom: 20px;
    font-size: clamp(0.9rem, 1.8vw, 1rem);
}

form .message {
    padding: 20px 10px 60px 10px;
}

form .inputs::placeholder {
    color: var(--text-color);
    font-weight: 500;
}

form .submitbtn {
    width: 100px;
    border: 3px solid;
    color: var(--text-color);
    box-shadow: none;
    padding: 10px;
    cursor: pointer;
    font-weight: 700;
    align-self: flex-end;
    margin-top: -10px;
    transition: transform 0.3s ease;
}

form .submitbtn:hover {
    transform: scale(1.1);
}

.contact .sec1 {
    width: 100%;
    max-width: 600px;
}

.contact .sec2 {
    width: 100%;
    max-width: 600px;
}

.contact h2 {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    margin-bottom: 1rem;
}

.contact p {
    font-size: clamp(1rem, 2vw, 1.1rem);
    font-weight: 700;
    max-width: 800px;
    margin: 0 auto 2rem;
}

/* ==================== */
/* RESPONSIVE DESIGN */
/* ==================== */

/* Tablet Devices (768px and below) */
@media (max-width: 768px) {
    .hero {
        padding: 80px 20px;
        min-height: 400px;
    }
    
    .investment_cards {
        padding: 30px 15px;
        gap: 20px;
    }
    
    .investment_cards .card {
        max-width: 100%;
        padding: 20px 15px;
    }
    
    .message-container {
        gap: 30px;
    }
    
    .messagesDiv {
        max-width: 100%;
    }
    
    .ceoImage {
        height: 400px;
    }
    
    .message-card {
        padding: 20px;
    }
    
    .features-grid,
    .values-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        padding: 0 15px;
    }
    
    .feature-card,
    .value-card {
        padding: 1.5rem;
    }
    
    .contact {
        padding: 40px 15px;
        gap: 30px;
    }
}

/* Mobile Devices (480px and below) */
@media (max-width: 480px) {
    .hero {
        padding: 60px 15px;
        min-height: 350px;
    }
    
    .hero h1 {
        font-size: clamp(1.5rem, 6vw, 2.5rem);
    }
    
    .hero p {
        font-size: clamp(0.9rem, 3vw, 1.1rem);
    }
    
    .investment_cards {
        padding: 20px 10px;
    }
    
    .investment_cards .card {
        padding: 15px 10px;
    }
    
    .investment_cards .card button {
        padding: 12px 20px;
        width: 100%;
        max-width: 180px;
    }
    
    .ceoImage {
        height: 300px;
    }
    
    .message-card h3 {
        font-size: 1.3rem;
    }
    
    .message-card h4 {
        font-size: 1.1rem;
    }
    
    .message-card p {
        font-size: 0.9rem;
    }
    
    .feature-icon img {
        width: 80px;
    }
    
    .value-card img {
        width: 80px;
    }
    
    form .inputs {
        padding: 15px;
    }
}

/* Small Mobile Devices (360px and below) */
@media (max-width: 360px) {
    .hero {
        padding: 50px 10px;
    }
    
    .investment_cards .card h2 {
        font-size: 1.3rem;
    }
    
    .investment_cards .card p {
        font-size: 0.9rem;
    }
    
    .ceoImage {
        height: 250px;
    }
    
    .message-card {
        padding: 15px;
    }
    
    .feature-card,
    .value-card {
        padding: 1rem;
    }
}

/* Large Desktop Screens (1200px and above) */
@media (min-width: 1200px) {
    .container {
        padding: 40px 30px;
    }
    
    .features-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .values-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* High DPI Screens */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .hero {
        background-image: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url("assets/mainBg.jpg");
    }
}

/* Touch Device Optimizations */
@media (hover: none) and (pointer: coarse) {
    .messagesDiv:hover .message-card {
        display: none;
    }
    
    .feature-card:hover {
        transform: none;
    }
    
    .investment_cards .card button:hover {
        transform: none;
    }
}