*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Times New Roman', Times, serif;
}

body{
    background: linear-gradient(135deg, #667eea 0%, #764ba2 25%, #f093fb 50%, #f5576c 75%, #4facfe 100%);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
    color: white;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow-x: hidden;
}

/* Animated background gradient */
@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

/* Add floating particles effect */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 20% 80%, rgba(120, 119, 198, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 119, 198, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(120, 219, 255, 0.3) 0%, transparent 50%);
    z-index: -1;
    animation: floatingBubbles 20s ease-in-out infinite;
}

@keyframes floatingBubbles {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
        opacity: 1;
    }
    50% {
        transform: translateY(-20px) rotate(180deg);
        opacity: 0.8;
    }
}

/* Add geometric pattern overlay */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(45deg, transparent 24%, rgba(255, 255, 255, 0.05) 25%, rgba(255, 255, 255, 0.05) 26%, transparent 27%, transparent 74%, rgba(255, 255, 255, 0.05) 75%, rgba(255, 255, 255, 0.05) 76%, transparent 77%);
    background-size: 60px 60px;
    z-index: -1;
    animation: patternMove 25s linear infinite;
}

@keyframes patternMove {
    0% {
        transform: translateX(0) translateY(0);
    }
    100% {
        transform: translateX(-60px) translateY(-60px);
    }
}

.container{
    display: flex;
    flex-direction: column;
    gap: 1rem;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 30px; 
    border-radius: 20px;
    width: 50%;
    max-width: 600px;
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    position: relative;
    z-index: 10;
    animation: containerGlow 3s ease-in-out infinite alternate;
}

@keyframes containerGlow {
    0% {
        box-shadow: 
            0 8px 32px rgba(0, 0, 0, 0.3),
            inset 0 1px 0 rgba(255, 255, 255, 0.2),
            0 0 20px rgba(102, 126, 234, 0.3);
    }
    100% {
        box-shadow: 
            0 8px 32px rgba(0, 0, 0, 0.3),
            inset 0 1px 0 rgba(255, 255, 255, 0.2),
            0 0 40px rgba(245, 87, 108, 0.4);
    }
}

/* Toast Notifications */
#toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
}

.toast {
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    color: white;
    padding: 15px 25px;
    border-radius: 15px;
    margin-bottom: 10px;
    min-width: 250px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transform: translateX(400px);
    transition: all 0.3s ease-in-out;
}

.toast.show {
    transform: translateX(0);
}

.toast.error {
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.9), rgba(192, 57, 43, 0.9));
    border-color: rgba(231, 76, 60, 0.5);
}

.toast.success {
    background: linear-gradient(135deg, rgba(39, 174, 96, 0.9), rgba(22, 160, 133, 0.9));
    border-color: rgba(39, 174, 96, 0.5);
}

.toast.warning {
    background: linear-gradient(135deg, rgba(243, 156, 18, 0.9), rgba(230, 126, 34, 0.9));
    border-color: rgba(243, 156, 18, 0.5);
}

.toast.info {
    background: linear-gradient(135deg, rgba(52, 152, 219, 0.9), rgba(41, 128, 185, 0.9));
    border-color: rgba(52, 152, 219, 0.5);
}

/* Loading States */
.loading {
    position: relative;
    pointer-events: none;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #299f5d;
    border-top: 2px solid transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Improved Button Styles */
#search-btn {
    padding: 0.4rem 1rem;
    border-radius: 12px;
    background: linear-gradient(45deg, #667eea, #764ba2);
    color: white;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    position: relative;
    overflow: hidden;
}

#search-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

#search-btn:hover::before {
    left: 100%;
}

#search-btn:hover {
    background: linear-gradient(45deg, #764ba2, #667eea);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

#search-btn:disabled {
    background: rgba(255, 255, 255, 0.3);
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Improved Input Styles */
#user-input {
    width: 80%;
    padding: 0.4rem;
    border-radius: 12px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    color: white;
    transition: all 0.3s ease;
    font-size: 1rem;
}

#user-input:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.6);
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.2);
}

#user-input::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.header {
    text-align: center;
    margin-bottom: 1.5rem;
    position: relative;
}

.header::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 100px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    border-radius: 50%;
    z-index: -1;
    animation: headerGlow 4s ease-in-out infinite;
}

@keyframes headerGlow {
    0%, 100% {
        opacity: 0.5;
        transform: translateX(-50%) scale(1);
    }
    50% {
        opacity: 1;
        transform: translateX(-50%) scale(1.2);
    }
}

