@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

/* Base font */
body {
    font-family: 'Inter', system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Inter', system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* Nav styling aligned with appar.php */
.navbar.navbar-light.bg-light {
    background-color: #f8f9fa !important;
}

.navbar {
    padding-top: .5rem;
    padding-bottom: .5rem;
}

.navbar-brand {
    font-weight: 700;
    padding-top: .3125rem;
    padding-bottom: .3125rem;
}

.navbar .nav-link {
    padding: .5rem .85rem;
    margin-right: 15px;
}

.navbar .nav-item:last-child .nav-link {
    margin-right: 0;
}

.navbar .nav-link.active {
    color: #000 !important;
}

.navbar .nav-link.btn.btn-primary {
    background-color: #10b981 !important;
    border-color: #10b981 !important;
    color: #fff !important;
    padding: .3125rem 1rem;
    font-weight: 600;
    border-radius: 50px;
}

.btn-success {
    background-color: #10b981 !important;
    border-color: #10b981 !important;
    color: #fff !important;
}

.btn-success:hover,
.btn-success:focus,
.btn-success:active {
    background-color: #0f9f72 !important;
    border-color: #0f9f72 !important;
    color: #fff !important;
}

.btn-outline-success {
    color: #10b981 !important;
    border-color: #10b981 !important;
}

.btn-outline-success:hover,
.btn-outline-success:focus,
.btn-outline-success:active {
    background-color: #10b981 !important;
    border-color: #10b981 !important;
    color: #fff !important;
}

/* Central Botfinder hero styling for all subpages */
.hero-home,
.hero-network,
.hero-course {
    position: relative;
    overflow: hidden;
    padding-top: 0;
    padding-bottom: 0;
}

.hero-home::before,
.hero-network::before,
.hero-course::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(102, 126, 234, .88), rgba(118, 75, 162, .92));
    z-index: 0;
}

.hero-particles-canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
    pointer-events: none;
    z-index: 1;
}

.hero-home .container,
.hero-network .container,
.hero-course .container {
    position: relative;
    z-index: 2;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    margin-top: 80px;
    margin-bottom: 80px;
    color: #fff;
}

.hero-home h1,
.hero-home .lead,
.hero-home .small,
.hero-network h1,
.hero-network .lead,
.hero-network .small,
.hero-course h1,
.hero-course .lead,
.hero-course .small {
    text-shadow: 0 2px 14px rgba(0, 0, 0, .28);
}

.hero-home .hero-copy,
.hero-course .hero-copy {
    max-width: 860px;
    margin: 0 auto;
}

.hero-home .lead,
.hero-course .lead {
    max-width: 860px;
    margin-left: auto;
    margin-right: auto;
}

.apps-search .form-control {
    border-radius: 999px;
    padding-left: 1.25rem;
    padding-right: 1.25rem;
}

.apps-search .btn {
    border-radius: 999px;
}

.apps-tag {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    padding: .4rem .7rem;
    border-radius: 999px;
    background: #f8f9fa;
    border: 1px solid rgba(0,0,0,.08);
    color: #495057;
    text-decoration: none;
    font-size: .875rem;
    line-height: 1;
    transition: all .2s ease;
}

.apps-tag:hover,
.apps-tag:focus {
    background: #eef2ff;
    border-color: rgba(102, 126, 234, .28);
    color: #243b53;
    text-decoration: none;
}

.apps-tag.is-active {
    background: linear-gradient(135deg, rgba(102, 126, 234, .14), rgba(118, 75, 162, .16));
    border-color: rgba(102, 126, 234, .25);
    color: #243b53;
    font-weight: 600;
}

.apps-tag-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.35rem;
    height: 1.35rem;
    padding: 0 .3rem;
    border-radius: 999px;
    background: rgba(255,255,255,.85);
    color: #495057;
    font-size: .78rem;
    font-weight: 600;
}

.app-card {
    border-radius: 1rem;
    overflow: hidden;
}

.app-card-logo {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
    background: linear-gradient(135deg, rgba(102, 126, 234, .12), rgba(118, 75, 162, .15));
}

.app-card-logo img {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    object-fit: cover;
}

.app-card-logo-fallback {
    font-size: 1.2rem;
    font-weight: 700;
    color: #4f46e5;
}

.app-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: .4rem;
}

.apps-toplist-card .card-header {
    background: transparent;
}

.apps-toplist-item-wrap + .apps-toplist-item-wrap {
    margin-top: .35rem;
}

