/*
|--------------------------------------------------------------------------
| CGEI Home Page
|--------------------------------------------------------------------------
*/

/*
|--------------------------------------------------------------------------
| Home-page typography
|--------------------------------------------------------------------------
*/

body,
body * {
    font-family: Georgia, "Times New Roman", serif !important;
    font-size: 13pt !important;
}

.service-card-link,
.service-card-link span {
    font-size: 31px !important;
}

/*
|--------------------------------------------------------------------------
| Hero description
|--------------------------------------------------------------------------
*/

.home-hero .hero-description {
    line-height: 1.5;
}

/*
|--------------------------------------------------------------------------
| CGEI Lens
|--------------------------------------------------------------------------
*/

.ceig-lens-section {
    display: grid;

    grid-template-columns:
        380px
        minmax(0, 1fr);

    align-items: stretch;

    column-gap: 16px;

    width: calc(100% - 40px);
    max-width: calc(var(--content-width) - 40px);

    margin: 0 auto;
    padding: 10px 0 12px;

    background: var(--ceig-white);
}

.ceig-lens-image {
    align-self: start;

    width: 100%;

    margin: 0;
    padding: 0;
}

.ceig-lens-image img {
    display: block;

    width: 100%;
    max-width: 380px;
    height: auto;

    margin: 0;

    object-fit: contain;
    object-position: left top;
}

.ceig-lens-content {
    display: flex;
    align-items: center;
    justify-content: flex-start;

    width: 100%;
    min-width: 0;
    min-height: 100%;

    margin: 0;
    padding: 0;
}

.ceig-lens-content p {
    width: 100%;

    margin: 0;
    padding: 0;

    color: var(--ceig-black);

    font-family: Georgia, "Times New Roman", serif;
    font-weight: 400;
    line-height: 1.58;

    text-align: justify;
    text-align-last: left;
    text-justify: inter-word;

    -webkit-hyphens: none;
    -moz-hyphens: none;
    -ms-hyphens: none;
    hyphens: none;

    word-break: normal;
    overflow-wrap: normal;
}

/*
|--------------------------------------------------------------------------
| Three service cards
|--------------------------------------------------------------------------
*/

