/* Customer portal — tracking experience */

.tka-customer-hero__surface {
    position: relative;
    overflow: hidden;
    padding: 1.75rem 1.5rem;
    border-radius: 1rem;
    background:
        radial-gradient(circle at top right, rgba(var(--bs-primary-rgb), 0.14), transparent 42%),
        linear-gradient(135deg, rgba(var(--bs-primary-rgb), 0.08), rgba(var(--bs-gray-100-rgb, 245, 248, 250), 0.95));
    border: 1px solid rgba(var(--bs-primary-rgb), 0.12);
    box-shadow: 0 0.75rem 2rem rgba(15, 23, 42, 0.06);
}

.tka-customer-hero__header {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 1rem 1.25rem;
    align-items: start;
}

.tka-customer-hero__status-icon {
    width: 3.25rem;
    height: 3.25rem;
    border-radius: 1rem;
    display: grid;
    place-items: center;
    background: #fff;
    color: var(--bs-primary);
    box-shadow: inset 0 0 0 1px rgba(var(--bs-primary-rgb), 0.12);
}

.tka-customer-hero__status-icon i {
    font-size: 1.5rem;
}

.tka-customer-hero__eyebrow {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--bs-gray-600);
    margin-bottom: 0.35rem;
}

.tka-customer-hero__title {
    font-size: clamp(1.35rem, 2vw, 1.85rem);
    line-height: 1.25;
    font-weight: 700;
    color: var(--bs-gray-900);
    margin-bottom: 0.5rem;
}

.tka-customer-hero__description {
    color: var(--bs-gray-700);
    font-size: 0.95rem;
    line-height: 1.55;
    max-width: 42rem;
}

.tka-customer-hero__badge {
    align-self: start;
}

.tka-customer-hero__progress-label,
.tka-customer-hero__progress-value {
    font-size: 0.8125rem;
    font-weight: 700;
}

.tka-customer-hero__progress-value {
    font-size: 1.125rem;
    color: var(--bs-primary);
}

.tka-customer-progress-track {
    height: 0.65rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.75);
    border: 1px solid rgba(var(--bs-primary-rgb), 0.12);
    overflow: hidden;
}

.tka-customer-progress-track__fill {
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, rgba(var(--bs-primary-rgb), 0.85), var(--bs-primary));
    transition: width 0.45s ease;
}

.tka-customer-summary__panel {
    padding: 1.25rem;
    border-radius: 0.85rem;
    background: rgba(var(--bs-gray-100-rgb, 245, 248, 250), 0.65);
    border: 1px solid rgba(var(--bs-gray-300-rgb, 224, 228, 235), 0.75);
}

.tka-customer-summary__panel-title,
.tka-customer-summary__request-block-title,
.tka-customer-summary__dates-title {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--bs-gray-600);
    margin-bottom: 0.85rem;
}

.tka-customer-summary__customer-name {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--bs-gray-900);
}

.tka-customer-summary__pickup-mode {
    display: flex;
    gap: 0.85rem;
    align-items: flex-start;
    padding: 0.85rem 1rem;
    border-radius: 0.75rem;
    background: #fff;
    border: 1px solid rgba(var(--bs-primary-rgb), 0.1);
}

.tka-customer-summary__pickup-mode-icon {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.75rem;
    display: grid;
    place-items: center;
    background: rgba(var(--bs-primary-rgb), 0.08);
    color: var(--bs-primary);
    flex-shrink: 0;
}

.tka-customer-summary__pickup-mode-label {
    font-size: 0.75rem;
    color: var(--bs-gray-600);
    margin-bottom: 0.15rem;
}

.tka-customer-summary__pickup-mode-value {
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--bs-gray-900);
}

.tka-customer-summary__address,
.tka-customer-summary__pickup-hint {
    display: flex;
    gap: 0.65rem;
    align-items: flex-start;
    font-size: 0.875rem;
    line-height: 1.5;
}

.tka-customer-summary__dates-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
}

.tka-customer-date-tile {
    padding: 0.85rem 0.95rem;
    border-radius: 0.75rem;
    background: #fff;
    border: 1px solid rgba(var(--bs-gray-300-rgb, 224, 228, 235), 0.85);
}

.tka-customer-date-tile--featured {
    border-color: rgba(var(--bs-primary-rgb), 0.18);
    box-shadow: inset 0 0 0 1px rgba(var(--bs-primary-rgb), 0.05);
}

.tka-customer-date-tile--success {
    border-color: rgba(var(--bs-success-rgb), 0.25);
}

.tka-customer-date-tile--today {
    border-color: rgba(var(--bs-primary-rgb), 0.28);
}

