/* ============================================================
   teample timepicker — 바텀 시트 방식 시간 선택 UI
   ============================================================ */

/* ── 트리거 버튼 ── */
.tp-time-wrap {
    position: relative;
    display: block;
}
.tp-time-btn {
    display: flex;
    align-items: center;
    gap: 7px;
    width: 100%;
    padding: 10px 13px;
    background: #fff;
    border: 1px solid #E5E7EB;
    border-radius: 10px;
    cursor: pointer;
    font-size: 15px;
    color: #111827;
    text-align: left;
    box-sizing: border-box;
    font-family: inherit;
    line-height: 1.4;
    transition: border-color 0.15s, box-shadow 0.15s;
    -webkit-tap-highlight-color: transparent;
}
.tp-time-btn:hover,
.tp-time-btn:focus {
    border-color: #86EFAC;
    outline: none;
}
.tp-time-btn:active {
    background: #F0FDF4;
    border-color: #16A34A;
}
.tp-time-btn-icon {
    font-size: 19px;
    color: #16A34A;
    flex-shrink: 0;
    line-height: 1;
}
.tp-time-btn-text {
    flex: 1;
    color: #111827;
    font-size: 15px;
}
.tp-time-btn-text.is-empty {
    color: #9CA3AF;
    font-size: 14px;
}
.tp-time-btn-arrow {
    font-size: 20px;
    color: #9CA3AF;
    flex-shrink: 0;
    line-height: 1;
}

/* ── 오버레이 ── */
.tp-time-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    z-index: 9998;
    opacity: 0;
    transition: opacity 0.25s ease;
    pointer-events: none;
}
.tp-time-overlay.is-open {
    opacity: 1;
    pointer-events: auto;
}

/* ── 바텀 시트 ── */
/* bottom: 60px — 하단 네비게이션(#bottom_menu) 높이만큼 위로 */
.tp-time-sheet {
    position: fixed;
    bottom: 60px;
    left: 0;
    right: 0;
    background: #fff;
    border-radius: 22px 22px 0 0;
    z-index: 9999;
    padding-bottom: 8px;
    transform: translateY(calc(100% + 60px));
    transition: transform 0.32s cubic-bezier(0.32, 0.72, 0, 1);
    max-height: 82vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 -4px 32px rgba(15, 23, 42, 0.14);
}
.tp-time-sheet.is-open {
    transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
    .tp-time-sheet,
    .tp-time-overlay { transition: none; }
}

/* 드래그 바 */
.tp-sheet-drag {
    flex-shrink: 0;
    display: flex;
    justify-content: center;
    padding: 12px 0 4px;
}
.tp-sheet-drag-bar {
    width: 40px;
    height: 4px;
    background: #D1D5DB;
    border-radius: 99px;
}

/* 시트 헤더 */
.tp-sheet-head {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 4px 20px 12px;
    border-bottom: 1px solid #EEF0F3;
}
.tp-sheet-title {
    font-size: 16px;
    font-weight: 700;
    color: #111827;
}
.tp-sheet-close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: #F3F4F6;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    color: #6B7280;
    padding: 0;
    -webkit-tap-highlight-color: transparent;
    transition: background 0.12s;
}
.tp-sheet-close:active { background: #E5E7EB; }
.tp-sheet-close .material-symbols-outlined { font-size: 18px; }

/* 시트 바디 (스크롤) */
.tp-sheet-body {
    flex: 1;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 14px 20px 20px;
    overscroll-behavior: contain;
}

/* 섹션 */
.tp-time-section + .tp-time-section {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid #EEF0F3;
}
.tp-time-section-label {
    font-size: 11px;
    font-weight: 700;
    color: #9CA3AF;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    margin-bottom: 9px;
}

/* 칩 그리드 */
.tp-time-chips {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(68px, 1fr));
    gap: 7px;
}

/* 칩 */
.tp-time-chip {
    padding: 9px 0;
    background: #F9FAFB;
    border: 1.5px solid #E5E7EB;
    border-radius: 10px;
    font-size: 14px;
    color: #374151;
    cursor: pointer;
    text-align: center;
    font-family: 'Courier New', monospace;
    line-height: 1;
    transition: background 0.12s, border-color 0.12s, color 0.12s, transform 0.08s;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}
.tp-time-chip:hover {
    border-color: #86EFAC;
    background: #F0FDF4;
    color: #15803D;
}
.tp-time-chip:active {
    transform: scale(0.94);
}
.tp-time-chip.is-selected {
    background: #16A34A;
    border-color: #16A34A;
    color: #fff;
    font-weight: 700;
}
