/* =========================================================
   QM PERSONAL – Vorschau anonymes QM-Qualifikationsprofil
   ========================================================= */

.profile-preview {
    max-width: 72rem;
    margin-inline: auto;
}

.profile-preview__nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin: 1rem 0 1.25rem;
}

.profile-preview__nav--bottom {
    scroll-margin-top: 5rem;
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--qm-border, #dce6cc);
}

.profile-preview__nav-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0.7rem 1rem;
    color: var(--qm-primary, #7fa82f);
    background: #fff;
    border: 2px solid var(--qm-primary, #7fa82f);
    border-radius: 0.5rem;
    font: inherit;
    font-weight: 700;
    line-height: 1.3;
    text-align: center;
    text-decoration: none;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.profile-preview__nav-button:hover,
.profile-preview__nav-button:focus-visible {
    color: #fff;
    background: var(--qm-primary, #7fa82f);
    text-decoration: none;
}

.profile-preview__nav-button:focus-visible {
    outline: 3px solid rgba(127, 168, 47, 0.3);
    outline-offset: 2px;
}

.profile-preview__hero {
    padding: clamp(1.2rem, 3vw, 2rem);
    background: linear-gradient(135deg, #fff 0%, #f4f8ec 100%);
    border: 2px solid var(--qm-primary, #7fa82f);
    border-radius: 0.9rem;
    box-shadow: var(--qm-shadow, 0 2px 10px rgba(0, 0, 0, 0.04));
    text-align: center;
}

.profile-preview__eyebrow {
    margin: 0 0 0.4rem;
    color: #597426;
    font-weight: 700;
}

.profile-preview__hero h1 {
    margin: 0;
    color: #243b0e;
    font-size: clamp(1.5rem, 4vw, 2.25rem);
    line-height: 1.2;
}

.profile-preview__meta {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.55rem 1.25rem;
    margin-top: 1rem;
    color: #3f4738;
}

.profile-preview__section {
    margin: 1.25rem 0;
    padding: clamp(1rem, 2.5vw, 1.35rem);
    border: 1px solid #d8e1cd;
    border-radius: 0.875rem;
    box-shadow: 0 0.25rem 0.9rem rgba(0, 0, 0, 0.045);
    scroll-margin-top: 5rem;
}

.profile-preview__section--green { background: #f4f9ec; border-color: #cfdfb5; }
.profile-preview__section--blue { background: #f1f7fc; border-color: #c9ddec; }
.profile-preview__section--yellow { background: #fffbea; border-color: #eadfae; }
.profile-preview__section--purple { background: #f7f3fb; border-color: #dcd0e8; }
.profile-preview__section--mint { background: #f0faf5; border-color: #c7e4d5; }
.profile-preview__section--gray { background: #f7f7f7; border-color: #ddd; }
.profile-preview__section--orange { background: #fff5ef; border-color: #ead2c4; }

.profile-preview__section-heading {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(80, 100, 60, 0.18);
}

.profile-preview__section-heading span {
    display: inline-flex;
    flex: 0 0 2.25rem;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    color: #fff;
    background: var(--qm-primary, #7fa82f);
    border-radius: 50%;
    font-weight: 700;
}

.profile-preview__section-heading h2 {
    margin: 0;
    color: #243b0e;
    font-size: 1.3rem;
}

.profile-preview__facts {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
    margin: 0;
}

.profile-preview__facts > div {
    min-width: 0;
    padding: 0.75rem;
    background: rgba(255, 255, 255, 0.82);
    border: 1px solid rgba(70, 95, 45, 0.18);
    border-radius: 0.55rem;
}

.profile-preview__facts dt {
    margin-bottom: 0.25rem;
    color: #4f5a48;
    font-size: 0.9rem;
    font-weight: 700;
}

.profile-preview__facts dd {
    margin: 0;
    color: #1a1a1a;
    overflow-wrap: anywhere;
}

.profile-preview__facts-full {
    grid-column: 1 / -1;
}

.profile-preview__projects {
    display: grid;
    gap: 1rem;
}

.profile-preview__project {
    padding: 1rem;
    background: rgba(255, 255, 255, 0.78);
    border: 1px solid rgba(70, 95, 45, 0.2);
    border-radius: 0.65rem;
}

.profile-preview__project h3,
.profile-preview__note h3 {
    margin: 0 0 0.75rem;
    color: #365417;
    font-size: 1.08rem;
}

.profile-preview__table-wrap {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.profile-preview__table {
    width: 100%;
    min-width: 32rem;
    border-collapse: collapse;
    table-layout: fixed;
    background: #fff;
}

.profile-preview__table th,
.profile-preview__table td {
    padding: 0.75rem;
    border: 1px solid var(--qm-border, #dce6cc);
    text-align: left;
    vertical-align: top;
    overflow-wrap: anywhere;
}

.profile-preview__table th {
    color: #29420f;
    background: var(--qm-soft, #eef5e3);
    font-weight: 700;
}

.profile-preview__table--software th:first-child,
.profile-preview__table--software td:first-child {
    width: 28%;
}

.profile-preview__tag-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr));
    gap: 0.65rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.profile-preview__tag-list li {
    padding: 0.75rem;
    background: rgba(255, 255, 255, 0.84);
    border: 1px solid rgba(92, 69, 118, 0.22);
    border-radius: 0.5rem;
}

.profile-preview__note {
    margin-top: 1rem;
    padding: 0.9rem;
    background: rgba(255, 255, 255, 0.84);
    border: 1px solid rgba(70, 95, 45, 0.18);
    border-radius: 0.55rem;
}

.profile-preview__note p {
    margin: 0;
    overflow-wrap: anywhere;
}

.profile-preview__empty {
    margin: 0;
    padding: 0.85rem;
    color: #555;
    background: rgba(255, 255, 255, 0.75);
    border-radius: 0.5rem;
}

@media (max-width: 48rem) {
    .profile-preview__nav {
        flex-direction: column;
        align-items: stretch;
    }

    .profile-preview__nav-button {
        width: 100%;
        min-height: 50px;
    }

    .profile-preview__meta {
        align-items: stretch;
        flex-direction: column;
    }

    .profile-preview__facts {
        grid-template-columns: 1fr;
    }

    .profile-preview__facts-full {
        grid-column: 1;
    }

    .profile-preview__section-heading {
        align-items: flex-start;
    }
}

@media print {
    .profile-preview__nav,
    .site-header,
    .site-footer {
        display: none !important;
    }

    .profile-preview__section,
    .profile-preview__hero {
        break-inside: avoid;
        box-shadow: none;
    }
}

/* =========================================================
   Sprungnavigation innerhalb der Profilvorschau
   ========================================================= */

.profile-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    margin: 1.25rem 0;
    padding: 1rem;
    background: var(--qm-soft-2, #f8fbf2);
    border: 1px solid var(--qm-border, #dce6cc);
    border-radius: 0.75rem;
    scroll-margin-top: 5rem;
}

.profile-nav a,
.profile-preview__section-nav a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0.6rem 0.85rem;
    color: #365417;
    background: #fff;
    border: 1px solid var(--qm-primary, #7fa82f);
    border-radius: 0.45rem;
    font-weight: 700;
    line-height: 1.25;
    text-align: center;
    text-decoration: none;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.profile-nav a:hover,
.profile-nav a:focus-visible,
.profile-preview__section-nav a:hover,
.profile-preview__section-nav a:focus-visible {
    color: #fff;
    background: var(--qm-primary, #7fa82f);
    text-decoration: none;
}

.profile-nav a:focus-visible,
.profile-preview__section-nav a:focus-visible {
    outline: 3px solid rgba(127, 168, 47, 0.3);
    outline-offset: 2px;
}

.profile-preview__section-nav {
    display: flex;
    justify-content: flex-end;
    margin-top: 1rem;
    padding-top: 0.85rem;
    border-top: 1px solid rgba(80, 100, 60, 0.16);
}

.profile-preview__section-nav a {
    min-height: 40px;
    padding: 0.5rem 0.75rem;
    font-size: 0.92rem;
}

@media (max-width: 48rem) {
    .profile-nav {
        display: grid;
        grid-template-columns: 1fr;
    }

    .profile-nav a,
    .profile-preview__section-nav a {
        width: 100%;
    }
}

@media print {
    .profile-nav,
    .profile-preview__section-nav {
        display: none !important;
    }
}
