/*
Theme Name:   Astra Child – GrünHaus Agentur
Theme URI:    https://example.com/astra-child-gruenhaus/
Description:  Child Theme für Astra – Design für eine Agentur im Bereich Garten & Haushalt. Natürlich, warm und einladend mit Grüntönen, dezenten Terrakotta-Akzenten und einer modernen, organischen Typografie.
Author:       GrünHaus
Author URI:   https://example.com/
Template:     astra
Version:      1.0.0
License:      GNU General Public License v2 or later
License URI:  http://www.gnu.org/licenses/gpl-2.0.html
Tags:         astra-child, garden, household, business, agency
Text Domain:  astra-child-gruenhaus
*/

/* =========================================================
   DESIGN-SYSTEM – CSS-Variablen
   ========================================================= */
:root {
    /* Farbpalette – natürlich, warm, einladend */
    --gh-green-900: #1f3a2b;   /* Dunkelgrün – Headlines */
    --gh-green-700: #2f5d3f;   /* Mittelgrün – Primärfarbe */
    --gh-green-500: #5a8a6b;   /* Salbei – Akzent */
    --gh-green-300: #b8d4be;   /* Pastell-Grün */
    --gh-green-50:  #eef4ef;   /* Sehr helles Grün – Backgrounds */

    --gh-terra-600: #c1693d;   /* Terrakotta – Call-to-Action */
    --gh-terra-400: #e89971;   /* Helles Terrakotta */

    --gh-sand-100:  #faf6ef;   /* Sandbeige – Backgrounds */
    --gh-sand-300:  #e8dfc9;   /* Tiefes Sandbeige */

    --gh-ink:       #2b2a26;   /* Fließtext */
    --gh-muted:     #6f6d65;   /* Sekundärtext */
    --gh-white:     #ffffff;
    --gh-line:      #e6e2d8;   /* Trennlinien */

    /* Typografie */
    --gh-font-display: 'Fraunces', 'Playfair Display', Georgia, serif;
    --gh-font-body:    'Nunito Sans', 'Helvetica Neue', Arial, sans-serif;

    /* Spacing-Scale */
    --gh-space-xs: 0.5rem;
    --gh-space-sm: 1rem;
    --gh-space-md: 2rem;
    --gh-space-lg: 4rem;
    --gh-space-xl: 6rem;

    /* Radius & Shadow */
    --gh-radius-sm: 8px;
    --gh-radius-md: 16px;
    --gh-radius-lg: 28px;
    --gh-radius-full: 999px;

    --gh-shadow-sm: 0 2px 8px rgba(31, 58, 43, 0.06);
    --gh-shadow-md: 0 10px 30px rgba(31, 58, 43, 0.10);
    --gh-shadow-lg: 0 24px 60px rgba(31, 58, 43, 0.14);

    /* Übergänge */
    --gh-trans-fast: 180ms ease;
    --gh-trans-base: 320ms cubic-bezier(0.22, 1, 0.36, 1);
}

/* =========================================================
   Web-Font – Fraunces (Display) & Nunito Sans (Body)
   ========================================================= */
@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,400;9..144,500;9..144,600;9..144,700&family=Nunito+Sans:wght@300;400;600;700&display=swap');

/* =========================================================
   Basis-Reset & Typografie
   ========================================================= */