.apps-toplist-item {
    display: flex;
    align-items: center;
    gap: .6rem;
    padding: .5rem .65rem;
    border-radius: .75rem;
    text-decoration: none;
    color: #212529;
    transition: background .15s ease;
}

.apps-toplist-item:hover,
.apps-toplist-item:focus {
    background: #f1f3f5;
    color: #212529;
    text-decoration: none;
}

.apps-toplist-rank {
    flex: 0 0 1.25rem;
    font-size: .8rem;
    font-weight: 700;
    color: #6c757d;
    text-align: center;
}

.apps-toplist-logo {
    flex: 0 0 32px;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: linear-gradient(135deg, rgba(102, 126, 234, .12), rgba(118, 75, 162, .15));
    overflow: hidden;
}

.apps-toplist-logo img {
    width: 32px;
    height: 32px;
    object-fit: cover;
}

.apps-toplist-logo-fallback {
    font-size: .95rem;
    font-weight: 700;
    color: #4f46e5;
}

.apps-toplist-name {
    flex: 1;
    font-weight: 600;
    font-size: .95rem;
    line-height: 1.3;
}

/* Fancybox – app detail (ingen galleri-navigering) */
.app-fancybox-wrap .fancybox__nav,
.app-fancybox-wrap .f-thumbs,
.app-fancybox-wrap .fancybox__thumbs {
    display: none !important;
}

.app-fancybox-wrap {
    --f-button-color: #212529;
    --f-button-bg: #f1f3f5;
}

.app-fancybox-wrap .fancybox__content {
    padding: 0;
    width: min(92vw, 520px);
    max-width: min(92vw, 520px);
    border-radius: 1rem;
    overflow: visible;
    box-sizing: border-box;
}

.app-fancybox {
    position: relative;
    padding: 1.5rem 1.75rem 1.75rem;
    background: #fff;
    border-radius: 1rem;
    text-align: left;
    color: #212529;
}

.app-fancybox-close-btn {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    width: 2.75rem;
    height: 2.75rem;
    margin: 0;
    padding: 0;
    border: none;
    border-radius: 50%;
    background: #f1f3f5;
    color: #212529;
    font-size: 1.75rem;
    line-height: 1;
    font-weight: 300;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
    z-index: 2;
}

.app-fancybox-close-btn:hover {
    background: #e9ecef;
}

.app-fancybox-header {
    position: relative;
    padding-right: 2.5rem;
    margin-bottom: 1.25rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(0, 0, 0, .08);
}

.app-fancybox-logo {
    flex: 0 0 56px;
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(102, 126, 234, .12), rgba(118, 75, 162, .15));
    overflow: hidden;
}

.app-fancybox-logo img {
    width: 56px;
    height: 56px;
    object-fit: cover;
}

.app-fancybox-logo-fallback {
    font-size: 1.35rem;
    font-weight: 700;
    color: #4f46e5;
}

.app-fancybox-body {
    font-size: 1rem;
    line-height: 1.65;
    margin-bottom: 1.25rem;
}

.feature-card {
    border: 1px solid rgba(0,0,0,.06);
}

.mini-badge {
    display: inline-block;
    padding: .4rem .8rem;
    border-radius: 999px;
    background: rgba(255,255,255,.12);
    border: 1px solid rgba(255,255,255,.18);
    color: #fff;
    margin: .25rem .25rem 0 0;
    font-size: .92rem;
}

.section-title {
    margin-bottom: .85rem;
}

.home-about-img {
    width: 100%;
    height: auto;
    object-fit: cover;
    aspect-ratio: 3 / 2;
}

.assess-options {
    display: flex;
    flex-direction: column;
    gap: .65rem;
}

.assess-option-check {
    display: flex;
    align-items: flex-start;
    gap: .75rem;
    padding: .75rem 1rem;
    padding-left: 1rem;
    border: 1px solid rgba(0, 0, 0, .08);
    border-radius: .5rem;
    background: #f8f9fa;
    margin: 0;
    min-height: auto;
}

.assess-option-check .form-check-input {
    float: none;
    margin: .2rem 0 0 0;
    flex-shrink: 0;
    position: static;
}

.assess-option-check .form-check-label {
    flex: 1;
    padding-left: 0;
    line-height: 1.45;
}

.assess-option-check:has(.form-check-input:checked) {
    border-color: #10b981;
    background: rgba(16, 185, 129, .08);
}

