/*
Theme Name:   Impeka Child – Alster+
Theme URI:    https://freiland.de
Description:  Child theme for Impeka with the custom Alster+ header menu (GSAP).
Author:       freiland
Template:     impeka
Version:      1.0.0
Text Domain:  impeka-child
*/

.alster-brand {
    white-space: nowrap;
}

.alster-brand__plus {
    display: inline-block !important;

    position: relative !important;
    top: -0.55em !important;

    margin-left: 0.025em !important;

    font-size: 0.72em !important;
    line-height: 1 !important;

    font-family: inherit !important;
    font-weight: inherit !important;
}

/* Add general child-theme overrides below. The header menu styles live in assets/css/alster-menu.css */
/* ==========================================
   IMPEKA – INVERTED UNDERLINE ANIMATION
   Default: Visible
   Hover: Slides out to the right
   Mouse leave: Slides in from the left
   ========================================== */

/* Button container */
a.grve-btn-line.grve-line-bottom .grve-btn-inner {
    position: relative;
    overflow: hidden;
}

/* Disable original Impeka underline */
a.grve-btn-line.grve-line-bottom .grve-line {
    display: none !important;
}

/* Custom underline */
a.grve-btn-line.grve-line-bottom .grve-btn-inner::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 1px;
    background-color: currentColor;
    pointer-events: none;

    animation: underline-enter-left 0.45s ease both;
}

/* Hover: Line slides out to the right */
a.grve-btn-line.grve-line-bottom:hover .grve-btn-inner::after {
    animation: underline-exit-right 0.45s ease both;
}

/* Mouse leave: Line enters from the left */
@keyframes underline-enter-left {
    from {
        transform: translateX(-101%);
    }
    to {
        transform: translateX(0);
    }
}

/* Hover: Line exits to the right */
@keyframes underline-exit-right {
    from {
        transform: translateX(0);
    }
    to {
        transform: translateX(101%);
    }
}

/* Anpassungen Portfolio Seiten */
#grve-portfolio-title .grve-container {
	max-width: 100%;
    width: calc(100% - 3.5rem);
} 

#grve-portfolio-title .grve-description {
	opacity: 0.5 !important;
}

#grve-portfolio-title .grve-title {
    margin-bottom: 10px;
}

/* ==========================================
   ALSTER+ – FLEX SPACE BETWEEN: HEIGHT FIX
   Add AFTER your existing CSS
   ========================================== */

/* 1. Stretch columns within the relevant parent row */
.grve-row:has(> .grve-column.flex-space-between),
.grve-row-inner:has(> .grve-column-inner.flex-space-between) {
    display: flex !important;
    flex-wrap: wrap;
    align-items: stretch !important;
}

/* 2. Make the marked column stretch its own wrapper */
.grve-column.flex-space-between,
.grve-column-inner.flex-space-between {
    display: flex !important;
    flex-direction: column;
    align-self: stretch !important;
}

/* 3. Grow the wrapper without relying on height: 100% */
.flex-space-between > .grve-column-wrapper,
.flex-space-between > .grve-column-wrapper-inner {
    display: flex !important;
    flex-direction: column;
    flex: 1 1 auto;
    height: auto !important;
    min-width: 0;
}

/* 4. Let the content fill the wrapper and distribute items */
.flex-space-between > .grve-column-wrapper > .grve-column-content,
.flex-space-between > .grve-column-wrapper-inner > .grve-column-inner-content {
    display: flex !important;
    flex-direction: column;
    justify-content: space-between !important;
    flex: 1 1 auto;
    min-width: 0;
    min-height: 0;
}

/* 5. Keep the image and text at their natural heights */
.flex-space-between > .grve-column-wrapper > .grve-column-content > .grve-element,
.flex-space-between > .grve-column-wrapper-inner > .grve-column-inner-content > .grve-element {
    flex: 0 0 auto;
}

/* 6. Remove any clearfix pseudo-elements on these flex containers */
.grve-row:has(> .grve-column.flex-space-between)::before,
.grve-row:has(> .grve-column.flex-space-between)::after,
.grve-row-inner:has(> .grve-column-inner.flex-space-between)::before,
.grve-row-inner:has(> .grve-column-inner.flex-space-between)::after,
.flex-space-between > .grve-column-wrapper > .grve-column-content::before,
.flex-space-between > .grve-column-wrapper > .grve-column-content::after,
.flex-space-between > .grve-column-wrapper-inner > .grve-column-inner-content::before,
.flex-space-between > .grve-column-wrapper-inner > .grve-column-inner-content::after {
    content: none !important;
    display: none !important;
}

/* ==========================================
   ALSTER+ – PORTFOLIO CATEGORY LABELS
   ========================================== */

