@import url('open-iconic/font/css/open-iconic-bootstrap.min.css');

*, *::before, *::after {
    box-sizing: border-box;
}

/* Layout & Flex for Sticky Footer */
html, body {
    margin: 0;
    padding: 0;
    width: 100%;
    overflow-x: hidden; /* Prevent horizontal scroll caused by overflow */
}



.layout-container {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.layout-main {
    flex: 1;
}

.layout-normal {
    flex: 1;
    padding: 2rem;
}

/* Header Styling */
header {
    background-color: rgba(255, 255, 255, 0); /* Adjust for transparency */
    padding: 1rem 2rem;
    border-bottom: 2px solid white;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative; /* Allows absolute positioning of hero image */
    z-index: 2; /* Ensure header is above hero */
}

    header h1 {
        font-size: 1.8rem;
        color: white;
        margin: 0;
    }

/* Navigation */
nav a {
    color: white;
    text-decoration: none;
    margin-left: 1.5rem;
    font-weight: bold;
}

    nav a:hover {
        color: white;
    }


.navbar {
    margin-top: 0 !important;
    padding-top: 0 !important;
}

/* Game Cards */
.game-card {
    flex: 1 1 0; /* grow/shrink freely */
    min-width: 200px; /* wrap if narrower */
    max-width: 100%;
    padding: 1rem;
    box-sizing: border-box;
    color: white; /* ensure text is visible on background */
    border-radius: 8px;
    height: 100%;
    min-height: 400px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3); /* optional for depth */
    position: relative; /* REQUIRED for ::before to position inside it */
}

    .game-card::before {
        content: "";
        position: absolute;
        inset: 0;
        border-radius: 8px;
        background-color: rgba(0, 0, 0, 0.3); /* Adjust darkness here (0.1 - 0.3 is typical) */
        z-index: 0;
    }

    .game-card * {
        position: relative;
        z-index: 1; /* Ensure text/content appears above the dark overlay */
    }

    .game-card h3,
    .game-card p {
        color: white;
    }




/* Footer */
footer {
    background-color: #eaeaea;
    padding: 1rem;
    text-align: center;
    border-top: 2px solid #262D33;
    margin-top: 2rem;
    color: #333;
}

/* Buttons */
.btn-primary {
    background-color: #1b6ec2;
    color: #fff;
    padding: 0.6rem 1.2rem;
    border: none;
    border-radius: 4px;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

    .btn-primary:hover {
        background-color: #155fa0;
    }

/* Accessibility & Focus */
h1:focus {
    outline: none;
}

a, .btn-link {
    color: #0071c1;
}

    .btn:focus,
    .btn:active:focus,
    .btn-link.nav-link:focus,
    .form-control:focus,
    .form-check-input:focus {
        box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
    }

/* Validation */
.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid red;
}

.validation-message {
    color: red;
}

/* Blazor Error UI */
#blazor-error-ui {
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

    #blazor-error-ui .dismiss {
        cursor: pointer;
        position: absolute;
        right: 0.75rem;
        top: 0.5rem;
    }

.blazor-error-boundary {
    background-color: #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
    background-image: url(data:image/svg+xml;base64,...); /* keeping your original icon */
    background-repeat: no-repeat;
    background-position: 1rem center;
    background-size: 1.8rem;
}

    .blazor-error-boundary::after {
        content: "An error has occurred.";
    }

/* Responsive */
@media (max-width: 768px) {
    header {
        flex-direction: column;
        align-items: flex-start;
    }

    nav {
        margin-top: 1rem;
    }

        nav a {
            display: block;
            margin: 0.5rem 0;
        }
}

.hero {
    width: 100%;
    height: 101vh;
    display: flex;
    flex-direction: column;
    padding: 0;
    background-image: url('/images/hero-background.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    text-align: center;
    color: white;
    overflow: hidden;
}

    .hero::before {
        content: "";
        position: absolute;
        inset: 0;
        border-radius: 8px;
        background-color: rgba(0, 0, 0, 0.4); /* Adjust darkness here (0.1 - 0.3 is typical) */
        z-index: 0;
    }


.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    padding: 2rem;
}

    .hero-content .text-bg {
        background-color: rgba(0, 0, 0, 0.5); /* semi-transparent black */
        padding: 1rem 2rem;
        border-radius: 0.5rem;
        display: inline-block; /* background wraps content */
        text-align: center; /* optional: center the text */
    }


    .hero-content .btn-primary {
        display: inline-block;
    }

.game-card * {
    position: relative;
    z-index: 1; /* Ensure text/content appears above the dark overlay */
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.hero p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
}

.main-content {
    padding: 0rem 2rem;
    background-color: #ffffff;
    color: #111111;
}

.sub-content {
    padding: 2rem;
    background-color: #ffffff;
    color: #111111;
}

.x-follow-button {
    display: inline-flex;
    align-items: center;
    background-color: black;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    font-weight: bold;
    text-decoration: none;
    transition: background-color 0.3s ease;
}

    .x-follow-button:hover {
        background-color: #1a1a1a;
    }

.x-logo {
    width: 20px;
    height: 20px;
    margin-right: 0.5rem;
}

.icon-img {
    width: 50px;
    height: 50px;
    object-fit: contain;
    background-color: transparent;
    transition: transform 0.3s ease;
}

    .icon-img:hover {
        transform: scale(1.1);
        border-color: #1b6ec2;
    }

.perfect-center {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    margin-top: -40px;
    margin-bottom: 40px;
    height: 128px;
}

.full-width {
    width: 100%;
}


.child-aligned-top {
    position: absolute;
    top: 0;
}

.card-wrapper {
    flex: 1 1 0;
    min-width: 200px;
}


.loading-progress {
    position: relative;
    display: block;
    width: 8rem;
    height: 8rem;
    margin: 20vh auto 1rem auto;
}

    .loading-progress circle {
        fill: none;
        stroke: #e0e0e0;
        stroke-width: 0.6rem;
        transform-origin: 50% 50%;
        transform: rotate(-90deg);
    }

        .loading-progress circle:last-child {
            stroke: #1b6ec2;
            stroke-dasharray: calc(3.141 * var(--blazor-load-percentage, 0%) * 0.8), 500%;
            transition: stroke-dasharray 0.05s ease-in-out;
        }

.loading-progress-text {
    position: absolute;
    text-align: center;
    font-weight: bold;
    inset: calc(20vh + 3.25rem) 0 auto 0.2rem;
}

    .loading-progress-text:after {
        content: var(--blazor-load-percentage-text, "Loading");
    }

code {
    color: #c02d76;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}

.center-image {
    max-width: none; /* don't shrink to fit */
    height: auto; /* keep aspect ratio */
}

