/* Help » meetings with the DMS team (templates/dms_pages_new/team_meetings.html). Logical properties throughout, so
   Arabic and Hebrew mirror it; times and phone numbers stay left to right. */
.tm-page {
    max-width: 1100px;
    margin: 0 auto;
    padding: 24px 16px 48px;
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.tm-title {
    margin: 0;
    font-size: 26px;
    font-weight: 700;
    color: var(--blue_color);
}

.tm-sub {
    margin: 6px 0 0;
    color: var(--gray-color);
}

.tm-section {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.tm-h2 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: var(--blue_color);
}

.tm-h3 {
    margin: 10px 0 0;
    font-size: 14px;
    font-weight: 600;
    color: var(--gray-color);
}

.tm-empty {
    margin: 0;
    padding: 16px;
    border: 1px dashed var(--light_color);
    border-radius: 12px;
    color: var(--gray-color);
}

/* ---- The meeting types ---- */
.tm-types {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 14px;
}

.tm-type {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 18px;
    border: 1px solid var(--light_gray);
    border-radius: 14px;
    background: #fff;
}

.tm-type-name {
    margin: 0;
    font-size: 17px;
    font-weight: 600;
    color: var(--blace-color);
}

.tm-type-meta {
    margin: 0;
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--gray-color);
}

.tm-type .tm-book {
    margin-top: auto;
    min-height: 44px;
    border-radius: 10px;
    font-weight: 600;
}

/* ---- My meetings: one row each on a computer, stacked on a phone ---- */
.tm-list {
    list-style: none;
    margin: 0;
    padding: 0;
    border: 1px solid var(--light_gray);
    border-radius: 14px;
    background: #fff;
    overflow: hidden;
}

.tm-row {
    display: grid;
    grid-template-columns: minmax(170px, 1.1fr) minmax(170px, 1.2fr) minmax(150px, 1fr) auto;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
}

.tm-row + .tm-row {
    border-top: 1px solid var(--light_gray);
}

.tm-when, .tm-what, .tm-who {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.tm-day-text, .tm-kind {
    font-weight: 600;
    color: var(--blace-color);
}

.tm-time-text, .tm-how, .tm-who {
    color: var(--gray-color);
    font-size: 14px;
}

/* The time's own box, at the line's start in every language */
.tm-time-text {
    align-self: flex-start;
}

.tm-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
}

.tm-actions form {
    margin: 0;
}

.tm-badge {
    padding: 4px 10px;
    border-radius: 999px;
    background: var(--bg-color);
    color: var(--concel_color);
    font-size: 13px;
    font-weight: 600;
}

.tm-row.is-cancelled .tm-day-text,
.tm-row.is-cancelled .tm-kind {
    color: var(--concel_color);
    text-decoration: line-through;
}

@media (max-width: 767px) {
    .tm-row {
        grid-template-columns: 1fr;
        gap: 6px;
    }

    .tm-actions {
        justify-content: flex-start;
        margin-top: 4px;
    }
}

/* ---- The booking panel ---- */
.tm-step legend {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 4px;
    font-size: 15px;
}

.tm-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--aque-color);
    color: var(--blue_color);
    font-size: 13px;
}

.tm-language {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    color: var(--gray-color);
    font-size: 14px;
}

.tm-language .form-select {
    width: auto;
    min-width: 140px;
}

.tm-days {
    display: flex;
    align-items: stretch;
    gap: 4px;
}

.tm-day-list {
    flex: 1;
    min-width: 0;
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(0, 1fr);  /* one column per day the panel asked for (team_meetings.js dayCount) */
    gap: 4px;
}

.tm-arrow, .tm-day {
    border: 1px solid var(--light_gray);
    border-radius: 10px;
    background: #fff;
    color: var(--blue_color);
}

.tm-arrow {
    flex: none;
    width: 32px;
    font-size: 20px;
}

[dir="rtl"] .tm-arrow i {
    display: inline-block;
    transform: scaleX(-1);
}

.tm-arrow:disabled {
    visibility: hidden;
}

.tm-day {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
    padding: 6px 0;
    min-width: 0;
    line-height: 1.2;
}

.tm-day-w, .tm-day-m {
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 11px;
    opacity: 0.75;  /* the day's own colour, lighter: pressed and greyed-out days need nothing more */
}

.tm-day-n {
    font-size: 17px;
    font-weight: 600;
}

.tm-day[aria-pressed="true"] {
    border-color: var(--primary-color);
    background: var(--primary-color);
    color: #fff;
}

.tm-day:disabled {
    background: var(--bg-color);
    color: var(--text-color);
    border-color: var(--bg-color);
}

.tm-times {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(84px, 1fr));
    gap: 8px;
}

.tm-times:empty {
    display: none;
}

/* A free time / a way to meet: a radio drawn as a button */
.tm-time, .tm-way {
    position: relative;
    margin: 0;
    cursor: pointer;
}

.tm-time input, .tm-way input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.tm-time span {
    display: block;
    padding: 9px 0;
    border: 1px solid var(--light_gray);
    border-radius: 10px;
    text-align: center;
    font-weight: 600;
    color: var(--blue_color);
}

.tm-time input:checked + span {
    border-color: var(--primary-color);
    background: var(--primary-color);
    color: #fff;
}

.tm-time input:focus-visible + span,
.tm-way:focus-within {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

.tm-ways {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.tm-way {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 48px;
    padding: 0 14px;
    border: 1px solid var(--light_gray);
    border-radius: 10px;
    color: var(--blace-color);
}

.tm-way i {
    font-size: 18px;
    color: var(--primary-color);
}

.tm-way.is-checked {
    border-color: var(--primary-color);
    background: var(--bg_pending);
}

.tm-way[hidden] {
    display: none;
}

.tm-status:empty {
    display: none;
}

.tm-status {
    margin: 0;
    color: var(--gray-color);
    font-size: 13px;
}

.tm-error {
    margin: 0;
    color: var(--danger-color);
    font-size: 13px;
}

/* Change time: the meeting's current time at the top of the panel (team_meetings.js; /book's change page) */
.tm-now {
    margin: 0 0 12px;
    padding: 10px 12px;
    border-radius: 10px;
    background: var(--aque-color);
    color: var(--blue_color);
    font-weight: 500;
}