.principal-services {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.service-card,
.service-card-content {
    width: 100%;
}

.service-card:last-child {
    grid-column: auto;
}

/*
|--------------------------------------------------------------------------
| Card headings
|--------------------------------------------------------------------------
*/

.service-card h2 {
    align-self: center;

    width: fit-content;
    max-width: 100%;

    margin: 0 auto 12px;
    padding: 0 0 5px;

    border-bottom: 4px solid #d4af37;

    font-family: Georgia, "Times New Roman", serif;
    font-weight: 700;
    line-height: 1.3;

    text-align: center;
}

/*
|--------------------------------------------------------------------------
| Card descriptions
|--------------------------------------------------------------------------
*/

.service-card p {
    width: 100%;
    max-width: none;

    margin: 0;
    padding: 0;

    font-family: Georgia, "Times New Roman", serif;
    font-weight: 400;
    line-height: 1.5;

    text-align: justify;
    text-align-last: left;
    text-justify: inter-word;

    -webkit-hyphens: none;
    -moz-hyphens: none;
    -ms-hyphens: none;
    hyphens: none;

    word-break: normal;
    overflow-wrap: normal;
}

/*
|--------------------------------------------------------------------------
| Geopolitics & Economic Intelligence Roundup
|--------------------------------------------------------------------------
*/

.newsletter-section {
    display: grid;
    grid-template-columns: minmax(300px, 0.82fr) minmax(420px, 1.18fr);
    width: calc(100% - 40px);
    max-width: calc(var(--content-width) - 40px);
    margin: 8px auto 22px;
    padding: 0;
    overflow: hidden;
    border: 1px solid rgba(0, 32, 91, 0.18);
    border-bottom: 4px solid #d4af37;
    border-radius: var(--border-radius);
    background: var(--ceig-white);
    box-shadow: 0 14px 34px rgba(0, 22, 62, 0.12);
}

.newsletter-copy {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
    padding: 42px 38px;
    background: var(--ceig-navy);
}

.newsletter-copy h2 {
    position: relative;
    width: fit-content;
    max-width: 100%;
    margin: 0 auto 22px;
    padding: 0 0 15px;
    color: #ffffff;
    font-size: clamp(25px, 2.15vw, 34px);
    font-weight: 700;
    line-height: 1.16;
    text-align: center;
}

.newsletter-copy h2::after {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: #d4af37;
    content: "";
}

.newsletter-copy p,
.newsletter-terms p {
    margin: 0;
    color: var(--ceig-black);
    font-weight: 400;
    line-height: 1.5;
    text-align: left;
    hyphens: none;
}

.newsletter-copy p {
    width: 100%;
    color: #ffffff;
    font-size: 13pt;
    line-height: 1.6;
    text-align: justify;
    text-align-last: left;
    text-justify: inter-word;
}

.newsletter-subscription-panel {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
    padding: 38px 40px 34px;
    border-left: 4px solid #d4af37;
    background: #ffffff;
}

.newsletter-form {
    position: relative;
    width: 100%;
    margin: 0 auto 18px;
}

.newsletter-form-controls {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0;
}

.newsletter-form input[type="email"] {
    width: 100%;
    min-width: 0;
    min-height: 54px;
    padding: 12px 16px;
    border: 1px solid #7b8492;
    border-right: 0;
    border-radius: 3px 0 0 3px;
    background: #ffffff;
    color: var(--ceig-black);
}

.newsletter-form button {
    min-height: 54px;
    padding: 12px 28px;
    border: 1px solid #d4af37;
    border-radius: 0 3px 3px 0;
    background: #d4af37;
    color: var(--ceig-navy);
    font-weight: 700;
    cursor: pointer;
}

.newsletter-form button:hover {
    background: #c7a12d;
}

.newsletter-form input[type="email"]:focus-visible,
.newsletter-form button:focus-visible,
.newsletter-terms a:focus-visible {
    outline: 3px solid #d4af37;
    outline-offset: 2px;
}

.newsletter-terms {
    display: grid;
    gap: 8px;
    width: 100%;
    margin: 0 auto;
}

.newsletter-terms p {
    font-size: 12px;
    line-height: 1.55;
}

.newsletter-terms a {
    color: var(--ceig-navy);
    font-weight: 700;
    text-decoration: underline;
    text-decoration-color: #d4af37;
    text-underline-offset: 3px;
}

.newsletter-message {
    width: 100%;
    margin: 0 auto 16px;
    padding: 10px 12px;
    border-left: 4px solid;
    line-height: 1.45;
}

.newsletter-message-success {
    border-color: #22633b;
    background: #f2faf5;
    color: #174f32;
}

.newsletter-message-error {
    border-color: #9a2525;
    background: #fff3f3;
    color: #7e1f1f;
}

.newsletter-honeypot {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    clip-path: inset(50%) !important;
    white-space: nowrap !important;
}

.visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

/*
|--------------------------------------------------------------------------
| Smaller desktop screens
|--------------------------------------------------------------------------
*/

@media (max-width: 1180px) {

    .principal-services {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .service-card:last-child {
        grid-column: auto;
    }

    .ceig-lens-section {
        grid-template-columns:
            340px
            minmax(0, 1fr);

        column-gap: 14px;
    }

    .ceig-lens-image img {
        max-width: 340px;
    }
}

/*
|--------------------------------------------------------------------------
| Tablet screens
|--------------------------------------------------------------------------
*/

@media (max-width: 900px) {

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

    .newsletter-section {
        grid-template-columns: 1fr;
    }

    .newsletter-copy {
        padding: 32px 30px;
    }

    .newsletter-subscription-panel {
        padding: 30px;
        border-top: 4px solid #d4af37;
        border-left: 0;
    }

    .ceig-lens-section {
        grid-template-columns:
            300px
            minmax(0, 1fr);

        column-gap: 14px;

        width: calc(100% - 28px);
    }

    .ceig-lens-image img {
        max-width: 300px;
    }

    .ceig-lens-content p {
        text-align: justify;
        text-align-last: left;
    }
}

/*
|--------------------------------------------------------------------------
| Small mobile screens
|--------------------------------------------------------------------------
*/

@media (max-width: 560px) {

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

    .service-card:last-child {
        grid-column: auto;
    }

    .ceig-lens-section {
        grid-template-columns: 1fr;

        row-gap: 12px;

        width: calc(100% - 22px);

        padding: 10px 0 12px;
    }

    .ceig-lens-image {
        align-self: start;
    }

    .ceig-lens-image img {
        width: 100%;
        max-width: 100%;
    }

    .ceig-lens-content {
        display: block;

        min-height: 0;
    }

    .ceig-lens-content p {
        text-align: justify;
        text-align-last: left;
    }

    .service-card p {
        text-align: justify;
        text-align-last: left;
        text-justify: inter-word;

        -webkit-hyphens: none;
        -moz-hyphens: none;
        -ms-hyphens: none;
        hyphens: none;

        word-break: normal;
        overflow-wrap: normal;
    }

    .newsletter-section {
        width: calc(100% - 22px);
        padding: 0;
    }

    .newsletter-copy,
    .newsletter-subscription-panel {
        padding: 26px 20px;
    }

    .newsletter-form-controls {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .newsletter-form input[type="email"] {
        border-right: 1px solid #7b8492;
        border-radius: 3px;
    }

    .newsletter-form button {
        width: 100%;
        border-radius: 3px;
    }
}

/* CGEI Motion: panoramic video uses the same proportions as the site hero. */
.cgei-motion-section {
    width: calc(100% - 40px);
    max-width: calc(var(--content-width) - 40px);
    margin: 8px auto 18px;
    padding: 0;
}
.cgei-motion-panel {
    position: relative;
    width: 100%;
    aspect-ratio: 2171 / 619;
    background: #091d33;
    overflow: hidden;
    border-radius: 11px;
}
.cgei-motion-poster {
    display: block;
    position: relative;
    width: 100%;
    height: 100%;
    padding: 0;
    margin: 0;
    border: 0;
    background: #091d33;
    cursor: pointer;
}
.cgei-motion-poster[hidden], .cgei-motion-video[hidden] { display: none !important; }
.cgei-motion-poster img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: fill;
}
.cgei-motion-play-icon {
    position: absolute;
    top: 50%; left: 50%;
    width: clamp(42px, 5.5vw, 72px);
    height: auto;
    transform: translate(-50%, -50%);
    pointer-events: none;
}
.cgei-motion-poster:focus-visible { outline: 3px solid #d4af37; outline-offset: -4px; }
.cgei-motion-video {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: fill;
    background: #091d33;
}
@media (max-width: 700px) {
    .cgei-motion-section { width: calc(100% - 28px); margin-left: 14px; margin-right: 14px; }
    .cgei-motion-panel { border-radius: 8px; }
}
