/* ==========================================================================
   İstSoft Pro — WISECP 5.0 Bridge & Visual Polish Layer
   Harmonizes istsoft-legacy-pro.css + istsoft-legacy-v38.css with WISECP 5.0
   ========================================================================== */

:root {
    --font-display: 'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-primary: 'Inter', 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    --font-theme: var(--font-primary);
    --theme-primary: #0891b2;
    --theme-primary-light: #06b6d4;
    --theme-primary-dark: #0e7490;
    --theme-primary-soft: rgba(8, 145, 178, 0.11);
    --theme-primary-glow: rgba(8, 145, 178, 0.28);
    --theme-secondary: #0f172a;
    --theme-accent: #f59e0b;
    --surface-page: #f8fafc;
    --surface-card: #ffffff;
    --surface-muted: #f1f5f9;
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --border-color: #e2e8f0;
}

[data-bs-theme="dark"] {
    --surface-page: #0b1120;
    --surface-card: #111827;
    --surface-muted: #1e293b;
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --border-color: rgba(148, 163, 184, 0.18);
}

/* Dark mode: invert dark header & mobile drawer logos so İstSoft logo is crisp white */
[data-bs-theme="dark"] .ist-brand-logo img,
body.dark-mode .ist-brand-logo img,
[data-bs-theme="dark"] .ist-md-logo img,
body.dark-mode .ist-md-logo img {
    filter: brightness(0) invert(1) !important;
}

/* Ensure WISECP 5.0 .chrome-overlay never collides with IstSoft sticky header */
body.chrome-overlay .ist-header-wrapper {
    position: relative;
    z-index: 1030;
}
body.chrome-overlay .page-hero,
.page-hero {
    margin-top: 0 !important;
    padding: 3rem 0 2.5rem !important;
    color: #ffffff !important;
}
.page-hero h1,
.page-hero .h1,
.page-hero .page-hero-title,
.page-hero p,
.page-hero .page-hero-lead,
.page-hero .breadcrumb,
.page-hero .breadcrumb-item,
.page-hero .breadcrumb a {
    color: #ffffff !important;
}
.page-hero .page-hero-lead,
.page-hero .breadcrumb-item + .breadcrumb-item::before {
    color: rgba(255, 255, 255, 0.85) !important;
}

/* Fix dark popular pricing card headings (.plan-card.plan-popular) */
.plan-card.plan-popular h1,
.plan-card.plan-popular h2,
.plan-card.plan-popular h3,
.plan-card.plan-popular h4,
.plan-card.plan-popular .price-now {
    color: #ffffff !important;
}
.plan-card.plan-popular .text-body-secondary,
.plan-card.plan-popular .billing-compare {
    color: rgba(255, 255, 255, 0.78) !important;
}

/* Fix stray floating 0 badge on .ist-cart-btn */
.ist-cart-btn {
    position: relative !important;
}
.ist-cart-btn .cart-count,
.ist-cart-btn .ist-cart-badge {
    position: static !important;
    inset: auto !important;
    transform: none !important;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.24) !important;
    color: #ffffff !important;
    font-size: 11px !important;
    font-weight: 800;
}

/* Fix Bootstrap 5 / WStyle .text-secondary turning gray body text into bright cyan */
:root {
    --bs-secondary-color: #475569;
    --bs-secondary-color-rgb: 71, 85, 105;
}
[data-bs-theme="dark"] {
    --bs-secondary-color: #94a3b8;
    --bs-secondary-color-rgb: 148, 163, 184;
}
.ist-panel-card p.text-secondary,
.ist-section .text-secondary {
    color: var(--text-secondary) !important;
}
footer .text-secondary {
    color: #94a3b8 !important;
}
footer a.text-secondary:hover {
    color: #ffffff !important;
}

/* Ensure header locale switcher looks crisp inside .ist-topbar & NEVER hides behind main header */
.ist-topbar {
    position: relative;
    z-index: 1045 !important;
}
.ist-main-header {
    position: relative;
    z-index: 1030 !important;
}
.ist-topbar .locale-toggle {
    color: rgba(255, 255, 255, 0.88) !important;
    font-size: 12.5px;
    padding: 2px 8px;
    border-radius: 6px;
}
.ist-topbar .locale-toggle:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #fff !important;
}
.ist-topbar .locale-menu {
    z-index: 1065 !important;
}
.ist-topbar .locale-menu a,
.ist-topbar .locale-menu button,
.ist-topbar .locale-menu .dropdown-item {
    color: #0f172a !important;
}
[data-bs-theme="dark"] .ist-topbar .locale-menu a,
[data-bs-theme="dark"] .ist-topbar .locale-menu button,
[data-bs-theme="dark"] .ist-topbar .locale-menu .dropdown-item {
    color: #f8fafc !important;
}