.assess-options .form-check:not(.assess-option-check) {
    padding: .5rem 0;
}

.assess-question + .assess-question {
    padding-top: .25rem;
    border-top: 1px solid rgba(0, 0, 0, .06);
}

.assess-other-field {
    padding-left: .15rem;
}

/* Resultatsida – kompakt header, innehåll på vit bakgrund (läsbar text) */
.results-hero {
    padding-bottom: 0;
}

.results-hero-inner {
    margin-top: 2.5rem !important;
    margin-bottom: 2.5rem !important;
}

.results-main {
    background: #fff;
    color: #212529;
}

.results-page .results-main .card {
    color: #212529;
}

.assessment-personal-lead {
    color: #0f766e;
    font-size: .95rem;
    line-height: 1.45;
}

.results-actions {
    border-top: 1px solid rgba(0, 0, 0, .08);
}

.results-print-brand {
    font-size: 1.1rem;
    font-weight: 600;
}

.results-print-meta {
    font-size: .85rem;
    color: #6c757d;
}

@media print {
    body.results-page {
        background: #fff;
    }

    body.results-page nav.navbar,
    body.results-page footer.site-footer,
    body.results-page .results-hero,
    body.results-page .no-print,
    body.results-page .results-actions {
        display: none !important;
        visibility: hidden !important;
        height: 0 !important;
        min-height: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: hidden !important;
        border: 0 !important;
    }

    .results-main {
        padding-top: 0 !important;
    }

    .results-print-header {
        padding-bottom: .75rem;
        margin-bottom: 1rem !important;
        border-bottom: 1px solid #dee2e6;
    }

    .results-print-brand {
        color: #000 !important;
    }

    .results-app-card {
        break-inside: avoid;
        box-shadow: none !important;
        border: 1px solid #dee2e6 !important;
    }

    .assessment-personal-lead {
        color: #000 !important;
    }
}

/* Bedömning – "beräknings"-overlay */
body.assess-computing-active {
    overflow: hidden;
}

.assess-compute-overlay {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    background: rgba(15, 23, 42, .72);
    backdrop-filter: blur(6px);
}

.assess-compute-overlay[hidden] {
    display: none !important;
}

.assess-compute-panel {
    width: min(100%, 420px);
    padding: 2rem 1.75rem;
    border-radius: 1rem;
    background: linear-gradient(160deg, #1e293b 0%, #0f172a 100%);
    color: #f8fafc;
    box-shadow: 0 24px 60px rgba(0, 0, 0, .35);
    text-align: center;
}

.assess-compute-title {
    font-weight: 700;
    font-size: 1.15rem;
}

.assess-compute-status {
    color: #94a3b8;
    min-height: 1.5em;
}

.assess-compute-ring {
    width: 72px;
    height: 72px;
    margin: 0 auto 1.25rem;
    border-radius: 50%;
    border: 3px solid rgba(16, 185, 129, .25);
    display: flex;
    align-items: center;
    justify-content: center;
    animation: assess-ring-spin 1.2s linear infinite;
}

.assess-compute-ring-core {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #10b981;
    box-shadow: 0 0 20px rgba(16, 185, 129, .8);
    animation: assess-core-pulse 1s ease-in-out infinite;
}

@keyframes assess-ring-spin {
    to { transform: rotate(360deg); }
}

@keyframes assess-core-pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.35); opacity: .7; }
}

.assess-compute-progress-track {
    height: 8px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .12);
    overflow: hidden;
}

.assess-compute-progress-bar {
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #10b981, #34d399, #6ee7b7);
    transition: width .12s ease-out;
}

.assess-compute-steps {
    text-align: left;
    color: #64748b;
}

.assess-compute-steps li {
    position: relative;
    padding-left: 1.35rem;
    margin-bottom: .35rem;
}

.assess-compute-steps li::before {
    content: '';
    position: absolute;
    left: 0;
    top: .45rem;
    width: .55rem;
    height: .55rem;
    border-radius: 50%;
    background: #334155;
}

.assess-compute-steps li.is-active {
    color: #e2e8f0;
}

.assess-compute-steps li.is-active::before {
    background: #10b981;
    box-shadow: 0 0 8px rgba(16, 185, 129, .6);
}

.assess-compute-steps li.is-done {
    color: #94a3b8;
}

.assess-compute-steps li.is-done::before {
    background: #10b981;
}

