/* ============================================================
   STYLES.CSS — Globales Design-System
   Rainer Günter Galerie
   ============================================================ */

/* ============================================================
   LOCAL FONTS — Cormorant Garamond (DSGVO-konform)
   ============================================================ */
@font-face {
    font-family: 'Cormorant Garamond';
    font-style: normal;
    font-weight: 300;
    font-display: swap;
    src: url('../fonts/CormorantGaramond-Light.ttf') format('truetype');
}
@font-face {
    font-family: 'Cormorant Garamond';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('../fonts/CormorantGaramond-Regular.ttf') format('truetype');
}
@font-face {
    font-family: 'Cormorant Garamond';
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url('../fonts/CormorantGaramond-Medium.ttf') format('truetype');
}
@font-face {
    font-family: 'Cormorant Garamond';
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url('../fonts/CormorantGaramond-SemiBold.ttf') format('truetype');
}
@font-face {
    font-family: 'Cormorant Garamond';
    font-style: italic;
    font-weight: 300;
    font-display: swap;
    src: url('../fonts/CormorantGaramond-LightItalic.ttf') format('truetype');
}
@font-face {
    font-family: 'Cormorant Garamond';
    font-style: italic;
    font-weight: 400;
    font-display: swap;
    src: url('../fonts/CormorantGaramond-Italic.ttf') format('truetype');
}
@font-face {
    font-family: 'Cormorant Garamond';
    font-style: italic;
    font-weight: 500;
    font-display: swap;
    src: url('../fonts/CormorantGaramond-MediumItalic.ttf') format('truetype');
}

/* ============================================================
   CSS VARIABLEN
   ============================================================ */
:root {
    --gold:        #c9a96e;
    --gold-dark:   #a8894f;
    --gold-light:  #e8d5b0;
    --warm-white:  #faf8f4;
    --cream:       #f3ede3;
    --ink:         #111009;
    --charcoal:    #2a2520;
    --mid-gray:    #6b6259;
    --light-gray:  #ddd6cc;
    --border:      #e8e2d9;

    --font-display: 'Cormorant Garamond', 'Georgia', serif;
    --font-serif:   'Cormorant Garamond', 'Georgia', serif;
    --font-sans:    system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;

    --space-xs:  0.5rem;
    --space-s:   1rem;
    --space-m:   1.5rem;
    --space-l:   2.5rem;
    --space-xl:  4rem;
    --space-2xl: 7rem;

    --header-h: 72px;
    --ease: cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
    --transition: 0.3s var(--ease);
    --transition-slow: 0.6s var(--ease-out);
    --radius: 2px;
}

/* ============================================================
   RESET & BASIS
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; font-size: 16px; height: 100%; }

body {
    font-family: var(--font-sans);
    background-color: var(--warm-white);
    color: var(--charcoal);
    font-size: 1rem;
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    min-height: 100%;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1;
}

img { width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }

h1[id], h2[id], h3[id], section[id] {
    scroll-margin-top: calc(var(--header-h) + 1rem);
}

/* ============================================================
   TYPOGRAFIE
   ============================================================ */
h1 {
    font-family: var(--font-display);
    font-weight: 300;
    font-size: clamp(2.4rem, 6vw, 4rem);
    line-height: 1.1;
    color: var(--ink);
    letter-spacing: -0.01em;
}

h2 {
    font-family: var(--font-display);
    font-weight: 400;
    font-size: clamp(1.2rem, 2.5vw, 1.6rem);
    line-height: 1.3;
    color: var(--ink);
}

h3 {
    font-family: var(--font-sans);
    font-weight: 500;
    font-size: 0.75rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--mid-gray);
}

.lead {
    font-family: var(--font-display);
    font-size: clamp(1.1rem, 2vw, 1.3rem);
    font-style: italic;
    color: var(--mid-gray);
    line-height: 1.75;
    font-weight: 300;
}

.label {
    font-family: var(--font-sans);
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--gold);
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
    display: inline-block;
    font-family: var(--font-sans);
    font-size: 0.72rem;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    padding: 0.85rem 1.8rem;
    border-radius: var(--radius);
    cursor: pointer;
    transition: background var(--transition), color var(--transition),
                border-color var(--transition), transform var(--transition),
                box-shadow var(--transition);
    text-decoration: none;
    border: none;
    position: relative;
}

.btn--primary, .btn.cta {
    background-color: var(--gold);
    color: white;
}
.btn--primary:hover, .btn.cta:hover {
    background-color: var(--gold-dark);
    transform: translateY(-1px);
    box-shadow: 0 6px 24px rgba(201, 169, 110, 0.3);
}

.btn--dark {
    background-color: var(--ink);
    color: white;
}
.btn--dark:hover {
    background-color: var(--charcoal);
    transform: translateY(-1px);
}

.btn--secondary {
    background-color: transparent;
    color: var(--gold);
    border: 1.5px solid var(--gold);
}
.btn--secondary:hover {
    background-color: var(--gold);
    color: white;
}

