body {
    margin: 0;
    background: #000;
    color: #e6e6e6;
    font-family: "Segoe UI", sans-serif;
}

/* LANGUAGE SWITCH */
.lang-switch {
    position: absolute;
    top: 8px;
    right: 30px;
    z-index: 999;
    display: flex;
    gap: 10px;
}

.lang-switch button {
    width: 90px;
    height: 34px;
    padding: 0;
    background: #c9a856;
    color: #000;
    border: none;
    border-radius: 7px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
}

.lang-switch button:hover {
    background: #d8b864;
}

/* HEADER */
.main-header {
    background: #0d0d0d;
    padding: 55px 60px 18px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #222;
}

.logo-text {
    color: #fff;
    font-size: 18px;
    font-weight: 600;
}

.main-header nav {
    display: flex;
    align-items: center;
    gap: 24px;
}

.main-header a {
    margin-left: 0;
    color: #ccc;
    text-decoration: none;
    font-size: 16px;
}

.main-header a:hover,
.main-header .active {
    color: #c9a856;
}

/* HERO */
.companies-hero {
    padding: 80px 20px;
    text-align: center;
    background: radial-gradient(circle, rgba(201,168,86,0.18), transparent 70%);
}

.section-title {
    font-size: 42px;
    color: #c9a856;
    text-align: center;
}

/* GRID */
.companies-grid {
    padding: 60px 40px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: stretch;
    gap: 25px;
}

.company-card {
    width: 230px;
    min-height: 260px;
    height: auto;
    background: #111;
    border-radius: 12px;
    border: 1px solid #333;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    text-align: center;
    padding: 26px 18px 22px;
    cursor: pointer;
    transition: 0.3s;
}

.company-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 0 25px rgba(201,168,86,0.5);
}

.company-logo {
    width: 96px;
    height: 96px;
    flex-shrink: 0;
    object-fit: contain;
    background: #222;
    padding: 8px;
    border-radius: 8px;
    margin-bottom: 16px;
}

.company-card h3 {
    color: #fff;
    font-size: 16px;
    line-height: 1.4;
    text-align: center;
    margin: 0;
    max-width: 100%;
    word-wrap: break-word;
}

/* POPUP MODAL */
.modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.75);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.hidden {
    display: none;
}

.modal-content {
    position: relative;
    width: 600px;
    background: #111;
    border-radius: 14px;
    overflow: hidden;
    border: 2px solid #c9a856;
    box-shadow: 0 0 35px rgba(201,168,86,0.5);
    animation: fadeIn 0.4s ease;
}

@keyframes fadeIn {
    from {
        transform: scale(0.7);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}


.modal-header {
    text-align: center;
    padding: 40px 24px 28px;
    background: linear-gradient(135deg, var(--ag-green, #007a4d) 0%, var(--ag-teal, #00a6a6) 55%, var(--ag-blue, #1675b9) 100%);
    position: relative;
}

.modal-logo {
    width: 104px;
    height: 104px;
    object-fit: contain;
    background: #fff;
    padding: 14px;
    border-radius: 50%;
    margin-bottom: 16px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, .28);
}

.modal-header #modalName {
    color: #fff;
    margin: 0;
}

.modal-close {
    position: absolute;
    right: 20px;
    top: 10px;
    font-size: 32px;
    cursor: pointer;
    color: #c9a856;
    z-index: 2;
}

.modal-content p {
    padding: 10px 30px;
    font-size: 18px;
    line-height: 1.8;
    text-align: center;
}

.contact-btn {
    display: block;
    text-align: center;
    background: #c9a856;
    padding: 12px;
    margin: 20px auto;
    width: 70%;
    font-weight: bold;
    color: #000;
    border-radius: 8px;
    text-decoration: none;
}

/* RTL SUPPORT */
body.rtl {
    direction: rtl;
    text-align: right;
}

body.rtl .main-header {
    direction: rtl;
}

body.rtl .main-header a {
    margin-right: 0;
}

body.rtl .company-card,
body.rtl .modal-header,
body.rtl .modal-content p {
    text-align: center;
}

/* RESPONSIVE */
@media (max-width: 900px) {
    .main-header {
        padding: 55px 20px 18px;
        flex-direction: column;
        gap: 15px;
    }

    .main-header nav {
        flex-wrap: wrap;
        justify-content: center;
        gap: 14px;
    }

    .companies-grid {
        padding: 40px 20px;
    }

    .modal-content {
        width: 90%;
    }
}