/* =========================================================================
   AMP Projects – Detail Template
   Ablage: child-theme/inc/projects-detail.css
   Begleitend zu: projects-detail-template.php
   Aufbauend auf: CSS-Spec v06 (Eyebrow, Keyfacts, Section, Saeulen, …)
   ========================================================================= */

/* ── Tokens ───────────────────────────────────────────────────────────── */
.amp-detail {
    --amp-red:        #c8102e;
    --amp-red-hover:  #a00c25;
    --amp-red-deep:   #c7082e;
    --amp-dark:       #1a1a1a;
    --amp-mid:        #4a4a4a;
    --amp-light:      #f5f5f3;
    --amp-border:     #e2e2de;
    --amp-white:      #ffffff;
    --amp-hero-blue:  #2c3e62;
    --amp-hero-overlay: linear-gradient(180deg, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0.45) 50%, rgba(0,0,0,0.6) 100%);

    --amp-font-body:  'Georgia', 'Times New Roman', serif;
    --amp-font-ui:    system-ui, -apple-system, 'Segoe UI', sans-serif;

    --amp-radius:     2px;
    --amp-section-px: clamp(16px, 4vw, 32px);
    --amp-content-max: 1100px;
    --amp-narrow-max:  760px;

    color: var(--amp-dark);
    font-family: var(--amp-font-ui);
    line-height: 1.6;
}

/* Reset für inline-content innerhalb des Templates */
.amp-detail * { box-sizing: border-box; }

/* ── HERO ─────────────────────────────────────────────────────────────── */
.amp-hero {
    position: relative;
    min-height: 540px;
    background-size: cover;
    background-position: center;
    background-color: var(--amp-hero-blue);
    color: var(--amp-white);
    padding: 80px var(--amp-section-px) 0px;
}

.amp-hero__overlay {
    position: absolute;
    inset: 0;
    background: var(--amp-hero-overlay);
    z-index: 1;
}

.amp-hero__inner {
    position: relative;
    z-index: 2;
    max-width: var(--amp-content-max);
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 24px;
    transform: translateY(100px);
}

/* Eyebrow Pill (CSS-Spec v06 – Sektion 1) */
.amp-detail .amp-eyebrow {
    display: inline-block;
    width: fit-content;
    margin: 0;
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--amp-white);
}
.amp-detail .amp-eyebrow.amp-eyebrow--pill {
    background-color: var(--amp-red);
    color: var(--amp-white);
    padding: 0.55em 0.9em 0.6em;
    border-radius: var(--amp-radius);
    line-height: 1.1;
}

.amp-hero__h1 {
    font-family: var(--amp-font-body);
    font-size: clamp(1.8rem, 3.4vw, 2.6rem);
    line-height: 1.15;
    font-weight: 700;
    color: var(--amp-white);
    margin: 0;
    max-width: 720px;
}
.amp-hero__h1-zweite {
    display: block;
    font-size: 0.7em;
    font-weight: 400;
    color: rgba(255,255,255,0.85);
    margin-top: 4px;
}

/* ── HERO PANELS (Eckdaten + Maps nebeneinander) ──────────────────────── */
.amp-hero__panels {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    align-items: stretch;
    width: 100%;
}
@media (min-width: 880px) {
    .amp-hero__panels {
        grid-template-columns: minmax(320px, 480px) 1fr;
        gap: 20px;
    }
}

/* ── KEYFACTS (Hero) ──────────────────────────────────────────────────── */
.amp-keyfacts--hero {
    background: rgba(44, 62, 98, 0.92);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: var(--amp-radius);
    padding: 22px 26px;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    display: flex;
    flex-direction: column;
}

/* ── MAPS-PANEL ──────────────────────────────────────────────────────── */
.amp-hero__map {
    border-radius: var(--amp-radius);
    overflow: hidden;
    border: 1px solid rgba(255,255,255,0.12);
    background: rgba(44, 62, 98, 0.4);
    min-height: 360px;
    display: flex;
}
.amp-hero__map iframe {
    width: 100%;
    height: 100%;
    min-height: 360px;
    border: 0;
    display: block;
    flex: 1;
}
@media (max-width: 879px) {
    .amp-hero__map {
        min-height: 260px;
    }
    .amp-hero__map iframe {
        min-height: 260px;
    }
}