.tka-customer-date-tile--passed {
    border-color: rgba(var(--bs-danger-rgb), 0.25);
}

.tka-customer-date-tile__head {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    margin-bottom: 0.35rem;
}

.tka-customer-date-tile__icon {
    color: var(--bs-gray-600);
}

.tka-customer-date-tile__label {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--bs-gray-600);
}

.tka-customer-date-tile__value {
    font-size: 1rem;
    font-weight: 700;
    color: var(--bs-gray-900);
}

.tka-customer-date-tile__hint,
.tka-customer-date-tile__status {
    font-size: 0.75rem;
    margin-top: 0.25rem;
}

.tka-customer-summary__problem-text {
    display: flex;
    gap: 0.85rem;
    padding: 1rem 1.05rem;
    border-radius: 0.85rem;
    background: #fff;
    border: 1px solid rgba(var(--bs-gray-300-rgb, 224, 228, 235), 0.85);
}

.tka-customer-summary__problem-icon {
    font-size: 1.35rem;
    color: var(--bs-primary);
    flex-shrink: 0;
    margin-top: 0.1rem;
}

.tka-customer-summary__problem-body {
    white-space: pre-wrap;
    line-height: 1.6;
    color: var(--bs-gray-800);
    font-size: 0.9375rem;
}

.tka-customer-summary__info-grid {
    display: grid;
    gap: 0.75rem;
}

.tka-customer-summary__info-tile {
    display: flex;
    gap: 0.75rem;
    align-items: flex-start;
    padding: 0.85rem 1rem;
    border-radius: 0.75rem;
    background: #fff;
    border: 1px solid rgba(var(--bs-gray-300-rgb, 224, 228, 235), 0.85);
}

.tka-customer-summary__info-icon {
    font-size: 1.25rem;
    color: var(--bs-gray-600);
    margin-top: 0.1rem;
}

.tka-customer-summary__info-label {
    font-size: 0.75rem;
    color: var(--bs-gray-600);
    margin-bottom: 0.15rem;
}

.tka-customer-summary__info-value {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--bs-gray-900);
}

/* Process track */
.tka-customer-stepper__percent-badge {
    min-width: 5.5rem;
    padding: 0.65rem 0.85rem;
    border-radius: 0.85rem;
    text-align: center;
    background: rgba(var(--bs-primary-rgb), 0.08);
    border: 1px solid rgba(var(--bs-primary-rgb), 0.14);
}

.tka-customer-stepper__percent-value {
    display: block;
    font-size: 1.35rem;
    font-weight: 800;
    line-height: 1;
    color: var(--bs-primary);
}

.tka-customer-stepper__percent-label {
    display: block;
    margin-top: 0.25rem;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: var(--bs-gray-600);
}

.tka-customer-process-track {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 0.35rem;
}

.tka-customer-process-track__segment {
    position: relative;
    display: grid;
    grid-template-rows: auto auto;
    justify-items: center;
    text-align: center;
    gap: 0.55rem;
    min-width: 0;
}

.tka-customer-process-track__node {
    position: relative;
    z-index: 2;
    width: 2.35rem;
    height: 2.35rem;
    border-radius: 999px;
    display: grid;
    place-items: center;
    background: #fff;
    border: 2px solid var(--bs-gray-300);
    color: var(--bs-gray-600);
    font-weight: 700;
    box-shadow: 0 0.25rem 0.75rem rgba(15, 23, 42, 0.05);
}

.tka-customer-process-track__segment.tka-customer-process-track__node--current .tka-customer-process-track__node {
    border-color: var(--bs-primary);
    background: var(--bs-primary);
    color: #fff;
    transform: scale(1.06);
}

.tka-customer-process-track__segment.tka-customer-process-track__node--completed .tka-customer-process-track__node {
    border-color: rgba(var(--bs-primary-rgb), 0.35);
    background: rgba(var(--bs-primary-rgb), 0.1);
    color: var(--bs-primary);
}

.tka-customer-process-track__connector {
    position: absolute;
    top: 1.15rem;
    height: 0.2rem;
    background: var(--bs-gray-300);
    z-index: 1;
}

.tka-customer-process-track__connector--before {
    left: 0;
    right: calc(50% + 1.2rem);
}

.tka-customer-process-track__connector--after {
    left: calc(50% + 1.2rem);
    right: 0;
}

.tka-customer-process-track__connector.is-active {
    background: linear-gradient(90deg, rgba(var(--bs-primary-rgb), 0.55), var(--bs-primary));
}

.tka-customer-process-track__label {
    font-size: 0.6875rem;
    line-height: 1.35;
    font-weight: 600;
    color: var(--bs-gray-600);
    padding: 0 0.15rem;
    word-break: break-word;
}

