/* CSS RESET */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* VARIABLES */
:root {
    --primary-color: #004A72;
    --secondary-color: #337C9C;
    --dark-bg: #003a5c;
    --light-bg: #f4f7f6;
    --text-light: #ffffff;
    --text-dark: #333333;
    --font-family: 'Poppins', sans-serif;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--text-light);
}

body.nav-open, body.modal-open {
    overflow: hidden;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

a {
    color: var(--secondary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--primary-color);
}

h1, h2, h3, h4 {
    line-height: 1.2;
    margin-bottom: 20px;
    font-weight: 600;
}

h1 {
    font-size: 2.8rem;
    font-weight: 700;
}

h2 {
    font-size: 2.2rem;
    text-align: center;
    margin-bottom: 40px;
    color: var(--primary-color);
}

h3 {
    font-size: 1.5rem;
    color: var(--primary-color);
}

h4 {
    font-size: 1.2rem;
    color: var(--primary-color);
}

p {
    margin-bottom: 15px;
}

ul, ol {
    margin-bottom: 15px;
    padding-left: 20px;
}

/* HEADER & NAVIGATION */
.main-header {
    background-color: var(--primary-color);
    color: var(--text-light);
    padding: 15px 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.main-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    height: 40px;
    z-index: 1001;
}

.main-nav ul {
    list-style: none;
    display: flex;
    padding-left: 0;
}

.main-nav ul li {
    margin-left: 25px;
}

.main-nav ul li a {
    color: var(--text-light);
    font-weight: 400;
    padding: 10px 0;
    border-bottom: 2px solid transparent;
    transition: color 0.3s ease;
    position: relative;
}

.main-nav ul li a::after {
    content: '';
    position: absolute;
    bottom: 0px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--text-light);
    transition: width 0.3s ease;
}

.main-nav ul li a:hover::after {
    width: 100%;
}

.main-nav ul li a:hover {
    color: var(--text-light);
}

.menu-toggle {
    display: none;
    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 1001;
    padding: 10px;
}

.menu-toggle span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--text-light);
    margin: 5px 0;
    transition: all 0.3s ease-in-out;
}


/* HERO SECTION */
.hero {
    background: linear-gradient(rgba(0, 74, 114, 0.8), rgba(0, 58, 92, 0.9)), url('img/due-diligence-bg.png') no-repeat center center/cover;
    background-attachment: fixed;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--text-light);
    padding-top: 70px; /* Header height */
}

.hero .container {
    max-width: 800px;
}

.hero .subtitle {
    font-size: 1.2rem;
    font-weight: 300;
    margin-bottom: 30px;
}

.cta-button {
    background-color: var(--text-light);
    color: var(--primary-color);
    padding: 15px 35px;
    border-radius: 5px;
    font-weight: 600;
    display: inline-block;
    transition: background-color 0.3s ease, color 0.3s ease, transform 0.3s ease;
    margin-top: 20px;
    font-size: 1.1rem;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    border: 1px solid transparent;
}

.cta-button:hover {
    background-color: var(--secondary-color);
    color: var(--text-light);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0,0,0,0.15);
}

.cta-container {
    text-align: center;
    margin-top: 50px;
}

/* CONTENT SECTIONS */
.content-section {
    padding: 80px 0;
}

.content-section-dark {
    padding: 80px 0;
    background-color: var(--dark-bg);
    color: var(--text-light);
}

.content-section-dark h2,
.content-section-dark h3 {
    color: var(--text-light);
}

.content-section-dark p,
.content-section-dark li {
    color: rgba(255,255,255,0.85);
}

/* HISTORY TIMELINE */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.timeline::after {
    content: '';
    position: absolute;
    width: 3px;
    background-color: var(--secondary-color);
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -1.5px;
}

.timeline-item {
    padding: 10px 40px;
    position: relative;
    width: 50%;
}

.timeline-item:nth-child(odd) {
    left: 0;
}

.timeline-item:nth-child(even) {
    left: 50%;
}

.timeline-item::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    background-color: var(--light-bg);
    border: 4px solid var(--secondary-color);
    top: 25px;
    border-radius: 50%;
    z-index: 1;
}
.timeline-item:nth-child(odd)::after {
    right: -10px;
}
.timeline-item:nth-child(even)::after {
    left: -10px;
}

.timeline-content {
    padding: 20px 30px;
    background-color: rgba(0, 74, 114, 0.5);
    border: 1px solid var(--secondary-color);
    border-radius: 6px;
    position: relative;
}

.timeline-item:nth-child(odd) .timeline-content {
    text-align: right;
}

