/* Style halaman time-conditions; urutan selector dipertahankan untuk menjaga cascade. */
.tc-page {
    color: #302823;
}

.tc-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 28px;
    margin-bottom: 18px;
    border: 1px solid #efd6a0;
    border-radius: 12px;
    background: linear-gradient(105deg, #fff3d8 0%, #fff8eb 62%, #fffdf8 100%);
}

.tc-eyebrow {
    margin: 0 0 7px;
    color: #966516;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 2px;
}

.tc-heading h1 {
    margin: 0;
    font-size: 30px;
    line-height: 1.2;
    font-weight: 650;
    letter-spacing: -0.8px;
}

.tc-heading h1 + p {
    margin: 9px 0 0;
    color: #766554;
    font-size: 12px;
}

.tc-heading-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.tc-page button {
    cursor: pointer;
    font: inherit;
}

.tc-page .tc-primary,
.tc-page .tc-secondary,
.tc-page .tc-ghost {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 40px;
    padding: 9px 16px;
    border-radius: 7px;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}

.tc-page .tc-primary {
    border: 1px solid #d98b19;
    background: #ffbd32;
    color: #291c0b;
    box-shadow: 0 3px 8px #8b5a1517;
}

.tc-page .tc-primary:hover {
    background: #ffca57;
}

.tc-page .tc-secondary {
    border: 1px solid #e4c27d;
    background: #fff8e8;
    color: #845711;
}

.tc-page .tc-secondary:hover {
    background: #fff0d1;
}

.tc-page .tc-ghost {
    border: 1px solid #e2dbd2;
    background: #fff;
    color: #635950;
}

.tc-page button:disabled {
    opacity: 0.5;
    cursor: wait;
}

.tc-page button:focus-visible {
    outline: 3px solid #ffbd3266;
    outline-offset: 2px;
}

.tc-notice {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    margin: 0 0 10px;
    padding: 12px 14px;
    border: 1px solid #ecdfca;
    border-radius: 8px;
    background: #fff9ed;
    color: #88714e;
    font-size: 11px;
    line-height: 1.6;
}

.tc-notice > i {
    color: #ad7a29;
    margin-top: 2px;
}

.tc-page [data-message]:empty,
.tc-page [data-error]:empty {
    display: none;
}

.tc-page [data-message][hidden] {
    display: none;
}

.tc-message {
    position: relative;
    padding-right: 42px;
}

.tc-message > span {
    min-width: 0;
    overflow-wrap: anywhere;
}

.tc-message[data-type="success"] {
    border-color: #bfddc6;
    background: #edf8ef;
    color: #397247;
}

.tc-message[data-type="warning"] {
    border-color: #f0cd91;
    background: #fff5df;
    color: #9a6818;
}

.tc-message[data-type="error"] {
    border-color: #e6b7b1;
    background: #fff2f0;
    color: #97443b;
}

.tc-message[data-type="info"] {
    border-color: #cbdced;
    background: #edf5fc;
    color: #4777a8;
}

.tc-message > i {
    color: inherit;
}

.tc-page .tc-message-close {
    position: absolute;
    top: 8px;
    right: 8px;
    display: grid;
    place-items: center;
    width: 26px;
    height: 26px;
    padding: 0;
    border: 0;
    border-radius: 5px;
    background: transparent;
    color: inherit;
    font-size: 12px;
}

.tc-page .tc-message-close:hover {
    background: #0000000a;
}

.tc-table {
    overflow-x: auto;
    border: 1px solid #e5ded5;
    border-radius: 11px;
    background: #fffefa;
}

.tc-table table {
    width: 100%;
    border-collapse: collapse;
    font-size: 11px;
}

.tc-table th {
    padding: 12px 16px;
    background: #faf7f2;
    color: #877b70;
    text-align: left;
    font-size: 9px;
    font-weight: 650;
    letter-spacing: 0.45px;
    text-transform: uppercase;
    white-space: nowrap;
}

