:root {
    --bg: #050816;
    --bg-alt: #0f172a;
    --card-bg: #0b1220;
    --primary: #7c3aed; /* accent purple */
    --primary-soft: rgba(124, 58, 237, 0.18);
    --accent: #12b981;  /* green */
    --accent-soft: rgba(16, 185, 129, 0.18);
    --text: #e5e7eb;
    --muted: #9ca3af;
    --border: rgba(148, 163, 184, 0.35);
    --danger: #f97373;
    --radius-xl: 18px;
    --shadow-soft: 0 18px 45px rgba(15, 23, 42, 0.7);
}

/* Reset */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: "Poppins", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: radial-gradient(circle at top left, #1d1b3c 0, #020617 45%, #000 100%);
    color: var(--text);
    line-height: 1.6;
}

/* Language handling */

/* default = English, left-to-right */
body {
    direction: ltr;
}

/* hide Arabic text in EN mode */
body .lang-ar {
    display: none;
}

/* Arabic mode */
body.lang-ar {
    direction: rtl;
    font-family: "Tajawal", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

/* in Arabic mode, hide English text and show Arabic text */
body.lang-ar .lang-en {
    display: none;
}
body.lang-ar .lang-ar {
    display: inline;
}

/* Layout helpers */
.wrapper {
    width: min(1200px, 100% - 3rem);
    margin-inline: auto;
}

.section {
    padding: 5rem 0;
}

.section-inner {
    background: linear-gradient(135deg, rgba(15,23,42,0.9), rgba(17,24,39,0.9));
    border-radius: 32px;
    padding: 3rem;
    box-shadow: var(--shadow-soft);
    border: 1px solid rgba(148, 163, 184, 0.4);
    backdrop-filter: blur(18px);
}

.section-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.section-header h2 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.section-header p {
    color: var(--muted);
}

/* Top bar */
.top-bar {
    background: rgba(15, 23, 42, 0.9);
    border-bottom: 1px solid rgba(148, 163, 184, 0.4);
    font-size: 0.85rem;
}

.top-bar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-block: 0.4rem;
}

.top-left a,
.top-right a {
    color: var(--muted);
    text-decoration: none;
    margin-right: 0.35rem;
}

.top-left a:hover,
.top-right a:hover {
    color: var(--accent);
}

.top-bar .icon {
    margin-right: 0.25rem;
}

.top-bar .divider {
    margin: 0 0.35rem;
    color: rgba(148, 163, 184, 0.8);
}

.lang-toggle {
    margin-left: 0.75rem;
    padding: 0.25rem 0.7rem;
    border-radius: 999px;
    border: 1px solid rgba(148, 163, 184, 0.7);
    background: transparent;
    color: var(--text);
    cursor: pointer;
    font-size: 0.8rem;
}

/* Header / nav */
.header {
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: blur(18px);
    background: linear-gradient(to bottom, rgba(15, 23, 42, 0.96), rgba(15, 23, 42, 0.7));
    border-bottom: 1px solid rgba(148, 163, 184, 0.35);
}

.nav-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-block: 0.8rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.logo img {
    width: 96px;
    height: auto;
}

.logo-main {
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.95rem;
}

.logo-sub {
    display: block;
    font-size: 0.75rem;
    color: var(--muted);
}

.nav {
    display: flex;
    align-items: center;
    gap: 1.2rem;
}

.nav-link {
    text-decoration: none;
    font-size: 0.9rem;
    color: var(--muted);
    position: relative;
    padding-bottom: 0.1rem;
}

.nav-link::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -0.25rem;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--accent), var(--primary));
    transition: width 0.25s ease-out;
}

.nav-link:hover {
    color: var(--text);
}
.nav-link:hover::after {
    width: 100%;
}

.nav-cta {
    padding: 0.35rem 0.9rem;
    border-radius: 999px;
    border: 1px solid rgba(94, 234, 212, 0.6);
    background: radial-gradient(circle at top left, var(--primary-soft), transparent 60%);
    color: var(--text);
}

/* Mobile nav toggle */
.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 0.22rem;
    background: transparent;
    border: none;
    cursor: pointer;
}
.nav-toggle span {
    width: 22px;
    height: 2px;
    background: var(--text);
    border-radius: 999px;
}

/* Hero */
.hero {
    position: relative;
    min-height: 80vh;
    display: flex;
    align-items: center;
    padding: 4.5rem 0 5rem;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.45;
    filter: grayscale(30%) contrast(1.1);
    z-index: -2;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at top right, rgba(124,58,237,0.5), transparent 55%),
        radial-gradient(circle at bottom left, rgba(16,185,129,0.6), transparent 55%),
        linear-gradient(to bottom, rgba(15,23,42,0.9), rgba(15,23,42,0.97));
    z-index: -1;
}

