body, html {
    height: 100%;
    margin: 0;
    font-family: 'Roboto Condensed', sans-serif;
    scroll-behavior: smooth;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Roboto Condensed', sans-serif;
}

.video {
    filter: brightness(200%);
}
.video-container {
    position: relative;
    width: 100%;
    height: 90vh;
    overflow: hidden;
}

.video-container .video {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: translate(-50%, -50%);
    z-index: 1;
}

.video-container .overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2;
}

.video-container .text {
    position: relative;
    z-index: 3;
    color: white;
    text-align: center;
    top: 50%;
    transform: translateY(-50%);
}

.section {
    padding: 60px 0;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.section.visible {
    opacity: 1;
    transform: translateY(0);
}

.section h2 {
    margin-bottom: 40px;
}
.black-background {
    background-color: black;
    color: white;
}

.black-background h2, 
.black-background h3, 
.black-background p {
    color: red;
}

@keyframes fadeIn {
    to {
        opacity: 1;
    }
}

.motto-bar {
    overflow: hidden;
    white-space: nowrap;
    position: relative;
    background-color: black;
    padding: 10px 0;
    height: 50px;
}

.motto-text {
    display: inline-block;
    color: red;
    font-size: 1.2em;
    animation: scroll 40s linear infinite;
}

@keyframes scroll {
    0% {
        transform: translateX(100%);
        opacity: 0;
    }
    5% {
        transform: translateX(95%);
        opacity: 1;
    }
    95% {
        transform: translateX(-95%);
        opacity: 1;
    }
    100% {
        transform: translateX(-100%);
        opacity: 0;
    }
}

.btn-danger {
    background-color: red;
    border: none;
    color: white;
    padding: 15px 30px;  /* Increase padding for larger button */
    font-size: 1.2em;
}

.btn-danger:hover {
    background-color: darkred;
}

.img-fluid:hover {
    background-color: darkred;
}

h2 {
    margin-bottom: 40px; /* Adjust the spacing as needed */
}

h2.special-heading {
    color: white;
}

h3 {
    font-weight: lighter;
    margin-top: 20px; /* Adjust the spacing as needed */
}

.black-background .img-fluid {
    border-radius: 0 !important;
}

h3.tiles {
    font-size: small;
    color: red;
    font-weight: lighter;
    margin-top: 20px;
    padding: 20px;
}

.portrait-img {
    width: 100%;
    height: auto;
    object-fit: cover;
    aspect-ratio: 3/4; /* Portrait shape */
    max-height: 1200px; /* Adjust this value as needed */
    margin-bottom: 15px;
}

.text-danger {
    margin-top: 0;
    color: red !important;
}

p.quotes {
    font-style: italic;
}

p.job-title {
    font-weight: lighter;
    font-size: x-large;
}

@media (min-width: 768px) {
    .portrait-img {
        max-height: 1500px; /* Larger size for larger screens */
    }
}

@media (min-width: 1024px) {
    .portrait-img {
        max-height: 1800px; /* Even larger size for very large screens */
    }
}

#portfolio h2 {
    text-align: center;
    margin: 0 auto 3rem auto; /* Increased margin to push images down */
    z-index: 2;
    position: relative;
}

#portfolio .row {
    margin-top: 3rem; /* Adjust the value as needed */
    display: flex;
    flex-wrap: wrap;
    justify-content: center; /* Center the items horizontally */
}

.card-container {
    perspective: 1000px;
    margin-bottom: 30px;
    width: 100%;
    max-width: 300px; /* Set a max-width for the cards */
}

.card {
    width: 100%;
    height: 400px; /* Adjust height as needed */
    position: relative;
    transform-style: preserve-3d;
    transition: transform 0.8s;
}

.card .front, .card .back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.card .front {
    z-index: 2; /* Ensure front content stays above */
    transform: rotateY(0deg);
}

.card .front img {
    width: 100%;
    height: calc(100% - 40px);
    object-fit: cover;
}

.card .back {
    transform: rotateY(180deg);
    background-color: white;
    padding: 20px;
    z-index: 1;
}

.card.flipped {
    transform: rotateY(180deg);
}

h3.tiles {
    font-size: small;
    color: red;
    font-weight: lighter;
    margin-top: 5px;
    padding: 0px;
    margin-bottom: 20px; /* Add bottom margin */
}

.icon-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* Adjust the number of columns as needed */
    gap: 15px;
    justify-items: center;
}

.single-item-grid {
    display: grid;
    grid-template-columns: 1fr;
    justify-items: center;
}

.double-item-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    justify-items: center;
}

.text-content {
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    height: 100%;
    background-color: #ffffff;
    font-size: 16px;
}

.icon-grid img {
    width: 60px; /* Adjust size as needed */
    height: 60px; /* Adjust size as needed */
    object-fit: contain;
}

@media (min-width: 768px) {
    .col-md-4 {
        flex: 0 0 33.3333%;
        max-width: 33.3333%;
    }
}

#competencies {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh; /* Ensure it takes at least the full height of the viewport */
    padding: 3rem 0;
    background-color: #000;
    color: #fff;
}

#competencies h2 {
    color: red;
    margin-bottom: 2rem;
    text-align: center;
}

.row {
    display: flex;
    justify-content: center; /* Center the content within the row */
    flex-wrap: wrap; /* Ensure columns wrap on smaller screens */
    width: 100%;
}

.col-md-5 {
    max-width: 300px; /* Set a max width for the columns */
    margin: 1rem; /* Add margin between columns */
}

.competency-list {
    list-style: none;
    padding: 0;
    text-align: left; /* Align text to the left within each column */
    min-height: 2rem;
    min-width: 1.5rem;
}

.competency-list li {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
}

.competency-list i {
    color: red;
    margin-right: 1rem;
    font-size: 1.5rem;
}

@media (max-width: 768px) {
    .row {
        flex-direction: column;
        align-items: center;
    }

    .col-md-5 {
        width: 100%;
        max-width: 600px; /* Adjust as needed */
        margin-bottom: 2rem; /* Space between the columns */
    }
}

.image-container {
    position: relative;
    display: inline-block;
}

.img-fluid {
    display: block;
    width: 100%;
    height: auto;
}

.image-container::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: darkred;
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 1; /* Ensure the overlay is above the image */
}

.image-container:hover::after {
    opacity: 0.5; /* Adjust the opacity to get the desired tint effect */
}

.fade-in {
    opacity: 0;
    transition: opacity 1s ease-in;
}

.fade-in.visible {
    opacity: 1;
}