body {
    font-family: var(--gh-font-body);
    color: var(--gh-ink);
    background-color: var(--gh-sand-100);
    font-size: 17px;
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6,
.entry-title,
.site-title {
    font-family: var(--gh-font-display);
    color: var(--gh-green-900);
    font-weight: 600;
    line-height: 1.15;
    letter-spacing: -0.01em;
}

h1, .entry-title { font-size: clamp(2.4rem, 5vw, 4rem); }
h2 { font-size: clamp(1.9rem, 3.5vw, 2.8rem); }
h3 { font-size: clamp(1.4rem, 2.5vw, 1.8rem); }

p, li {
    color: var(--gh-ink);
}

a {
    color: var(--gh-green-700);
    text-decoration: none;
    transition: color var(--gh-trans-fast);
}
a:hover {
    color: var(--gh-terra-600);
}

/* =========================================================
   Header & Navigation (Astra Overrides)
   ========================================================= */
.ast-primary-header-bar {
    background-color: rgba(255, 255, 255, 0.92) !important;
    backdrop-filter: saturate(140%) blur(10px);
    -webkit-backdrop-filter: saturate(140%) blur(10px);
    border-bottom: 1px solid var(--gh-line);
}

.site-title a,
.site-logo-img img {
    color: var(--gh-green-900) !important;
}

.main-header-menu .menu-link,
.main-navigation a {
    font-family: var(--gh-font-body);
    font-weight: 600;
    font-size: 15px;
    letter-spacing: 0.02em;
    color: var(--gh-green-900) !important;
    transition: color var(--gh-trans-fast);
}

.main-header-menu .menu-item:hover > .menu-link,
.main-header-menu .current-menu-item > .menu-link {
    color: var(--gh-terra-600) !important;
}

/* dezenter Hover-Indikator */
.main-header-menu > .menu-item > .menu-link {
    position: relative;
}
.main-header-menu > .menu-item > .menu-link::after {
    content: '';
    position: absolute;
    left: 20px;
    right: 20px;
    bottom: 12px;
    height: 2px;
    background: var(--gh-terra-600);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform var(--gh-trans-base);
}
.main-header-menu > .menu-item:hover > .menu-link::after,
.main-header-menu > .current-menu-item > .menu-link::after {
    transform: scaleX(1);
}

/* =========================================================
   Buttons – Astra & WP Block-Buttons
   ========================================================= */
.ast-button,
.button,
button,
input[type="submit"],
.wp-block-button__link,
.menu-item-has-children .menu-link.ast-menu-toggle {
    font-family: var(--gh-font-body);
    font-weight: 700;
    letter-spacing: 0.03em;
    padding: 0.95em 2em;
    border-radius: var(--gh-radius-full);
    border: none;
    background: var(--gh-green-700);
    color: var(--gh-white) !important;
    box-shadow: var(--gh-shadow-sm);
    transition: transform var(--gh-trans-fast), box-shadow var(--gh-trans-base), background var(--gh-trans-base);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.5em;
}

.ast-button:hover,
.button:hover,
button:hover,
input[type="submit"]:hover,
.wp-block-button__link:hover {
    background: var(--gh-terra-600);
    transform: translateY(-2px);
    box-shadow: var(--gh-shadow-md);
}

/* Outline-Button Variante */
.wp-block-button.is-style-outline .wp-block-button__link {
    background: transparent;
    color: var(--gh-green-700) !important;
    border: 2px solid var(--gh-green-700);
}
.wp-block-button.is-style-outline .wp-block-button__link:hover {
    background: var(--gh-green-700);
    color: var(--gh-white) !important;
    border-color: var(--gh-green-700);
}

/* =========================================================
   Hero-Bereich (für die Startseite)
   ========================================================= */
.gh-hero {
    position: relative;
    padding: var(--gh-space-xl) var(--gh-space-md);
    background:
        radial-gradient(ellipse at top right, rgba(184, 212, 190, 0.55), transparent 55%),
        radial-gradient(ellipse at bottom left, rgba(232, 153, 113, 0.18), transparent 50%),
        var(--gh-sand-100);
    overflow: hidden;
    isolation: isolate;
}

.gh-hero::before {
    /* dekoratives Blattmuster */
    content: '';
    position: absolute;
    inset: 0;
    background-image: url('assets/images/leaf-pattern.svg');
    background-repeat: no-repeat;
    background-position: 105% 50%;
    background-size: 540px;
    opacity: 0.4;
    z-index: -1;
    pointer-events: none;
}

.gh-hero__inner {
    max-width: 1180px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    align-items: center;
    gap: var(--gh-space-lg);
}

.gh-hero__eyebrow {
    display: inline-block;
    padding: 0.4em 1em;
    border-radius: var(--gh-radius-full);
    background: rgba(47, 93, 63, 0.1);
    color: var(--gh-green-700);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin-bottom: var(--gh-space-sm);
}

.gh-hero__title {
    margin: 0 0 var(--gh-space-sm) 0;
}
.gh-hero__title em {
    font-style: italic;
    color: var(--gh-terra-600);
    font-weight: 500;
}

.gh-hero__lead {
    font-size: 1.15rem;
    color: var(--gh-muted);
    max-width: 50ch;
    margin-bottom: var(--gh-space-md);
}

.gh-hero__cta {
    display: flex;
    gap: var(--gh-space-sm);
    flex-wrap: wrap;
}

.gh-hero__visual {
    position: relative;
    aspect-ratio: 4 / 5;
    border-radius: var(--gh-radius-lg);
    background: var(--gh-green-300);
    background-image: url('assets/images/hero-illustration.svg');
    background-size: cover;
    background-position: center;
    box-shadow: var(--gh-shadow-lg);
    transform: rotate(-1.5deg);
}

@media (max-width: 900px) {
    .gh-hero__inner { grid-template-columns: 1fr; }
    .gh-hero__visual { aspect-ratio: 4 / 3; }
}

/* =========================================================
   Service-Karten (Garten / Haushalt / etc.)
   ========================================================= */
.gh-services {
    padding: var(--gh-space-xl) var(--gh-space-md);
    background: var(--gh-white);
}
.gh-services__head {
    max-width: 720px;
    margin: 0 auto var(--gh-space-lg);
    text-align: center;
}
.gh-services__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--gh-space-md);
    max-width: 1180px;
    margin: 0 auto;
}
.gh-service-card {
    background: var(--gh-sand-100);
    border: 1px solid var(--gh-line);
    border-radius: var(--gh-radius-md);
    padding: var(--gh-space-md);
    position: relative;
    overflow: hidden;
    transition: transform var(--gh-trans-base), box-shadow var(--gh-trans-base), border-color var(--gh-trans-base);
}
.gh-service-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--gh-green-700), var(--gh-terra-400));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform var(--gh-trans-base);
}
.gh-service-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--gh-shadow-md);
    border-color: var(--gh-green-300);
}
.gh-service-card:hover::before {
    transform: scaleX(1);
}
.gh-service-card__icon {
    width: 64px;
    height: 64px;
    border-radius: var(--gh-radius-md);
    background: var(--gh-green-50);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: var(--gh-space-sm);
}
.gh-service-card__icon img,
.gh-service-card__icon svg {
    width: 36px;
    height: 36px;
}
.gh-service-card h3 {
    margin: 0 0 0.5em 0;
}
.gh-service-card p {
    color: var(--gh-muted);
    font-size: 0.96rem;
    margin: 0 0 var(--gh-space-sm) 0;
}
.gh-service-card a.gh-link {
    font-weight: 700;
    color: var(--gh-green-700);
    display: inline-flex;
    align-items: center;
    gap: 0.4em;
}
.gh-service-card a.gh-link::after {
    content: '→';
    transition: transform var(--gh-trans-fast);
}
.gh-service-card a.gh-link:hover::after {
    transform: translateX(4px);
}