.timeline-content h3 {
    margin-bottom: 10px;
}

/* TIMELINE - FUTURE ITEM */
.timeline-item-future .timeline-content {
    border-color: var(--text-light);
}

.timeline-item-future::after {
    content: '➤';
    font-size: 16px;
    line-height: 20px;
    text-align: center;
    color: var(--dark-bg);
    background-color: var(--secondary-color);
    border-color: var(--text-light);
}


/* SERVICES SECTION */
#services h3 {
    margin-top: 40px;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    margin: 20px 0 40px 0;
}

.service-card {
    text-align: center;
    padding: 20px;
}

.service-card img {
    max-width: 60px;
    margin-bottom: 15px;
}

.service-card h4 {
    margin-bottom: 10px;
}

.services-extra {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-top: 50px;
    margin-bottom: 30px;
    padding-top: 40px;
    border-top: 1px solid #e0e0e0;
}
.services-extra .extra-item {
    background-color: var(--light-bg);
    padding: 25px;
    border-radius: 5px;
}
.services-extra h3 {
    margin-top: 0;
}
.services-extra ul {
    list-style: none;
    padding-left: 0;
}
.services-extra ul li {
    padding-left: 25px;
    position: relative;
    margin-bottom: 10px;
}
.services-extra ul li::before {
    content: '✔';
    position: absolute;
    left: 0;
    color: var(--secondary-color);
    font-weight: bold;
}


/* HOW WE WORK SECTION */
#how ol {
    list-style: none;
    counter-reset: how-counter;
    padding-left: 0;
}

#how ol li {
    counter-increment: how-counter;
    margin-bottom: 15px;
    padding-left: 50px;
    position: relative;
}

#how ol li::before {
    content: '0' counter(how-counter);
    position: absolute;
    left: 0;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--secondary-color);
    top: 50%;
    transform: translateY(-50%);
}

#how h3 {
    margin-top: 40px;
}

#how ul {
    list-style: none;
    padding-left: 0;
}

#how ul li {
    padding-left: 25px;
    position: relative;
    margin-bottom: 10px;
}

#how ul li::before {
    content: '■';
    position: absolute;
    left: 0;
    color: var(--secondary-color);
}

/* LEADERSHIP SECTION */
#leadership {
    background: var(--light-bg);
    color: var(--text-dark);
}

#leadership h2, #leadership h3 {
    color: var(--primary-color);
}

.leadership-container {
    display: flex;
    align-items: center;
    gap: 50px;
}

.leader-photo {
    width: 250px;
    height: 250px;
    border-radius: 50%;
    object-fit: cover;
    border: 5px solid var(--secondary-color);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.leader-bio {
    flex: 1;
}
.leader-bio h2, .leader-bio h3 {
    text-align: left;
    margin-bottom: 10px;
}

/* CLIENTS & TESTIMONIALS SECTION */
.client-logos {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 40px;
    margin: 40px 0 60px 0;
}

.client-logo-card {
    text-align: center;
    flex-basis: 200px;
}

.client-logo-card img {
    max-height: 50px;
    filter: grayscale(100%);
    opacity: 0.7;
    transition: all 0.3s ease;
}

.client-logo-card img:hover {
    filter: grayscale(0%);
    opacity: 1;
}
.client-logo-card p {
    font-size: 0.85rem;
    margin-top: 10px;
    color: #666;
}

.testimonials {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
    margin-top: 50px;
    margin-bottom: 40px;
}

.testimonial-card {
    background-color: var(--light-bg);
    padding: 30px;
    border-left: 5px solid var(--secondary-color);
    border-radius: 0 5px 5px 0;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    flex-grow: 0; /* Prevents single card on last row from stretching */
    flex-shrink: 1;
    flex-basis: calc(50% - 30px);
    min-width: 300px;
    max-width: 520px;
}

.testimonial-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
}

.testimonial-card p {
    font-style: italic;
    margin-bottom: 0;
}

.testimonial-card footer {
    margin-top: 15px;
    font-weight: 600;
    color: var(--primary-color);
    font-style: normal;
}

#clients .cta-container {
    padding-top: 20px;
}

#clients .cta-container .cta-button {
    padding: 18px 45px;
    font-size: 1.25rem;
    font-weight: 700;
}

/* FAQ SECTION */
#faq {
    background-color: var(--light-bg);
}

#faq .container {
    max-width: 800px;
}

#faq h3 {
    color: var(--primary-color);
    margin-top: 30px;
}
#faq h3:first-of-type {
    margin-top: 0;
}
#faq p {
    margin-left: 10px;
    border-left: 2px solid var(--secondary-color);
    padding-left: 15px;
}