.tc-table td {
    padding: 15px 16px;
    border-top: 1px solid #f0ebe4;
    color: #62584f;
    vertical-align: middle;
}

.tc-table tbody tr:hover {
    background: #fffcf7;
}

.tc-number {
    color: #433a33;
    font-weight: 600;
}

.tc-members-summary {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.tc-member-more {
    align-self: center;
    padding: 3px 5px;
    color: #895c17;
    font-size: 12px;
}

.tc-member-tag {
    padding: 3px 7px;
    border: 1px solid #ecdfca;
    border-radius: 5px;
    background: #fff9ed;
    color: #895c17;
    font-size: 10px;
}

.tc-table th:last-child {
    width: 90px;
    text-align: center;
}

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

.tc-row-actions button,
.tc-icon-button {
    display: grid;
    place-items: center;
    width: 30px;
    height: 30px;
    padding: 0;
    border: 1px solid #e6dfd6;
    border-radius: 7px;
    background: #fff;
    color: #786c61;
}

.tc-row-actions button:hover,
.tc-icon-button:hover {
    border-color: #e4c27d;
    background: #fff3dc;
    color: #83570f;
}

.tc-row-actions [data-delete]:hover {
    border-color: #e6b7b1;
    background: #fff2f0;
    color: #a33f35;
}

.tc-table .tc-empty {
    padding: 48px 24px;
    text-align: center;
    color: #8b8178;
}

.tc-empty > i {
    display: block;
    margin-bottom: 12px;
    color: #ad7a29;
    font-size: 26px;
}

.tc-empty > strong {
    display: block;
    margin-bottom: 6px;
    color: #51463c;
    font-size: 13px;
}

.tc-empty > span {
    display: block;
    font-size: 11px;
}

.tc-dialog {
    box-sizing: border-box;
    width: min(620px, calc(100% - 32px));
    max-height: 88vh;
    padding: 0;
    overflow: auto;
    border: 0;
    border-radius: 12px;
    background: #fffefa;
    box-shadow: 0 24px 70px #20160f42;
    color: #342b25;
}

.tc-dialog::backdrop {
    background: #1d1714a3;
    backdrop-filter: blur(2px);
}

.tc-dialog-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 21px 24px;
    border-bottom: 1px solid #ece5dc;
}

.tc-dialog h2 {
    margin: 0;
    font-size: 18px;
    font-weight: 650;
}

.tc-dialog form > label {
    display: grid;
    gap: 7px;
    margin: 18px 24px;
    color: #62574d;
    font-size: 11px;
    font-weight: 600;
}

.tc-dialog input:not([type="checkbox"]),
.tc-dialog select {
    box-sizing: border-box;
    width: 100%;
    min-height: 42px;
    padding: 9px 11px;
    border: 1px solid #dcd4ca;
    border-radius: 7px;
    background: #fff;
    color: #3e352f;
    font: inherit;
    font-weight: 400;
}

.tc-dialog input:focus,
.tc-dialog select:focus {
    border-color: #cf9b42;
    outline: 3px solid #ffbd3224;
}

.tc-dialog input[readonly] {
    background: #faf7f2;
    color: #887d73;
}

.tc-dialog [aria-invalid="true"] {
    border-color: #b34438;
}

.tc-dialog small {
    color: #968b81;
    font-size: 9px;
    line-height: 1.6;
    font-weight: 400;
}

.tc-dialog fieldset {
    min-width: 0;
    margin: 20px 24px;
    padding: 12px;
    border: 1px solid #e5ded5;
    border-radius: 8px;
}

.tc-dialog legend {
    padding: 0 5px;
    color: #62574d;
    font-size: 11px;
    font-weight: 600;
}

.tc-dialog [data-members] {
    display: grid;
    gap: 4px;
    max-height: 220px;
    overflow-y: auto;
}

.tc-dialog [data-members] label {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 8px;
    border-radius: 5px;
    color: #62584f;
    font-size: 11px;
    cursor: pointer;
}