/* =========================================================
   Inhalte / Sidebar / Cards generell
   ========================================================= */
.site-content,
.ast-container {
    background: transparent;
}

.entry-content {
    font-size: 1.05rem;
    line-height: 1.8;
}

.entry-content blockquote {
    border-left: 4px solid var(--gh-terra-400);
    padding: var(--gh-space-sm) var(--gh-space-md);
    background: var(--gh-green-50);
    border-radius: 0 var(--gh-radius-md) var(--gh-radius-md) 0;
    font-family: var(--gh-font-display);
    font-style: italic;
    color: var(--gh-green-900);
    margin: var(--gh-space-md) 0;
}

/* Sidebar Widgets */
.widget {
    background: var(--gh-white);
    padding: var(--gh-space-md);
    border-radius: var(--gh-radius-md);
    margin-bottom: var(--gh-space-md);
    box-shadow: var(--gh-shadow-sm);
}
.widget-title {
    font-size: 1.1rem;
    margin-bottom: var(--gh-space-sm);
    padding-bottom: var(--gh-space-xs);
    border-bottom: 2px solid var(--gh-green-300);
}

/* =========================================================
   Footer
   ========================================================= */
.site-footer,
.footer-adv,
[data-section="section-footer-builder"] {
    background: var(--gh-green-900) !important;
    color: var(--gh-sand-100) !important;
    padding: var(--gh-space-lg) var(--gh-space-md) !important;
}
.site-footer a {
    color: var(--gh-green-300) !important;
}
.site-footer a:hover {
    color: var(--gh-terra-400) !important;
}
.site-footer h1, .site-footer h2,
.site-footer h3, .site-footer h4 {
    color: var(--gh-sand-100) !important;
}
.site-footer .widget-title {
    border-bottom-color: rgba(255,255,255,0.15);
}

/* =========================================================
   Formulare (Kontaktformular Astra/CF7 kompatibel)
   ========================================================= */
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="url"],
input[type="password"],
textarea,
select {
    background: var(--gh-white);
    border: 1.5px solid var(--gh-line);
    border-radius: var(--gh-radius-sm);
    padding: 0.85em 1em;
    font-family: var(--gh-font-body);
    font-size: 16px;
    color: var(--gh-ink);
    transition: border-color var(--gh-trans-fast), box-shadow var(--gh-trans-fast);
    width: 100%;
}
input:focus, textarea:focus, select:focus {
    outline: none;
    border-color: var(--gh-green-700);
    box-shadow: 0 0 0 4px rgba(47, 93, 63, 0.12);
}

/* =========================================================
   Utility-Klassen
   ========================================================= */
.gh-section { padding: var(--gh-space-xl) var(--gh-space-md); }
.gh-container { max-width: 1180px; margin: 0 auto; }
.gh-text-center { text-align: center; }
.gh-bg-sand { background: var(--gh-sand-100); }
.gh-bg-green-50 { background: var(--gh-green-50); }
.gh-bg-white { background: var(--gh-white); }

/* =========================================================
   Animationen
   ========================================================= */
@keyframes gh-fade-up {
    from { opacity: 0; transform: translateY(24px); }
    to   { opacity: 1; transform: translateY(0); }
}
.gh-animate-in {
    animation: gh-fade-up 700ms var(--gh-trans-base) both;
}
.gh-animate-in.delay-1 { animation-delay: 100ms; }
.gh-animate-in.delay-2 { animation-delay: 220ms; }
.gh-animate-in.delay-3 { animation-delay: 340ms; }

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
}

/* =========================================================
   Responsive – Mobile Anpassungen
   ========================================================= */
@media (max-width: 768px) {
    body { font-size: 16px; }
    .gh-section { padding: var(--gh-space-lg) var(--gh-space-sm); }
    .gh-hero { padding: var(--gh-space-lg) var(--gh-space-sm); }
    .gh-hero__visual { transform: none; }
}