@media (prefers-reduced-motion: reduce) {
    .assess-compute-ring,
    .assess-compute-ring-core {
        animation: none;
    }
    .assess-compute-progress-bar {
        transition: none;
    }
}

.soft-shadow {
    box-shadow: 0 12px 30px rgba(0,0,0,.06);
}

.course-badge { letter-spacing: .02em; }
.feature-pill {
    background: rgba(255,255,255,.12);
    border: 1px solid rgba(255,255,255,.18);
    border-radius: 999px;
    padding: .45rem .8rem;
    display: inline-block;
    margin: .25rem .35rem .25rem 0;
    color: #fff;
    font-size: .95rem;
}
.benefit-card { border: 1px solid rgba(0,0,0,.06); }
.course-section-title { margin-bottom: .75rem; }
.course-timeline li { margin-bottom: .35rem; }

.course-faq-item {
    padding: 1.25rem 1.25rem 1.35rem;
    background: #f8f9fa;
    border-radius: .75rem;
    border: 1px solid rgba(0, 0, 0, .06);
}

.course-faq-label {
    font-size: .8rem;
    letter-spacing: .04em;
    text-transform: uppercase;
    margin-bottom: .5rem;
}

/* Kurssida – visuell landning */
.course-landing {
    background: #fff;
}

.course-visual-img {
    width: 100%;
    height: auto;
    aspect-ratio: 3 / 2;
    object-fit: cover;
    border-radius: 1rem;
    box-shadow: 0 16px 40px rgba(0, 0, 0, .08);
}

.course-lead {
    font-size: 1.125rem;
    line-height: 1.65;
    color: #444;
}

.course-intro .course-section-title {
    margin-bottom: 1rem;
}

.course-steps-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: .85rem;
}

.course-steps-list-item {
    display: flex;
    gap: .85rem;
    align-items: flex-start;
    padding: 1rem 1.1rem;
    background: #f8f9fa;
    border: 1px solid rgba(0, 0, 0, .06);
    border-radius: .75rem;
}

.course-steps-list-num {
    flex-shrink: 0;
    width: 2rem;
    height: 2rem;
    border-radius: 50%;
    background: #667eea;
    color: #fff;
    font-size: .85rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.course-audience-card {
    display: flex;
    gap: .85rem;
    align-items: flex-start;
    padding: 1rem 1.1rem;
    background: #f8f9fa;
    border: 1px solid rgba(0, 0, 0, .06);
    border-radius: .75rem;
    height: 100%;
}

.course-audience-icon {
    flex-shrink: 0;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: .65rem;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: #fff;
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .02em;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.course-steps-row {
    display: flex;
    flex-wrap: wrap;
    gap: .65rem;
}

.course-step-chip {
    display: inline-flex;
    align-items: center;
    gap: .55rem;
    padding: .55rem .85rem;
    background: #f8f9fa;
    border: 1px solid rgba(0, 0, 0, .07);
    border-radius: 999px;
    font-size: .92rem;
}

.course-step-num {
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 50%;
    background: #667eea;
    color: #fff;
    font-size: .78rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.course-step-label {
    font-weight: 500;
    color: #333;
}

.course-purchase-panel {
    border-radius: 1rem;
    overflow: hidden;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, .08);
    box-shadow: 0 12px 32px rgba(0, 0, 0, .07);
}

.course-purchase-panel-img {
    width: 100%;
    height: 11rem;
    object-fit: cover;
    display: block;
}

.course-purchase-panel-body {
    padding: 1.35rem 1.5rem 1.5rem;
}

.course-purchase-price {
    font-size: 1.75rem;
    font-weight: 700;
    color: #667eea;
    line-height: 1.2;
}

.course-purchase-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.course-purchase-list li {
    position: relative;
    padding: .3rem 0 .3rem 1.35rem;
    font-size: .95rem;
}

.course-purchase-list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: #10b981;
    font-weight: 700;
}

.course-faq-accordion .accordion-item {
    border: 1px solid rgba(0, 0, 0, .08);
    border-radius: .75rem !important;
    overflow: hidden;
    margin-bottom: .65rem;
}

.course-faq-accordion .accordion-button {
    font-weight: 600;
    font-size: 1rem;
    box-shadow: none;
}

.course-faq-accordion .accordion-button:not(.collapsed) {
    background: #f8f9fa;
    color: #333;
}

@media (max-width: 991.98px) {
    .course-purchase-panel {
        margin-top: .5rem;
    }
}

.article-sidebar {
    position: sticky;
    top: 90px;
}

.article-sidebar-list {
    display: grid;
    gap: 1rem;
}

.article-sidebar-item + .article-sidebar-item {
    padding-top: 1rem;
    border-top: 1px solid rgba(0,0,0,.08);
}

.article-sidebar-link {
    color: #212529;
    text-decoration: none;
}

.article-sidebar-link:hover,
.article-sidebar-link:focus {
    color: #0d6efd;
    text-decoration: none;
}

.site-footer .footer-links {
    text-align: right;
}

.site-footer .footer-links li + li {
    margin-top: .5rem;
}

.site-footer a {
    color: #495057;
    text-decoration: none;
    font-size: .95rem;
}

.site-footer a:hover,
.site-footer a:focus {
    color: #212529;
    text-decoration: none;
}

@media (max-width: 767px) {
    .hero-home h1,
    .hero-network h1,
    .hero-course h1 {
        font-size: 2rem;
        line-height: 1.15;
    }
}

/* Contact form – honeypot hidden from users */
.guide-card {
    border-radius: 1rem;
    transition: transform .2s ease, box-shadow .2s ease;
}

.guide-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 .75rem 1.5rem rgba(0, 0, 0, .1) !important;
}

