/* ==========================================================================
   orderQ Design System Layer
   --------------------------------------------------------------------------
   Übernimmt die Form-Sprache des TerminQ Design Systems (Typografie, Pill-
   Controls, Radien, Elevation, Motion, Rhythmus) auf das bestehende orderQ
   Marketing-Frontend.

   Bewusst NICHT übernommen: Farben, Texte, Bilder, Logo. Die orderQ-Marke
   bleibt unverändert (--primary-color: #625bff).

   Wird in layouts/landing.blade.php NACH @stack('styles') geladen, damit die
   seiteneigenen <style>-Blöcke überschrieben werden.
   ========================================================================== */

/* ==================== 1. TOKENS ==================== */
:root {
    /* --- Type --- */
    --ds-font-display: "Archivo", "Helvetica Neue", Helvetica, sans-serif;
    --ds-font-text: "Instrument Sans", "Helvetica Neue", Helvetica, sans-serif;

    /* Die Seiten-Styles lesen diese beiden Variablen — hier umgebogen */
    --font-heading: var(--ds-font-display);
    --font-body: var(--ds-font-text);

    --ds-track-display: -0.035em;
    --ds-track-heading: -0.02em;
    --ds-track-body: -0.005em;
    --ds-track-eyebrow: 0.02em;

    --ds-display-xl: clamp(3.5rem, 7vw, 6rem);
    --ds-display-l: clamp(2.75rem, 5vw, 4.25rem);
    --ds-display-m: clamp(2.25rem, 3.6vw, 3.25rem);
    --ds-display-s: 1.75rem;

    --ds-measure-body: 58ch;

    /* --- Radius: jedes Control ist eine Pille, nichts unter 6px --- */
    --ds-radius-xs: 6px;
    --ds-radius-sm: 10px;
    --ds-radius-md: 14px;
    --ds-radius-lg: 20px;
    --ds-radius-xl: 28px;
    --ds-radius-2xl: 36px;
    --ds-radius-pill: 999px;

    --border-radius: var(--ds-radius-lg);

    /* --- Elevation: zwei Schatten, mehr nicht --- */
    --ds-shadow-card: 0 1px 2px rgba(10, 10, 10, .04), 0 10px 28px rgba(10, 10, 10, .05);
    --ds-shadow-card-hover: 0 2px 4px rgba(10, 10, 10, .06), 0 18px 44px rgba(10, 10, 10, .09);
    --ds-shadow-pop: 0 12px 40px rgba(10, 10, 10, .14);
    --ds-blur-chrome: saturate(180%) blur(16px);

    /* --- Motion: schnell und abbremsend --- */
    --ds-ease-out: cubic-bezier(.2, .8, .2, 1);
    --ds-dur-fast: 120ms;
    --ds-dur-base: 200ms;
    --ds-dur-slow: 400ms;

    --transition: all var(--ds-dur-base) var(--ds-ease-out);
    --ds-transition-control:
        background-color var(--ds-dur-base) var(--ds-ease-out),
        color var(--ds-dur-base) var(--ds-ease-out),
        box-shadow var(--ds-dur-base) var(--ds-ease-out),
        border-color var(--ds-dur-base) var(--ds-ease-out);

    /* --- Rhythmus --- */
    --ds-section-y: clamp(64px, 9vw, 128px);
    --ds-section-y-tight: clamp(48px, 6vw, 80px);

    /* --- Marke (unverändert) --- */
    --primary-light: #837dff;
    --primary-soft: #f1f0ff;
}

/* ==================== 2. BASIS-TYPOGRAFIE ==================== */
/* span bewusst ausgelassen: erbt ohnehin, und ein !important hier würde
   Display-Elemente wie .plan-amount auf die Textschrift zwingen. */
body,
p, li, a, small, strong, em, b, i, label, td, th, blockquote, figcaption,
input, textarea, select, .column-paragraph, .faq-answer, .page-hero-subtitle,
.product-description, .blog-content, .blog-content p, .blog-content li {
    font-family: var(--ds-font-text) !important;
}

