/* ===================================================
   Tachograph Errors Block
   =================================================== */

.te-wrap {
    max-width: 920px;
    margin: 0 auto;
    padding: 36px 20px 40px;
    font-family: inherit;
    box-sizing: border-box;
}

/* ── Heading ──────────────────────────────────────── */

.te-heading {
    text-align: center;
    color: #111;
    font-size: 28px;
    font-weight: 700;
    margin: 0 0 28px;
    letter-spacing: .3px;
}

/* ── Search row ───────────────────────────────────── */

.te-search-row {
    position: relative;
    max-width: 520px;
    margin: 0 auto 32px;
}

.te-search-input {
    width: 100%;
    padding: 13px 16px;
    border: 2px solid #dde3ec;
    border-radius: 6px;
    font-size: 15px;
    color: #333;
    outline: none;
    transition: border-color .2s;
    background: #fff;
    box-sizing: border-box;
}

.te-search-input:focus {
    border-color: #FDD400;
}

.te-search-input.te-input-open {
    border-radius: 6px 6px 0 0;
    border-bottom-color: transparent;
}

/* ── Dropdown ─────────────────────────────────────── */

.te-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border: 2px solid #FDD400;
    border-top: none;
    border-radius: 0 0 6px 6px;
    box-shadow: 0 6px 16px rgba(0,0,0,.1);
    z-index: 200;
    max-height: 340px;
    overflow-y: auto;
}

.te-dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    cursor: pointer;
    border-bottom: 1px solid #f0f0f0;
    transition: background .15s, border-left .15s;
    border-left: 3px solid transparent;
}

.te-dropdown-item:last-child {
    border-bottom: none;
}

.te-dropdown-item:hover {
    background: #fffbe6;
    border-left-color: #FDD400;
}

.te-dd-code {
    font-weight: 700;
    font-size: 13px;
    color: #111;
    font-family: 'Courier New', monospace;
    min-width: 90px;
    flex-shrink: 0;
}

.te-dd-desc {
    flex: 1;
    font-size: 13px;
    color: #444;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.te-dd-section {
    font-size: 11px;
    font-weight: 700;
    color: #aaa;
    flex-shrink: 0;
    text-transform: uppercase;
    letter-spacing: .3px;
}

.te-dropdown-item.te-dd-active {
    background: #fffbe6;
    border-left-color: #FDD400;
}

.te-dd-message {
    padding: 12px 16px;
    font-size: 13px;
    color: #9e9e9e;
    font-style: italic;
}

.te-dd-message.te-dd-not-found {
    color: #c62828;
    font-style: normal;
    font-weight: 600;
}

/* ── Section buttons ──────────────────────────────── */

.te-buttons-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    margin-bottom: 28px;
}

.te-section-btn {
    padding: 20px 14px;
    background-image: linear-gradient(180deg, #FDD400 0%, #FDD400 100%);
    color: #111;
    border: 2px solid transparent;
    border-radius: 8px;
    font-size: 17px;
    font-weight: 700;
    cursor: pointer;
    letter-spacing: .6px;
    transition: background .2s, background-image .2s, border-color .2s, color .2s;
    text-align: center;
}

.te-section-btn:hover {
    background-image: none;
    background: #000;
    color: #fff;
    border-color: transparent;
}

.te-section-btn.te-active {
    background-image: none;
    background: #000;
    color: #fff;
    border-color: transparent;
}

/* ── Preloader ────────────────────────────────────── */

.te-loader {
    display: flex;
    justify-content: center;
    padding: 36px 0;
}

.te-spinner {
    width: 46px;
    height: 46px;
    border: 4px solid #e5e5e5;
    border-top-color: #FDD400;
    border-right-color: #FDD400;
    border-radius: 50%;
    animation: te-spin .75s linear infinite;
}

@keyframes te-spin {
    to { transform: rotate(360deg); }
}

/* ── Not found ────────────────────────────────────── */

.te-not-found {
    color: #c62828;
    font-size: 15px;
    font-weight: 600;
    text-align: center;
    padding: 16px 20px;
    border: 2px solid #ef9a9a;
    border-radius: 7px;
    background: #fff5f5;
    margin-bottom: 10px;
}

/* ── Accordion ────────────────────────────────────── */

.te-accordion {
    border: 1px solid #dde3ec;
    border-radius: 8px;
    overflow: hidden;
}

.te-accordion-section-label {
    background-image: linear-gradient(180deg, #FDD400 0%, #FDD400 100%);
    color: #111;
    padding: 13px 20px;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: .5px;
    text-transform: uppercase;
}

.te-accordion-item {
    border-bottom: 1px solid #dde3ec;
}

.te-accordion-item:last-child {
    border-bottom: none;
}

.te-accordion-header {
    display: flex;
    align-items: center;
    padding: 13px 18px;
    background: #fff;
    border-left: 4px solid transparent;
    cursor: pointer;
    transition: background .18s, color .18s, border-color .18s;
    user-select: none;
    gap: 0;
}

.te-accordion-header:hover {
    border-left-color: #FDD400;
}

.te-accordion-header.te-open {
    background: #fff;
    border-left-color: #FDD400;
}

.te-accordion-code {
    font-weight: 700;
    color: #111;
    font-size: 13px;
    min-width: 90px;
    flex-shrink: 0;
    font-family: 'Courier New', monospace;
    transition: color .18s;
}

.te-accordion-desc {
    flex: 1;
    color: #333;
    font-size: 14px;
    line-height: 1.4;
    padding: 0 12px;
    transition: color .18s;
}

.te-accordion-arrow {
    color: #888;
    font-size: 11px;
    flex-shrink: 0;
    transition: transform .22s, color .18s;
}

.te-accordion-header.te-open .te-accordion-arrow {
    transform: rotate(180deg);
}

.te-accordion-body {
    display: none;
    padding: 14px 20px 14px 110px;
    background: #fff;
    border-top: 1px solid #dde3ec;
}

.te-accordion-body ul {
    margin: 0;
    padding-left: 20px;
}

.te-accordion-body ul li {
    color: #444;
    font-size: 14px;
    line-height: 1.65;
    margin-bottom: 5px;
}

.te-accordion-body ul li:last-child {
    margin-bottom: 0;
}

.te-accordion-body .te-body-text {
    margin: 0 0 10px;
    color: #444;
    font-size: 14px;
    line-height: 1.6;
}

.te-accordion-body .te-block-label {
    margin: 10px 0 4px;
    font-weight: 700;
    font-size: 13px;
    color: #111;
    text-transform: uppercase;
    letter-spacing: .3px;
}

.te-accordion-body .te-block-label:first-child {
    margin-top: 0;
}

.te-accordion-body .te-no-fix {
    color: #9e9e9e;
    font-style: italic;
    font-size: 13px;
}

/* Search result highlight */

.te-accordion-item.te-search-found .te-accordion-body {
    background: #fff;
}

/* ── Mobile ───────────────────────────────────────── */

@media (max-width: 640px) {

    .te-heading {
        font-size: 22px;
    }

    .te-buttons-row {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .te-section-btn {
        padding: 17px 14px;
        font-size: 16px;
    }

    .te-accordion-body {
        padding-left: 20px;
    }

    .te-accordion-code {
        min-width: 70px;
        font-size: 12px;
    }

    .te-accordion-desc {
        font-size: 13px;
        padding: 0 8px;
    }
}
