@import url("https://fonts.googleapis.com/css2?family=Heebo:wght@400;600;800&display=swap");

:root {
    --blue: #1e3a8a;
    --blue-light: #2563eb;
    --blue-dark: #1e40af;
    --text: #141823;
    --muted: #6b7280;
    --muted-dark: #4b5563;
    --star: #fbbf24;
    --border: #e5e7eb;
    --bg: #f7f7fb;
    --btn-gray: #f3f4f6;
    --icon-gray: #9aa0a6;

    /* ===== Germany (DE) theme ===== */
    --de-black: #000000;
    --de-red: #DD0000;
    --de-gold: #FFCE00;
}

/* בסיס */
body {
    margin: 0;
    background: var(--bg);
    font-family: "Heebo", sans-serif;
    color: var(--text);
}

.wrapper {
    padding: 28px;
}

.card {
    max-width: 900px;
    margin: auto;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 18px;
    box-shadow: 0 8px 22px rgba(0, 0, 0, .06);
    padding: 26px;
    margin-bottom: 34px;
}

.header {
    display: flex;
    flex-direction: row;
    gap: 46px;
    align-items: flex-start;
}

.avatar {
    width: 130px;
    height: 130px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid #d1d5db;
    box-shadow: 0 2px 10px rgba(0, 0, 0, .05);
}

.title {
    margin: 0 0 6px;
    color: #142669;
    font-size: clamp(22px, 3.2vw, 30px);
    font-weight: 800;
}

.subtitle {
    margin: 6px 0 14px;
    font-size: 17px;
    color: var(--muted-dark);
}

.meta-row {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}

.meta {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 15px;
    color: var(--muted-dark);
}

.meta svg {
    width: 18px;
    height: 18px;
}

.rating .score {
    color: #d97706;
    font-weight: 700;
}

.price-wrap {
    display: flex;
    align-items: center;
    margin: 6px 0 2px;
    color: var(--blue);
}

.amount {
    font-size: 26px;
    font-weight: 800;
}

.currency {
    font-weight: 700;
    margin-right: 4px;
}

.per {
    color: var(--muted-dark);
    margin-top: 2px;
}

.actions {
    display: flex;
    gap: 12px;
    margin-top: 18px;
    flex-wrap: wrap;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 11px 18px;
    border-radius: 12px;
    font-weight: 400;
    font-size: 15px;
    border: 1px solid var(--border);
    cursor: pointer;
    text-decoration: none;
    transition: .2s;
}

.btn svg {
    width: 18px;
    height: 18px;
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, .08);
}

.btn-whatsapp {
    color: #fff;
    border: none;
    background: linear-gradient(90deg, var(--blue-dark) 0%, var(--blue-light) 100%);
}

.btn-whatsapp svg {
    stroke: #fff;
    fill: none;
    stroke-width: 2;
}

.btn-soft {
    background: var(--btn-gray);
    border: 1px solid var(--border);
    color: #0f172a;
}

.btn-soft svg {
    fill: none;
    stroke: var(--icon-gray);
    stroke-width: 2;
}

.star {
    fill: gold;
}

.star.dim {
    fill: #ccc;
}

.star.half {
    fill: gold;
    clip-path: inset(0 50% 0 0);
}

/* תג מוביל */
.card {
    position: relative;
    overflow: visible;
}

.card--top {
    border: 3px solid #f59e0b !important;
    box-shadow: 0 8px 22px rgba(0, 0, 0, .06);
}

.top-badge {
    position: absolute;
    top: -14px;
    left: 16px;
    z-index: 10;
    background: #f59e0b;
    color: #fff;
    padding: 8px 12px;
    border-radius: 999px;
    font-weight: 800;
    font-size: 13px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border: 2px solid #fff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, .12);
    white-space: nowrap;
    pointer-events: none;
}

.top-badge svg {
    width: 16px;
    height: 16px;
    stroke: #fff;
    fill: none;
    stroke-width: 2;
}

.page-title {
    text-align: center;
    margin: 30px 0 12px;
    font-weight: 800;
    font-size: clamp(22px, 4vw, 32px);
    color: #1e40af;
}

/* רספונסיביות (כמו במקור) */
@media (max-width:768px) {
    .wrapper {
        padding: 18px
    }

    .card {
        padding: 20px;
        margin-bottom: 22px;
        border-radius: 16px
    }

    .header {
        gap: 24px
    }

    .title {
        font-size: clamp(20px, 4.5vw, 26px)
    }

    .subtitle {
        font-size: 15px
    }

    .amount {
        font-size: 22px
    }

    .actions {
        gap: 10px
    }
}