.tka-customer-process-track__segment.tka-customer-process-track__node--current .tka-customer-process-track__label {
    color: var(--bs-primary);
    font-weight: 700;
}

.tka-customer-process-track__segment.tka-customer-process-track__node--completed .tka-customer-process-track__label {
    color: var(--bs-gray-800);
}

.tka-customer-step-focus {
    padding: 1.25rem 1.35rem;
    border-radius: 1rem;
    background:
        linear-gradient(180deg, rgba(var(--bs-primary-rgb), 0.05), rgba(var(--bs-primary-rgb), 0.02));
    border: 1px solid rgba(var(--bs-primary-rgb), 0.14);
}

.tka-customer-step-focus__header {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.tka-customer-step-focus__icon {
    width: 3rem;
    height: 3rem;
    border-radius: 0.85rem;
    display: grid;
    place-items: center;
    background: #fff;
    color: var(--bs-primary);
    border: 1px solid rgba(var(--bs-primary-rgb), 0.12);
}

.tka-customer-step-focus__kicker {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--bs-primary);
    margin-bottom: 0.25rem;
}

.tka-customer-step-focus__title {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--bs-gray-900);
}

.tka-customer-step-focus__substeps {
    background: #fff;
    border-color: rgba(var(--bs-primary-rgb), 0.12);
}

/* Shared substeps */
.tka-journey-substeps {
    width: 100%;
    text-align: left;
    padding: 0.85rem 1rem;
    border-radius: 0.75rem;
    background: rgba(var(--bs-gray-100-rgb, 245, 248, 250), 0.85);
    border: 1px solid rgba(var(--bs-gray-300-rgb, 224, 228, 235), 0.65);
}

.tka-journey-substeps__item {
    display: flex;
    align-items: flex-start;
    gap: 0.45rem;
    font-size: 0.8125rem;
    line-height: 1.45;
    color: var(--bs-gray-700);
    padding: 0.2rem 0;
}

.tka-journey-substeps__marker {
    flex-shrink: 0;
    width: 0.5rem;
    height: 0.5rem;
    margin-top: 0.35rem;
    border-radius: 50%;
    background: var(--bs-gray-500);
}

.tka-journey-substeps__check {
    flex-shrink: 0;
    width: 0.875rem;
    font-size: 0.75rem;
    line-height: 1;
    margin-top: 0.22rem;
    color: var(--bs-primary);
}

.tka-journey-substeps__text {
    flex: 1;
    min-width: 0;
    word-break: break-word;
}

.tka-journey-substeps__item--current {
    font-weight: 600;
}

.tka-journey-substeps__item--current .tka-journey-substeps__text,
.tka-journey-substeps__item--current .tka-journey-substeps__marker {
    color: var(--bs-primary);
}

.tka-journey-substeps__item--current .tka-journey-substeps__marker {
    background: var(--bs-primary);
    box-shadow: 0 0 0 2px rgba(var(--bs-primary-rgb), 0.18);
}

.tka-journey-substeps__item--branch-label .tka-journey-substeps__text {
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: var(--bs-gray-500);
}

.tka-journey-substeps__item--branch-option {
    position: relative;
    padding-left: 0.85rem;
}

.tka-journey-substeps__item--skipped .tka-journey-substeps__text {
    color: var(--bs-gray-500);
    text-decoration: line-through;
}

.tka-journey-substeps__round-divider {
    margin: 0.45rem 0 0.25rem;
    padding: 0.35rem 0.5rem;
    border-radius: 0.375rem;
    background: rgba(var(--bs-warning-rgb), 0.08);
    border: 1px dashed rgba(var(--bs-warning-rgb), 0.35);
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: var(--bs-gray-700);
}