body {
    font-size: 17px;
    line-height: 1.55;
    letter-spacing: var(--ds-track-body);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, h5, h6,
.page-hero-title, .page-title, .content-section-title, .subsection-title,
.product-title, .question-title, .plan-amount, .pricing-amount, .pricing-name,
.step-number, .stat-number, .blog-card-title, .hero-title {
    font-family: var(--ds-font-display) !important;
    letter-spacing: var(--ds-track-display);
    text-wrap: balance;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 800;
    line-height: 1.02;
}

h3, h4, h5, h6 {
    font-weight: 700;
    letter-spacing: var(--ds-track-heading);
    line-height: 1.25;
}

p {
    text-wrap: pretty;
}

/* Display-Skala: Headlines sind schwer, eng, fast berührend */
.page-hero-title, .hero-title {
    font-size: var(--ds-display-xl);
    font-weight: 800;
    line-height: 0.94;
    letter-spacing: var(--ds-track-display);
}

.content-section-title,
.page-title,
.section-centered h2,
.faq-header h2,
.gallery-header h2,
.cta-section h2,
.steps-section h2,
.logo-marquee-section h2,
.comparison-header h2 {
    font-size: var(--ds-display-m);
    font-weight: 800;
    line-height: 1.02;
    letter-spacing: var(--ds-track-display);
}

/* Karten-Überschriften bleiben Headings, keine Display-Größe */
.product-card .product-title,
.benefit-item h3,
.step-card h3,
.service-card h3,
.comparison-card h3,
.anwendung-card h3,
.selection-card h3,
.blog-post h3 {
    font-size: 1.375rem;
    font-weight: 700;
    line-height: 1.25;
    letter-spacing: var(--ds-track-heading);
}

.page-hero-subtitle {
    font-size: 1.25rem;
    line-height: 1.5;
    letter-spacing: var(--ds-track-body);
}

.column-paragraph,
.faq-answer p,
.benefit-item p,
.step-card p {
    font-size: 1.0625rem;
    line-height: 1.55;
    letter-spacing: var(--ds-track-body);
}

/* Icons behalten ihre eigene Familie — Symbols Rounded statt der eckigen Icons */
.material-icons,
.material-symbols-rounded {
    font-family: "Material Symbols Rounded", "Material Icons" !important;
    font-variation-settings: "FILL" 0, "wght" 400, "GRAD" 0, "opsz" 24;
    font-weight: normal;
    font-style: normal;
    letter-spacing: normal;
    text-transform: none;
    display: inline-block;
    white-space: nowrap;
    word-wrap: normal;
    direction: ltr;
    -webkit-font-feature-settings: "liga";
    -webkit-font-smoothing: antialiased;
}

/* ==================== 3. CONTROLS — alles ist eine Pille ==================== */
.btn-primary-custom,
.btn-secondary-custom,
.btn-product-primary,
.btn-product-secondary,
.dropdown-cta-btn,
.btn,
button.btn,
.btn-primary,
.btn-outline-primary {
    border-radius: var(--ds-radius-pill) !important;
    font-family: var(--ds-font-text) !important;
    font-weight: 600;
    letter-spacing: var(--ds-track-body);
    transition: var(--ds-transition-control) !important;
    white-space: nowrap;
}

.btn-primary-custom,
.btn-secondary-custom,
.btn-product-primary,
.btn-product-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    height: 56px;
    padding: 0 28px;
    font-size: 17px;
    border-width: 1px;
}

