/* ════════════════════════════════════════════════════════════════
   tarif_ui.css — Tarif in der Oberfläche (zu js/components/tarif_ui.js)
   ────────────────────────────────────────────────────────────────
   Flach und in den Farben der App: kein Farbverlauf, kein Glanz.
   Ein dunkles Lavendel (#4f4a8c) markiert alles, was mit dem Tarif zu
   tun hat — dasselbe wie die Schilder im Export-Fenster und das
   Upgrade-Fenster (role_gate.js).
   ════════════════════════════════════════════════════════════════ */

/* ── Schild „Pro · Testphase" im Kopf (header.php) ─────────────── */
.tarif-marke {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    height: 30px;
    padding: 0 12px 0 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(29, 29, 31, 0.08);
    color: #1d1d1f;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: -0.1px;
    text-decoration: none;
    white-space: nowrap;
    transition: background 0.15s;
}
.tarif-marke:hover { background: rgba(255, 255, 255, 0.92); }
.tarif-marke-punkt {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #4f4a8c;
    flex-shrink: 0;
}
.tarif-marke-rest { font-weight: 500; color: rgba(29, 29, 31, 0.62); }
.tarif-marke.is-knapp .tarif-marke-punkt { background: #c2410c; }
[data-theme="dark"] .tarif-marke {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.12);
    color: #e8eaf0;
}
[data-theme="dark"] .tarif-marke-rest { color: rgba(232, 234, 240, 0.6); }
[data-theme="dark"] .tarif-marke-punkt { background: #b8b0f4; }
/* Der Kopf ist in der Planungsansicht voll (Plan-Auswahl, Ansicht-Tabs,
   KI, Teilen). Deshalb steht das Schild dort erst ab 1440 px Breite
   („Pro · 14 Tage", ab 1560 px mit „Testphase, noch"). Darunter zeigt
   die Übersicht denselben Hinweis unter dem Namen (.tarif-seitenchip). */
.tarif-marke-rest-lang { display: none; }
@media (max-width: 1439px) {
    .tarif-marke { display: none; }
}
@media (min-width: 1560px) {
    .tarif-marke-rest-lang { display: inline; }
}

/* Hinweis in der Übersicht (dashboard_view.php), unter dem Namen */
.tarif-seitenchip {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-top: 8px;
    padding: 5px 10px 5px 8px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(29, 29, 31, 0.08);
    color: #1d1d1f;
    font-size: 11.5px;
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;
}
.tarif-seitenchip:hover { background: rgba(255, 255, 255, 0.85); }
[data-theme="dark"] .tarif-seitenchip { background: rgba(255, 255, 255, 0.08); border-color: rgba(255, 255, 255, 0.12); color: #e8eaf0; }

/* ── Schreibschutz-Hinweis über dem Diagramm ───────────────────── */
.tarif-hinweis {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0 0 12px;
    padding: 11px 14px;
    border-radius: 14px;
    background: #f1f0f9;
    border: 1px solid rgba(79, 74, 140, 0.18);
    color: #1d1d1f;
    font-size: 13.5px;
    line-height: 1.45;
}
.tarif-hinweis > svg {
    width: 20px; height: 20px; flex-shrink: 0;
    fill: none; stroke: #4f4a8c; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
}
.tarif-hinweis-text { flex: 1; min-width: 0; color: rgba(29, 29, 31, 0.78); }
.tarif-hinweis-text strong { color: #1d1d1f; }
.tarif-hinweis-knopf {
    flex-shrink: 0;
    padding: 7px 12px;
    border-radius: 10px;
    background: #1d1d1f;
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
}
.tarif-hinweis-knopf:hover { background: #33333a; }
[data-theme="dark"] .tarif-hinweis { background: rgba(184, 176, 244, 0.1); border-color: rgba(184, 176, 244, 0.22); color: #e8eaf0; }
[data-theme="dark"] .tarif-hinweis-text { color: rgba(232, 234, 240, 0.78); }
[data-theme="dark"] .tarif-hinweis-text strong { color: #fff; }
[data-theme="dark"] .tarif-hinweis > svg { stroke: #b8b0f4; }
@media (max-width: 600px) {
    .tarif-hinweis { flex-wrap: wrap; }
    .tarif-hinweis-knopf { margin-left: 32px; }
}

/* ── Kosten ohne Kostenrecht (Gast, Kostenlos) ─────────────────── */
.tarif-sperre-zeile { display: none; }
body.tarif-ohne-kosten .te-field-kosten .te-costwrap,
body.tarif-ohne-kosten .tip-row-cost,
body.tarif-ohne-kosten .gmv-detail-cost { display: none !important; }
body.tarif-ohne-kosten .te-field-kosten .tarif-sperre-zeile {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 10px 12px;
    border: 1px dashed rgba(79, 74, 140, 0.35);
    border-radius: 10px;
    background: transparent;
    color: #4f4a8c;
    font: inherit;
    font-size: 13px;
    font-weight: 600;
    text-align: left;
    cursor: pointer;
}
body.tarif-ohne-kosten .te-field-kosten .tarif-sperre-zeile:hover { background: rgba(79, 74, 140, 0.06); }
.tarif-sperre-zeile svg {
    width: 15px; height: 15px; flex-shrink: 0;
    fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round;
}
/* Kosten-Knöpfe und -Chip zeigen ein kleines Schloss */
body.tarif-ohne-kosten #gantt-cost-overview-btn,
body.tarif-ohne-kosten #gmv-cost-btn,
body.tarif-ohne-kosten .qc-chip[data-opt="cost"] { position: relative; }
body.tarif-ohne-kosten #gantt-cost-overview-btn::after,
body.tarif-ohne-kosten #gmv-cost-btn::after,
body.tarif-ohne-kosten .qc-chip[data-opt="cost"]::after {
    content: '';
    position: absolute;
    top: -4px;
    right: -4px;
    width: 15px;
    height: 15px;
    border-radius: 50%;
    background: #4f4a8c url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2.6' stroke-linecap='round'%3E%3Cpath d='M7 11V8a5 5 0 0 1 10 0v3'/%3E%3Crect x='5' y='11' width='14' height='10' rx='2'/%3E%3C/svg%3E") center / 9px no-repeat;
    box-shadow: 0 0 0 2px #fff;
}
