/* Code: P! */
@charset "UTF-8";

:root {
    /* Color Palette */
    --clr-txt-dark: rgb(45, 45, 45);
    --clr-txt-light: rgb(230, 230, 230);
    --clr-bg-dark: rgb(28, 28, 28);
    --clr-bg-light: rgb(230, 230, 230);
    /* Text */
    --txt-body: normal normal 400 1rem/1.7 "Inter", sans-serif;
    --txt-masthead: italic normal 100 4rem/1.3 "Inter", sans-serif;
    --txt-h1: normal normal 300 2rem/1.5 "Inter", sans-serif;
    --txt-h2: normal normal 300 1.6rem/1.5 "Inter", sans-serif;
    --txt-h3: normal normal 400 1.2rem/1.5 "Inter", sans-serif;
    --txt-small: normal normal 400 0.8rem/1.7 "Inter", sans-serif;
    --txt-footer: normal normal 300 0.6rem/1.7 "Inter", sans-serif;
}

html {
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    font-size: 100%;
}

* {
    box-sizing: border-box;
}

body {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    margin: 0;
    font-family: "Inter", sans-serif;
    color: var(--clr-txt-dark);
    background-color: var(--clr-bg-light);
}

h1 {
    font: var(--txt-h1);
}

h2 {
    font: var(--txt-h2);
}

h3 {
    font: var(--txt-h3);
}

p, ul, li {
    font: var(--txt-body);
}

a {
    text-decoration: none;
    border: none;
    outline: none;
}

/* --------------------------------------- HEADER */

header {
    display: inherit;
    flex-direction: inherit;
    align-items: inherit;
    width: 100%;
    height: 78px;
}

.headerbox {
    width: 100%;
    max-width: 1200px;
    height: 100%;
    padding: 1rem;
    background-color: black;
}

.headerbox img {
    height: 42px;
    width: auto;
}

/* --------------------------------------- MASTHEAD */

.masthead {
    display: flex;
    justify-self: center;
    justify-content: space-around;
    align-items: center;
    width: 100%;
    max-width: 1200px;
    height: 512px;
    margin-bottom: 4rem;
    background-image: url(/images/header.avif);
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
}

.masthead h1 {
    font: var(--txt-masthead);
    color: rgb(255, 255, 255);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 1);
}

/* --------------------------------------- LOGOS */

.container {
    display: flex;
    flex-wrap: wrap;
    justify-self: center;
    max-width: 1200px;
    padding: 2rem 2rem 6rem 2rem;
    /* background-color: blueviolet; */
}

.title {
    flex: 100%;
    text-align: center;
    padding-bottom: 1rem;
}

.logos {
    display: flex;
    flex-wrap: wrap;
    flex: 100%;
    gap: 2rem 4rem;
    justify-content: center;
}

.logos img {
    height: 42px;
}

/* --------------------------------------- CASE STUDIES */

.gallery {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 4rem;
}

button {
    border: none;
    outline: none;
    cursor: pointer;
    display: block;
    -webkit-appearance: none;
    appearance: none;
    background: transparent;
    background-color: rgba(0, 0, 0, 0);
    padding: 0;
    margin: 0;
}

button img {
    width: 320px;
    height: auto;
    max-width: 100%;
}

/* --------------------------------------- MODALS */

/* Hidden by default */
.modal-overlay {
    display: none; 
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.7);
    align-items: center;
    justify-content: center;
}

/* The Modal Box */
.modal-content {
    display: flex;
    flex-direction: column;
    background-color: var(--clr-bg-light);
    padding: 2rem;
    max-height: 80vh;
    width: 80%;
    max-width: 1024px;
    /* border-radius: 8px; */
    position: relative;
    animation: fadeIn 0.3s ease;
}

/* Flexbox for side-by-side */
.modal-body {
    display: flex;
    gap: 2rem;
    align-items: center;
    overflow: hidden;
}

.modal-image {
    align-self: flex-start;
}

.modal-image img {
    width: 420px;
    max-width: 100%;
    display: block;
}

.modal-text {
    flex: 1; /* Takes up remaining space */
    position: relative;
    overflow-y: auto;
    padding-right: 1rem;
    padding-bottom: 4rem;
    max-height: 70vh;
    overscroll-behavior: contain;
    -webkit-mask-image: linear-gradient(to bottom, black 90%, transparent 100%);
    mask-image: linear-gradient(to bottom, black 90%, transparent 100%);

    /* Firefox */
    scrollbar-width: thin;
    scrollbar-color: rgb(128, 128, 128) transparent;

    /* Webkit (Chrome/Safari/Edge) */
    &::-webkit-scrollbar {
        width: 6px;
    }
    &::-webkit-scrollbar-track {
        background: transparent; /* Makes it look cleaner */
    }
    &::-webkit-scrollbar-thumb {
        background-color: rgb(128, 128, 128);
        /* border-radius: 20px; */
        border: 0 solid transparent; /* Acts as padding */
    }
}

.close-btn {
    position: absolute;
    top: 0;
    right: 0.5rem;
    font-size: 2rem;
    cursor: pointer;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Responsive: Stack columns on small screens */
@media (max-width: 600px) {
    .modal-body {
        flex-direction: column;
    }
}

/* --------------------------------------- ABOUT & CONTACT */

.text-block {
    justify-self: center;
    width: 680px;
    max-width: 100%;
    padding: 4rem 2rem;
}

.text-block img {
    height: 24px;
}

.txt-notice {
    font: var(--txt-small);
    padding-bottom: 6rem;
}

/* --------------------------------------- FOOTER */
footer {
    display: inherit;
    flex-direction: inherit;
    align-items: inherit;
    width: 100%;
    background-color: var(--clr-bg-dark);
}

.footer-block {
    width: 680px;
    max-width: 100%;
    justify-self: center;
    padding: 1rem 2rem 2rem 2rem;
}

.icons {
    display: flex;
    flex: 100%;
    justify-content: center;
    gap: 1rem;
}

.icons img {
    height: 18px;
}

.footer-block p {
    font: var(--txt-footer);
    color: var(--clr-txt-light);
    padding-bottom: 1rem;
}