/* ==========================================
   KETMarket Expert Profile
   ========================================== */

:root {
    --ketm-primary: #0f172a;
    --ketm-primary-2: #1e293b;
    --ketm-accent: #005E86;
    --ketm-accent-dark: #0095cc;
    --ketm-bg: #f8fafc;
    --ketm-surface: #ffffff;
    --ketm-text: #0f172a;
    --ketm-text-soft: #64748b;
    --ketm-border: #e2e8f0;
    --ketm-shadow: 0 20px 50px rgba(15, 23, 42, 0.10);
    --ketm-radius-xl: 24px;
    --ketm-radius-lg: 18px;
    --ketm-radius-md: 5px;
}

/* =========================
   WRAPPER
   ========================= */
.ketm-expert-profile {
    max-width: 1200px;
    margin: 48px auto;
    background: var(--ketm-surface);
    border: 1px solid var(--ketm-border);
    border-radius: var(--ketm-radius-md);
    box-shadow: var(--ketm-shadow);
    overflow: hidden;
    color: var(--ketm-text);
}

/* =========================
   HERO / COVER
   ========================= */
.ketm-expert-profile__media {
    position: relative;
    height: 320px;
    overflow: hidden;
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.88), rgba(0, 174, 239, 0.55));
}

.ketm-expert-profile__media img,
.ketm-expert-profile__hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    opacity: 0.45;
    transform: scale(1.02);
}

.ketm-expert-profile__media::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(15, 23, 42, 0.10) 0%,
        rgba(15, 23, 42, 0.68) 100%
    );
    pointer-events: none;
}

/* =========================
   INTRO / HEADER
   ========================= */
.ketm-expert-profile__header {
    position: relative;
    z-index: 2;
    max-width: 1200px;
    margin: -88px auto 0;
    padding: 0 32px 24px;
    display: flex;
    align-items: flex-end;
    gap: 24px;
}

.ketm-expert-profile__image {
    width: 168px;
    height: 168px;
    min-width: 168px;
    border-radius: 50%;
    object-fit: cover;
    background: #fff;
    border: 6px solid #fff;
    box-shadow: 0 16px 40px rgba(15, 23, 42, 0.18);
}

.ketm-expert-profile__image--placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--ketm-primary), var(--ketm-accent));
    color: #fff;
    font-size: 3rem;
    font-weight: 800;
    line-height: 1;
}

.ketm-expert-profile__header-text {
    min-width: 0;
    flex: 1;
}

.ketm-expert-profile__name {
    margin: 0;
    font-size: clamp(1.5rem, 2.2vw, 2.2rem);
    line-height: 1.05;
    font-weight: 600;
    color: var(--ketm-text);
    letter-spacing: -0.02em;
    background: #fff;
    padding: 6px 14px;
    border-radius: var(--ketm-radius-md);
    box-shadow: 0 8px 20px rgba(0,0,0,0.08);
    display: inline-block;
}

.ketm-expert-profile__title {
    margin-top: 10px;
    font-size: 1.05rem;
    font-weight: 500;
    color: var(--ketm-text-soft);
}

/* =========================
   2-COLUMN LAYOUT
   ========================= */
.ketm-expert-profile__body {
    display: grid;
    grid-template-columns: minmax(0, 1.8fr) minmax(280px, 0.9fr);
    gap: 32px;
    padding: 8px 32px 32px;
    align-items: start;
}

.ketm-expert-profile__main,
.ketm-expert-profile__sidebar {
    min-width: 0;
}

.ketm-expert-profile__sidebar {
    position: sticky;
    top: 110px;
    display: grid;
    gap: 16px;
    align-self: start;
}

/* =========================
   CARDS / SECTIONS
   ========================= */
.ketm-expert-profile__section,
.ketm-expert-profile__contact-card,
.ketm-expert-profile__meta-col {
    background: var(--ketm-surface);
    border: 1px solid var(--ketm-border);
    border-radius: var(--ketm-radius-md);
    padding: 24px;
}

.ketm-expert-profile__section {
    margin-bottom: 20px;
}

.ketm-expert-profile__section:last-child {
    margin-bottom: 0;
}

.ketm-expert-profile__section h3,
.ketm-expert-profile__contact-card h3,
.ketm-expert-profile__meta-col h3 {
    margin: 0 0 12px;
    font-size: 16px;
    line-height: 1;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--ketm-accent);
}

.ketm-expert-profile__content,
.ketm-expert-profile__section > p,
.ketm-expert-profile__section li {
    color: var(--ketm-text);
    line-height: 1.75;
    font-size: 1rem;
}

.ketm-expert-profile__content p:first-child {
    margin-top: 0;
}