.amp-keyfacts__list {
    list-style: none;
    margin: 0;
    padding: 0;
}
.amp-keyfacts__item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 5px 0;
    color: var(--amp-white);
    font-size: 0.92rem;
    line-height: 1.45;
}
.amp-keyfacts__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    margin-top: 2px;
    opacity: 0.9;
    font-size: 0.95rem;
}
.amp-keyfacts__icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}
.amp-keyfacts__text { flex: 1; }
.amp-keyfacts__text strong { font-weight: 600; }
.amp-keyfacts__more {
    opacity: 0.7;
    font-size: 0.85em;
}

.amp-keyfacts__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: auto;
    padding-top: 18px;
    border-top: 1px solid rgba(255,255,255,0.15);
}
.amp-keyfacts__list + .amp-keyfacts__actions { margin-top: 18px; }

/* ── BUTTONS ──────────────────────────────────────────────────────────── */
.amp-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 18px;
    font-family: var(--amp-font-ui);
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: var(--amp-radius);
    border: 1.5px solid transparent;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
    white-space: nowrap;
    line-height: 1.2;
}
.amp-btn--ghost {
    color: var(--amp-white);
    border-color: rgba(255,255,255,0.5);
    background: transparent;
}
.amp-btn--ghost:hover {
    background: rgba(255,255,255,0.1);
    border-color: var(--amp-white);
    color: var(--amp-white);
}
.amp-btn--primary {
    background: var(--amp-red);
    color: var(--amp-white);
    border-color: var(--amp-red);
}
.amp-btn--primary:hover {
    background: var(--amp-red-hover);
    border-color: var(--amp-red-hover);
    color: var(--amp-white);
}
.amp-btn--large {
    padding: 14px 28px;
    font-size: 0.95rem;
}

/* ── PAUSE-BANNER ─────────────────────────────────────────────────────── */
.amp-pause-banner {
    background: #fff8f8;
    border-bottom: 1px solid #f5cdd3;
    padding: 14px var(--amp-section-px);
}
.amp-pause-banner__inner {
    max-width: var(--amp-content-max);
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: var(--amp-mid);
    font-size: 0.92rem;
}
.amp-pause-banner__inner strong {
    color: var(--amp-red);
}

/* ── SECTIONS ─────────────────────────────────────────────────────────── */
.amp-section {
    padding: 56px var(--amp-section-px);
}
.amp-section__inner {
    max-width: var(--amp-content-max);
    margin: 0 auto;
}
.amp-section__inner--narrow {
    max-width: var(--amp-narrow-max);
    text-align: center;
}
.amp-section--einleitung{padding:160px var(--amp-section-px) 0px;}


/* H2 mit rotem Trennstrich (CSS-Spec v06 – Sektion 4) */
.amp-section h2 {
    font-family: var(--amp-font-body);
    font-size: clamp(1.5rem, 2.4vw, 1.9rem)!important;
    font-weight: 700;
    line-height: 1.2;
    color: var(--amp-dark);
    margin: 0 0 28px;
    position: relative;
    padding-bottom: 30px;
}
.amp-section h2::before {
    content: "";
    display: block;
    width: 60px;
    height: 3px;
    background-color: var(--amp-red);
    margin-bottom: 24px;
}
.amp-section--cta h2,
.amp-section--cta h2::before {
    margin-left: auto;
    margin-right: auto;
}
.amp-section--cta h2::before {
    margin-left: auto;
    margin-right: auto;
}