.hero-content {
    display: grid;
    grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
    gap: 3rem;
}

.hero-text h1 {
    font-size: clamp(2.3rem, 3vw + 1.7rem, 3.4rem);
    line-height: 1.1;
    margin-bottom: 1rem;
}
.hero-subtitle {
    color: var(--muted);
    max-width: 36rem;
    margin-bottom: 1.7rem;
}

.hero-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
    margin-bottom: 1.7rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.8rem 1.4rem;
    border-radius: 999px;
    font-size: 0.9rem;
    font-weight: 500;
    text-decoration: none;
    border: 1px solid transparent;
    cursor: pointer;
}
.primary-btn {
    background: linear-gradient(135deg, var(--accent), var(--primary));
    color: #0f172a;
    box-shadow: 0 14px 30px rgba(15, 118, 110, 0.55);
}
.secondary-btn {
    border-color: rgba(148, 163, 184, 0.6);
    background: rgba(15, 23, 42, 0.8);
    color: var(--text);
}
.btn.full-width {
    width: 100%;
}

.hero-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.9rem;
}

.badge {
    padding: 0.6rem 1rem;
    border-radius: 999px;
    border: 1px solid rgba(94, 234, 212, 0.45);
    background: rgba(15, 23, 42, 0.85);
    font-size: 0.8rem;
}
.badge-title {
    font-weight: 500;
    margin-right: 0.35rem;
}
.badge-sub {
    color: var(--muted);
}

.hero-stats {
    display: grid;
    gap: 0.9rem;
    align-content: center;
}

.stat-card {
    padding: 1.1rem 1.2rem;
    border-radius: 18px;
    border: 1px solid rgba(148, 163, 184, 0.45);
    background: radial-gradient(circle at top left, rgba(124,58,237,0.2), rgba(15,23,42,0.9));
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.7);
}
.stat-number {
    display: block;
    font-size: 1.5rem;
    font-weight: 600;
}
.stat-label {
    color: var(--muted);
    font-size: 0.85rem;
}

/* About */
.about-grid {
    display: grid;
    grid-template-columns: minmax(0, 3fr) minmax(0, 2.3fr);
    gap: 2.5rem;
}
.about-text h2 {
    margin-bottom: 0.6rem;
}
.about-text h3 {
    margin-top: 1.5rem;
    margin-bottom: 0.4rem;
}
.about-text p + p {
    margin-top: 0.7rem;
}
.pill-list {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.6rem;
}
.pill-list li {
    padding: 0.3rem 0.8rem;
    border-radius: 999px;
    border: 1px solid rgba(148, 163, 184, 0.5);
    font-size: 0.8rem;
}

.about-side {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}
.about-card {
    padding: 1.2rem 1.3rem;
    border-radius: 18px;
    background: radial-gradient(circle at top left, rgba(16,185,129,0.2), rgba(15,23,42,0.95));
    border: 1px solid rgba(148, 163, 184, 0.5);
}

.map-container iframe {
    border-radius: 14px;
    border: 0;
}

/* Services */
.services {
    background: radial-gradient(circle at top, rgba(15,23,42,0.9), rgba(2,6,23,1));
}
.services-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1.7rem;
}
.service-card {
    padding: 1.4rem 1.2rem;
    border-radius: 20px;
    background: radial-gradient(circle at top left, rgba(124,58,237,0.18), rgba(15,23,42,0.95));
    border: 1px solid rgba(148, 163, 184, 0.45);
    box-shadow: 0 14px 35px rgba(15, 23, 42, 0.8);
}
.service-card h3 {
    margin-bottom: 0.7rem;
}
.service-card ul {
    list-style: none;
    font-size: 0.9rem;
    color: var(--muted);
}
.service-card li::before {
    content: "▹";
    margin-right: 0.35rem;
    color: var(--accent);
}

/* Gallery */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.2rem;
}
.gallery-item {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid rgba(148, 163, 184, 0.4);
    background: rgba(15, 23, 42, 0.9);
}
.gallery-item::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(15,23,42,0.75), transparent 50%);
    opacity: 0;
    transition: opacity 0.25s ease-out;
}
.gallery-item img {
    display: block;
    width: 100%;
    height: 220px;
    object-fit: cover;
    transform: scale(1.02);
    transition: transform 0.45s ease-out;
}
.gallery-item:hover img {
    transform: scale(1.07);
}
.gallery-item:hover::after {
    opacity: 1;
}