.btn--ghost {
    background-color: transparent;
    color: white;
    border: 1px solid rgba(255,255,255,0.5);
}
.btn--ghost:hover {
    border-color: white;
    background: rgba(255,255,255,0.1);
}

.btn--outline {
    background-color: transparent;
    color: var(--charcoal);
    border: 1px solid var(--border);
}
.btn--outline:hover {
    border-color: var(--gold);
    color: var(--gold);
}

.btn--interest {
    background-color: transparent;
    color: var(--charcoal);
    border: 1px solid var(--border);
    font-size: 0.7rem;
    padding: 0.65rem 1.2rem;
}
.btn--interest:hover {
    background-color: var(--gold);
    color: white;
    border-color: var(--gold);
}

.btn--sold,
.btn--interest.btn--sold,
.btn--interest.btn--sold:hover {
    background-color: #c23b3b;
    color: #ffffff;
    border-color: #c23b3b;
    cursor: not-allowed;
    pointer-events: none;
    transform: none;
    box-shadow: none;
}

/* ============================================================
   HEADER & NAVIGATION
   ============================================================ */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: var(--ink);
    height: var(--header-h);
    padding: 0 var(--space-l);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.logo-link { display: flex; align-items: center; }

#logo {
    height: 46px;
    width: auto;
    filter: invert(1) sepia(1) saturate(0.4) brightness(1.2);
}

/* Hamburger */
#menu-toggle { display: none; }

nav label.menu-label {
    display: block;
    width: 44px;
    height: 44px;
    cursor: pointer;
    background-image: url('../images/icons/toggle-menu.svg');
    background-size: 22px;
    background-repeat: no-repeat;
    background-position: center;
    position: relative;
    z-index: 1001;
    transition: opacity var(--transition);
    filter: invert(1);
}
nav label.menu-label:hover { opacity: 0.7; }

nav ul {
    list-style: none;
    position: absolute;
    top: var(--header-h);
    left: 0;
    width: 100%;
    background: var(--ink);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s var(--ease-out);
}

nav ul li {
    opacity: 0;
    transform: translateX(-12px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

nav ul li a {
    display: block;
    padding: 1rem 2rem;
    color: rgba(255,255,255,0.75);
    font-family: var(--font-sans);
    font-size: 0.85rem;
    font-weight: 400;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    transition: color var(--transition), padding-left var(--transition);
}

nav ul li a:hover,
nav ul li a.active {
    color: var(--gold);
    padding-left: 2.5rem;
}

#menu-toggle:checked ~ ul { max-height: 400px; }
#menu-toggle:checked ~ ul li {
    opacity: 1;
    transform: translateX(0);
}
#menu-toggle:checked ~ ul li:nth-child(1) { transition-delay: 0.05s; }
#menu-toggle:checked ~ ul li:nth-child(2) { transition-delay: 0.1s; }
#menu-toggle:checked ~ ul li:nth-child(3) { transition-delay: 0.15s; }
#menu-toggle:checked ~ ul li:nth-child(4) { transition-delay: 0.2s; }

#menu-toggle:checked + label.menu-label {
    background-image: url('../images/icons/toggle-x.svg');
}

/* Desktop Navigation */
@media (min-width: 960px) {
    header { padding: 0 var(--space-xl); }

    nav label.menu-label { display: none; }
    nav ul {
        position: static;
        max-height: none;
        overflow: visible;
        display: flex;
        flex-direction: row;
        background: transparent;
        width: auto;
        gap: 0.25rem;
    }
    nav ul li {
        opacity: 1;
        transform: none;
    }
    nav ul li a {
        padding: 0.4rem 0.9rem;
        font-size: 0.72rem;
        border: none;
        color: rgba(255,255,255,0.65);
        letter-spacing: 0.1em;
    }
    nav ul li a:hover,
    nav ul li a.active {
        color: white;
        padding-left: 0.9rem;
        background: transparent;
    }
    nav ul li a.active {
        color: var(--gold);
    }
}

/* ============================================================
   SCROLL-NACH-OBEN KNOPF
   ============================================================ */
a.oben {
    position: fixed;
    bottom: 2rem;
    right: 1.5rem;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--ink);
    color: white;
    font-size: 1.1rem;
    border-radius: 50%;
    text-decoration: none;
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transform: translateY(12px);
    transition: opacity var(--transition), transform var(--transition), visibility var(--transition);
}

a.oben.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
a.oben:hover { background-color: var(--gold); }

/* ============================================================
   FOOTER
   ============================================================ */
footer {
    background-color: var(--ink);
    color: rgba(255,255,255,0.4);
    text-align: center;
    padding: var(--space-l);
    font-size: 0.75rem;
    letter-spacing: 0.05em;
    font-family: var(--font-sans);
}

footer a {
    color: rgba(255,255,255,0.6);
    transition: color var(--transition);
}
footer a:hover { color: var(--gold); }

/* ============================================================
   DIVIDER
   ============================================================ */
.divider {
    width: 40px;
    height: 1px;
    background: var(--gold);
    margin: var(--space-m) auto;
}
.divider--left { margin-left: 0; }

/* ============================================================
   UTILITY: SCREEN-READER ONLY
   ============================================================ */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