/* Hide commas and space pills */
#grve-portfolio-title .grve-title-categories .grve-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    font-size: 0 !important;
}

/* Base pill styling */
#grve-portfolio-title .grve-title-categories .grve-categories a {
    display: inline-block;
    font-size: 20px !important;
    padding: 4px 12px !important;
    border-radius: 999px !important;
    line-height: 1.4 !important;
    color: #FFFFFF !important;
    text-decoration: none !important;
}

/* Default colour and white text */
.grve-categories a[href*="/portfolio-category/"] {
    background-color: rgba(255, 255, 255, 0.16) !important;
    color: #fff !important;
}

/* Penthouse */
.grve-categories a[href*="/portfolio-category/penthouse"] {
    background-color: #BA2F36 !important;
}

/* Apartments / Appartements */
.grve-categories a[href*="/portfolio-category/apartments"],
.grve-categories a[href*="/portfolio-category/appartement"] {
    background-color: #624F3B !important;
}

/* Suites */
.grve-categories a[href*="/portfolio-category/suite"] {
    background-color: #C2B1A7 !important;
}

/* Villa / Villen */
.grve-categories a[href*="/portfolio-category/villa"],
.grve-categories a[href*="/portfolio-category/villen"] {
    background-color: #A8B7C0 !important;
}

/* Gardens / Gardenliving */
.grve-categories a[href*="/portfolio-category/gardenliving"] {
    background-color: #3D6C3E !important;
}

/* Stories */
.grve-categories a[href*="/portfolio-category/stories"],
.grve-categories a[href*="/portfolio-category/story"] {
    background-color: #F2B825 !important;
}

/* Coming soon */
.grve-categories a[href*="/portfolio-category/coming-soon"] {
    background-color: #707070 !important;
    color: #fff !important;
}


/* ALSTER+ – Disable portfolio category links */

#grve-portfolio-title .grve-title-categories .grve-categories a,
#grve-portfolio-title .grve-title-categories .grve-categories a:hover,
#grve-portfolio-title .grve-title-categories .grve-categories a:focus {
    pointer-events: none !important;
    cursor: default !important;
    text-decoration: none !important;
    opacity: 1 !important;
    transform: none !important;
    filter: none !important;
    transition: none !important;
}

.keyfacts {
	opacity: 0.55;
}

/* ALSTER+ – Background image with horizontal gutters */

.inset-background {
    position: relative;
}

.inset-background > .grve-background-wrapper {
    left: 30px !important;
    right: 30px !important;
    width: auto !important;
}

@media (max-width: 767px) {
    .inset-background > .grve-background-wrapper {
        left: 15px !important;
        right: 15px !important;
    }
}

/* Related Section Container Width */
#grve-related-section .grve-container { 
	max-width: 100%;
    width: calc(100% - 3.5rem);
}

#grve-related-section .grve-small-text {
	display: none;
}

#grve-related-section .grve-h4 {
    font-size: 24px !important;
	line-height: 1.4 !important;
}


/* ALSTER+ – Global Grey override */

/* Text */
body .grve-text-grey,
body .grve-text-hover-grey:hover {
    color: #707070 !important;
}

/* Background */
body .grve-bg-grey,
body .grve-bg-hover-grey:hover {
    background-color: #707070 !important;
}

/* Border */
body .grve-border-grey,
body .grve-border-hover-grey:hover {
    border-color: #707070 !important;
}

/* Links */
body .grve-link-hover-grey a:hover,
body .grve-inner-section.grve-link-hover-grey a:hover,
body .grve-column.grve-link-hover-grey a:hover,
body .grve-inner-section .grve-column-inner.grve-link-hover-grey a:hover,
body .grve-link-hover-grey .grve-menu-element .grve-arrow:hover,
body .grve-link-hover-grey .widget:not(.grve-social) a:not(.grve-outline):not(.grve-btn):hover,
body .grve-inner-section.grve-link-hover-grey .widget:not(.grve-social) a:not(.grve-outline):not(.grve-btn):hover,
body .grve-column.grve-link-hover-grey .widget:not(.grve-social) a:not(.grve-outline):not(.grve-btn):hover,
body .grve-inner-section .grve-column-inner.grve-link-hover-grey .widget:not(.grve-social) a:not(.grve-outline):not(.grve-btn):hover,
body #grve-theme-wrapper .grve-fixed-colors.grve-link-hover-grey a:hover {
    color: #707070 !important;
}

/* Link Animation */
a {
  -webkit-transition: color 250ms ease-out;
  -moz-transition: color 250ms ease-out;
  -o-transition: color 250ms ease-out;
  transition: color 250ms ease-out;
}