/**
 * AprovaCV - Custom Styles
 * Complementary styles for Tailwind CSS
 */

/* =====================
   Smooth Scroll
   ===================== */
html {
    scroll-behavior: smooth;
}

/* =====================
   Custom Animations
   ===================== */
@keyframes fade-in {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fade-in-up {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse-glow {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.4);
    }
    50% {
        box-shadow: 0 0 20px 10px rgba(59, 130, 246, 0);
    }
}

@keyframes score-fill {
    from {
        stroke-dashoffset: 352;
    }
}

.animate-fade-in {
    animation: fade-in 0.3s ease-out;
}

.animate-fade-in-up {
    animation: fade-in-up 0.5s ease-out;
}

/* =====================
   Score Circle Animation
   ===================== */
#score-circle {
    transition: stroke-dashoffset 1s ease-out, stroke 0.3s ease;
}

/* =====================
   Drop Zone Styles
   ===================== */
#drop-zone {
    transition: all 0.2s ease;
}

#drop-zone.dragging {
    border-color: #3b82f6;
    background-color: rgba(59, 130, 246, 0.1);
}

/* =====================
   Button Hover Effects
   ===================== */
.btn-primary {
    position: relative;
    overflow: hidden;
}

.btn-primary::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.btn-primary:hover::after {
    width: 300px;
    height: 300px;
}

/* =====================
   Card Hover Effects
   ===================== */
.card-hover {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card-hover:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

/* =====================
   Loading Spinner
   ===================== */
.spinner {
    animation: spin 1s linear infinite;
}

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

/* =====================
   Toast Notifications
   ===================== */
.toast-enter {
    animation: slide-in-right 0.3s ease-out;
}

.toast-exit {
    animation: slide-out-right 0.3s ease-in;
}

@keyframes slide-in-right {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slide-out-right {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* =====================
   Results Section
   ===================== */
#results {
    animation: fade-in-up 0.5s ease-out;
}

/* =====================
   Gradient Text
   ===================== */
.gradient-text {
    background: linear-gradient(135deg, #60a5fa 0%, #3b82f6 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* =====================
   Scrollbar Styling
   ===================== */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #1e293b;
}

::-webkit-scrollbar-thumb {
    background: #475569;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #64748b;
}

/* =====================
   Form Inputs
   ===================== */
select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%239ca3af'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1.5rem;
    padding-right: 3rem;
}

select:focus {
    outline: none;
}

/* =====================
   File Preview
   ===================== */
#file-preview {
    animation: fade-in 0.3s ease-out;
}

/* =====================
   Progress Bar
   ===================== */
.progress-bar {
    height: 4px;
    background: #334155;
    border-radius: 2px;
    overflow: hidden;
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #3b82f6, #60a5fa);
    transition: width 0.3s ease;
}

/* =====================
   Responsive Adjustments
   ===================== */
@media (max-width: 640px) {
    .hero-headline {
        font-size: 2rem;
        line-height: 1.2;
    }

    #drop-zone {
        padding: 2rem;
    }

    .score-card {
        padding: 1.5rem;
    }
}

/* =====================
   Navbar Blur Effect
   ===================== */
nav {
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

/* =====================
   Focus States for Accessibility
   ===================== */
a:focus,
button:focus,
input:focus,
select:focus {
    outline: 2px solid #3b82f6;
    outline-offset: 2px;
}

/* =====================
   Selection Color
   ===================== */
::selection {
    background: #3b82f6;
    color: white;
}

/* =====================
   Disabled State
   ===================== */
button:disabled {
    cursor: not-allowed;
    opacity: 0.6;
}

/* =====================
   Badge Pulse
   ===================== */
.badge-pulse {
    animation: pulse-glow 2s infinite;
}