@media (max-width: 991.98px) {
    .tka-customer-hero__header {
        grid-template-columns: auto 1fr;
    }

    .tka-customer-hero__badge {
        grid-column: 1 / -1;
    }

    .tka-customer-process-track {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        row-gap: 1.25rem;
    }

    .tka-customer-process-track__connector {
        display: none;
    }

    .tka-customer-summary__dates-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 575.98px) {
    .tka-customer-hero__surface {
        padding: 1.25rem 1rem;
    }

    .tka-customer-process-track {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

[data-bs-theme="dark"] .tka-customer-hero__surface,
[data-bs-theme="dark"] .tka-customer-summary__panel,
[data-bs-theme="dark"] .tka-customer-summary__pickup-mode,
[data-bs-theme="dark"] .tka-customer-date-tile,
[data-bs-theme="dark"] .tka-customer-summary__problem-text,
[data-bs-theme="dark"] .tka-customer-summary__info-tile,
[data-bs-theme="dark"] .tka-customer-step-focus,
[data-bs-theme="dark"] .tka-customer-step-focus__substeps,
[data-bs-theme="dark"] .tka-customer-step-focus__icon,
[data-bs-theme="dark"] .tka-customer-hero__status-icon {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.08);
}

/* Metronic dark theme inverts gray scale: 900 = light text, 100 = dark surface. */
[data-bs-theme="dark"] .tka-customer-hero__surface .text-gray-900,
[data-bs-theme="dark"] .tka-customer-summary .text-gray-900,
[data-bs-theme="dark"] .tka-customer-stepper .text-gray-900,
[data-bs-theme="dark"] .tka-customer-timeline-card .text-gray-900,
[data-bs-theme="dark"] .tka-customer-feedback-card .text-gray-900 {
    color: var(--bs-gray-900) !important;
}

[data-bs-theme="dark"] .tka-customer-hero__eyebrow,
[data-bs-theme="dark"] .tka-customer-summary__panel-title,
[data-bs-theme="dark"] .tka-customer-summary__request-block-title,
[data-bs-theme="dark"] .tka-customer-summary__dates-title,
[data-bs-theme="dark"] .tka-customer-summary__info-label,
[data-bs-theme="dark"] .tka-customer-date-tile__label,
[data-bs-theme="dark"] .tka-customer-stepper__percent-label {
    color: var(--bs-gray-600);
}

[data-bs-theme="dark"] .tka-customer-progress-track {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.08);
}

[data-bs-theme="dark"] .tka-customer-process-track__node {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.12);
    color: var(--bs-gray-600);
    box-shadow: none;
}

[data-bs-theme="dark"] .tka-customer-process-track__connector {
    background: rgba(255, 255, 255, 0.12);
}

[data-bs-theme="dark"] .tka-customer-process-track__label {
    color: var(--bs-gray-600);
}

[data-bs-theme="dark"] .tka-customer-process-track__segment.tka-customer-process-track__node--completed .tka-customer-process-track__label {
    color: var(--bs-gray-700);
}

[data-bs-theme="dark"] .tka-customer-stepper .notice.bg-light-warning {
    background-color: rgba(var(--bs-warning-rgb), 0.12) !important;
    border-color: rgba(var(--bs-warning-rgb), 0.28) !important;
}

[data-bs-theme="dark"] .tka-customer-stepper .notice .text-gray-700 {
    color: var(--bs-gray-700) !important;
}

[data-bs-theme="dark"] .tka-customer-step-focus .tka-journey-substeps {
    background: rgba(255, 255, 255, 0.03);
    border-color: rgba(255, 255, 255, 0.08);
}

[data-bs-theme="dark"] .tka-customer-step-focus .tka-journey-substeps__item--current .tka-journey-substeps__text,
[data-bs-theme="dark"] .tka-customer-step-focus .tka-journey-substeps__item--completed .tka-journey-substeps__text {
    color: var(--bs-gray-800);
}

[data-bs-theme="dark"] .tka-customer-step-focus .tka-journey-substeps__round-divider {
    background: rgba(var(--bs-warning-rgb), 0.12);
    border-color: rgba(var(--bs-warning-rgb), 0.28);
    color: var(--bs-gray-700);
}

@media (prefers-reduced-motion: reduce) {
    .tka-customer-progress-track__fill {
        transition: none;
    }
}

/* Timeline + Feedback side-by-side on desktop */
.tka-customer-activity-split {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 1.5rem;
    align-items: start;
}

.tka-customer-activity-split__timeline,
.tka-customer-activity-split__feedback {
    min-width: 0;
}

@media (min-width: 1200px) {
    .tka-customer-activity-split {
        grid-template-columns: minmax(0, 1.4fr) minmax(18rem, 0.9fr);
        gap: 1.75rem;
    }

    .tka-customer-activity-split__feedback {
        position: sticky;
        top: calc(var(--bs-app-header-height, 70px) + 1.25rem);
        max-height: calc(100vh - var(--bs-app-header-height, 70px) - 2.5rem);
        overflow-y: auto;
        overscroll-behavior: contain;
        scrollbar-gutter: stable;
    }
}

@media (min-width: 1400px) {
    .tka-customer-activity-split {
        grid-template-columns: minmax(0, 1.55fr) minmax(20rem, 0.95fr);
        gap: 2rem;
    }
}

.tka-customer-timeline-feed .timeline-item:last-child .timeline-content {
    margin-bottom: 0 !important;
}

/* Collapsible sections (feedback thread items) */
.tka-customer-collapsible-header .btn:focus-visible {
    outline: 2px solid rgba(var(--bs-primary-rgb), 0.45);
    outline-offset: 2px;
}

