/* Phone input, button/table state managers — extracted from debug.php */

/* Phone input with country code prefix */
.phone-input-wrapper {
    display: flex;
    gap: 8px;
    align-items: stretch;
}

.country-code-select {
    width: 110px !important;
    min-width: 110px;
    flex-shrink: 0;
    padding: 0.75rem 0.5rem;
    font-size: 0.95rem;
    border-radius: 8px;
    background: rgba(15, 15, 15, 0.8);
    border: 2px solid rgba(64, 64, 64, 0.6);
    color: #f0f0f0;
    cursor: pointer;
    transition: all 0.3s ease;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath fill='%23888' d='M5 6L0 0h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
    background-size: 16px;
    padding-right: 28px;
}

.country-code-select:hover,
.country-code-select:focus {
    border-color: #22c55e;
    outline: none;
}

.country-code-select option {
    background: #1a1a1a;
    color: #f0f0f0;
    padding: 8px;
}

.phone-input-wrapper input[type="tel"],
.phone-input-wrapper input[type="text"] {
    flex: 1;
    min-width: 0;
}

/* Button loading state */
.btn-loading {
    opacity: 0.7 !important;
    cursor: not-allowed !important;
    pointer-events: none !important;
}

/* Modal loading spinner animation */
@keyframes modalSpinnerRotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.modal-loading-container .wechat-spinner {
    border: 3px solid #333;
    border-top: 3px solid #22c55e;
    border-radius: 50%;
    animation: modalSpinnerRotate 1s linear infinite;
}

/* Table card loading state - for TableClickManager */
.table-processing {
    position: relative;
}

.table-loading-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: inherit;
    z-index: 10;
}

.table-loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top-color: #00ff88;
    border-radius: 50%;
    animation: modalSpinnerRotate 1s linear infinite;
}
