/* Container bao quanh */
.k-install-wrapper {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 15px;
    box-sizing: border-box;
}

/* Thẻ Card */
.k-install-card {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    border: 1px solid #e2e8f0;
}

/* Header */
.k-install-header {
    background-color: #475569; /* Màu xám đậm chuẩn hệ thống */
    padding: 20px;
    text-align: center;
}

.k-install-title {
    color: #ffffff;
    margin: 0;
    font-size: 18px;
    font-weight: 500;
    letter-spacing: 0.5px;
}

.k-install-subtitle {
    color: #cbd5e1;
    margin: 5px 0 0;
    font-size: 14px;
}

/* Body Form */
.k-install-body {
    padding: 30px;
}

.k-install-group {
    margin-bottom: 20px;
}

.k-install-autocomplete {
    position: relative;
}

.k-install-label {
    display: block;
    margin-bottom: 8px;
    color: #334155;
    font-weight: 600;
    font-size: 14px;
}

.k-install-label span {
    color: #ef4444; /* Dấu sao đỏ bắt buộc */
}

.k-install-input, 
.k-install-textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: 15px;
    color: #1e293b;
    transition: all 0.2s;
    box-sizing: border-box;
    background-color: #f8fafc;
}

.k-install-input:focus,
.k-install-textarea:focus {
    outline: none;
    border-color: #ff6b00; /* Màu cam chủ đạo */
    background-color: #fff;
    box-shadow: 0 0 0 3px rgba(255, 107, 0, 0.1);
}

.k-install-textarea {
    resize: vertical;
    min-height: 80px;
}

/* Thông báo lỗi */
.k-install-error {
    color: #ef4444;
    font-size: 13px;
    margin-top: 6px;
    display: none; /* Ẩn mặc định */
}

/* Nút Submit */
.k-install-btn {
    width: 100%;
    padding: 14px;
    background-color: #ff6b00;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    margin-top: 10px;
}

.k-install-btn:hover {
    background-color: #e65e00;
    transform: translateY(-1px);
}

/* Trạng thái Disabled (Khi validate chưa xong) */
.k-install-btn-disabled {
    background-color: #94a3b8 !important;
    cursor: not-allowed !important;
    opacity: 0.7;
    transform: none !important;
}

.k-install-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    margin-top: 4px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    z-index: 20;
    display: none;
    max-height: 220px;
    overflow-y: auto;
}

.k-install-suggestion-item {
    padding: 10px 12px;
    cursor: pointer;
    transition: background-color 0.15s ease;
}

.k-install-suggestion-item:hover {
    background-color: #f8fafc;
}

/* Radio buttons styling */
.k-install-type-option {
    display: flex;
    align-items: center;
    cursor: pointer;
    padding: 12px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    transition: all 0.2s;
    background-color: #ffffff;
}

.k-install-type-option:hover {
    border-color: #ff6b00;
    background-color: #fff7ed;
}

.k-install-type-option:has(input[type="radio"]:checked) {
    border-color: #ff6b00;
    background-color: #fff7ed;
}

.k-install-type-option input[type="radio"] {
    margin-right: 10px;
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #ff6b00;
}

.k-install-type-option > div {
    flex: 1;
}

.k-install-type-option > div > div:first-child {
    font-weight: 500;
    color: #1f2937;
}

.k-install-type-option > div > div:last-child {
    font-size: 13px;
    color: #6b7280;
    margin-top: 2px;
}

/* Pending Request Card - Modern & Professional */
.k-pending-request-card {
    background: linear-gradient(135deg, #fff7ed 0%, #ffedd5 100%);
    border: none;
    border-radius: 16px;
    padding: 2rem 1.5rem;
    margin: 1.5rem;
    text-align: center;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    position: relative;
    overflow: hidden;
}

.k-pending-request-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #f59e0b, #f97316, #ea580c);
}

