/* SF Bauanleitungen – Frontend Styles
   Orange: #F97316 | Hover: #EA6A0A | Light: #FFF0E6
   Alle Regeln mit hoher Spezifität um Theme-Overrides zu verhindern
   ------------------------------------------------------------------ */

/* ── Buttons (theme-proof) ──────────────────────── */

.sf-ba-wrap .sf-ba-btn-primary,
.sf-ba-tab-content .sf-ba-btn-primary,
.sf-ba-tab-loginwall .sf-ba-btn-primary,
a.sf-ba-btn-primary {
    display: inline-flex !important;
    align-items: center !important;
    gap: 7px !important;
    padding: 11px 20px !important;
    background: #F97316 !important;
    color: #fff !important;
    border: none !important;
    border-radius: 8px !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    text-decoration: none !important;
    cursor: pointer !important;
    transition: background 0.15s ease !important;
    white-space: nowrap !important;
    line-height: 1.2 !important;
    box-shadow: 0 2px 8px rgba(249,115,22,0.30) !important;
    letter-spacing: 0 !important;
    text-transform: none !important;
}

.sf-ba-wrap .sf-ba-btn-primary:hover,
.sf-ba-tab-content .sf-ba-btn-primary:hover,
.sf-ba-tab-loginwall .sf-ba-btn-primary:hover,
a.sf-ba-btn-primary:hover {
    background: #EA6A0A !important;
    color: #fff !important;
    text-decoration: none !important;
    box-shadow: 0 4px 12px rgba(249,115,22,0.40) !important;
}

.sf-ba-wrap .sf-ba-btn-ghost,
.sf-ba-tab-loginwall .sf-ba-btn-ghost,
a.sf-ba-btn-ghost {
    display: inline-flex !important;
    align-items: center !important;
    padding: 11px 20px !important;
    background: #fff !important;
    color: #333 !important;
    border: 1.5px solid #d0d0d0 !important;
    border-radius: 8px !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    text-decoration: none !important;
    cursor: pointer !important;
    transition: border-color 0.15s, color 0.15s !important;
    white-space: nowrap !important;
    line-height: 1.2 !important;
    letter-spacing: 0 !important;
    text-transform: none !important;
}

.sf-ba-wrap .sf-ba-btn-ghost:hover,
.sf-ba-tab-loginwall .sf-ba-btn-ghost:hover,
a.sf-ba-btn-ghost:hover {
    border-color: #F97316 !important;
    color: #F97316 !important;
    text-decoration: none !important;
}

/* ── Responsive ─────────────────────────────────── */

.sf-ba-desktop-only { display: flex !important; }

@media (max-width: 768px) {
    .sf-ba-desktop-only { display: none !important; }
}

/* ══════════════════════════════════════════════════
   VARIANTE A: CTA-Kachel
   ══════════════════════════════════════════════════ */

.sf-ba-wrap {
    margin: 16px 0 20px;
}

.sf-ba-cta-card {
    display: flex;
    align-items: stretch;
    border-radius: 14px;
    overflow: visible;
    background: #fff;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08), 0 0 0 1px rgba(0,0,0,0.05);
    min-height: 90px;
    transition: box-shadow 0.2s ease;
    position: relative;
}

.sf-ba-cta-card:hover {
    box-shadow: 0 4px 20px rgba(0,0,0,0.11), 0 0 0 1px rgba(0,0,0,0.06);
}

.sf-ba-cta-accent {
    width: 5px;
    background: #F97316;
    flex-shrink: 0;
    border-radius: 14px 0 0 14px;
}

.sf-ba-cta-illustration {
    width: 80px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #FFF0E6;
    padding: 14px;
}

.sf-ba-cta-body {
    flex: 1;
    padding: 14px 16px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    min-width: 0;
}

.sf-ba-cta-title {
    font-size: 14px !important;
    font-weight: 700 !important;
    color: #111 !important;
    margin: 0 !important;
    line-height: 1.3 !important;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sf-ba-cta-sub {
    font-size: 12px !important;
    color: #888 !important;
    margin: 0 !important;
    line-height: 1.4 !important;
}

.sf-ba-cta-action {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    padding: 14px 18px;
}

.sf-ba-loginwall-actions {
    display: flex;
    flex-direction: column;
    gap: 7px;
    align-items: stretch;
}

/* Loginwall-Kachel */
.sf-ba-cta-locked {
    border: 1px dashed rgba(249,115,22,0.3);
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}
.sf-ba-cta-locked .sf-ba-cta-illustration {
    background: #f8f8f8;
}

/* ══════════════════════════════════════════════════
   VARIANTE B: Produkttab
   ══════════════════════════════════════════════════ */

/* Kachel-Wrapper im Tab */
.sf-ba-tab-card {
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08), 0 0 0 1px rgba(0,0,0,0.05);
    padding: 24px 28px;
    margin: 4px 0;
}

/* Tab-Inhalt: eingeloggt */
.sf-ba-tab-content {
    display: flex;
    align-items: flex-start;
    gap: 28px;
}

@media (max-width: 600px) {
    .sf-ba-tab-content {
        flex-direction: column;
        gap: 20px;
    }
}

.sf-ba-tab-illustration {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 80px;
    height: 100px;
    background: #FFF0E6;
    border-radius: 10px;
    padding: 12px;
}