/* Hover hellt auf, statt abzudunkeln. Nichts skaliert, nichts springt. */
.btn-primary-custom,
.btn-product-primary {
    background: var(--primary-color, #625bff);
    color: #fff;
    border: 1px solid transparent;
    box-shadow: none;
}

.btn-primary-custom:hover,
.btn-primary-custom:focus-visible,
.btn-product-primary:hover,
.btn-product-primary:focus-visible {
    background: var(--primary-light, #837dff);
    color: #fff;
    transform: none !important;
    box-shadow: none;
}

.btn-secondary-custom,
.btn-product-secondary {
    background: transparent;
    color: var(--primary-color, #625bff);
    border: 1px solid var(--primary-color, #625bff);
    box-shadow: none;
}

.btn-secondary-custom:hover,
.btn-secondary-custom:focus-visible,
.btn-product-secondary:hover,
.btn-product-secondary:focus-visible {
    background: var(--primary-soft, #f1f0ff);
    color: var(--primary-color, #625bff);
    border-color: var(--primary-color, #625bff);
    transform: none !important;
    box-shadow: none;
}

/* Auf dunklem Grund / über Bildern: weiße Pille mit Haarlinie */
.cta-section .btn-secondary-custom,
.section-dark .btn-secondary-custom {
    background: transparent;
    border-color: rgba(255, 255, 255, .6);
    color: #fff;
}

.cta-section .btn-secondary-custom:hover,
.section-dark .btn-secondary-custom:hover {
    background: rgba(255, 255, 255, .12);
    border-color: #fff;
    color: #fff;
}

/* Kompakte Pille in der Navigation */
.nav-buttons .btn-primary-custom,
.nav-buttons .btn-secondary-custom {
    height: 44px;
    padding: 0 20px;
    font-size: 16px;
}

.dropdown-cta-btn {
    display: inline-flex;
    align-items: center;
    height: 44px;
    padding: 0 20px;
    font-size: 16px;
}

.dropdown-cta-btn:hover {
    transform: none !important;
    box-shadow: none;
    background: rgba(255, 255, 255, .88);
}

/* Formularfelder: ebenfalls Pillen, Haarlinien-Rahmen */
.form-control,
.form-control-custom,
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="search"],
select {
    border-radius: var(--ds-radius-pill) !important;
    border: 1px solid #dedede;
    padding: 0 20px;
    height: 52px;
    font-size: 16px;
    transition: var(--ds-transition-control);
    box-shadow: none !important;
}

textarea.form-control,
textarea.form-control-custom {
    border-radius: var(--ds-radius-lg) !important;
    border: 1px solid #dedede;
    padding: 16px 20px;
    height: auto;
    font-size: 16px;
}

.form-control:focus,
.form-control-custom:focus,
textarea.form-control:focus,
select:focus {
    border-color: var(--primary-color, #625bff);
    outline: none;
}

/* Tags, Badges, Eyebrows — Satzform, kein Versal-Satz */
.product-badge,
.pricing-badge,
.trust-badge,
.blog-category,
.badge,
.subtitle,
.eyebrow {
    border-radius: var(--ds-radius-pill) !important;
    font-family: var(--ds-font-text) !important;
    font-weight: 600;
    font-size: 13px;
    letter-spacing: var(--ds-track-eyebrow);
    text-transform: none !important;
}

/* Pills sind inline, sie füllen keine Kartenbreite */
.product-card .product-badge {
    display: inline-flex;
    align-items: center;
    align-self: flex-start;
    width: auto;
    height: 28px;
    padding: 0 14px;
}

/* ==================== 4. NAVIGATION ==================== */
.main-nav {
    background: rgba(255, 255, 255, .72);
    -webkit-backdrop-filter: var(--ds-blur-chrome);
    backdrop-filter: var(--ds-blur-chrome);
    box-shadow: none;
    border-bottom: 1px solid rgba(222, 222, 222, .6);
    transition: padding var(--ds-dur-base) var(--ds-ease-out);
}

.main-nav.scrolled {
    box-shadow: none;
    border-bottom-color: #dedede;
}

.nav-link {
    font-family: var(--ds-font-text) !important;
    font-weight: 600;
    font-size: 16px;
    letter-spacing: var(--ds-track-body);
}

.mega-dropdown {
    border-radius: var(--ds-radius-xl);
    box-shadow: var(--ds-shadow-pop);
    border: 1px solid #ebebeb;
}

.dropdown-link {
    border-radius: var(--ds-radius-md);
    transition: background-color var(--ds-dur-base) var(--ds-ease-out);
}

.dropdown-link:hover {
    transform: none;
    background: var(--primary-soft, #f1f0ff);
}

.dropdown-text h4 {
    font-family: var(--ds-font-display) !important;
    font-weight: 700;
    letter-spacing: var(--ds-track-heading);
}

.dropdown-cta-block {
    border-radius: var(--ds-radius-lg);
}

.offcanvas {
    border-radius: 0;
}

.mobile-dropdown-links a {
    font-family: var(--ds-font-text) !important;
    font-weight: 600;
    min-height: 48px;
    display: flex;
    align-items: center;
}

/* ==================== 5. FLÄCHEN & KARTEN ==================== */
.benefit-item,
.product-card,
.step-card,
.service-card,
.comparison-card,
.anwendung-card,
.selection-card,
.blog-post,
.qr-code-container,
.faq-container,
.feature-card {
    border-radius: var(--ds-radius-xl) !important;
    box-shadow: var(--ds-shadow-card);
    border: none;
    transition: transform var(--ds-dur-base) var(--ds-ease-out),
                box-shadow var(--ds-dur-base) var(--ds-ease-out);
}

.benefit-item:hover,
.product-card:hover,
.service-card:hover,
.comparison-card:hover,
.blog-post:hover,
.selection-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--ds-shadow-card-hover);
}

/* Akzentkarten tragen keine Schatten — die Farbe trennt */
.product-card.featured,
.dropdown-cta-block {
    box-shadow: none;
}

.qr-code-container:hover {
    transform: translateY(-2px);
}

.gallery-image-wrapper,
.content-image img,
.content-image video,
.page-hero-image-block,
.feature-image img {
    border-radius: var(--ds-radius-2xl) !important;
}

.gallery-image {
    border-radius: var(--ds-radius-2xl);
}

/* ==================== 6. FAQ ==================== */
.faq-item,
.faq-wrap,
.faq-question-wrap {
    border-radius: var(--ds-radius-lg) !important;
    box-shadow: none;
    border: 1px solid #ebebeb;
    transition: border-color var(--ds-dur-base) var(--ds-ease-out),
                background-color var(--ds-dur-base) var(--ds-ease-out);
}

.faq-item:hover,
.faq-wrap:hover {
    border-color: #dedede;
}

.faq-question,
.question-title {
    font-family: var(--ds-font-display) !important;
    font-weight: 700;
    letter-spacing: var(--ds-track-heading);
}

/* Nur das Chevron dreht sich */
.faq-question .material-icons,
.faq-icon .material-icons {
    transition: transform var(--ds-dur-base) var(--ds-ease-out);
}

.faq-price-highlight {
    border-radius: var(--ds-radius-md);
}

/* ==================== 7. RHYTHMUS DER SEKTIONEN ==================== */
.section-white,
.section-gray,
.faq-section,
.gallery-section,
.steps-section,
.cta-section,
.products-section,
.comparison-section,
.logo-marquee-section {
    padding-top: var(--ds-section-y);
    padding-bottom: var(--ds-section-y);
}

.page-hero {
    padding-top: var(--ds-section-y);
    padding-bottom: var(--ds-section-y-tight);
}

.cta-section {
    border-radius: 0;
}

.section-centered p,
.faq-header p,
.gallery-header p {
    max-width: var(--ds-measure-body);
    margin-left: auto;
    margin-right: auto;
}

/* ==================== 8. KAROUSSELS ==================== */
.slick-arrow {
    border-radius: var(--ds-radius-pill) !important;
    transition: var(--ds-transition-control);
}

.slick-arrow:hover {
    transform: translateY(-50%);
}

.slick-dots li button:before {
    transition: opacity var(--ds-dur-base) var(--ds-ease-out);
}

.logo-slide img {
    transition: opacity var(--ds-dur-base) var(--ds-ease-out);
}

/* ==================== 9. FOOTER & COOKIE-BANNER ==================== */
.footer .title {
    font-family: var(--ds-font-display) !important;
    letter-spacing: var(--ds-track-heading);
}

.footer a {
    transition: color var(--ds-dur-base) var(--ds-ease-out);
}

.footer .flag {
    border-radius: var(--ds-radius-xs) !important;
}

.cookie-banner {
    border-radius: 0;
    box-shadow: var(--ds-shadow-pop);
}

.cookie-banner .btn,
.cookie-banner .btn-primary-custom {
    height: 44px;
    padding: 0 20px;
    font-size: 15px;
    border-radius: var(--ds-radius-pill) !important;
}

.modal-content {
    border-radius: var(--ds-radius-xl) !important;
}

/* ==================== 10. RESPONSIVE ==================== */
@media (max-width: 768px) {
    /* Tap-Targets: 44px Minimum */
    .btn-primary-custom,
    .btn-secondary-custom,
    .btn-product-primary,
    .btn-product-secondary,
    .btn {
        min-height: 44px;
    }

    .page-hero-buttons {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }

    .page-hero-buttons .btn-primary-custom,
    .page-hero-buttons .btn-secondary-custom {
        width: 100%;
    }

    .mobile-dropdown-links a {
        min-height: 48px;
    }
}

/* ==================== 11. MOTION-PRÄFERENZ ==================== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
        scroll-behavior: auto !important;
    }
}
