/* ============================================================
   Opel GT Club – user.css
   Custom layout overrides on top of Cassiopeia
   ============================================================ */

/* ---- Reset border-radius site-wide ---- */
:root {
    --bs-border-radius: 0;
    --bs-border-radius-sm: 0;
    --bs-border-radius-lg: 0;
    --bs-border-radius-xl: 0;
    --bs-border-radius-xxl: 0;
    --bs-border-radius-pill: 0;

    /* Header height — change here to resize the header globally */
    --header-height: 80px;

    /* Pre-footer */
    --pre-footer-bg: #f5f5f5;
    --pre-footer-color: inherit;
    --pre-footer-padding: 3rem 0;
}

*,
*::before,
*::after {
    border-radius: 0 !important;
}

/* ============================================================
   HEADER — background scoped to .container, not full-screen
   ============================================================ */

/* The <header> itself is transparent — no bleed to screen edges */
.site-header {
    background: transparent;
    padding: 0;
    margin: 0;
}

/* The inner container carries the background */
.header-inner {
    background-color: var(--headerbg);
    color: var(--headercolor);
    display: flex;
    align-items: stretch;
    height: var(--header-height);
    padding-top: 0;
    padding-bottom: 0;
    gap: 0;
}

/* ---- Logo (left, full height) ---- */
.header-brand {
    display: flex;
    align-items: center;
    align-self: stretch;
    flex-shrink: 0;
    padding: 0;
    margin-right: 1.5rem;
}

.header-brand__link {
    display: flex;
    align-items: center;
    height: 100%;
    text-decoration: none;
}

/* Logo image fills the full header height */
.header-logo__img {
    height: 100%;
    width: auto;
    max-height: var(--header-height);
    display: block;
    object-fit: contain;
}

/* Site title as text logo */
.header-logo__text {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--headercolor);
    white-space: nowrap;
}

.header-brand__description {
    font-size: 0.75rem;
    color: var(--headercolor);
    opacity: 0.75;
    margin-top: 0.125rem;
}

/* ---- Navigation (right side) ---- */
.header-right {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: flex-end;
    padding: 0.25rem 0;
    min-width: 0;
}

/* Topbar row */
.header-topbar {
    width: 100%;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    font-size: 0.85rem;
    color: var(--headercolor);
}

.header-topbar a {
    color: var(--headercolor);
}

/* Main navigation row */
.header-nav {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 1rem;
}

/* Bring Cassiopeia menu colors in line */
.header-inner .mod-menu,
.header-inner .navbar-nav {
    color: var(--headercolor);
}

.header-inner .mod-menu a,
.header-inner .navbar-nav a {
    color: var(--headercolor);
}

/* Remove the full-width header background Cassiopeia sets */
.container-header {
    background-color: transparent !important;
    background-image: none !important;
}

/* ============================================================
   BANNER — full-width below the header
   ============================================================ */
.site-banner {
    width: 100%;
    overflow: hidden;
    line-height: 0; /* removes gap under inline img/iframe */
}

.site-banner img,
.site-banner .mod-banners img {
    width: 100%;
    height: auto;
    display: block;
}

/* ============================================================
   PRE-FOOTER — multi-column module row
   ============================================================ */
.pre-footer {
    background-color: var(--pre-footer-bg);
    color: var(--pre-footer-color);
    padding: var(--pre-footer-padding);
}

/* Flex row with evenly distributed module items */
.pre-footer__grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-around;
    align-items: flex-start;
    gap: 2rem;
}

/* Each module item (rendered by prefooter chrome) */
.pre-footer-item {
    flex: 1 1 200px;
    min-width: 160px;
}

.pre-footer-item__title {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.pre-footer-item__content {
    font-size: 0.9rem;
}

.pre-footer-item__content a {
    color: inherit;
}

/* ============================================================
   FOOTER — re-scoped to match container width
   ============================================================ */
.container-footer.footer {
    background-color: transparent;
    background-image: none;
}

.container-footer.footer > .container {
    background-color: var(--footerbg);
    color: var(--footercolor);
    padding-top: 1.5rem;
    padding-bottom: 1.5rem;
}

.container-footer.footer > .container a {
    color: var(--footercolor);
}

/* ============================================================
   BLOCK LAYOUT — for the blocks article layout override
   ============================================================ */
.block-row {
    display: flex;
    align-items: center;
    gap: 3rem;
    padding: 4rem 0;
}

/* Image-right variant — reverses the flex order */
.block-row--image-right {
    flex-direction: row-reverse;
}

.block-row__image {
    flex: 0 0 45%;
    max-width: 45%;
}

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

.block-row__content {
    flex: 1;
}

.block-row__title {
    margin-bottom: 1rem;
}

.block-row__text {
    margin-bottom: 1.5rem;
    line-height: 1.7;
}

.block-row__btn {
    display: inline-block;
}

/* Stack on mobile */
@media (max-width: 767.98px) {
    .block-row,
    .block-row--image-right {
        flex-direction: column;
    }

    .block-row__image {
        flex: 0 0 100%;
        max-width: 100%;
    }
}

/* ============================================================
   RESPONSIVE — collapse header on mobile
   ============================================================ */
@media (max-width: 767.98px) {
    .header-inner {
        height: auto;
        min-height: var(--header-height);
        flex-wrap: wrap;
        padding: 0.5rem 0;
    }

    .header-brand {
        flex: 1 0 auto;
    }

    .header-logo__img {
        max-height: calc(var(--header-height) * 0.75);
    }

    .header-right {
        flex: 0 0 100%;
        align-items: flex-start;
        padding: 0.25rem 0;
    }
}