h1{
    font-size: 2rem;
    margin: 0;
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4, #45b7d1, #96ceb4, #feca57);
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: titleGradient 4s ease infinite;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

@keyframes titleGradient {
    0%, 100% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
}

.subtitle {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1rem;
    margin: 0.5rem 0 0 0;
    font-style: italic;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.user-container{
    display: flex;
    flex-direction: column;
    gap: 10px;
    justify-content: start;
}

.user-input-container{
    display: flex;
    justify-content: space-between;
    gap: 10px;
}

.circle{
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 4px solid transparent;
    background: 
        linear-gradient(45deg, #ff6b6b, #4ecdc4, #45b7d1, #96ceb4, #feca57) border-box,
        conic-gradient(from 0deg, 
            #ff6b6b var(--progress-degree, 0%), 
            rgba(255, 255, 255, 0.1) var(--progress-degree, 0%)) padding-box;
    background-clip: border-box, padding-box;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 16px;
    color: white;
    font-weight: 700;
    flex-direction: column;
    transition: all 0.3s ease;
    cursor: pointer;
    box-shadow: 
        0 4px 15px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.circle:hover {
    transform: scale(1.05) rotate(5deg);
    box-shadow: 
        0 8px 25px rgba(255, 107, 107, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.easy-progress {
    background: 
        linear-gradient(45deg, #4ecdc4, #44a08d) border-box,
        conic-gradient(from 0deg, 
            #4ecdc4 var(--progress-degree, 0%), 
            rgba(255, 255, 255, 0.1) var(--progress-degree, 0%)) padding-box;
}

.medium-progress {
    background: 
        linear-gradient(45deg, #feca57, #ff9ff3) border-box,
        conic-gradient(from 0deg, 
            #feca57 var(--progress-degree, 0%), 
            rgba(255, 255, 255, 0.1) var(--progress-degree, 0%)) padding-box;
}

.hard-progress {
    background: 
        linear-gradient(45deg, #ff6b6b, #ee5a6f) border-box,
        conic-gradient(from 0deg, 
            #ff6b6b var(--progress-degree, 0%), 
            rgba(255, 255, 255, 0.1) var(--progress-degree, 0%)) padding-box;
}

.circle span{
    position: relative;
    z-index: 2;
}

.progress{
    display: flex;
    flex-direction: row;
    justify-content: space-evenly;
    flex-wrap: wrap;
    gap: 15px;
    animation: fadeInUp 0.4s ease-out;
}

.stats-card{
    margin-top: 2rem ; 
    margin-bottom: 2rem;
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: space-evenly;
    animation: fadeInUp 0.6s ease-out;
}

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

h4{
    font-size: 1rem;
}

.card{
    background: linear-gradient(135deg, 
        rgba(255, 255, 255, 0.2) 0%, 
        rgba(255, 255, 255, 0.1) 50%, 
        rgba(255, 255, 255, 0.05) 100%);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    width: 45% ; 
    max-width: 290px;
    min-width: 250px;
    padding: 20px;
    border-radius: 20px;
    font-size: 1rem;
    min-height: 5rem;
    transition: all 0.3s ease;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, 
        transparent, 
        rgba(255, 255, 255, 0.1), 
        transparent);
    transform: rotate(45deg);
    transition: all 0.5s ease;
    opacity: 0;
}

.card:hover::before {
    animation: shimmer 0.8s ease-in-out;
}

@keyframes shimmer {
    0% {
        transform: translateX(-100%) translateY(-100%) rotate(45deg);
        opacity: 1;
    }
    100% {
        transform: translateX(100%) translateY(100%) rotate(45deg);
        opacity: 0;
    }
}

.card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 
        0 12px 30px rgba(0, 0, 0, 0.3),
        0 0 20px rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
}

.card-icon {
    font-size: 2rem;
    margin-bottom: 8px;
}

.card h4 {
    margin: 8px 0;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.9);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.card-value {
    font-size: 1.6rem;
    font-weight: bold;
    color: #ffffff;
    margin: 0;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4, #45b7d1);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: textGradient 3s ease infinite;
}

@keyframes textGradient {
    0%, 100% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        width: 90%;
        padding: 15px;
    }
    
    .progress {
        flex-direction: column;
        align-items: center;
    }
    
    .card {
        width: 100%;
        max-width: none;
        min-width: auto;
    }
    
    .user-input-container {
        flex-direction: column;
        gap: 10px;
    }
    
    #user-input {
        width: 100%;
    }
    
    #toast-container {
        right: 10px;
        left: 10px;
    }
    
    .toast {
        min-width: auto;
    }
    
    .circle {
        width: 100px;
        height: 100px;
        font-size: 14px;
    }
    
    h1 {
        font-size: 1.5rem;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .container {
        width: 95%;
        padding: 10px;
    }
    
    .circle {
        width: 80px;
        height: 80px;
        font-size: 12px;
    }
}