.ketm-expert-profile__content p:last-child {
    margin-bottom: 0;
}

.ketm-expert-profile__section a,
.ketm-expert-profile__content a {
    color: var(--ketm-accent-dark);
    text-decoration: none !important;
    font-weight: 600;
}

.ketm-expert-profile__section a:hover,
.ketm-expert-profile__content a:hover {
    text-decoration: underline;
}

/* =========================
   CATEGORIES / TAGS
   ========================= */
.ketm-expert-profile__meta-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.ketm-expert-profile__meta-col {
    min-width: 0;
}

/* =========================
   ORGANIZATION
   ========================= */
/*.ketm-expert-profile__organization-media {
    margin-top: 14px;
}*/

.ketm-expert-profile__organization-image {
    display: block;
    max-width: 180px;
    width: 100%;
    height: auto;
    background: #fff;
}

/* =========================
   BADGES
   ========================= */
.ketm-expert-profile__badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.ketm-badge {
    display: inline-flex;
    align-items: center;
    padding: 7px 12px;
    border-radius: 999px;
    background: rgba(0, 174, 239, 0.10);
    border: 1px solid rgba(0, 174, 239, 0.16);
    color: var(--ketm-accent-dark);
    font-size: 0.86rem;
    font-weight: 700;
    line-height: 1.2;
}

/* =========================
   SIDEBAR CONTACT CARD
   ========================= */
.ketm-expert-profile__contact-card {
    background: linear-gradient(180deg, #ffffff 0%, #f8fbfd 100%);
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.06);
    padding: 24px;
    border-radius: var(--ketm-radius-md);
}

.ketm-expert-profile__contact-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 8px;
}

.ketm-expert-profile__contact-list li {
    margin: 0;
}

.ketm-expert-profile__contact-link {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 10px 12px;
    border-radius: var(--ketm-radius-md);
    border: 1px solid var(--ketm-border);
    background: #fff;
    color: var(--ketm-primary);
    text-decoration: none;
    font-weight: 400;
    transition:
        transform 0.15s ease,
        box-shadow 0.15s ease,
        border-color 0.15s ease;
    box-sizing: border-box;
}

.ketm-expert-profile__contact-link:hover {
    transform: translateY(-1px);
    border-color: var(--ketm-accent);
    box-shadow: 0 6px 16px rgba(15, 23, 42, 0.06);
    text-decoration: none;
}

.ketm-expert-profile__contact-icon {
    width: 34px;
    height: 34px;
    min-width: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: rgba(0, 174, 239, 0.12);
    color: var(--ketm-accent-dark);
}

.ketm-expert-profile__contact-icon svg {
    width: 16px;
    height: 16px;
    display: block;
}

.ketm-expert-profile__contact-text {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0;
    line-height: 1;
}

.ketm-expert-profile__contact-label {
    font-size: 14px;
    line-height: 1;
    margin: 0;
    padding: 0;
    font-weight: 600;
}

.ketm-expert-profile__contact-value {
    font-size: 14px;
    line-height: 1.1;
    margin: 0;
    padding: 0;
}

/* =========================
   RESPONSIVE
   ========================= */
@media (max-width: 980px) {
    .ketm-expert-profile__body {
        grid-template-columns: 1fr;
    }

    .ketm-expert-profile__sidebar {
        position: static;
        top: auto;
    }
}

@media (max-width: 767px) {
    .ketm-expert-profile {
        margin: 24px auto;
        border-radius: var(--ketm-radius-md);
    }

    .ketm-expert-profile__media {
        height: 220px;
    }

    .ketm-expert-profile__header {
        margin-top: -64px;
        padding: 0 20px 20px;
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .ketm-expert-profile__image {
        width: 128px;
        height: 128px;
        min-width: 128px;
    }

    .ketm-expert-profile__image--placeholder {
        font-size: 2.4rem;
    }

    .ketm-expert-profile__body {
        padding: 4px 20px 20px;
        gap: 20px;
    }

    .ketm-expert-profile__section,
    .ketm-expert-profile__contact-card {
        padding: 18px;
    }

    .ketm-expert-profile__contact-link {
        padding: 10px 11px;
    }

    .ketm-expert-profile__contact-value {
        white-space: normal;
        overflow: visible;
        text-overflow: unset;
    }
}

/* ========================================================================================================================================================================
   Expert Archive
   ======================================================================================================================================================================== */
.ketm-expert-archive {
    max-width: 1200px;
    margin: 48px auto;
    overflow: visible;
}

/* =========================
   HERO (FULL WIDTH)
========================= */
.ketm-expert-archive__hero {
    position: relative;
    min-height: 360px;
    margin-bottom: 0;

    /* FULL WIDTH BREAKOUT */
    width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);

    overflow: hidden;
    background-color: #0f172a;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;

    display: flex;
    align-items: center;
}