/* FOOTER / CONTACT */
.main-footer-bottom {
    background-color: var(--text-dark);
    color: var(--text-light);
    padding: 40px 0;
}
.main-footer-bottom .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}
.main-footer-bottom a {
    color: var(--text-light);
}
.main-footer-bottom a:hover {
    text-decoration: underline;
}

.footer-info {
    display: flex;
    align-items: center;
    gap: 20px;
}
.footer-info img {
    height: 30px;
}
.footer-info p {
    margin: 0;
    line-height: 1.8;
}

.footer-legal {
    text-align: right;
    font-size: 0.9rem;
    flex-basis: 50%;
    min-width: 300px;
}
.footer-legal p {
    margin: 0;
}

.footer-social {
    margin: 8px 0;
}

.footer-legal .disclaimer {
    font-size: 0.7rem;
    opacity: 0.7;
    margin-top: 10px;
    line-height: 1.5;
}

/* MODAL STYLES */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 58, 92, 0.85); /* Dark blue overlay */
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0s 0.3s ease;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
    transition: opacity 0.3s ease;
}

.modal-content {
    background-color: var(--text-light);
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    width: 90%;
    max-width: 600px;
    position: relative;
    text-align: center;
    transform: translateY(20px) scale(0.98);
    transition: transform 0.3s ease;
}

.modal-overlay.active .modal-content {
    transform: translateY(0) scale(1);
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 2.5rem;
    font-weight: 300;
    color: #aaa;
    cursor: pointer;
    line-height: 1;
    transition: color 0.2s ease, transform 0.2s ease;
}
.modal-close:hover {
    color: var(--text-dark);
    transform: scale(1.1);
}

.modal-content h2 {
    margin-top: 0;
    margin-bottom: 15px;
}

.modal-content p {
    margin-bottom: 30px;
    color: #666;
    font-size: 1.1rem;
}

.modal-contact-info {
    display: flex;
    gap: 30px;
    justify-content: center;
}

.contact-item {
    flex: 1;
    padding: 20px 10px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

.contact-item:hover {
    background-color: var(--light-bg);
    border-color: #cccccc;
}

.contact-item .contact-icon {
    font-size: 2.5rem;
    display: block;
    margin-bottom: 15px;
}

.contact-item h3 {
    margin-bottom: 10px;
    font-size: 1.2rem;
}

.contact-item a {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--secondary-color);
    word-break: break-all;
}
.contact-item a:hover {
    color: var(--primary-color);
}


/* RESPONSIVE DESIGN */
@media (max-width: 850px) {
    h1 { font-size: 2.2rem; }
    h2 { font-size: 1.8rem; }

    .menu-toggle {
        display: block;
    }

    .main-nav {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background-color: var(--primary-color);
        transform: translateX(100%);
        transition: transform 0.3s ease-in-out;
        display: flex;
        justify-content: center;
        align-items: center;
    }
    body.nav-open .main-nav {
        transform: translateX(0);
    }
    .main-nav ul {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }
    .main-nav ul li { margin-left: 0; }
    .main-nav ul li a { font-size: 1.5rem; }

    body.nav-open .menu-toggle span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }
    body.nav-open .menu-toggle span:nth-child(2) {
        opacity: 0;
    }
    body.nav-open .menu-toggle span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -6px);
    }

    .hero { height: auto; padding: 150px 0 60px 0; }

    .timeline::after { left: 20px; }
    .timeline-item { width: 100%; padding-left: 50px; padding-right: 0; }
    .timeline-item:nth-child(even) { left: 0; }
    .timeline-item:nth-child(odd)::after, .timeline-item:nth-child(even)::after {
        left: 10px;
    }
    .timeline-item:nth-child(odd) .timeline-content {
        text-align: left;
    }

    .services-grid { grid-template-columns: 1fr; }
    .services-extra { grid-template-columns: 1fr; }

    .leadership-container { flex-direction: column; text-align: center; }
    .leader-bio h2, .leader-bio h3 { text-align: center; }

    .testimonial-card {
        flex-basis: 100%;
    }

    .main-footer-bottom .container {
        flex-direction: column;
        gap: 30px;
        text-align: center;
    }
    .footer-legal { text-align: center; flex-basis: 100%;}
}

@media (max-width: 600px) {
    .modal-contact-info {
        flex-direction: column;
        gap: 15px;
    }
    .modal-content {
        padding: 30px 20px;
    }
    .contact-item {
        padding: 10px;
    }
}