/* === CRMasjid Landing — Custom Styles === */

/* Hide Alpine-controlled UI until Alpine runs (prevents mega-menu / dropdown flash). */
[x-cloak] {
    display: none !important;
}

:root {
    --color-primary: #212922;
    --color-primary-dark: #1a201b;
    --color-primary-light: #2e3830;
    --color-accent: #E6AA28;
    --color-dark: #212922;
    --color-dark-lighter: #2e3830;
    --color-body: #334155;
    --color-muted: #64748b;
    --color-border: #e2e8f0;
    --color-surface: #f8fafc;
}

html {
    scroll-behavior: smooth;
}

::selection {
    background-color: var(--color-dark);
    color: white;
}

/* === Navbar === */
.nav-blur {
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

/* === Hero gradient overlay (feature pages) === */
/* Layer order: first image paints on top. Base gradient must stay in the stack — a lone
   .hero-pattern background-image used to override .hero-gradient and left white + unreadable text-white. */
.hero-gradient {
    background-color: #212922;
    background-image:
        radial-gradient(circle at 25% 25%, rgba(255, 255, 255, 0.03) 0%, transparent 50%),
        radial-gradient(circle at 75% 75%, rgba(255, 255, 255, 0.02) 0%, transparent 50%),
        linear-gradient(135deg, #212922 0%, #2a3a2d 50%, #2e3830 100%);
    background-repeat: no-repeat;
    background-size: 100% 100%, 100% 100%, 100% 100%;
}

/* .hero-pattern in templates is inert; radial overlays are merged into .hero-gradient. */

/* === Feature tabs — glowing icon tiles (matches CRMasjid emerald + brand gold accents) === */
.feature-icon-glow {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #fff;
    transition: box-shadow 0.25s ease, transform 0.2s ease, background 0.2s ease;
}
.feature-icon-glow svg {
    display: block;
}
.feature-icon-glow--sm {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.75rem;
}
.feature-icon-glow--lg {
    width: 3rem;
    height: 3rem;
    border-radius: 1rem;
}
/* „3 Schritte“ — gleiche Glow-Palette, etwas größer als Tab-Icons */
.feature-icon-glow--xl {
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 1rem;
    font-weight: 700;
    font-size: 1.25rem;
    line-height: 1;
}
.feature-icon-glow--2xl {
    width: 4.5rem;
    height: 4.5rem;
    border-radius: 1.25rem;
}
.feature-icon-glow--muted {
    background: #f1f5f9;
    color: #64748b;
    box-shadow: none;
}
.feature-icon-glow--muted:hover {
    background: #e2e8f0;
}
/* Mitglieder — blue */
.feature-icon-glow--members {
    background: linear-gradient(145deg, #3b82f6, #2563eb);
    box-shadow: 0 10px 32px -10px rgba(37, 99, 235, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.12) inset;
}
/* Spenden — red (heart / giving) */
.feature-icon-glow--donations {
    background: linear-gradient(145deg, #f87171, #dc2626);
    box-shadow: 0 10px 32px -10px rgba(220, 38, 38, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.12) inset;
}
/* Events — amber */
.feature-icon-glow--events {
    background: linear-gradient(145deg, #f59e0b, #d97706);
    box-shadow: 0 10px 32px -10px rgba(217, 119, 6, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.12) inset;
}
/* Marketing — violet */
.feature-icon-glow--marketing {
    background: linear-gradient(145deg, #a855f7, #7c3aed);
    box-shadow: 0 10px 32px -10px rgba(124, 58, 237, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.1) inset;
}
/* Buchhaltung — emerald */
.feature-icon-glow--accounting {
    background: linear-gradient(145deg, #10b981, #059669);
    box-shadow: 0 10px 32px -10px rgba(5, 150, 105, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.12) inset;
}
/* Webseite — sky */
.feature-icon-glow--website {
    background: linear-gradient(145deg, #0ea5e9, #0284c7);
    box-shadow: 0 10px 32px -10px rgba(2, 132, 199, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.12) inset;
}

/* === Animated underline === */
.hover-underline {
    position: relative;
}
.hover-underline::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -2px;
    width: 0;
    height: 2px;
    background: var(--color-dark);
    transition: width 0.3s ease;
}
.hover-underline:hover::after {
    width: 100%;
}

/* === Card hover === */
.card-hover {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.card-hover:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
}

/* === Scroll reveal animations === */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

.reveal-left {
    opacity: 0;
    transform: translateX(-40px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal-left.visible {
    opacity: 1;
    transform: translateX(0);
}

.reveal-right {
    opacity: 0;
    transform: translateX(40px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal-right.visible {
    opacity: 1;
    transform: translateX(0);
}

/* Staggered children */
.reveal-stagger > * {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}
.reveal-stagger.visible > *:nth-child(1) { transition-delay: 0.05s; }
.reveal-stagger.visible > *:nth-child(2) { transition-delay: 0.1s; }
.reveal-stagger.visible > *:nth-child(3) { transition-delay: 0.15s; }
.reveal-stagger.visible > *:nth-child(4) { transition-delay: 0.2s; }
.reveal-stagger.visible > *:nth-child(5) { transition-delay: 0.25s; }
.reveal-stagger.visible > *:nth-child(6) { transition-delay: 0.3s; }
.reveal-stagger.visible > *:nth-child(7) { transition-delay: 0.35s; }
.reveal-stagger.visible > *:nth-child(8) { transition-delay: 0.4s; }
.reveal-stagger.visible > * {
    opacity: 1;
    transform: translateY(0);
}

/* === Counter animation === */
.counter-value {
    font-variant-numeric: tabular-nums;
}

/* === Pricing highlight === */
.pricing-highlighted {
    background: linear-gradient(135deg, #212922 0%, #2a3a2d 100%);
    color: white;
    transform: scale(1.05);
    border: 2px solid #2e3830;
    box-shadow: 0 25px 50px rgba(33, 41, 34, 0.25);
}

/* === Blog card image === */
.blog-img-wrapper {
    overflow: hidden;
}
.blog-img-wrapper img {
    transition: transform 0.5s ease;
}
.blog-img-wrapper:hover img {
    transform: scale(1.05);
}

/* === FAQ accordion === */
.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}
.faq-answer.open {
    max-height: 500px;
}

/* === CTA section === */
.cta-gradient {
    background: linear-gradient(135deg, #212922 0%, #2a3a2d 50%, #212922 100%);
    position: relative;
    overflow: hidden;
}
.cta-gradient::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 30% 50%, rgba(255, 255, 255, 0.03) 0%, transparent 50%);
    animation: cta-glow 8s ease-in-out infinite alternate;
}
@keyframes cta-glow {
    0% { transform: translate(0, 0); }
    100% { transform: translate(5%, 5%); }
}

/* === Section divider === */
.section-divider {
    width: 60px;
    height: 3px;
    background: var(--color-dark);
    border-radius: 2px;
}

/* === Button styles === */
.btn-primary {
    background: var(--color-dark);
    color: white;
    padding: 0.75rem 2rem;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}
.btn-primary:hover {
    background: var(--color-dark-lighter);
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(33, 41, 34, 0.25);
}

.btn-outline {
    border: 2px solid var(--color-dark);
    color: var(--color-dark);
    padding: 0.75rem 2rem;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}
.btn-outline:hover {
    background: var(--color-dark);
    color: white;
}

.btn-white {
    background: white;
    color: var(--color-dark);
    padding: 0.75rem 2rem;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}
.btn-white:hover {
    background: var(--color-surface);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* === Footer === */
.footer-gradient {
    background: linear-gradient(180deg, white 0%, var(--color-surface) 100%);
}

/* === Rich text content === */
.rich-text h2 { font-size: 1.75rem; font-weight: 700; margin: 2rem 0 1rem; }
.rich-text h3 { font-size: 1.375rem; font-weight: 600; margin: 1.5rem 0 0.75rem; }
.rich-text p { margin: 0 0 1rem; line-height: 1.75; }
.rich-text ul { list-style: disc; padding-left: 1.5rem; margin: 0 0 1rem; }
.rich-text ol { list-style: decimal; padding-left: 1.5rem; margin: 0 0 1rem; }
.rich-text li { margin: 0.25rem 0; }
.rich-text a { color: var(--color-dark); text-decoration: underline; }
.rich-text blockquote {
    border-left: 3px solid var(--color-dark);
    padding-left: 1rem;
    margin: 1rem 0;
    color: var(--color-muted);
    font-style: italic;
}