.tka-customer-collapsible-header__chevron {
    transition: transform 0.2s ease;
    color: var(--bs-gray-600);
}

.tka-customer-collapsible-header .btn[aria-expanded="false"] .tka-customer-collapsible-header__chevron {
    transform: rotate(-90deg);
}

/* Timeline feed (always expanded) */
.tka-customer-timeline-details {
    border: 0;
    margin: 0;
    padding: 0;
}

.tka-customer-timeline-details__summary {
    list-style: none;
    cursor: pointer;
}

.tka-customer-timeline-details__summary::-webkit-details-marker {
    display: none;
}

.tka-customer-timeline-details__summary::after {
    content: "▾";
    float: right;
    color: var(--bs-gray-500);
    font-size: 0.85rem;
    line-height: 1.6;
}

.tka-customer-timeline-details:not([open]) .tka-customer-timeline-details__summary::after {
    content: "▸";
}

.tka-customer-timeline-details__body {
    padding-top: 0.75rem;
}

.tka-customer-timeline-note {
    background: rgba(var(--bs-gray-100-rgb, 245, 248, 250), 0.85);
    border: 1px solid rgba(var(--bs-gray-300-rgb, 224, 228, 235), 0.75);
    border-radius: 0.75rem;
    padding: 0.85rem 1rem;
    font-size: 0.875rem;
    line-height: 1.55;
    color: var(--bs-gray-800);
    white-space: pre-wrap;
}

.tka-customer-timeline-shared-file {
    background: rgba(var(--bs-gray-100-rgb, 245, 248, 250), 0.85);
    border: 1px dashed rgba(var(--bs-info-rgb, 114, 57, 234), 0.35);
    border-radius: 0.75rem;
    padding: 0.85rem 1rem;
}

.tka-customer-timeline-staff-summary {
    padding: 0.75rem 0.9rem;
    border-radius: 0.65rem;
    background: #fff;
    border: 1px dashed rgba(var(--bs-gray-300-rgb, 224, 228, 235), 0.9);
}

.tka-customer-timeline-staff-summary--hint {
    display: flex;
    gap: 0.65rem;
    align-items: flex-start;
    background: rgba(var(--bs-primary-rgb), 0.06);
    border-color: rgba(var(--bs-primary-rgb), 0.18);
}

.tka-customer-timeline-staff-summary--staff {
    border-color: rgba(var(--bs-success-rgb), 0.25);
    background: rgba(var(--bs-success-rgb), 0.04);
}

/* Feedback */
.tka-customer-feedback-staff-question {
    padding: 1.1rem 1.15rem;
    border-radius: 0.9rem;
    background: rgba(var(--bs-info-rgb), 0.06);
    border: 1px solid rgba(var(--bs-info-rgb), 0.18);
}

.tka-customer-feedback-staff-question__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.tka-customer-feedback-staff-question__title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--bs-gray-900);
    margin-bottom: 0.25rem;
}

.tka-customer-feedback-staff-question__subtitle {
    font-size: 0.8125rem;
    color: var(--bs-gray-600);
}

.tka-customer-feedback-thread {
    border: 1px solid rgba(var(--bs-gray-300-rgb, 224, 228, 235), 0.85);
    border-radius: 0.85rem;
    background: #fff;
    overflow: hidden;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.tka-customer-feedback-thread:not([open]) {
    border-color: rgba(var(--bs-primary-rgb), 0.22);
    box-shadow: inset 3px 0 0 rgba(var(--bs-primary-rgb), 0.55);
}

.tka-customer-feedback-thread__summary {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.9rem 1rem;
    cursor: pointer;
    list-style: none;
    user-select: none;
    transition: background-color 0.2s ease;
}

.tka-customer-feedback-thread__summary:hover {
    background: rgba(var(--bs-primary-rgb), 0.04);
}

.tka-customer-feedback-thread__summary:focus-visible {
    outline: 2px solid rgba(var(--bs-primary-rgb), 0.45);
    outline-offset: -2px;
}

.tka-customer-feedback-thread__summary::-webkit-details-marker {
    display: none;
}

.tka-customer-feedback-thread__summary-main {
    min-width: 0;
    flex: 1;
}

.tka-customer-feedback-thread__meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.45rem;
    flex-shrink: 0;
}

.tka-customer-feedback-thread__date {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--bs-gray-600);
    white-space: nowrap;
}

.tka-customer-feedback-thread__toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.25rem 0.55rem 0.25rem 0.65rem;
    border-radius: 999px;
    background: rgba(var(--bs-primary-rgb), 0.08);
    border: 1px solid rgba(var(--bs-primary-rgb), 0.16);
    color: var(--bs-primary);
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    line-height: 1;
}