.sf-ba-tab-body { flex: 1; }

.sf-ba-tab-title {
    font-size: 17px !important;
    font-weight: 700 !important;
    color: #111 !important;
    margin: 0 0 8px !important;
    line-height: 1.3 !important;
}

.sf-ba-tab-sub {
    font-size: 14px !important;
    color: #666 !important;
    line-height: 1.65 !important;
    margin: 0 0 20px !important;
}

/* Tab-Inhalt: nicht eingeloggt (Loginwall) */
.sf-ba-tab-loginwall-blur {
    display: flex;
    align-items: flex-start;
    gap: 28px;
    filter: blur(4px);
    user-select: none;
    pointer-events: none;
    opacity: 0.5;
    padding-bottom: 8px;
}

.sf-ba-placeholder-line {
    display: block;
    background: #E2E2E2;
    border-radius: 4px;
}

.sf-ba-tab-loginwall-overlay {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding-top: 20px;
    background: linear-gradient(
        to bottom,
        rgba(255,255,255,0)   0%,
        rgba(255,255,255,0.96) 22%,
        rgba(255,255,255,1)   40%
    );
    margin-top: -60px;
    position: relative;
}

.sf-ba-lock-circle {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: #FFF0E6;
    border: 1.5px solid rgba(249,115,22,0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.sf-ba-loginwall-title {
    font-size: 16px !important;
    font-weight: 700 !important;
    color: #111 !important;
    margin: 0 !important;
    text-align: center;
}

.sf-ba-loginwall-sub {
    font-size: 13px !important;
    color: #777 !important;
    margin: 0 !important;
    text-align: center;
    max-width: 340px;
    line-height: 1.55 !important;
}

.sf-ba-loginwall-btns {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 6px;
    padding-bottom: 8px;
}

/* ── Dropdown (Variante A, mehrere Teile) ───────── */

.sf-ba-dropdown-wrap {
    position: relative;
}

.sf-ba-dropdown-wrap .sf-ba-chevron {
    margin-left: 2px;
    transition: transform 0.2s ease;
    flex-shrink: 0;
}

.sf-ba-dropdown-wrap.sf-ba-open .sf-ba-chevron {
    transform: rotate(180deg);
}

.sf-ba-dropdown-menu {
    display: none;
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    min-width: 240px;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.16), 0 0 0 1px rgba(0,0,0,0.07);
    overflow: hidden;
    z-index: 9999;
}

.sf-ba-dropdown-wrap.sf-ba-open .sf-ba-dropdown-menu {
    display: block;
}

.sf-ba-dropdown-item {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    padding: 10px 14px !important;
    font-size: 13px !important;
    font-weight: 500 !important;
    color: #222 !important;
    text-decoration: none !important;
    border-bottom: 0.5px solid #f0f0f0 !important;
    transition: background 0.12s !important;
    line-height: 1.3 !important;
}

.sf-ba-dropdown-item:last-child {
    border-bottom: none !important;
}

.sf-ba-dropdown-item:hover {
    background: #FFF0E6 !important;
    color: #F97316 !important;
    text-decoration: none !important;
}

.sf-ba-dropdown-item svg {
    flex-shrink: 0;
    opacity: 0.6;
}

.sf-ba-dropdown-item:hover svg {
    opacity: 1;
}

/* ── Dateiliste (Variante B, mehrere Teile) ─────── */

.sf-ba-file-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 4px;
}

.sf-ba-file-item {
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
    padding: 11px 16px !important;
    background: #fafafa !important;
    border: 1px solid #efefef !important;
    border-radius: 8px !important;
    text-decoration: none !important;
    transition: background 0.15s, border-color 0.15s !important;
}

.sf-ba-file-item:hover {
    background: #FFF0E6 !important;
    border-color: rgba(249,115,22,0.3) !important;
    text-decoration: none !important;
}

.sf-ba-file-part {
    font-size: 12px !important;
    font-weight: 700 !important;
    color: #F97316 !important;
    background: #FFF0E6 !important;
    padding: 3px 8px !important;
    border-radius: 5px !important;
    white-space: nowrap !important;
    flex-shrink: 0 !important;
}

.sf-ba-file-name {
    flex: 1 !important;
    font-size: 13px !important;
    font-weight: 500 !important;
    color: #333 !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
}

.sf-ba-file-item:hover .sf-ba-file-name {
    color: #111 !important;
}

.sf-ba-file-dl {
    display: inline-flex !important;
    align-items: center !important;
    gap: 5px !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    color: #F97316 !important;
    flex-shrink: 0 !important;
}

/* ── Loginwall-Kachel Button-Fixes ──────────────── */

/* Beide Buttons gleich breit in der Kachel */
.sf-ba-loginwall-actions .sf-ba-btn-primary,
.sf-ba-loginwall-actions .sf-ba-btn-ghost {
    width: 100% !important;
    justify-content: center !important;
    text-align: center !important;
}

/* Lock-Icon im Primary-Button korrekt (weiß) */
.sf-ba-loginwall-actions .sf-ba-btn-primary svg {
    stroke: #fff !important;
}

/* Lock-Kreis im Tab-Loginwall */
.sf-ba-lock-circle svg {
    stroke: #F97316 !important;
}
