/*
Theme Name: Moth Theme
Version: 1.3.1
Author: M. Oth
Description: Ein Theme, um Indie-Autoren und Selfpublishern das Leben zu erleichtern. Ein interaktives Karussell stellt deine Bücher in den Fokus, inklusive individueller Shop-Links und stimmungsvoller Hintergründe. Nutze intuitive Werke-Verwaltung mit Funktionen für Leseproben, Triggerwarnungen, ARC-Formulare und ISBNs. Mit Optionen für Blog, Newsletter, Social Media und automatischer Erzeugung eleganter Shop-Links für dein Marketing. Leichtgewichtig, barrierefrei und DSGVO-konform, mit Fokus auf Nutzerfreundlichkeit.
*/

/* --- BASE SETTINGS & LAYOUT --- */
:root {
    --shadow-subtle: 1px 1px 6px rgba(0, 0, 0, 0.4); 
    --shadow-box: 0 4px 15px rgba(0, 0, 0, 0.2);
    --shadow-floating: 0 10px 40px rgba(0, 0, 0, 0.4);
    --radius-main: 8px;
    --radius-pill: 50px;
    --font-heading: var(--wp--preset--font-family--system-font);
    --font-body: var(--wp--preset--font-family--georgia);
    --header-offset: 120px;
    --line-width-main: 2px;
}
html { color-scheme: dark; scroll-behavior: smooth; }
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: var(--font-body); font-weight: 300; color: var(--color-light); line-height: 1.6; }
body.modal-is-active { overflow: hidden; }
h1, h2, h3, h4, h5, h6 { font-family: var(--font-heading); font-weight: 700; text-transform: uppercase; line-height: 1.2; margin-bottom: 1rem; }
.site-container { display: flex; flex-direction: column; min-height: 100vh; overflow-x: hidden; }
.site-main { flex-grow: 1; position: relative; }

/* --- BACKGROUND CONTROL --- */
.background-container { position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: -1; background-color: var(--color-dark); }
.background-media { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 0.8s ease-in-out; background-size: cover; background-position: center; }
.background-media.is-active { opacity: 1; }
#reward-video-player.is-active { z-index: 2; }
#reward-video-player.is-playing { cursor: pointer; }

/* --- BLOG STYLES --- */
.blog-post-section .entry-content {
    text-align: justify;
    text-justify: inter-word;
    hyphens: auto;
    -webkit-hyphens: auto;
    -ms-hyphens: auto;
    line-height: 1.8;
    max-width: 800px;
    margin: 0 auto;
}

.blog-post-section {
    margin-bottom: 6rem !important;
    padding-top: 4rem; 
    display: block;
    position: relative;
    z-index: 10;
    border-top: 1px solid rgba(var(--color-light-rgb), 0.1);
}
.blog-post-section:first-of-type { border-top: none; } 
.blog-post-section.content-block { background-color: rgba(var(--color-dark-rgb), var(--glass-background-opacity)); backdrop-filter: var(--glass-blur-strength); border-radius: var(--radius-main); }
.blog-post-section .entry-content > * { margin-bottom: 1.5em; }
.blog-post-section h2.entry-title { font-size: clamp(3rem, 8vw, 5rem); line-height: 1.05; margin-top: 1rem !important; margin-bottom: 3.5rem; letter-spacing: -0.02em; text-transform: uppercase; }
.blog-post-section .entry-content h2 { font-size: 2.2rem; line-height: 1.3; margin-top: 2.5em; margin-bottom: 1em; }
.blog-post-section .entry-content h3 { font-size: 1.7rem; line-height: 1.4; margin-top: 2.5em; margin-bottom: 1em; }
.blog-post-section .entry-content h4 { font-size: 1.3rem; line-height: 1.4; margin-top: 2em; margin-bottom: 1rem; color: rgba(var(--color-light-rgb), 0.8); }
.blog-post-section .entry-content h5, .blog-post-section .entry-content h6 { font-size: 1.1rem; line-height: 1.4; margin-top: 1.5rem; margin-bottom: 0.5rem; letter-spacing: 0.1em; color: rgba(var(--color-light-rgb), 0.6); }

/* --- Galerien Abstände & Verschmelzen (FINAL) --- */
.blog-post-section .entry-content .wp-block-gallery { 
    margin-top: 3rem; /* Standard-Abstand für eine einzelne Galerie nach oben */
    margin-bottom: 3rem; /* Standard-Abstand nach unten */
}

/* WENN eine Galerie auf eine andere folgt (egal was dazwischen ist)... */
.blog-post-section .entry-content .wp-block-gallery ~ .wp-block-gallery { 
    /* ...dann ziehe sie um 2rem nach oben. (3rem - 2rem = 1rem finaler Abstand) */
    margin-top: -1rem !important; 
}