.guide-card-link {
    cursor: pointer;
}

.guide-card-more {
    font-size: .9rem;
    font-weight: 600;
    color: #667eea;
}

.guides-intro {
    max-width: 640px;
}

/* Fancybox – guide detail */
.guide-fancybox-wrap {
    --f-button-color: #212529;
    --f-button-hover-color: #000;
    --f-button-bg: #f1f3f5;
    --f-button-hover-bg: #e9ecef;
    --f-button-active-bg: #dee2e6;
    --f-button-border-radius: 50%;
    --f-button-svg-stroke-width: 2;
    --f-button-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
}

.guide-fancybox-wrap .fancybox__content {
    padding: 0;
    width: 95vw;
    max-width: 95vw;
    border-radius: 1rem;
    overflow: visible;
    box-sizing: border-box;
}

.guide-fancybox {
    padding: 1.5rem 1.75rem 1.75rem;
    text-align: left;
    color: #212529;
    background: #fff;
    border-radius: 1rem;
    overflow: hidden;
}

.guide-fancybox-header {
    position: relative;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    padding-right: 3rem;
    border-bottom: 1px solid rgba(0, 0, 0, .08);
}

.guide-fancybox-close-btn {
    position: absolute;
    top: 0;
    right: 0;
    width: 2.75rem;
    height: 2.75rem;
    margin: 0;
    padding: 0;
    border: none;
    border-radius: 50%;
    background: #f1f3f5;
    color: #212529;
    font-size: 1.75rem;
    line-height: 1;
    font-weight: 300;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
    z-index: 2;
}

.guide-fancybox-close-btn:hover {
    background: #e9ecef;
    color: #000;
}

.guide-fancybox-body {
    font-size: 1rem;
    line-height: 1.65;
    max-height: 50vh;
    overflow-y: auto;
    margin-bottom: 1.25rem;
}

.guide-fancybox-body h2,
.guide-fancybox-body h3 {
    font-size: 1.15rem;
    font-weight: 700;
    margin-top: 1.25rem;
    margin-bottom: .5rem;
}

.guide-fancybox-body ul,
.guide-fancybox-body ol {
    padding-left: 1.25rem;
}

.guide-fancybox-body a {
    color: #667eea;
}

.guide-fancybox-footer {
    padding-top: .25rem;
}

.guide-fancybox-preview {
    max-height: 280px;
    overflow-y: auto;
    font-size: .95rem;
}

.contact-hp {
    position: absolute;
    left: -10000px;
    width: 1px;
    height: 1px;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
}

.contact-info-list dt {
    font-size: 0.875rem;
    color: #6c757d;
    margin-bottom: 0.25rem;
}

.contact-info-list dd {
    margin-left: 0;
}

.contact-info-card a {
    font-weight: 600;
    text-decoration: none;
}

.contact-info-card a:hover {
    text-decoration: underline;
}

.contact-vat {
    font-size: inherit;
    font-weight: 400;
    padding: 0;
    background: none;
    color: #6c757d;
    font-family: inherit;
}

/* Article card titles on homepage */
.card h3 a {
    color: #212529;
    text-decoration: none;
}

.card h3 a:hover {
    color: #0d6efd;
    text-decoration: underline;
}