.ketm-expert-archive__hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(15, 23, 42, 0.35) 0%,
        rgba(15, 23, 42, 0.65) 100%
    );
}

.ketm-expert-archive__hero-inner {
    position: relative;
    z-index: 1;

    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 48px 24px;

    display: flex;
    flex-direction: column;
    justify-content: center;

    color: #fff;
    box-sizing: border-box;
}

.ketm-expert-archive__hero-title {
    margin: 0 0 10px;
    font-size: clamp(2rem, 4vw, 3.5rem);
    line-height: 1.05;
    font-weight: 800;
    color: #fff;
    text-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.ketm-expert-archive__hero-subtitle {
    font-size: 1.05rem;
    line-height: 1.3;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #fff;
    text-shadow: 0 4px 14px rgba(0, 0, 0, 0.2);
}

/* =========================
   INTRO
========================= */
.ketm-expert-archive__intro {
    padding: 40px 24px 44px;
    background: #f8fafc;
    border: 1px solid var(--ketm-border);
    border-top: 0;
    margin-bottom: 32px;
}

.ketm-expert-archive__intro-inner {
    max-width: 1040px;
    margin: 0 auto;
    text-align: center;
    align-items: center;
    justify-content: center;
}

.ketm-expert-archive__intro-text {
    color: var(--ketm-text-soft);
    font-size: 1.05rem;
    line-height: 1.85;
}

.ketm-expert-archive__intro-text p {
    margin: 0;
}

.ketm-expert-archive__intro-action {
    margin-top: 28px;
}

.ketm-expert-archive__hero-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0 22px;
    border-radius: 999px;

    background: var(--ketm-accent);
    border: 1px solid var(--ketm-accent);
    color: #fff;

    text-decoration: none !important;
    font-size: 0.98rem;
    font-weight: 700;

    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.10);
    transition: all 0.18s ease;
}

.ketm-expert-archive__hero-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 16px 30px rgba(15, 23, 42, 0.14);
    color: #fff !important;
}

/* =========================
   GRID
========================= */
.ketm-expert-archive__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 12px;
    align-items: stretch;
}

/* Owner Actions*/
.ketm-expert-profile__owner-actions .gd-author-actions.text-white {
    display: flex !important;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 15px;
    margin-left: 32px;
}

.ketm-expert-profile__owner-actions .gd-author-actions.text-white > * {
    margin: 0 !important;
    width: auto !important;
}

/* =========================
   CARD
========================= */
.ketm-expert-archive__card {
    width: 100%;
    max-width: 320px;
    justify-self: center;

    display: flex;
    height: 100%; 

    background: var(--ketm-surface);
    border: 1px solid var(--ketm-border);
    border-radius: var(--ketm-radius-md);
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.06);
    overflow: hidden;
    transition: all 0.18s ease;
}

.ketm-expert-archive__card:hover {
    transform: translateY(-3px);
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.10);
    border-color: rgba(0, 149, 204, 0.35);
}

.ketm-expert-archive__card-link {
    display: flex;
    flex-direction: column;
    justify-self: center;
    padding: 22px;
    color: inherit;
    text-decoration: none !important;
    width: 100%; 
    height: 100%;

    justify-content: center;   /* vertikal */
    align-items: start;       /* horizontal */
}

.ketm-expert-archive__card-top {
    display: flex;
    align-items: center;
    gap: 16px;
}

.ketm-expert-archive__avatar {
    width: 72px;
    height: 72px;
    min-width: 72px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #fff;
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.10);
    background: #fff;
}

.ketm-expert-archive__avatar--placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--ketm-primary), var(--ketm-accent));
    color: #fff;
    font-weight: 800;
    font-size: 1.4rem;
}