/* --- COLLAPSIBLE BLOG CONTENT --- */
.entry-content.is-collapsible {
    max-height: 400px;
    overflow: hidden;
    position: relative;
    transition: max-height 0.5s ease;
    mask-image: linear-gradient(to bottom, black 50%, transparent 100%);
    -webkit-mask-image: linear-gradient(to bottom, black 50%, transparent 100%);
}
.entry-content.is-collapsible.is-expanded {
    max-height: 4000px; 
    mask-image: none;
    -webkit-mask-image: none;
}

/* --- BLOCKQUOTES (Zitate) & GALLERIES --- */
.wp-block-quote, blockquote { margin: 4rem auto; padding: 2rem 3rem; border-left: var(--line-width-main) solid var(--color-light); background: rgba(var(--color-light-rgb), 0.03); font-style: italic; position: relative; }
.wp-block-quote p { font-size: 1.4rem; line-height: 1.6; margin-bottom: 1rem; }
.wp-block-quote cite { display: block; font-size: 0.9rem; font-style: normal; text-transform: uppercase; letter-spacing: 0.1em; opacity: 0.7; }
.wp-block-verse, pre { font-family: var(--font-body); font-size: 1.1rem; line-height: 1.8; padding: 2rem; background: rgba(0, 0, 0, 0.2); border-radius: var(--radius-main); margin: 2.5rem 0; overflow-x: auto; white-space: pre-wrap; }
.entry-content ul, .entry-content ol { margin: 2rem 0; padding-left: 2rem; }
.entry-content li { margin-bottom: 0.75rem; }
.entry-content li::marker { color: var(--color-light); font-weight: bold; }
figcaption, .wp-element-caption { font-size: 0.85rem; text-align: center; margin-top: 0.75rem; opacity: 0.6; font-style: italic; }

/* FIX: Galerien Abstände komplett entfernen (Steuerung nun via Spacer-Blöcke) */
.blog-post-section .entry-content .wp-block-gallery { margin: 0 !important; padding: 0 !important; }

/* --- DROP CAPS --- */
.blog-post-section .entry-content p:first-of-type::first-letter{ float: left; font-size: 5.5rem; line-height: 0.8; margin-top: 0.1em; padding-right: 15px; font-family: var(--font-heading); font-weight: 700; color: var(--color-light); text-shadow: var(--shadow-subtle); }
.blog-post-section .entry-content p:first-of-type::after{ content: ""; display: table; clear: both; }
.blog-post-section hr { display: block; margin: 5rem auto; border: none; border-top: 1px solid rgba(var(--color-light-rgb), 0.1); width: 50%; }

/* --- HEADER --- */
.site-header { position: fixed; top: 0; left: 0; width: 100%; padding: 1.5rem; z-index: 50; }
@media (min-width: 768px) { .site-header { padding: 2rem; } }
.logo a { color: var(--color-light); text-decoration: none; display: inline-block; }
.logo a svg, .logo a video { display: block; height: 40px; width: auto; transition: opacity 0.3s; filter: drop-shadow(1px 1px 4px rgba(0, 0, 0, 0.4)); }
.logo a:hover svg, .logo a:hover video { opacity: 0.8; }
#logo-video { pointer-events: none; }

/* --- STATIC TOP AREA --- */
.static-top-content { position: relative; z-index: 10; padding-top: var(--header-offset); }
.hero-block { padding: 4rem 1.5rem; text-align: center; border-radius: 0; }
.author-bio-section p { max-width: 600px; margin: 0 auto; font-size: 1.1rem; }
.hero-block.style-dark { margin-top: calc(-1 * var(--header-offset)); }
.social-follow-links .social-follow-links-list { margin-top: 2rem; display: flex; justify-content: center; flex-wrap: wrap; gap: 0.75rem 1.5rem; list-style: none; padding-left: 0; }
.social-follow-links a { color: var(--color-light); text-decoration: underline; font-family: var(--font-body); font-size: 1.1rem; text-transform: none; letter-spacing: normal; opacity: 0.8; transition: opacity 0.3s; }
.social-follow-links a:hover { opacity: 1; }