.k-pending-request-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    line-height: 1;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.k-pending-request-title {
    color: #1f2937;
    margin: 0 0 0.75rem 0;
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.k-pending-request-description {
    color: #4b5563;
    margin: 0 0 1.5rem 0;
    font-size: 1rem;
    line-height: 1.6;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.k-pending-request-label {
    font-weight: 600;
    color: #374151;
    font-size: 0.875rem;
    margin-bottom: 0.25rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.k-pending-request-value {
    color: #111827;
    font-size: 0.9375rem;
    word-break: break-word;
    font-weight: 500;
}

/* Info Items - Clean Layout */
.k-pending-info-item {
    padding: 1rem 0;
    border-bottom: 1px solid rgba(229, 231, 235, 0.6);
}

.k-pending-info-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.k-pending-info-item:first-child {
    padding-top: 0;
}

.k-pending-info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.k-pending-info-label {
    text-align: left;
    font-weight: 600;
    color: #111827;
    font-size: 0.8125rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    min-width: 120px;
    flex-shrink: 0;
}

.k-pending-info-value {
    color: red;
    font-size: 0.9375rem;
    font-weight: 500;
    text-align: right;
    flex: 1;
    word-break: break-word;
}

.k-pending-request-note {
    color: #0055ff;
    margin: 2.5rem 0 0 0;
    font-size: 2rem;
    font-style: italic;
    padding: 1rem;
    background-color: rgba(255, 255, 255, 0.6);
    border-radius: 8px;
    border-left: 3px solid #f59e0b;
}

.k-pending-request-actions {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(229, 231, 235, 0.8);
}

/* Tablet và Desktop */
@media (min-width: 576px) {
    .k-pending-request-card {
        padding: 2.5rem 2rem;
        margin: 2rem;
    }
    
    .k-pending-request-icon {
        font-size: 5rem;
        margin-bottom: 1.5rem;
    }
    
    .k-pending-request-title {
        font-size: 1.75rem;
        margin-bottom: 1rem;
    }
    
    .k-pending-request-description {
        font-size: 1.0625rem;
        margin-bottom: 2rem;
    }
    
    .k-pending-request-label {
        font-size: 0.9375rem;
        margin-bottom: 0;
    }
    
    .k-pending-request-value {
        font-size: 1rem;
    }
    
    .k-pending-request-note {
        font-size: 0.9375rem;
        padding: 1.25rem;
    }
}

/* Checkbox Wrapper */
.k-install-checkbox-wrapper {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    cursor: pointer;
    padding: 12px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    transition: all 0.2s;
    background-color: #ffffff;
}

.k-install-checkbox-wrapper:hover {
    border-color: #ff6b00;
    background-color: #fff7ed;
}

.k-install-checkbox-wrapper input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: #ff6b00;
    flex-shrink: 0;
    margin-top: 2px;
}

.k-install-checkbox-wrapper:has(input[type="checkbox"]:checked) {
    border-color: #ff6b00;
    background-color: #fff7ed;
}

.k-install-checkbox-label {
    flex: 1;
    font-size: 14px;
    color: #1f2937;
    line-height: 1.5;
    user-select: none;
}

/* Security Delay Wrapper */
.k-install-security-delay {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    background: linear-gradient(135deg, #fff7ed 0%, #ffedd5 100%);
    border: 2px solid #f59e0b;
    border-radius: 12px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.k-install-security-icon {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

/* Loading effect cho countdown */
.k-install-countdown-loading {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.k-install-loading-dots {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    margin-left: 4px;
}

.k-install-loading-dots .dot {
    display: inline-block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background-color: #f59e0b;
    animation: dotBounce 1.4s ease-in-out infinite;
}

.k-install-loading-dots .dot:nth-child(1) {
    animation-delay: 0s;
}

.k-install-loading-dots .dot:nth-child(2) {
    animation-delay: 0.2s;
}

.k-install-loading-dots .dot:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes dotBounce {
    0%, 80%, 100% {
        transform: translateY(0);
        opacity: 0.5;
    }
    40% {
        transform: translateY(-8px);
        opacity: 1;
    }
}

.k-install-security-text {
    flex: 1;
}

.k-install-security-title {
    font-weight: 600;
    color: #1f2937;
    font-size: 15px;
    margin-bottom: 4px;
}

.k-install-security-countdown {
    font-size: 14px;
    color: #4b5563;
}

.k-install-security-countdown #countdown-timer {
    font-weight: 700;
    color: #f59e0b;
    font-size: 16px;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

/* Responsive */
@media (max-width: 480px) {
    .k-install-body {
        padding: 20px;
    }
    
    .k-pending-request-card {
        margin: 1rem;
        padding: 1.25rem;
    }
    
    .k-pending-info-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .k-pending-info-label {
        min-width: auto;
        font-size: 0.75rem;
    }
    
    .k-pending-info-value {
        text-align: left;
        font-size: 0.875rem;
        width: 100%;
    }
    
    .k-install-security-delay {
        padding: 12px;
        gap: 10px;
    }
    
    .k-install-security-icon {
        font-size: 1.5rem;
    }
    
    .k-install-security-title {
        font-size: 14px;
    }
    
    .k-install-security-countdown {
        font-size: 13px;
    }
}