/* Section copy */
.amp-section__copy {
    font-size: 1rem;
    line-height: 1.75;
    color: var(--amp-mid);
}
.amp-section__copy p { margin: 0 0 1em; }
.amp-section__copy p:last-child { margin-bottom: 0; }
.amp-section__copy ul {
    padding-left: 1.4em;
    margin: 0.5em 0 1em;
}
.amp-section__copy ul li {
    margin-bottom: 0.4em;
    line-height: 1.65;
}
.amp-section__copy strong { color: var(--amp-dark); }
.amp-section__copy a { color: var(--amp-red); }

.amp-section__lead {
    font-size: 1.05rem;
    line-height: 1.7;
    color: var(--amp-mid);
    margin: 0 0 24px;
}

/* 2-spaltiges Layout (Bild + Text) */
.amp-section__columns {
    display: grid;
    grid-template-columns: 1fr;
    gap: 32px;
    align-items: start;
}
@media (min-width: 800px) {
    .amp-section__columns {
        grid-template-columns: 1fr 1.4fr;
        gap: 40px;
    }
}
.amp-section__image {
    margin: 0;
    border-radius: var(--amp-radius);
    overflow: hidden;
}
.amp-section__image img {
    width: 100%;
    height: auto;
    display: block;
}
.amp-section__image--full {
    margin-top: 24px;
}

.amp-section__sub {
    margin-top: 28px;
}
.amp-section__sub:first-of-type {
    margin-top: 16px;
}

/* Subheading (CSS-Spec v06 – Sektion 5) */
.amp-subheading,
.amp-detail h3.amp-subheading {
    font-family: inherit;
    font-size: 1.2rem;
    font-weight: 700;
    line-height: 1.3;
    margin: 0 0 8px;
    color: var(--amp-dark);
}

.amp-section__video {
    aspect-ratio: 16 / 9;
    margin: 24px 0;
    border-radius: var(--amp-radius);
    overflow: hidden;
}
.amp-section__video iframe {
    width: 100%;
    height: 100%;
    border: 0;
}

/* ── PREMIUM-BLOCK / 4-SÄULEN (CSS-Spec v06 – Sektion 8) ──────────────── */
.amp-section--premium {
    background: var(--amp-light);
}
.amp-saeulen {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5em;
    margin-top: 2em;
}
@media (max-width: 980px) {
    .amp-saeulen { grid-template-columns: repeat(2, 1fr); gap: 1.25em; }
}
@media (max-width: 600px) {
    .amp-saeulen { grid-template-columns: 1fr; gap: 1em; }
}
.amp-saeule {
    background-color: var(--amp-white);
    border-top: 3px solid var(--amp-red);
    padding: 1.5em;
}
.amp-saeule h3 {
    font-family: inherit;
    font-size: 1.1rem;
    font-weight: 700;
    line-height: 1.3;
    margin: 0 0 0.6em;
    color: var(--amp-red-deep);
}
.amp-saeule p {
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--amp-mid);
    margin: 0;
}
.amp-saeule__icon {
    display: block;
    width: 64px;
    height: 64px;
    margin: 0 0 1em;
}

/* ── REISEABLAUF + LEISTUNGEN (2-Spalten) ─────────────────────────────── */
.amp-section--ablauf-leistungen {
    background: var(--amp-light);
}
.amp-ablauf-leistungen {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
    align-items: start;
}
@media (min-width: 900px) {
    .amp-ablauf-leistungen {
        grid-template-columns: 1fr 1fr;
        gap: 48px;
    }
}
.amp-ablauf-leistungen__col h2 { margin-bottom: 24px; }