.ketm-expert-archive__head {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.ketm-expert-archive__name {
    margin: 0 0 6px;
    font-size: 1.15rem;
    font-weight: 700;
    text-decoration: none !important;

    display: -webkit-box;
    -webkit-line-clamp: 2;   /* max 2 Zeilen */
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.ketm-expert-archive__title {
    font-size: 0.96rem;
    color: var(--ketm-text-soft);
    margin-bottom: 6px;

    display: -webkit-box;
    -webkit-line-clamp: 2;   /* max 2 Zeilen */
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.ketm-expert-archive__org,
.ketm-expert-archive__org a {
    font-size: 0.92rem;
    color: var(--ketm-accent);
    font-weight: 600;
    text-decoration: none;
}

/* =========================
   FOOTER / TAGS
========================= */
.ketm-expert-archive__footer {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin-top: 16px;
}

.ketm-expert-archive__pill {
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(0, 174, 239, 0.10);
    border: 1px solid rgba(0, 174, 239, 0.16);
    font-size: 0.8rem;
    font-weight: 700;
}

.ketm-expert-archive__more {
    margin-left: auto;
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--ketm-accent);
}

/* =========================
   PAGINATION
========================= */
.ketm-expert-archive__pagination {
    margin-top: 32px;
}

.ketm-expert-archive__pagination ul {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    list-style: none;
    padding: 0;
}

.ketm-expert-archive__pagination a,
.ketm-expert-archive__pagination span {
    min-width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--ketm-border);
    border-radius: var(--ketm-radius-md);
    background: #fff;
}

.ketm-expert-archive__pagination .current {
    background: var(--ketm-accent);
    color: #fff;
}

/* =========================
   PAGINATION
========================= */
.ketm-expert-archive__pagination {
    margin-top: 40px;
    display: flex;
    justify-content: center;
}

.ketm-expert-archive__pagination ul {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 10px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.ketm-expert-archive__pagination li {
    margin: 0;
    padding: 0;
}

.ketm-expert-archive__pagination a,
.ketm-expert-archive__pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 35px;
    height: 35px;
    padding: 0 14px;
    box-sizing: border-box;

    border: 1px solid var(--ketm-border);
    border-radius: var(--ketm-radius-md) !important;
    background: #fff;
    color: var(--ketm-primary);

    font-size: 14px;
    font-weight: 700;
    line-height: 1;
    text-decoration: none !important;

}

.ketm-expert-archive__pagination a:hover,
.ketm-expert-archive__pagination a:focus {
    transform: translateY(-1px);
    border-color: var(--ketm-accent);
    color: var(--ketm-accent);
    background: #f8fbfd;
    outline: none;
}

.ketm-expert-archive__pagination .current {
    background-color: var(--ketm-accent) !important;
    border-color: var(--ketm-accent);
    color: #fff !important
}

.ketm-expert-archive__pagination .dots {
    min-width: auto;
    width: auto;
    padding: 0 6px;
    border: 0;
    background: transparent;
    box-shadow: none;
    color: var(--ketm-text-soft);
}

.ketm-expert-archive__pagination .prev,
.ketm-expert-archive__pagination .next {
    padding: 0 16px;
    min-width: 35px;
}

.ketm-expert-archive__upsell {
    margin-top: 28px;
    padding: 18px 20px;
    border: 1px solid var(--ketm-border);
    border-radius: var(--ketm-radius-md);
    background: linear-gradient(180deg, #ffffff 0%, #f8fbfd 100%);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.05);
    text-align: center;
}

.ketm-expert-archive__upsell-text {
    margin: 0 0 12px;
    color: var(--ketm-text-soft);
    font-size: 0.98rem;
    line-height: 1.6;
}

.ketm-expert-archive__upsell-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 18px;
    border-radius: 999px;
    border: 1px solid var(--ketm-accent);
    background: #fff;
    color: var(--ketm-accent);
    font-weight: 700;
    text-decoration: none !important;
    transition: all 0.18s ease;
}

.ketm-expert-archive__upsell-link:hover {
    background: var(--ketm-accent);
    color: #fff;
    border-color: var(--ketm-accent);
}

/* =========================
   MOBILE
========================= */
@media (max-width: 767px) {
    .ketm-expert-archive {
        margin: 32px auto;
    }

    .ketm-expert-archive__hero {
        min-height: 240px;
    }

    .ketm-expert-archive__hero-inner {
        padding: 32px 16px;
    }

    .ketm-expert-archive__hero-title {
        font-size: 2rem;
    }

    .ketm-expert-archive__intro {
        padding: 28px 18px 32px;
    }

    .ketm-expert-archive__intro-text {
        font-size: 0.98rem;
    }

    .ketm-expert-archive__avatar {
        width: 64px;
        height: 64px;
        min-width: 64px;
    }
}

@media (max-width: 767px) {
    .ketm-expert-archive__pagination {
        margin-top: 28px;
    }

    .ketm-expert-archive__pagination ul {
        gap: 8px;
    }

    .ketm-expert-archive__pagination a,
    .ketm-expert-archive__pagination span {
        min-width: 40px;
        height: 40px;
        padding: 0 12px;
        font-size: 13px;
    }

    .ketm-expert-archive__pagination .prev,
    .ketm-expert-archive__pagination .next {
        padding: 0 12px;
    }
}