.tka-customer-feedback-thread__summary:hover .tka-customer-feedback-thread__toggle {
    background: rgba(var(--bs-primary-rgb), 0.12);
    border-color: rgba(var(--bs-primary-rgb), 0.28);
}

.tka-customer-feedback-thread__chevron {
    font-size: 0.85rem;
    transition: transform 0.2s ease;
}

.tka-customer-feedback-thread__toggle-text--collapse {
    display: none;
}

.tka-customer-feedback-thread[open] .tka-customer-feedback-thread__toggle-text--expand {
    display: none;
}

.tka-customer-feedback-thread[open] .tka-customer-feedback-thread__toggle-text--collapse {
    display: inline;
}

.tka-customer-feedback-thread[open] .tka-customer-feedback-thread__chevron {
    transform: rotate(180deg);
}

.tka-customer-feedback-thread[open] {
    border-color: rgba(var(--bs-gray-300-rgb, 224, 228, 235), 0.85);
    box-shadow: none;
}

.tka-customer-feedback-thread__preview {
    font-size: 0.875rem;
    line-height: 1.45;
    color: var(--bs-gray-700);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.tka-customer-feedback-thread[open] .tka-customer-feedback-thread__preview {
    display: none;
}

.tka-customer-feedback-thread__body {
    padding: 0 1rem 1rem;
    border-top: 1px solid rgba(var(--bs-gray-200-rgb, 241, 241, 242), 0.95);
}

.tka-customer-feedback-bubble {
    padding: 0.85rem 1rem;
    border-radius: 0.75rem;
    border: 1px solid rgba(var(--bs-gray-300-rgb, 224, 228, 235), 0.85);
}

.tka-customer-feedback-bubble--customer {
    background: rgba(var(--bs-primary-rgb), 0.05);
    border-color: rgba(var(--bs-primary-rgb), 0.14);
}

.tka-customer-feedback-bubble--staff {
    background: rgba(var(--bs-success-rgb), 0.05);
    border-color: rgba(var(--bs-success-rgb), 0.18);
}

.tka-customer-feedback-bubble__label {
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: var(--bs-gray-600);
    margin-bottom: 0.35rem;
}

.tka-customer-feedback-bubble__text {
    font-size: 0.9375rem;
    line-height: 1.55;
    color: var(--bs-gray-800);
    white-space: pre-wrap;
}

.tka-customer-feedback-bubble__time {
    margin-top: 0.45rem;
    font-size: 0.75rem;
    color: var(--bs-gray-600);
}

.tka-customer-feedback-status {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 0.9rem;
    border-radius: 0.65rem;
    background: rgba(var(--bs-gray-100-rgb, 245, 248, 250), 0.9);
    color: var(--bs-gray-700);
    font-size: 0.8125rem;
}

.tka-customer-feedback-status--success {
    background: rgba(var(--bs-success-rgb), 0.08);
    color: var(--bs-success);
}

.tka-customer-feedback-compose {
    padding: 1.15rem 1.2rem;
    border-radius: 0.9rem;
    background: rgba(var(--bs-gray-100-rgb, 245, 248, 250), 0.65);
    border: 1px solid rgba(var(--bs-gray-300-rgb, 224, 228, 235), 0.85);
}

.tka-customer-feedback-compose__title {
    font-size: 0.8125rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: var(--bs-gray-600);
    margin-bottom: 0.85rem;
}

.tka-customer-feedback-compose__hint {
    margin-top: 0.5rem;
    color: var(--bs-gray-600);
    line-height: 1.45;
}

.tka-customer-feedback-compose__textarea {
    min-height: 6.5rem;
}

.tka-customer-feedback-loading {
    position: absolute;
    inset: 0;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: inherit;
    background: rgba(255, 255, 255, 0.82);
    backdrop-filter: blur(2px);
}

.tka-customer-feedback-loading__panel {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.85rem 1.1rem;
    border-radius: 0.75rem;
    background: #fff;
    border: 1px solid rgba(var(--bs-primary-rgb), 0.18);
    box-shadow: 0 0.5rem 1.25rem rgba(15, 23, 42, 0.08);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--bs-gray-800);
}

.tka-journey-moderation-actions .btn-icon {
    width: 1.85rem;
    height: 1.85rem;
}

.tka-staff-avatar-label {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    min-width: 0;
}

.tka-staff-avatar-label__image,
.tka-staff-avatar-label__fallback {
    width: 2rem;
    height: 2rem;
    border-radius: 999px;
    flex-shrink: 0;
}

.tka-staff-avatar-label__image {
    object-fit: cover;
    border: 1px solid rgba(var(--bs-primary-rgb), 0.16);
    box-shadow: 0 0.15rem 0.45rem rgba(15, 23, 42, 0.08);
}

