/* ═══════════════════════════════════════════════════════
   AirHost App — Installer Custom Styles
   Tailwind CDN ile birlikte kullanılır
   ═══════════════════════════════════════════════════════ */

/* ───────── Spinner Animation ───────── */
.installer-spinner {
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* ───────── Success Bounce Animation ───────── */
.animate-success-bounce {
    animation: successBounce 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes successBounce {
    0% { transform: scale(0); opacity: 0; }
    60% { transform: scale(1.15); }
    100% { transform: scale(1); opacity: 1; }
}

/* ───────── Fade In Animation ───────── */
.fade-in {
    animation: fadeIn 0.4s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ───────── Slide Up Animation ───────── */
.slide-up {
    animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ───────── Button Loading State ───────── */
.btn-loading {
    position: relative;
    pointer-events: none;
    opacity: 0.7;
}

.btn-loading::after {
    content: '';
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.4);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

/* ───────── Password Strength Indicator ───────── */
.pw-strength-weak { background-color: #EF4444 !important; }
.pw-strength-fair { background-color: #F59E0B !important; }
.pw-strength-good { background-color: #3B82F6 !important; }
.pw-strength-strong { background-color: #10B981 !important; }

/* ───────── Step Progress Indicator ───────── */
.step-circle {
    transition: all 0.3s ease;
}

.step-completed {
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1);
}

.step-active {
    box-shadow: 0 0 0 4px rgba(255, 90, 95, 0.2);
}

/* ───────── Requirement Item Rows ───────── */
.requirement-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
    border-radius: 12px;
    border: 1px solid #E5E7EB;
    transition: background-color 0.2s ease;
}

.requirement-row:hover {
    background-color: #F9FAFB;
}

.requirement-row.passed {
    border-color: #D1FAE5;
    background-color: #ECFDF5;
}

.requirement-row.failed {
    border-color: #FECDD3;
    background-color: #FFF1F2;
}

.requirement-row.warning {
    border-color: #FEF3C7;
    background-color: #FFFBEB;
}

/* ───────── Badge Styles ───────── */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 2px 10px;
    border-radius: 9999px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.badge-success {
    background-color: #D1FAE5;
    color: #065F46;
}

.badge-error {
    background-color: #FECDD3;
    color: #9F1239;
}

.badge-warning {
    background-color: #FEF3C7;
    color: #92400E;
}

/* ───────── Alert Messages ───────── */
.alert {
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 16px;
    display: flex;
    gap: 12px;
    animation: fadeIn 0.3s ease-out;
}

.alert-success {
    background-color: #ECFDF5;
    border: 1px solid #D1FAE5;
}

.alert-error {
    background-color: #FFF1F2;
    border: 1px solid #FECDD3;
}

.alert-warning {
    background-color: #FFFBEB;
    border: 1px solid #FEF3C7;
}

.alert-info {
    background-color: #EFF6FF;
    border: 1px solid #DBEAFE;
}

/* ───────── Form Input Focus Ring ───────── */
input:focus, select:focus, textarea:focus {
    border-color: transparent !important;
    box-shadow: 0 0 0 2px #FF5A5F;
    outline: none;
}

input.input-error, select.input-error {
    border-color: #FECDD3 !important;
    background-color: #FFF1F2 !important;
}

input.input-error:focus, select.input-error:focus {
    box-shadow: 0 0 0 2px #EF4444 !important;
}

input.input-success {
    border-color: #D1FAE5 !important;
    background-color: #ECFDF5 !important;
}

input.input-success:focus {
    box-shadow: 0 0 0 2px #10B981 !important;
}

/* ───────── Scrollbar Styles (for code/pre blocks) ───────── */
pre::-webkit-scrollbar {
    height: 6px;
}

pre::-webkit-scrollbar-track {
    background: #F3F4F6;
    border-radius: 3px;
}

pre::-webkit-scrollbar-thumb {
    background: #D1D5DB;
    border-radius: 3px;
}

pre::-webkit-scrollbar-thumb:hover {
    background: #9CA3AF;
}

/* ───────── Responsive Tweaks ───────── */
@media (max-width: 640px) {
    .step-circle {
        width: 28px !important;
        height: 28px !important;
    }

    .step-circle span {
        font-size: 11px;
    }

    .step-circle svg {
        width: 12px;
        height: 12px;
    }
}

/* ───────── Print Styles ───────── */
@media print {
    header, nav, footer,
    .btn-primary, button,
    #global-loading,
    .installer-spinner {
        display: none !important;
    }

    body {
        background: white !important;
    }

    .bg-white {
        box-shadow: none !important;
        border: 1px solid #ccc !important;
    }
}

/* ───────── Pulse Animation (for loading indicators) ───────── */
.pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* ───────── Progress Bar Animation ───────── */
.progress-bar-animated {
    background-image: linear-gradient(
        45deg,
        rgba(255, 255, 255, 0.15) 25%,
        transparent 25%,
        transparent 50%,
        rgba(255, 255, 255, 0.15) 50%,
        rgba(255, 255, 255, 0.15) 75%,
        transparent 75%,
        transparent
    );
    background-size: 1rem 1rem;
    animation: progressStripes 1s linear infinite;
}

@keyframes progressStripes {
    from { background-position: 1rem 0; }
    to { background-position: 0 0; }
}