/* Akkordeon (CSS-Spec v06 – Sektion 6) */
.amp-reiseablauf {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.amp-reiseablauf__item {
    border: 1px solid var(--amp-border);
    border-radius: var(--amp-radius);
    background: var(--amp-white);
    overflow: hidden;
}
.amp-reiseablauf__summary {
    list-style: none;
    cursor: pointer;
    padding: 16px 56px 16px 22px;
    background: #f5f5f5;
    position: relative;
    transition: background 0.15s ease;
}
.amp-reiseablauf__summary::-webkit-details-marker { display: none; }
.amp-reiseablauf__summary:hover { background: #ededed; }
.amp-reiseablauf__title {
    font-family: inherit;
    font-size: 1rem!important;
    font-weight: 700;
    line-height: 1.3;
    color: #444;
    margin: 0;
}
.amp-reiseablauf__icon {
    position: absolute;
    right: 22px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    color: var(--amp-red);
}
.amp-reiseablauf__icon::before,
.amp-reiseablauf__icon::after {
    content: "";
    position: absolute;
    background: currentColor;
    transition: transform 0.2s ease, opacity 0.2s ease;
}
.amp-reiseablauf__icon::before {
    width: 18px; height: 2px;
    left: 0; top: 50%;
    transform: translateY(-50%);
}
.amp-reiseablauf__icon::after {
    width: 2px; height: 18px;
    left: 50%; top: 0;
    transform: translateX(-50%);
}
.amp-reiseablauf__item[open] .amp-reiseablauf__icon::after {
    opacity: 0;
    transform: translateX(-50%) rotate(90deg);
}
.amp-reiseablauf__content {
    padding: 20px 22px;
    background: var(--amp-white);
    color: var(--amp-mid);
    font-size: 0.95rem;
    line-height: 1.65;
}
.amp-reiseablauf__content p { margin: 0 0 0.6em; }
.amp-reiseablauf__content p:last-child { margin-bottom: 0; }

/* Leistungen-Block (CSS-Spec v06 – Sektion 7) */
.amp-leistungen {
    font-size: 0.95rem;
    line-height: 1.65;
    color: var(--amp-mid);
}
.amp-leistungen h3 {
    font-family: inherit;
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.3;
    margin: 1.5em 0 0.4em;
    color: var(--amp-dark);
}
.amp-leistungen h3:first-child { margin-top: 0; }
.amp-leistungen ul {
    padding-left: 1.2em;
    margin: 0.4em 0 1em;
}
.amp-leistungen ul li {
    margin-bottom: 0.3em;
    line-height: 1.55;
}
.amp-leistungen p {
    margin: 0.3em 0;
}
.amp-leistungen p strong {
    color: var(--amp-dark);
    font-weight: 600;
}

/* ── CTA-SEKTION ──────────────────────────────────────────────────────── */
.amp-section--cta {    
    text-align: center;
}
.amp-section--cta h2::before {
    margin-left: auto;
    margin-right: auto;
}
.amp-section--cta .amp-section__lead {
    max-width: 540px;
    margin-left: auto;
    margin-right: auto;
}

/* ── SERVICE-CARDS / CROSS-SELL (CSS-Spec v06 – Sektion 9) ────────────── */
.amp-services {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5em;
    margin-top: 1em;
}
@media (max-width: 600px) {
    .amp-services { grid-template-columns: 1fr; gap: 1em; }
}
.amp-service-card {
    display: block;
    background: var(--amp-white);
    border: 1px solid var(--amp-border);
    text-decoration: none;
    color: inherit;
    overflow: hidden;
    border-radius: var(--amp-radius);
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}
.amp-service-card:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.08);
    transform: translateY(-2px);
    color: inherit;
    text-decoration: none;
}
.amp-service-card img {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
    object-fit: cover;
}
.amp-service-card__body { padding: 1.5em; }
.amp-service-card h3 {
    font-family: inherit;
    font-size: 1.1rem;
    font-weight: 700;
    line-height: 1.3;
    margin: 0 0 0.5em;
    color: var(--amp-red-deep);
}
.amp-service-card p {
    font-size: 0.95rem;
    line-height: 1.55;
    margin: 0;
    color: var(--amp-mid);
}

/* ── ECKDATEN UNTEN (kompakter) ───────────────────────────────────────── */
.amp-section--eckdaten-bottom {
    padding-top: 0;    
}
.amp-keyfacts--bottom {
    background: var(--amp-light);
    border-left: 3px solid var(--amp-red);
    padding: 22px 28px;
    border-radius: var(--amp-radius);
    text-align: left;
}
.amp-keyfacts__row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 4px 0;
    font-size: 0.95rem;
    color: var(--amp-mid);
    line-height: 1.5;
}
.amp-keyfacts__row strong {
    color: var(--amp-dark);
    font-weight: 600;
    min-width: 200px;
}