/* Manpower */
.manpower {
    background: radial-gradient(circle at center, rgba(15,23,42,0.95), rgba(2,6,23,1));
}
.manpower-grid {
    display: grid;
    grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
    gap: 2rem;
}
.manpower-columns {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.5rem;
    margin-top: 1rem;
}
.manpower-columns ul {
    list-style: none;
    font-size: 0.9rem;
}
.manpower-columns li::before {
    content: "▹";
    margin-right: 0.35rem;
    color: var(--accent);
}
.manpower-cta .cta-card {
    padding: 1.8rem 1.5rem;
    border-radius: 20px;
    background: radial-gradient(circle at top left, rgba(16,185,129,0.25), rgba(15,23,42,0.96));
    border: 1px solid rgba(94, 234, 212, 0.6);
}

/* Careers */
.careers-grid {
    display: grid;
    grid-template-columns: minmax(0, 2.5fr) minmax(0, 3fr);
    gap: 2rem;
}
.careers-form-card {
    padding: 1.8rem 1.5rem;
    border-radius: 22px;
    background: radial-gradient(circle at top left, rgba(124,58,237,0.25), rgba(15,23,42,0.98));
    border: 1px solid rgba(129, 140, 248, 0.7);
}

/* Forms */
.form {
    display: grid;
    gap: 0.9rem;
}
.form-row {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}
.form-row label {
    font-size: 0.85rem;
    color: var(--muted);
}
.form-row input,
.form-row textarea {
    padding: 0.7rem 0.85rem;
    border-radius: 12px;
    border: 1px solid rgba(148, 163, 184, 0.75);
    background: rgba(15, 23, 42, 0.9);
    color: var(--text);
    font-size: 0.9rem;
}
.form-row input:focus,
.form-row textarea:focus {
    outline: 1px solid rgba(94, 234, 212, 0.9);
    box-shadow: 0 0 0 1px rgba(94, 234, 212, 0.5);
}
.form-note {
    margin-top: 0.6rem;
    font-size: 0.8rem;
    color: var(--muted);
}

/* Contact */
.contact-grid {
    display: grid;
    grid-template-columns: minmax(0, 2.3fr) minmax(0, 3fr);
    gap: 2rem;
}
.contact-block {
    margin-top: 1.2rem;
}
.contact-block a {
    color: var(--accent);
    text-decoration: none;
}
.contact-block a:hover {
    text-decoration: underline;
}
.contact-form-card {
    padding: 1.8rem 1.6rem;
    border-radius: 22px;
    background: radial-gradient(circle at top left, rgba(16,185,129,0.24), rgba(15,23,42,0.98));
    border: 1px solid rgba(52, 211, 153, 0.75);
}
.fw-form-table {
  width: 100%;
  border-collapse: collapse;
}

.fw-label-cell {
  width: 30%;
  padding: 6px 8px;
  vertical-align: middle;
}

.fw-input-cell {
  width: 70%;
  padding: 6px 8px;
}

.fw-input,
.fw-select,
.fw-textarea {
  width: 100%;
  box-sizing: border-box;
}

.valign-top {
  vertical-align: top;
}

.fw-form-actions {
  text-align: right;
  margin-top: 10px;
}


/* Footer */
.footer {
    border-top: 1px solid rgba(148, 163, 184, 0.35);
    background: rgba(15, 23, 42, 0.98);
    padding: 1rem 0;
}
.footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8rem;
    color: var(--muted);
}

/* Responsive */
@media (max-width: 960px) {
    .hero-content,
    .about-grid,
    .services-grid,
    .gallery-grid,
    .manpower-grid,
    .careers-grid,
    .contact-grid,
    .manpower-columns {
        grid-template-columns: 1fr;
    }

    .section-inner {
        padding: 2.2rem 1.7rem;
        border-radius: 22px;
    }

    .hero {
        padding-top: 4rem;
    }

    .hero-stats {
        grid-auto-flow: column;
        overflow-x: auto;
    }

    .nav {
        position: absolute;
        inset-inline: 0;
        top: 100%;
        background: rgba(15, 23, 42, 0.97);
        flex-direction: column;
        align-items: flex-start;
        padding: 0.8rem 1.5rem 1.2rem;
        gap: 0.75rem;
        transform: translateY(-10px);
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.2s ease-out, transform 0.2s ease-out;
    }

    .nav.open {
        opacity: 1;
        pointer-events: auto;
        transform: translateY(0);
    }

    .nav-toggle {
        display: flex;
    }

    .footer-inner {
        flex-direction: column;
        gap: 0.5rem;
        text-align: center;
    }
}

@media (max-width: 600px) {
    .top-bar-inner {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.2rem;
    }
    .hero-buttons {
        flex-direction: column;
        align-items: stretch;
    }
}