/* Navbar dropdown arrow & spacing polish */
.ist-nav-menu > li {
    position: relative;
}
.ist-nav-menu > li .ist-nav-badge {
    pointer-events: none;
}

/* Keep announcement bar & hero tabs crisp on desktop viewports */
@media (min-width: 992px) {
    .ist-announcement-inner {
        flex-wrap: nowrap;
        font-size: 12.5px;
    }
    .ist-hero-tabs-nav {
        flex-wrap: nowrap;
        overflow-x: auto;
        gap: 8px;
    }
    .ist-hero-tab-btn {
        white-space: nowrap;
        padding: 9px 14px;
        font-size: 13px;
    }
}

/* 2x3 Software Showcase Cards */
.ist-sw-card {
    border: 1px solid var(--border-color);
    border-radius: 1rem;
    overflow: hidden;
    background: var(--surface-card);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.ist-sw-card:hover {
    transform: translateY(-5px);
    border-color: rgba(6, 182, 212, 0.55);
    box-shadow: 0 18px 40px -14px rgba(8, 23, 46, 0.22);
}
.ist-sw-thumb {
    position: relative;
    display: block;
    overflow: hidden;
    background: #08172e;
}
.ist-sw-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.45s ease;
}
.ist-sw-card:hover .ist-sw-thumb img {
    transform: scale(1.04);
}
.ist-sw-badge {
    position: absolute;
    top: 0.75rem;
    left: 0.75rem;
    z-index: 2;
    padding: 0.28rem 0.65rem;
    border-radius: 999px;
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    color: #fff;
    backdrop-filter: blur(8px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.25);
}
.ist-badge-amber { background: linear-gradient(135deg, #d97706, #f59e0b); }
.ist-badge-emerald { background: linear-gradient(135deg, #059669, #10b981); }
.ist-badge-indigo { background: linear-gradient(135deg, #4f46e5, #6366f1); }
.ist-badge-cyan { background: linear-gradient(135deg, #0891b2, #06b6d4); }

.ist-sw-kpis {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
}
.ist-sw-kpi {
    display: inline-flex;
    align-items: center;
    padding: 0.18rem 0.52rem;
    border-radius: 0.45rem;
    font-size: 0.72rem;
    font-weight: 600;
    background: rgba(8, 145, 178, 0.1);
    color: #0e7490;
}
[data-bs-theme="dark"] .ist-sw-kpi {
    background: rgba(6, 182, 212, 0.15);
    color: #67e8f9;
}
.ist-sw-promo {
    font-size: 0.72rem;
    font-weight: 700;
    color: #059669;
    background: rgba(16, 185, 129, 0.12);
    padding: 0.18rem 0.5rem;
    border-radius: 999px;
}
[data-bs-theme="dark"] .ist-sw-promo {
    color: #6ee7b7;
}
.ist-sw-summary {
    font-size: 0.84rem;
    color: var(--text-secondary);
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* 2026 SEO Article Engine */
.ist-read-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    width: 0%;
    background: linear-gradient(90deg, #095174, #06b6d4, #f59e0b);
    z-index: 1090;
    transition: width 0.08s linear;
}
.ist-eeat-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.5rem 1rem;
    padding: 0.7rem 1rem;
    margin-bottom: 1.25rem;
    border-radius: 0.75rem;
    background: rgba(8, 145, 178, 0.07);
    border: 1px solid rgba(8, 145, 178, 0.16);
    font-size: 0.82rem;
}
.ist-eeat-verified {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-weight: 600;
    color: #095174;
}
[data-bs-theme="dark"] .ist-eeat-verified {
    color: #67e8f9;
}
.ist-toc-box {
    margin: 0 0 1.5rem 0;
    border-radius: 0.85rem;
    border: 1px solid var(--border-color);
    background: var(--surface-muted);
    overflow: hidden;
}
.ist-toc-toggle {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    background: transparent;
    border: 0;
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--text-primary);
    cursor: pointer;
}
.ist-toc-list {
    list-style: none;
    margin: 0;
    padding: 0 1rem 0.9rem 1rem;
    display: grid;
    gap: 0.35rem;
}
.ist-toc-list a {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.85rem;
    text-decoration: none;
    color: var(--text-secondary);
}
.ist-toc-list a:hover {
    color: var(--theme-primary);
}
.ist-toc-box.is-collapsed .ist-toc-list {
    display: none;
}

/* İstSoft Pro Visual Upgrade for WISECP 5.0 Category & Plan Cards (Hosting, Reseller, SEO, Social Media) */
.plan-card {
    border-radius: 20px !important;
    border: 1px solid rgba(8, 145, 178, 0.16) !important;
    box-shadow: 0 10px 28px -12px rgba(15, 23, 42, 0.12) !important;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease !important;
}
.plan-card:hover {
    transform: translateY(-5px);
    border-color: rgba(6, 182, 212, 0.55) !important;
    box-shadow: 0 20px 44px -14px rgba(8, 145, 178, 0.24) !important;
}
.plan-card.plan-popular {
    border: 2px solid #06b6d4 !important;
    background: linear-gradient(155deg, #071426 0%, #0b2545 55%, #0e3a5c 100%) !important;
    box-shadow: 0 22px 50px -14px rgba(6, 182, 212, 0.35) !important;
}
.plan-card .btn-primary,
.plan-card .btn-soft {
    border-radius: 12px !important;
    font-weight: 700 !important;
}
.plan-card .btn-primary {
    background: linear-gradient(135deg, #0891b2 0%, #06b6d4 100%) !important;
    border-color: transparent !important;
    color: #ffffff !important;
    box-shadow: 0 8px 20px -6px rgba(6, 182, 212, 0.45);
}
.plan-card .btn-primary:hover {
    filter: brightness(1.06);
    transform: translateY(-1px);
}
.plan-card .plan-features i {
    color: #06b6d4 !important;
}

/* İstSoft Pro Client Area Executive Visual Polish (100% WISECP 5.0 Native Compatible) */
body[data-client-nav="sidebar"] .client-sidebar {
    background: linear-gradient(180deg, #071426 0%, #091d36 60%, #0b2545 100%) !important;
    border-right: 1px solid rgba(56, 189, 248, 0.16) !important;
}
body[data-client-nav="sidebar"] .client-sidebar-link.active {
    background: linear-gradient(135deg, rgba(8, 145, 178, 0.32), rgba(6, 182, 212, 0.2)) !important;
    border: 1px solid rgba(56, 189, 248, 0.4) !important;
    color: #ffffff !important;
    box-shadow: 0 6px 18px -6px rgba(6, 182, 212, 0.45) !important;
}
body[data-client-nav="sidebar"] .dash-hero {
    background: radial-gradient(circle at 85% 25%, rgba(6, 182, 212, 0.3) 0%, transparent 55%), linear-gradient(135deg, #071426 0%, #095174 52%, #0891b2 100%) !important;
    border-radius: 20px !important;
    border: 1px solid rgba(56, 189, 248, 0.26) !important;
    box-shadow: 0 18px 42px -14px rgba(7, 20, 38, 0.34) !important;
}
body[data-client-nav="sidebar"] .dash-stat,
body[data-client-nav="sidebar"] .card {
    border-radius: 16px !important;
    border: 1px solid rgba(8, 145, 178, 0.14) !important;
    box-shadow: 0 8px 24px -12px rgba(15, 23, 42, 0.08) !important;
    transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease !important;
}
body[data-client-nav="sidebar"] .dash-stat:hover {
    transform: translateY(-3px) !important;
    border-color: rgba(6, 182, 212, 0.45) !important;
    box-shadow: 0 14px 30px -12px rgba(8, 145, 178, 0.2) !important;
}
body[data-client-nav="sidebar"] .progress-bar {
    background: linear-gradient(90deg, #095174 0%, #06b6d4 100%) !important;
}
body[data-client-nav="sidebar"] #panel_buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
}

/* Corporate İstSoft Scrollbar */
html {
    scrollbar-width: thin;
    scrollbar-color: #0891b2 #e2e8f0;
}
[data-bs-theme="dark"] {
    scrollbar-color: #06b6d4 #0b1120;
}
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}
::-webkit-scrollbar-track {
    background: var(--surface-muted, #f1f5f9);
}
::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #095174 0%, #0891b2 55%, #06b6d4 100%);
    border-radius: 999px;
    border: 2px solid var(--surface-muted, #f1f5f9);
}
::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #0891b2 0%, #06b6d4 100%);
}

/* Floating WhatsApp Button — Bottom-Right above Scroll-Top (NEVER overlaps left cookie card) */
.ist-wa-float {
    position: fixed;
    right: 1.25rem;
    bottom: 5rem;
    z-index: 1040;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.62rem 1.05rem;
    border-radius: 999px;
    background: #25d366;
    color: #052e16;
    font-weight: 700;
    font-size: 0.84rem;
    text-decoration: none;
    box-shadow: 0 10px 26px rgba(37, 211, 102, 0.38);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.ist-wa-float:hover {
    color: #052e16;
    transform: translateY(-2px);
    box-shadow: 0 14px 32px rgba(37, 211, 102, 0.48);
}
@media (max-width: 575.98px) {
    .ist-wa-float span {
        display: none;
    }
    .ist-wa-float {
        padding: 0.72rem;
    }
}