/* ── WARUM AMP ────────────────────────────────────────────────────────── */
.amp-section--warum {
    background: var(--amp-light);
}

/* ── FEHLERMELDUNG (Shortcode-Test) ───────────────────────────────────── */
.amp-detail-error {
    background: #fff8f8;
    border: 1px solid #f5cdd3;
    border-left: 3px solid var(--amp-red);
    padding: 16px 20px;
    color: var(--amp-mid);
    font-family: var(--amp-font-ui);
    font-size: 0.95rem;
    border-radius: var(--amp-radius);
}
.amp-detail-error code {
    background: rgba(0,0,0,0.06);
    padding: 1px 6px;
    border-radius: 2px;
    font-size: 0.9em;
}

/* ── ÜBERSICHTS-BUTTON ───────────────────────────────────────────────── */
.amp-section--uebersicht {    
    text-align: center;
}
.amp-btn--ghost-dark {
    background: transparent;
    color: var(--amp-dark);
    border-color: var(--amp-border);
}
.amp-btn--ghost-dark:hover {
    background: var(--amp-dark);
    color: var(--amp-white);
    border-color: var(--amp-dark);
}

/* ── POPUP (Kursanfrage) ─────────────────────────────────────────────── */
.amp-popup {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding: 20px;
}
.amp-popup[hidden] { display: none; }

.amp-popup__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    cursor: pointer;
}
.amp-popup__dialog {
    position: relative;
    background: var(--amp-white);
    border-radius: var(--amp-radius);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
    max-width: 1000px;
    width: 100%;
    max-height: 80vh;
    overflow-y: auto;
    padding: 32px 32px 28px;
    animation: amp-popup-in 0.2s ease;
}
@keyframes amp-popup-in {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}

.amp-popup__close {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    color: var(--amp-mid);
    font-size: 1.6rem;
    line-height: 1;
    cursor: pointer;
    border-radius: var(--amp-radius);
    transition: background 0.15s ease, color 0.15s ease;
}
.amp-popup__close:hover {
    background: var(--amp-light);
    color: var(--amp-red);
}

.amp-popup__title {
    font-family: var(--amp-font-body);
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.2;
    color: var(--amp-dark);
    margin: 0 0 20px;
    padding-right: 36px;
    position: relative;
}
.amp-popup__title::after {
    content: "";
    display: block;
    width: 50px;
    height: 3px;
    background: var(--amp-red);
    margin-top: 12px;
}

.amp-popup__body {
    font-size: 0.95rem;
    color: var(--amp-mid);
    line-height: 1.55;
}
.amp-popup__body label {
    display: block;
    margin-bottom: 4px;
    color: var(--amp-dark);
    font-weight: 500;
}
.amp-popup__body input[type="text"],
.amp-popup__body input[type="email"],
.amp-popup__body input[type="tel"],
.amp-popup__body textarea,
.amp-popup__body select {
    width: 100%;
}

/* Body-Lock wenn Popup offen */
body.amp-popup-open {
    overflow: hidden;
}


@media (max-width: 700px) {
    .amp-hero { padding: 48px 16px 32px; min-height: 0; }
    .amp-keyfacts--hero { max-width: 100%; padding: 18px 18px; }
    .amp-keyfacts__actions { flex-direction: column; align-items: stretch; }
    .amp-btn { width: 100%; }
    .amp-section { padding: 40px 16px; }
    .amp-section h2 { margin-bottom: 20px; }
    .amp-keyfacts__row strong { min-width: 0; }
}

/* ── ACF Backend: readonly-Style fürs Längen-Feld ─────────────────────── */
/* Greift im wp-admin – nicht im Frontend */
.acf-field.amp-readonly input[type="text"] {
    background: #f5f5f3 !important;
    color: #4a4a4a !important;
    cursor: not-allowed;
}