.tc-dialog [data-members] label:hover {
    background: #fff3dc;
}

.tc-dialog input[type="checkbox"] {
    flex: 0 0 auto;
    width: 15px;
    height: 15px;
    margin: 0;
    accent-color: #b9801c;
}

.tc-dialog [data-members] p {
    margin: 5px;
    color: #968b81;
    font-size: 11px;
}

.tc-dialog [data-error] {
    margin: 0 24px 18px;
    padding: 10px 12px;
    border: 1px solid #e6b7b1;
    border-radius: 6px;
    background: #fff2f0;
    color: #97443b;
    font-size: 11px;
    line-height: 1.6;
}

.tc-dialog form > footer {
    display: flex;
    justify-content: flex-end;
    gap: 9px;
    padding: 16px 24px;
    border-top: 1px solid #ece5dc;
    background: #fcf9f5;
}

@media (max-width: 680px) {
    .tc-heading {
        align-items: flex-start;
        flex-direction: column;
        gap: 18px;
        padding: 22px;
    }

    .tc-heading-actions {
        width: 100%;
        flex-wrap: wrap;
    }

    .tc-heading-actions button {
        flex: 1;
    }

    .tc-table table {
        min-width: 620px;
    }

    .tc-dialog-heading,
    .tc-dialog form > footer {
        padding: 18px 20px;
    }

    .tc-dialog form > label,
    .tc-dialog fieldset {
        margin-inline: 20px;
    }

    .tc-dialog [data-error] {
        margin-inline: 20px;
    }
}

.tc-dialog {
    width: min(760px, calc(100% - 32px));
}

.tc-dialog [hidden] {
    display: none !important;
}

.tc-filter-feedback {
    margin: 0 24px 18px;
    color: #88714e;
    font-size: 11px;
    line-height: 1.6;
}

.tc-filter-feedback:empty {
    display: none;
}

.tc-dialog fieldset > label {
    display: grid;
    gap: 7px;
    margin-bottom: 12px;
    font-size: 11px;
    color: #62574d;
}

.tc-dialog fieldset > small {
    display: block;
    margin-top: 10px;
}

.tc-schedule {
    margin-bottom: 12px;
    padding: 12px;
    border: 1px solid #ecdfca;
    border-radius: 7px;
    background: #fff9ed;
}

.tc-days {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 12px;
}

.tc-days label {
    display: flex;
    align-items: center;
    gap: 5px;
    color: #62574d;
    font-size: 11px;
}

.tc-time-range {
    display: flex;
    align-items: flex-end;
    gap: 12px;
}

.tc-time-range label {
    display: grid;
    gap: 6px;
    flex: 1;
    min-width: 0;
    font-size: 11px;
    color: #62574d;
}

.tc-time-range button {
    margin-bottom: 6px;
}

.tc-table td {
    line-height: 1.8;
    overflow-wrap: anywhere;
}

.tc-preview-help {
    margin: 16px 24px;
    color: #62574d;
    font-size: 12px;
    line-height: 1.6;
}

.tc-preview-code {
    margin: 0 24px 20px;
    padding: 16px;
    max-height: 55vh;
    overflow: auto;
    border: 1px solid #ece5dc;
    border-radius: 8px;
    background: #fcf9f5;
    font-size: 12px;
    line-height: 1.7;
}

.tc-preview-actions {
    display: flex;
    justify-content: flex-end;
    gap: 9px;
    padding: 16px 24px;
    border-top: 1px solid #ece5dc;
}

/* Petunjuk assignment dan perbedaan timezone master dengan dialplan tersimpan. */
.tc-form-notice {
    margin: 0 24px 18px;
    padding: 12px 14px;
    border: 1px solid #ead5a9;
    border-radius: 7px;
    background: #fff8e8;
    color: #766554;
    font-size: 12px;
    line-height: 1.6;
}

.tc-dialog input[readonly] {
    background: #f5f2ee;
}