.tka-staff-avatar-label__fallback {
    display: grid;
    place-items: center;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: var(--bs-primary);
    background: rgba(var(--bs-primary-rgb), 0.1);
    border: 1px solid rgba(var(--bs-primary-rgb), 0.14);
}

.tka-staff-avatar-label__name {
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--bs-gray-800);
    line-height: 1.3;
}

.tka-customer-feedback-bubble__label .tka-staff-avatar-label,
.tka-customer-timeline-staff-summary .tka-staff-avatar-label {
    margin-bottom: 0.15rem;
}

.tka-employee-profile-photo-preview {
    object-fit: cover;
    border-radius: 0.85rem;
    border: 1px solid rgba(var(--bs-gray-300-rgb, 224, 228, 235), 0.9);
    box-shadow: 0 0.35rem 1rem rgba(15, 23, 42, 0.08);
}

[data-bs-theme="dark"] .tka-customer-feedback-loading {
    background: rgba(15, 23, 42, 0.72);
}

[data-bs-theme="dark"] .tka-customer-feedback-loading__panel {
    background: rgba(30, 41, 59, 0.95);
    border-color: rgba(255, 255, 255, 0.12);
    color: var(--bs-gray-200);
}

[data-bs-theme="dark"] .tka-customer-timeline-feed .timeline-line {
    border-color: rgba(255, 255, 255, 0.12);
}

[data-bs-theme="dark"] .tka-customer-timeline-feed .symbol-label.bg-light-danger {
    background-color: rgba(var(--bs-danger-rgb), 0.18) !important;
    color: var(--bs-danger);
}

[data-bs-theme="dark"] .tka-customer-timeline-feed .symbol-label.bg-light-secondary {
    background-color: rgba(var(--bs-gray-500-rgb), 0.22) !important;
    color: var(--bs-gray-700);
}

[data-bs-theme="dark"] .tka-customer-timeline-card .bg-light {
    background: rgba(255, 255, 255, 0.04) !important;
}

[data-bs-theme="dark"] .tka-customer-timeline-note {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.1);
}

[data-bs-theme="dark"] .tka-customer-timeline-staff-summary {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.1);
}

[data-bs-theme="dark"] .tka-customer-timeline-staff-summary--hint {
    background: rgba(var(--bs-primary-rgb), 0.12);
    border-color: rgba(var(--bs-primary-rgb), 0.25);
}

[data-bs-theme="dark"] .tka-customer-timeline-staff-summary--staff {
    background: rgba(var(--bs-success-rgb), 0.1);
    border-color: rgba(var(--bs-success-rgb), 0.22);
}

[data-bs-theme="dark"] .tka-customer-timeline-staff-summary .text-gray-700,
[data-bs-theme="dark"] .tka-customer-timeline-staff-summary .text-gray-800 {
    color: var(--bs-gray-800) !important;
}

[data-bs-theme="dark"] .tka-customer-timeline-feed .badge-light-secondary,
[data-bs-theme="dark"] .tka-customer-feedback-card .badge-light-secondary {
    background-color: rgba(var(--bs-gray-500-rgb), 0.22);
    color: var(--bs-gray-700);
}

[data-bs-theme="dark"] .tka-customer-timeline-feed .badge-light-success,
[data-bs-theme="dark"] .tka-customer-feedback-card .badge-light-success {
    background-color: rgba(var(--bs-success-rgb), 0.18);
    color: var(--bs-success);
}

[data-bs-theme="dark"] .tka-customer-timeline-feed .badge-light-info,
[data-bs-theme="dark"] .tka-customer-feedback-card .badge-light-info {
    background-color: rgba(var(--bs-info-rgb), 0.18);
    color: var(--bs-info);
}

[data-bs-theme="dark"] .tka-customer-timeline-feed .badge-light-warning,
[data-bs-theme="dark"] .tka-customer-feedback-card .badge-light-warning {
    background-color: rgba(var(--bs-warning-rgb), 0.18);
    color: var(--bs-warning);
}

[data-bs-theme="dark"] .tka-customer-timeline-feed .badge-light-danger,
[data-bs-theme="dark"] .tka-customer-feedback-card .badge-light-danger {
    background-color: rgba(var(--bs-danger-rgb), 0.18);
    color: var(--bs-danger);
}

[data-bs-theme="dark"] .tka-customer-timeline-feed .badge-light-primary,
[data-bs-theme="dark"] .tka-customer-feedback-card .badge-light-primary {
    background-color: rgba(var(--bs-primary-rgb), 0.18);
    color: var(--bs-primary);
}