/* --- NEWSLETTER SECTIONS --- */
.newsletter-section-wrapper { padding: 12rem 1.5rem; position: relative; z-index: 20; }
.newsletter-section-wrapper .content-block-inner { max-width: 800px; margin: 0 auto; text-align: center; }
.global-newsletter-form .fluentform { max-width: 500px; width: 100%; margin: 0 auto; }
.global-newsletter-form .ff-el-group { margin-bottom: 1rem; position: relative; }
.global-newsletter-form input[type="email"] { height: 54px; width: 100%; border-radius: var(--radius-pill); padding: .75rem 1.5rem; font-size: 1rem; box-shadow: var(--shadow-box); -webkit-appearance: none; margin: 0; transition: all .3s; background: rgba(var(--color-dark-rgb),.8); border-color: var(--color-light); color: var(--color-light); font-family: var(--font-body); font-weight: 300; border-style: solid; border-width: var(--line-width-main); }
.global-newsletter-form input[type="email"]:focus { outline: 2px solid var(--color-light); outline-offset: 3px; border-color: var(--color-light); }
.global-newsletter-form .ff-btn-submit { -webkit-appearance: none; appearance: none; background: rgba(var(--color-light-rgb),.9) !important; border-radius: var(--radius-pill) !important; color: var(--color-dark) !important; padding: 0 1.5rem !important; font-family: var(--font-heading) !important; font-weight: 700 !important; text-transform: uppercase !important; font-size: 0.9rem !important; cursor: pointer; transition: all .3s; display: inline-flex; align-items: center; justify-content: center; text-align: center; white-space: nowrap; height: 54px !important; width: 100%; box-shadow: var(--shadow-box) !important; border: var(--line-width-main) solid var(--color-light) !important; }
.global-newsletter-form .ff-btn-submit:hover { background-color: transparent !important; color: var(--color-light) !important; }
.global-newsletter-form .ff-el-is-error .error, .global-newsletter-form .ff-el-is-error .ff-el-validation-message { position: absolute; top: 100%; left: 0; right: 0; margin-top: 6px; text-align: center; color: #ff9696; text-shadow: 1px 1px 3px rgba(0,0,0,0.8); font-size: 0.9rem; font-weight: bold; padding: 0 1rem; z-index: 2; }
.ff-message-success { border: none !important; background: transparent !important; box-shadow: none !important; padding: 1rem 0 !important; color: var(--color-light) !important; text-shadow: var(--shadow-subtle); }
@media (min-width: 768px) { .global-newsletter-form .fluentform form { display: flex; gap: 15px; align-items: flex-start; } .global-newsletter-form .ff-el-group { margin-bottom: 0; } .global-newsletter-form .ff-el-input--content { flex: 2; } .global-newsletter-form .ff-btn-wrapper { flex: 1; } }

/* ========================================================================
   FILTER SECTION (ABOVE CAROUSEL)
   ======================================================================== */
.filter-section { padding: 2rem 1.5rem 0; position: relative; z-index: 40; }
.filter-wrapper { max-width: 500px; margin: 0 auto; }
.search-bar-wrapper { position: relative; }
#tag-search-input { width: 100%; height: 48px; padding: 0 1.5rem; border-radius: var(--radius-pill); border: var(--line-width-main) solid rgba(var(--color-light-rgb), 0.5); background-color: rgba(var(--color-light-rgb), 0.1); backdrop-filter: var(--glass-blur-strength); -webkit-backdrop-filter: var(--glass-blur-strength); color: var(--color-light); font-family: var(--font-body); font-size: 0.9rem; -webkit-appearance: none; transition: all 0.3s; }
#tag-search-input::placeholder { color: rgba(var(--color-light-rgb), 0.6); }
#tag-search-input:focus { outline: 2px solid var(--color-light); outline-offset: 3px; border-color: var(--color-light); background-color: rgba(var(--color-dark-rgb), 0.8); }
.autocomplete-items { position: absolute; border: var(--line-width-main) solid rgba(var(--color-light-rgb), 0.5); border-top: none; z-index: 99; top: 100%; left: 0; right: 0; max-height: 200px; overflow-y: auto; background-color: rgba(var(--color-dark-rgb), 0.9); backdrop-filter: var(--glass-blur-strength); border-bottom-left-radius: var(--radius-main); border-bottom-right-radius: var(--radius-main); display: none; margin: 0 15px; }
.autocomplete-items div { padding: 10px 1.5rem; cursor: pointer; border-bottom: 1px solid rgba(var(--color-light-rgb), 0.1); }
.autocomplete-items div:last-child { border-bottom: none; }
.autocomplete-items div:hover { background-color: rgba(var(--color-light-rgb), 0.1); }
.autocomplete-active { background-color: rgba(var(--color-light-rgb), 0.2) !important; }
.active-filters-wrapper { display: flex; flex-wrap: wrap; justify-content: center; gap: 1.5rem; padding: 1.5rem 0; min-height: 40px; align-items: center; }
.active-filters-wrapper .context-tag { font-size: 0.9rem; text-decoration: none; border-bottom: 1px dotted; }
.active-filters-wrapper .context-tag.is-inclusive { color: #a5d6a7; }
.active-filters-wrapper .context-tag.is-exclusive { color: #ef9a9a; }

/* --- WORKS GRID (CAROUSEL) --- */
.works-section { padding-top: 2rem; padding-bottom: 4rem; position: relative; z-index: 6; }
.works-grid-wrapper { max-width: 100%; overflow-x: auto; -ms-overflow-style: none; scrollbar-width: none; scroll-snap-type: x mandatory; padding: 0 calc(50vw - 90px - 1.5rem); }
.works-grid-wrapper:focus { outline: none; }
.works-grid-wrapper::-webkit-scrollbar { display: none; }
.works-grid { display: flex; flex-wrap: nowrap; gap: 1.5rem; padding: 2.5rem 1.5rem; width: max-content; margin: 0 auto; }
.work-item { flex-shrink: 0; width: 180px; aspect-ratio: 2 / 3; border-radius: var(--radius-main); overflow: hidden; box-shadow: var(--shadow-box); transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1), box-shadow 0.4s; cursor: pointer; border-style: solid; border-color: transparent; border-width: var(--line-width-main); scroll-snap-align: center; }
.work-item:hover { transform: scale(1.03); }
.work-item.active { transform: scale(1.08); box-shadow: 0 8px 25px rgba(255, 255, 255, 0.2); border-color: var(--color-light); }
.work-item-link, .work-item img { display: block; width: 100%; height: 100%; object-fit: cover; }
.placeholder-thumbnail { display:flex; align-items:center; justify-content:center; height:100%; background-color:#333; color:white; padding:1rem; text-align:center; font-family: var(--font-heading); }

/* --- DYNAMIC BOTTOM AREA (DETAILS) --- */
.work-details-container { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 0.6s ease-in-out; z-index: 5; }
.work-details-container.is-open { grid-template-rows: 1fr; }
.work-details-content-wrapper { overflow: hidden; position: relative; min-height: 100px; }
.work-detail-content { position: absolute; top: 0; left: 0; width: 100%; opacity: 0; transition: opacity 0.5s ease-in-out; pointer-events: none; }
.work-detail-content.is-active { position: relative; opacity: 1; pointer-events: auto; }

/* --- CONTRAST BLOCKS --- */
.content-block { padding: 4rem 1.5rem; }
.content-block-inner { max-width: 800px; margin: 0 auto; width: 100%; }
.content-block.style-dark { background-color: rgba(var(--color-dark-rgb), var(--glass-background-opacity)); color: var(--color-light); backdrop-filter: var(--glass-blur-strength); -webkit-backdrop-filter: var(--glass-blur-strength); }
.content-block.style-light { background-color: rgba(var(--color-light-rgb), var(--glass-background-opacity)); color: var(--color-dark); backdrop-filter: var(--glass-blur-strength); -webkit-backdrop-filter: var(--glass-blur-strength); }
.content-block.style-light h2, .content-block.style-light h3, .content-block.style-light a { color: var(--color-dark); }
.content-block.style-dark h2, .content-block.style-dark h3, .content-block.style-dark a { color: var(--color-light); }
.text-content-area p+p, .content-wrapper-static .entry-content p+p{ margin-top: 1.5em; }

/* --- 50/50 GRID & MOBILE STACKING ORDER --- */
.detail-grid-50-50 { display: flex; flex-direction: column; gap: 2.5rem; }
.grid-col.text-content-area { order: 1; }
.grid-col.share-buttons-area { order: 2; display: flex; flex-direction: column; gap: 2.5rem; }
.work-cta-section { order: 1; }
.modal-triggers-wrapper { order: 2; margin-top: 0; }
.custom-share-buttons { order: 3; }

@media (min-width: 768px) {
    .detail-grid-50-50 { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: start; }
    .grid-col.text-content-area, .grid-col.share-buttons-area, .custom-share-buttons, .modal-triggers-wrapper, .work-cta-section { order: initial; }
    .grid-col.share-buttons-area { gap: 0; }
    .custom-share-buttons { align-self: start; }
    .modal-triggers-wrapper { margin-top: 2rem; }
}
.detail-grid-50-50 h2 { margin-top: 0; }

/* --- WORK CONTEXT BAR --- */
.work-context-bar {
    grid-column: 1 / -1; order: -1; margin-bottom: 2.5rem; overflow-x: auto; scrollbar-width: none; -ms-overflow-style: none; position: relative;
    -webkit-mask-image: linear-gradient(to right, transparent, black 40px, black calc(100% - 40px), transparent);
    mask-image: linear-gradient(to right, transparent, black 40px, black calc(100% - 40px), transparent);
    min-height: 4.5em; display: flex; align-items: center; 
}
.blog-post-section .work-context-bar { margin-top: 1rem; } 

.work-context-bar::-webkit-scrollbar { display: none; }
.context-bar-scroll-wrapper { display: flex; gap: 1.5rem; width: max-content; padding: 0.5rem 40px; }
.context-tag { color: var(--color-light); text-decoration: underline; font-family: var(--font-body); font-style: italic; font-size: 1rem; white-space: nowrap; opacity: 0.8; transition: opacity 0.3s; position: relative; }
a.context-tag { cursor: pointer; padding-right: 1.2em; }
a.context-tag:hover { opacity: 1; }
.context-tag.is-informational { cursor: default; text-decoration: underline; user-select: none; -webkit-user-select: none; }
.context-tag .filter-icon { position: absolute; right: 0; top: 50%; transform: translateY(-50%); display: inline-block; width: 0.8em; height: 0.8em; font-style: normal; text-decoration: none; vertical-align: -0.1em; }
.context-tag.is-inclusive .filter-icon { color: #a5d6a7; }
.context-tag.is-exclusive .filter-icon { color: #ef9a9a; }

/* --- CUSTOM SHARE BUTTONS --- */
.custom-share-buttons a { display: inline-block; color: var(--color-light); margin-right: 1.5rem; opacity: 0.8; transition: opacity 0.3s, transform 0.3s; }
.custom-share-buttons a:last-child { margin-right: 0; }
.custom-share-buttons a:hover { opacity: 1; transform: translateY(-2px) scale(1.05); }
.custom-share-buttons a svg { width: 32px; height: 32px; vertical-align: middle; }

/* --- FOOTER & STATIC PAGES --- */
.site-footer { position: relative; z-index: 25; background-color: rgba(var(--color-dark-rgb), var(--glass-background-opacity)); backdrop-filter: var(--glass-blur-strength); -webkit-backdrop-filter: var(--glass-blur-strength); flex-shrink: 0; box-shadow: 0 -5px 15px rgba(0, 0, 0, 0.3); color: var(--color-light); text-align: center; padding: 1.5rem 1rem; border-top: 1px solid rgba(255, 255, 255, 0.1); font-size: 0.9rem; }
.footer-legal-nav .footer-menu-list { list-style: none; padding: 0; margin: 0; display: flex; justify-content: center; gap: 1.5rem; }
.footer-legal-nav a { color: var(--color-light); text-decoration: underline; }
.main-content-static { padding-top: 120px; }
.content-wrapper-static { max-width: 800px; margin: 0 auto 6rem; padding: 2.5rem; background: rgba(var(--color-dark-rgb), var(--glass-background-opacity)); backdrop-filter: var(--glass-blur-strength); -webkit-backdrop-filter: var(--glass-blur-strength); border: 1px solid rgba(var(--color-light-rgb), 0.2); box-shadow: var(--shadow-floating); border-radius: var(--radius-main); }
.content-wrapper-static .entry-title { font-size: 2.5rem; margin-bottom: 2rem; text-align: center; }

/* ========================================================================
   MODALS & POPUPS
   ======================================================================== */
.modal-overlay { position: fixed; top: 0; left: 0; width: 100vw; height: 100vh; background: rgba(0, 0, 0, 0.8); z-index: 1000; display: none; align-items: center; justify-content: center; padding: 1rem; backdrop-filter: var(--glass-blur-strength); -webkit-backdrop-filter: var(--glass-blur-strength); opacity: 0; transition: opacity 0.4s ease-in-out; }
.modal-overlay.is-open { display: flex; opacity: 1; }
.modal-content { position: relative; border-radius: var(--radius-main); box-shadow: var(--shadow-floating); width: 100%; max-width: 800px; max-height: 85vh; background-color: rgba(var(--color-dark-rgb), 0.9); color: var(--color-light); transform: scale(0.95); transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1); display: flex; flex-direction: column; }
.modal-overlay.is-open .modal-content { transform: scale(1); }

.modal-content h2 { 
    padding: 2.5rem 2.5rem 1rem; 
    margin: 0;
    background-color: var(--color-dark); 
    border-radius: var(--radius-main) var(--radius-main) 0 0;
    position: relative;
    z-index: 10;
}

.modal-body { 
    padding: 1.5rem 2.5rem 2.5rem; 
    overflow-y: auto; 
    flex-grow: 1; 
    position: relative;
    z-index: 1;
    mask-image: linear-gradient(to bottom, transparent 0%, black 10%, black 90%, transparent 100%);
    -webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 10%, black 90%, transparent 100%);
    pointer-events: auto; 
}

.modal-close-btn { 
    position: absolute; top: 1.5rem; right: 1.5rem; background: none; border: none; color: currentColor; cursor: pointer; opacity: 0.7; z-index: 9999; pointer-events: auto; width: 40px; height: 40px; font-size: 0; transition: opacity 0.3s ease, transform 0.4s cubic-bezier(0.4, 0, 0.2, 1); transform-origin: 50% 50%;
}
.modal-close-btn::before, .modal-close-btn::after {
    content: ''; position: absolute; top: 50%; left: 50%; width: 24px; height: 2px; background-color: currentColor;
}
.modal-close-btn::before { transform: translate(-50%, -50%) rotate(45deg); }
.modal-close-btn::after { transform: translate(-50%, -50%) rotate(-45deg); }
.modal-overlay .modal-close-btn:hover { opacity: 1; transform: rotate(90deg); }

.modal-body h2 { padding: 0; }
.modal-body strong, .modal-body b { font-weight: 700; }
.modal-body { line-height: 1.7; }
.modal-body p { margin-bottom: 1.5em; }
.modal-body ul { list-style-position: outside; padding-left: 1.5em; margin-top: 1em; }
.modal-body ul li { padding-left: 0.5em; margin-bottom: 1.2em; }
.modal-body h2:not(h2 + h2) { text-align: left; text-transform: none; letter-spacing: 0.05em; font-size: 1.5em; margin-top: 2em; margin-bottom: 1em; }
.modal-body h2 + h2 { text-align: center; text-transform: uppercase; letter-spacing: 0.15em; font-size: 1rem; font-weight: 700; margin-top: 3em; margin-bottom: 2.5em; }
.modal-body > *:last-child, .modal-body ul:last-child li:last-child { margin-bottom: 0; }

/* ========================================================================
   BUTTONS (MODALS, BLOG EXPAND, SHOP)
   ======================================================================== */

.blog-post-section .content-block-inner { display: flex; flex-direction: column; }
.blog-post-section .entry-header, .blog-post-section .entry-content { width: 100%; }
.modal-triggers-wrapper { margin-top: 2rem; display: flex; flex-direction: column; gap: 1rem; align-items: flex-start; }

.modal-trigger-btn, 
.blog-expand-btn { 
    width: fit-content !important; 
    min-width: 180px;
    align-self: flex-start; 
    height: 54px; 
    padding: 0 2.5rem; 
    -webkit-appearance: none; appearance: none; background: transparent; border-radius: var(--radius-pill); color: var(--color-light); font-family: var(--font-heading); font-weight: 700; text-transform: uppercase; font-size: 0.9rem; cursor: pointer; transition: all .3s; display: inline-flex; align-items: center; justify-content: center; text-align: center; max-width: 100%; border: var(--line-width-main) solid var(--color-light); 
}

.blog-expand-btn {
    align-self: center !important; 
    margin: 2rem auto 0 !important; 
    position: relative;
    z-index: 10;
}

.modal-trigger-btn:hover, .blog-expand-btn:hover { background-color: var(--color-light); color: var(--color-dark); }

.modal-trigger-btn::after,
.blog-expand-btn::after {
    content: "";
    display: inline-block;
    width: 8px; 
    height: 8px;
    margin-left: 12px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg) translateY(-2px);
    transition: transform 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
}
.modal-trigger-btn:hover::after,
.blog-expand-btn:hover::after {
    transform: rotate(45deg) translate(2px, 2px);
}
.blog-expand-btn.is-active::after {
    transform: rotate(225deg) translate(-2px, -2px); 
}
.blog-expand-btn.is-active:hover::after {
    transform: rotate(225deg) translate(0px, 0px);
}

/* --- CALL-TO-ACTION (SHOP BUTTONS & ANNOUNCEMENT) --- */
@keyframes sunrise-shine-loop { 
    from { transform: translateX(-100%) skewX(-25deg); } 
    to { transform: translateX(250%) skewX(-25deg); } 
}

.work-cta-section { margin-top: 2rem; }
.work-announcement-section { margin-top: 2rem; }
.shop-links-list { display: flex; flex-direction: column; gap: 1rem; align-items: flex-start; }

.shop-button { 
    width: fit-content !important; 
    align-self: flex-start;
    display: inline-flex; align-items: center; justify-content: center; height: 54px; padding: 0 2.5rem; background-color: var(--color-light); color: var(--color-dark) !important; border-radius: var(--radius-pill); font-family: var(--font-heading); font-weight: 700; text-transform: uppercase; font-size: 0.9rem; text-decoration: none; border: var(--line-width-main) solid var(--color-light); box-shadow: var(--shadow-box); position: relative; overflow: hidden; z-index: 1; transition: all 0.3s ease; 
}
.shop-button:hover { background-color: transparent; color: var(--color-light) !important; transform: translateY(-2px); box-shadow: var(--shadow-floating); }
.shop-button::before { content: ''; position: absolute; top: 0; left: 0; width: 80%; height: 100%; background: linear-gradient(90deg, rgba(255, 150, 70, 0) 0%, rgba(255, 150, 70, 0.2) 25%, rgba(255, 20, 147, 0.25) 60%, rgba(255, 215, 0, 0.15) 90%, rgba(255, 215, 0, 0) 100%); z-index: -1; animation: sunrise-shine-loop 1.6s infinite linear; animation-delay: 0.5s; pointer-events: none; }

/* --- FLUENT FORMS IN MODALS & FOOTER --- */
.modal-body .fluentform { text-align: left; margin-top: 1.5rem; }
.modal-body .fluentform .ff-el-group { margin-bottom: 2.5rem; }
.modal-body .fluentform .ff-el-input--label label { font-family: var(--font-heading); font-weight: 700; text-transform: uppercase; font-size: 0.9rem; color: var(--color-light); margin-bottom: 0.75rem; letter-spacing: 0.5px; }
.modal-body .fluentform .ff-el-form-control { background: transparent; border: var(--line-width-main) solid rgba(var(--color-light-rgb), 0.7); border-radius: var(--radius-pill); color: var(--color-light); font-family: var(--font-body); font-size: 1rem; padding: 0.75rem 1.5rem; transition: all 0.3s ease; box-shadow: none; }
.modal-body .fluentform .ff-el-form-control:focus { box-shadow: none; border-color: var(--color-light); outline: 2px solid var(--color-light); outline-offset: 3px; }
.modal-body .fluentform .ff-el-help-message { font-style: italic; opacity: 0.8; margin-top: 0.5rem; padding-left: 1.5rem; }
.modal-body .fluentform .ff-el-form-check-label { font-family: var(--font-body); color: var(--color-light); cursor: pointer; display: flex; align-items: center; gap: 0.75em; }
.modal-body .fluentform .ff-el-form-check-input { appearance: none; -webkit-appearance: none; position: relative; width: 1.25em; height: 1.25em; border: var(--line-width-main) solid var(--color-light); cursor: pointer; transition: all 0.2s ease; flex-shrink: 0; }
.modal-body .fluentform .ff-el-form-check-input:checked { background-color: var(--color-light); }
.modal-body .fluentform .ff-el-form-check-input[type="checkbox"] { border-radius: 4px; }
.modal-body .fluentform .ff-el-form-check-input[type="checkbox"]:checked::after { content: ''; position: absolute; top: 50%; left: 50%; width: 0.3em; height: 0.6em; border: solid var(--color-dark); border-width: 0 var(--line-width-main) var(--line-width-main) 0; transform: translate(-50%, -60%) rotate(45deg); }
.modal-body .fluentform .ff-el-form-check-input[type="radio"] { border-radius: 50%; }
.modal-body .fluentform .ff-el-form-check-input[type="radio"]:checked::after { content: ''; position: absolute; top: 50%; left: 50%; width: 0.6em; height: 0.6em; background: var(--color-dark); border-radius: 50%; transform: translate(-50%, -50%); }
.modal-body .fluentform .ff_tos_label a { color: var(--color-light); text-decoration: underline; }
.modal-body .fluentform .ff-el-group:last-of-type { margin-bottom: 0; display: flex; justify-content: center; }
.modal-body .fluentform .ff-btn-submit { -webkit-appearance: none; appearance: none; width: auto; background: var(--color-light) !important; border-radius: var(--radius-pill) !important; color: var(--color-dark) !important; padding: 0 2rem !important; font-family: var(--font-heading) !important; font-weight: 700 !important; text-transform: uppercase !important; font-size: 0.9rem !important; cursor: pointer; transition: all .3s; display: inline-flex; align-items: center; justify-content: center; text-align: center; white-space: nowrap; height: 54px !important; box-shadow: var(--shadow-box) !important; border: var(--line-width-main) solid var(--color-light) !important; }
.modal-body .fluentform .ff-btn-submit:hover { background-color: transparent !important; color: var(--color-light) !important; }
.modal-body .fluentform .ff-message-success { border: none !important; background: transparent !important; box-shadow: none !important; padding: 1rem 0 !important; color: var(--color-light) !important; text-shadow: var(--shadow-subtle); text-align: center; }
.modal-body .fluentform .ff-el-is-error .error { color: #ff9696; text-shadow: 1px 1px 3px rgba(0,0,0,0.8); font-weight: bold; text-align: left; margin-top: 0.5rem; }
.global-newsletter-form .ff-el-form-check-label { font-family: var(--font-body); color: var(--color-light); cursor: pointer; display: inline-flex; align-items: center; gap: 0.75em; font-size: 0.9rem; }
.global-newsletter-form .ff-el-form-check-input { appearance: none; -webkit-appearance: none; position: relative; width: 1.25em; height: 1.25em; border: var(--line-width-main) solid var(--color-light); cursor: pointer; transition: all 0.2s ease; flex-shrink: 0; vertical-align: middle; }
.global-newsletter-form .ff-el-form-check-input:checked { background-color: var(--color-light); }
.global-newsletter-form .ff-el-form-check-input[type="checkbox"] { border-radius: 4px; }
.global-newsletter-form .ff-el-form-check-input[type="checkbox"]:checked::after { content: ''; position: absolute; top: 50%; left: 50%; width: 0.3em; height: 0.6em; border: solid var(--color-dark); border-width: 0 var(--line-width-main) var(--line-width-main) 0; transform: translate(-50%, -60%) rotate(45deg); }
.global-newsletter-form .ff-el-form-check { text-align: center; margin-top: 1rem; padding-left: 0; }
@media (min-width: 768px) { .global-newsletter-form .ff-el-form-check { text-align: center; } }
.modal-body h2 { padding: 0; }
.modal-body strong, .modal-body b { font-weight: 700; }
.modal-body { line-height: 1.7; }
.modal-body p { margin-bottom: 1.5em; }
.modal-body ul { list-style-position: outside; padding-left: 1.5em; margin-top: 1em; }
.modal-body ul li { padding-left: 0.5em; margin-bottom: 1.2em; }
.modal-body h2:not(h2 + h2) { text-align: left; text-transform: none; letter-spacing: 0.05em; font-size: 1.5em; margin-top: 2em; margin-bottom: 1em; }
.modal-body h2 + h2 { text-align: center; text-transform: uppercase; letter-spacing: 0.15em; font-size: 1rem; font-weight: 700; margin-top: 3em; margin-bottom: 2.5em; }
.modal-body > *:last-child, .modal-body ul:last-child li:last-child { margin-bottom: 0; }

/* --- ISBN TAG STYLING IN CONTEXT BAR --- */
.context-tag.is-isbn { text-decoration: none; cursor: default; background-color: rgba(var(--color-light-rgb), 0.05); padding: 0.2em 0.8em; border-radius: var(--radius-pill); display: inline-flex; align-items: center; gap: 0.75em; }
.moth-copy-btn { background: none; border: none; color: currentColor; cursor: pointer; padding: 0; margin: 0; opacity: 0.6; transition: opacity 0.2s, transform 0.2s, color 0.2s; line-height: 1; }
.moth-copy-btn:hover { opacity: 1; transform: scale(1.1); }
.moth-copy-btn svg { display: block; width: 1em; height: 1em; }
.moth-copy-btn.is-copied { color: #a5d6a7; opacity: 1; transform: scale(1.1); }

/* --- ADMIN UI CUSTOM STYLING (VIOLET ACCENT) --- */
#customize-controls .moth-font-uploader-control .moth-font-dropzone { border-color: #8A2BE2; }
#customize-controls .moth-font-uploader-control .moth-font-dropzone.moth-drag-over { background-color: #f0f6fc; border-color: #5d0f94; }
.notice.moth-activation-notice, .notice.moth-media-notice { border-left-color: #8A2BE2 !important; }
.logo-link { text-decoration: none; color: var(--color-light); display: inline-block; }
.site-title-text { font-family: var(--font-heading); font-weight: 700; text-transform: uppercase; font-size: 1.5rem; line-height: 1; letter-spacing: 0.05em; }
.logo img.custom-logo { height: 40px; width: auto; display: block; }

/* --- FIX: Button Icon Animation --- */
.blog-expand-btn.is-active:hover::after {
    transform: rotate(225deg) translateY(-2px); /* Korrigiert die Animation im aktiven Hover-Zustand */
}

/* --- FIX: Button Icon Animation --- */
.modal-trigger-btn::after,
.blog-expand-btn::after {
    content: "";
    display: inline-block;
    width: 8px; 
    height: 8px;
    margin-left: 12px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg);
    transition: transform 0.3s ease;
}
.blog-expand-btn.is-active::after {
    transform: rotate(225deg); 
}