@media (max-width:560px) {
    .page-title {
        margin: 14px 0 6px;
        font-size: clamp(20px, 6vw, 26px)
    }

    .header {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 16px
    }

    .avatar {
        width: 96px;
        height: 96px;
        border-width: 3px
    }

    .meta-row {
        justify-content: center;
        gap: 12px;
        margin-bottom: 12px
    }

    .price-wrap,
    .per {
        justify-content: center;
        text-align: center
    }

    .actions {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 10px;
        width: 100%;
        margin-top: 14px
    }

    .actions .btn {
        width: 100%;
        justify-content: center;
        padding: 12px 14px;
        font-size: 14px;
        min-height: 44px
    }

    .top-badge {
        top: -10px;
        left: 12px;
        font-size: 12px;
        padding: 6px 10px
    }
}

@media (max-width:360px) {
    .actions {
        grid-template-columns: 1fr
    }
}

@media (max-width:560px) {
    .actions {
        display: flex;
        flex-direction: column;
        gap: 10px;
        width: 100%;
        margin-top: 14px
    }

    .actions .btn {
        width: 100%;
        justify-content: center;
        padding: 12px 14px;
        font-size: 15px;
        min-height: 44px;
        border-radius: 12px
    }
}

/* no horizontal scroll */
html {
    box-sizing: border-box
}

*,
*::before,
*::after {
    box-sizing: inherit
}

html,
body {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden
}

.wrapper {
    max-width: 900px;
    margin: 0 auto;
    padding: min(28px, 5vw)
}

.card {
    width: 100%;
    max-width: 900px;
    margin-inline: auto
}

/* ===== DE Theme ===== */
.de-theme .site-header::after {
    content: "";
    display: block;
    height: 4px;
    background: linear-gradient(90deg, var(--de-black) 0 33%, var(--de-red) 33% 66%, var(--de-gold) 66%);
}

/* “גרמנית” — פס דק ומיקרו-קישוטים בכרטיס */
.de-card {
    position: relative
}

.de-ribbon {
    position: absolute;
    top: 0;
    inset-inline: 0;
    height: 6px;
    background: linear-gradient(90deg, var(--de-black), var(--de-red), var(--de-gold));
    border-radius: 16px 16px 0 0;
    pointer-events: none
}

.de-icons-row {
    display: flex;
    gap: 10px;
    align-items: center;
    margin: 6px 0 10px;
    opacity: .95
}

.de-ico {
    width: 18px;
    height: 18px
}

.de-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #fff;
    border: 1px solid #e5e7eb;
    color: #111827;
    border-radius: 999px;
    padding: 4px 8px;
    font-weight: 700;
    font-size: 12.5px;
    width: max-content;
    margin: 4px 0
}

.icon-12 {
    width: 14px;
    height: 14px
}

/* תג “מדורג עליון” עם דגל DE קטן */
.top-badge.de-flag-badge {
    position: absolute;
    inset-inline-end: 8px;
    top: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 10px;
    background: #ffffffee;
    backdrop-filter: blur(4px);
    border-radius: 999px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, .12);
    border: 1px solid #e5e7eb;
    z-index: 2
}

.de-flag-badge .icon-14 {
    width: 14px;
    height: 14px;
    opacity: .8
}

.de-flag-badge__txt {
    font-size: .9rem;
    font-weight: 600;
    color: #111827
}

/* דגל DE קטן (ללא אנימציית נפנוף כדי לשמור על סטריליות) */
.de-flag {
    width: 24px;
    height: 16px;
    border-radius: 2px;
    box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .08);
    background:
        linear-gradient(#000 0 33%, #DD0000 33% 66%, #FFCE00 66%)
}

/* 1) אין פס מתחת לתפריט בדף הגרמנית */
.de-theme .site-header::after {
    content: none !important;
    display: none !important;
    height: 0 !important;
    background: none !important;
}

/* 2) פס מעל כרטיסי המורים – חיתוך חד של צבעי הדגל (שחור/אדום/זהב) */
.de-card .de-ribbon {
    background: linear-gradient(90deg,
            var(--de-black) 0%,
            var(--de-black) 33.333%,
            var(--de-red) 33.333%,
            var(--de-red) 66.666%,
            var(--de-gold) 66.666%,
            var(--de-gold) 100%) !important;
}