[data-bs-theme="dark"] .tka-customer-timeline-feed .symbol-label.bg-light-info {
    background-color: rgba(var(--bs-info-rgb), 0.18) !important;
    color: var(--bs-info);
}

[data-bs-theme="dark"] .tka-customer-timeline-feed .symbol-label.bg-light-success {
    background-color: rgba(var(--bs-success-rgb), 0.18) !important;
    color: var(--bs-success);
}

[data-bs-theme="dark"] .tka-customer-timeline-feed .symbol-label.bg-light-primary {
    background-color: rgba(var(--bs-primary-rgb), 0.18) !important;
    color: var(--bs-primary);
}

[data-bs-theme="dark"] .tka-customer-timeline-feed .symbol-label.bg-light-warning {
    background-color: rgba(var(--bs-warning-rgb), 0.18) !important;
    color: var(--bs-warning);
}

[data-bs-theme="dark"] .tka-customer-feedback-staff-question {
    background: rgba(var(--bs-info-rgb), 0.1);
    border-color: rgba(var(--bs-info-rgb), 0.22);
}

[data-bs-theme="dark"] .tka-customer-feedback-staff-question__title {
    color: var(--bs-gray-900);
}

[data-bs-theme="dark"] .tka-customer-feedback-staff-question__subtitle {
    color: var(--bs-gray-600);
}

[data-bs-theme="dark"] .tka-customer-feedback-thread {
    background: rgba(255, 255, 255, 0.03);
    border-color: rgba(255, 255, 255, 0.1);
}

[data-bs-theme="dark"] .tka-customer-feedback-thread:not([open]) {
    border-color: rgba(var(--bs-primary-rgb), 0.28);
    box-shadow: inset 3px 0 0 rgba(var(--bs-primary-rgb), 0.45);
}

[data-bs-theme="dark"] .tka-customer-feedback-thread[open] {
    border-color: rgba(255, 255, 255, 0.12);
    box-shadow: none;
}

[data-bs-theme="dark"] .tka-customer-feedback-thread__body {
    border-top-color: rgba(255, 255, 255, 0.08);
}

[data-bs-theme="dark"] .tka-customer-feedback-thread__summary:hover {
    background: rgba(var(--bs-primary-rgb), 0.08);
}

[data-bs-theme="dark"] .tka-customer-feedback-thread__date {
    color: var(--bs-gray-500);
}

[data-bs-theme="dark"] .tka-customer-feedback-thread__toggle {
    background: rgba(var(--bs-primary-rgb), 0.14);
    border-color: rgba(var(--bs-primary-rgb), 0.28);
    color: var(--bs-primary);
}

[data-bs-theme="dark"] .tka-customer-feedback-thread__preview {
    color: var(--bs-gray-700);
}

[data-bs-theme="dark"] .tka-customer-feedback-bubble {
    border-color: rgba(255, 255, 255, 0.1);
}

[data-bs-theme="dark"] .tka-customer-feedback-bubble--customer {
    background: rgba(var(--bs-primary-rgb), 0.12);
    border-color: rgba(var(--bs-primary-rgb), 0.22);
}

[data-bs-theme="dark"] .tka-customer-feedback-bubble--staff {
    background: rgba(var(--bs-success-rgb), 0.12);
    border-color: rgba(var(--bs-success-rgb), 0.22);
}

[data-bs-theme="dark"] .tka-customer-feedback-bubble__label {
    color: var(--bs-gray-600);
}

[data-bs-theme="dark"] .tka-customer-feedback-bubble__time {
    color: var(--bs-gray-600);
}

[data-bs-theme="dark"] .tka-customer-feedback-status {
    background: rgba(255, 255, 255, 0.06);
    color: var(--bs-gray-600);
}

[data-bs-theme="dark"] .tka-customer-feedback-status--success {
    background: rgba(var(--bs-success-rgb), 0.14);
    color: var(--bs-success);
}

[data-bs-theme="dark"] .tka-customer-feedback-compose {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.1);
}

[data-bs-theme="dark"] .tka-customer-feedback-compose__title,
[data-bs-theme="dark"] .tka-customer-feedback-compose__hint {
    color: var(--bs-gray-600);
}

[data-bs-theme="dark"] .tka-customer-feedback-compose .form-control-solid::placeholder {
    color: var(--bs-gray-600);
    opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
    .tka-customer-feedback-thread__chevron,
    .tka-customer-feedback-thread,
    .tka-customer-feedback-thread__summary {
        transition: none;
    }
}

@media (max-width: 575.98px) {
    .tka-customer-feedback-thread__summary {
        flex-direction: column;
    }

    .tka-customer-feedback-thread__meta {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        width: 100%;
    }
}
