/**
 * Customer tracking display – frontend CSS (My Account / Thank you page).
 *
 * 1.13.179: Kompaktní moderní layout – jeden řádek místo blokové sekce
 * s několika oddělenými oblastmi. DPD červené akcenty, žádné rozdělující čáry,
 * žádný redundantní pomocný text. Vychází z UX moderních tracking widgetů
 * (Zásilkovna, Shopify, atd.).
 *
 * Hlavní třídy:
 *   .dpd-ct-box          – wrapper sekce
 *   .dpd-ct-box--single  – varianta pro 1 balík (horizontal flex)
 *   .dpd-ct-box--multi   – varianta pro vícebalíkové objednávky
 *   .dpd-ct-icon         – SVG ikona balíku (DPD červená)
 *   .dpd-ct-label        – nadpis
 *   .dpd-ct-number       – tracking číslo
 *   .dpd-ct-status-pill  – status pill
 *   .dpd-ct-btn          – CTA tlačítko
 *   .dpd-ct-list         – seznam multi-package
 *
 * Žádné !important. Žádné override WC core. Respektuje theme typografii.
 */

/* ============================================================
 *  WRAPPER
 * ============================================================ */

.dpd-ct-box {
    margin: 1.5em 0;
    padding: 16px 20px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-left: 3px solid #DC0032;   /* DPD červený akcent vlevo (subtílní) */
    border-radius: 6px;
    font-size: 14px;
    line-height: 1.5;
    color: #1a1a1a;
}

/* ============================================================
 *  SINGLE-PACKAGE LAYOUT (jeden řádek)
 * ============================================================ */

.dpd-ct-box--single {
    display: flex;
    align-items: center;
    gap: 14px;
}

.dpd-ct-icon {
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    color: #DC0032;
}

.dpd-ct-content {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.dpd-ct-label {
    font-size: 13px;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    line-height: 1.2;
}

.dpd-ct-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.dpd-ct-number {
    font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
    font-size: 14px;
    font-weight: 600;
    color: #1a1a1a;
    letter-spacing: 0.01em;
}

.dpd-ct-status-pill {
    display: inline-block;
    padding: 2px 10px;
    background: #fef2f2;
    color: #DC0032;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.4;
}

/* ============================================================
 *  CTA BUTTON
 * ============================================================ */

.dpd-ct-btn {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 18px;
    background: #DC0032;
    color: #fff;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    text-decoration: none;
    line-height: 1;
    transition: background 0.15s ease;
}

.dpd-ct-btn:hover,
.dpd-ct-btn:focus,
.dpd-ct-btn:active,
.dpd-ct-btn:visited {
    background: #a8001f;
    color: #fff;
    text-decoration: none;
}

.dpd-ct-arrow {
    display: inline-block;
    transition: transform 0.15s ease;
    font-weight: 400;
}

.dpd-ct-btn:hover .dpd-ct-arrow,
.dpd-ct-btn:focus .dpd-ct-arrow {
    transform: translateX(2px);
}

/* ============================================================
 *  MULTI-PACKAGE LAYOUT
 * ============================================================ */

.dpd-ct-box--multi {
    padding: 14px 20px 16px;
}

.dpd-ct-head {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-bottom: 12px;
    margin-bottom: 12px;
    border-bottom: 1px solid #f3f4f6;
}

.dpd-ct-head .dpd-ct-icon {
    width: 28px;
    height: 28px;
}

.dpd-ct-head-text {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.dpd-ct-sublabel {
    font-size: 12px;
    color: #9ca3af;
    line-height: 1.2;
}

.dpd-ct-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.dpd-ct-list-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 0;
}

.dpd-ct-pkg-idx {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    background: #f3f4f6;
    color: #6b7280;
    border-radius: 50%;
    font-size: 12px;
    font-weight: 700;
}

.dpd-ct-list-item .dpd-ct-number {
    flex: 1;
    min-width: 0;
}

.dpd-ct-list-link {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: #DC0032;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    transition: color 0.15s ease;
}

.dpd-ct-list-link:hover,
.dpd-ct-list-link:focus {
    color: #a8001f;
    text-decoration: underline;
}

.dpd-ct-list-link:hover .dpd-ct-arrow,
.dpd-ct-list-link:focus .dpd-ct-arrow {
    transform: translateX(2px);
}

/* ============================================================
 *  RESPONSIVE
 * ============================================================ */

@media (max-width: 600px) {
    .dpd-ct-box--single {
        flex-wrap: wrap;
    }
    .dpd-ct-content {
        flex-basis: calc(100% - 46px); /* zbytek po ikoně */
    }
    .dpd-ct-btn {
        width: 100%;
        justify-content: center;
        padding: 11px 18px;
    }
    .dpd-ct-list-item {
        flex-wrap: wrap;
    }
    .dpd-ct-list-item .dpd-ct-number {
        flex-basis: calc(100% - 36px);
    }
    .dpd-ct-list-link {
        margin-left: 36px;
    }
}

/* ============================================================
 *  1.13.197: TRACKING EVENTS TIMELINE
 *  Chronologický průběh zásilky pod hlavním tracking boxem.
 * ============================================================ */

.dpd-ct-timeline-box {
    margin: 1em 0 1.5em;
    padding: 16px 20px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
}

.dpd-ct-timeline-title {
    margin: 0 0 14px;
    font-size: 13px;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    line-height: 1.2;
}

.dpd-ct-timeline {
    list-style: none;
    margin: 0;
    padding: 0;
    position: relative;
}

.dpd-ct-timeline-item {
    position: relative;
    padding: 0 0 14px 22px;
    border-left: 2px solid #f3f4f6;
    margin-left: 5px;
}

.dpd-ct-timeline-item:last-child {
    padding-bottom: 0;
    border-left-color: transparent;
}

.dpd-ct-timeline-dot {
    position: absolute;
    left: -7px;
    top: 2px;
    width: 12px;
    height: 12px;
    background: #d1d5db;
    border: 2px solid #fff;
    border-radius: 50%;
    box-shadow: 0 0 0 1px #e5e7eb;
}

.dpd-ct-timeline-item.is-latest .dpd-ct-timeline-dot {
    background: #DC0032;
    box-shadow: 0 0 0 1px #DC0032, 0 0 0 4px rgba(220, 0, 50, 0.15);
}

.dpd-ct-timeline-item.is-latest .dpd-ct-timeline-desc {
    color: #1a1a1a;
    font-weight: 700;
}

.dpd-ct-timeline-content {
    margin-top: -2px;
    line-height: 1.5;
}

.dpd-ct-timeline-desc {
    font-size: 14px;
    color: #4b5563;
    font-weight: 500;
}

.dpd-ct-timeline-time {
    font-size: 12px;
    color: #9ca3af;
    margin-top: 2px;
}

@media (max-width: 600px) {
    .dpd-ct-timeline-box { padding: 14px 16px; }
    .dpd-ct-timeline-desc { font-size: 13px; }
}
