:root {
    --primary-color: #4466ee;
    --secondary-color: #6c757d;
    --success-color: #2ecc71;
    --info-color: #3498db;
    --warning-color: #f1c40f;
    --danger-color: #e74c3c;
    --light-color: #f8f9fa;
    --dark-color: #343a40;
}

body {
    background: 
        radial-gradient(circle at top right, rgba(68, 102, 238, 0.15), transparent 50%),
        radial-gradient(circle at bottom left, rgba(46, 204, 113, 0.15), transparent 50%),
        linear-gradient(135deg, #f5f7fa 0%, #e4e8f0 100%);
    background-attachment: fixed;
    font-family: 'Nunito', sans-serif;
    color: var(--dark-color);
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%234466ee' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    pointer-events: none;
    z-index: -1;
    animation: backgroundFloat 60s linear infinite;
}

@keyframes backgroundFloat {
    0% {
        background-position: 0 0;
    }
    100% {
        background-position: 60px 60px;
    }
}

.hero-section {
    background: linear-gradient(135deg, rgba(68, 102, 238, 0.15) 0%, rgba(46, 204, 113, 0.1) 100%);
    padding: 4rem 0;
    border-radius: 2rem;
    margin-bottom: 3rem;
    text-align: center;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.hero-section::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.2) 0%, transparent 50%);
    animation: heroShine 10s linear infinite;
}

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

.category-card {
    cursor: pointer;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    margin-bottom: 2rem;
    height: 100%;
    perspective: 1000px;
    transform-style: preserve-3d;
}

.category-card .card {
    border: none;
    border-radius: 1.5rem;
    background: white;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    height: 100%;
    transform-style: preserve-3d;
    position: relative;
}

.category-card:hover {
    transform: translateY(-15px);
}

.category-card:hover .card {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    transform: rotateY(10deg) translateY(-10px);
}

.category-card .card-body {
    padding: 2.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.95));
}

.category-card .icon-wrapper {
    width: 140px;
    height: 140px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 2rem;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(68, 102, 238, 0.1), rgba(52, 152, 219, 0.1));
    transition: all 0.5s ease;
    position: relative;
    overflow: hidden;
    transform: translateZ(20px);
}

.category-card:hover .icon-wrapper {
    transform: scale(1.1) rotate(5deg);
}

.category-card .icon-wrapper::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        45deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.8) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    transform: rotate(45deg);
    animation: shine 3s infinite;
}

@keyframes shine {
    0% {
        transform: translateX(-100%) rotate(45deg);
    }
    100% {
        transform: translateX(100%) rotate(45deg);
    }
}

.category-card .icon-wrapper img {
    width: 80px;
    height: 80px;
    object-fit: contain;
    transition: all 0.5s ease;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));
}

.category-card:hover .icon-wrapper img {
    transform: scale(1.1);
}

.category-card .card-title {
    color: var(--primary-color);
    font-weight: 700;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
    transform: translateZ(10px);
}

.category-card:hover .card-title {
    transform: scale(1.05);
    color: var(--info-color);
}

.category-card .card-text {
    color: var(--secondary-color);
    font-size: 1.1rem;
    transition: all 0.3s ease;
    transform: translateZ(10px);
}

.bottom-features {
    margin-top: 4rem;
    padding: 3rem 0;
    background: linear-gradient(135deg, rgba(52, 152, 219, 0.1) 0%, rgba(46, 204, 113, 0.1) 100%);
    border-radius: 2rem;
}

.feature-card {
    background: white;
    border-radius: 1.5rem;
    padding: 2.5rem;
    margin-bottom: 2rem;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    height: 100%;
    position: relative;
    overflow: hidden;
}

.feature-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.feature-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(68, 102, 238, 0.05), rgba(52, 152, 219, 0.05));
    opacity: 0;
    transition: all 0.5s ease;
}

.feature-card:hover::after {
    opacity: 1;
}

.feature-card .icon-wrapper {
    width: 120px;
    height: 120px;
    margin: 0 auto 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(68, 102, 238, 0.1), rgba(52, 152, 219, 0.1));
    transition: all 0.5s ease;
}

.feature-card:hover .icon-wrapper {
    transform: rotate(10deg) scale(1.1);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--info-color));
    border: none;
    padding: 1rem 2.5rem;
    border-radius: 2rem;
    font-weight: 600;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(68, 102, 238, 0.3);
}

.btn-primary::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        45deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.3) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    transform: rotate(45deg);
    animation: buttonShine 2s infinite;
}

@keyframes buttonShine {
    0% {
        transform: translateX(-100%) rotate(45deg);
    }
    100% {
        transform: translateX(100%) rotate(45deg);
    }
}

/* Chatbot specific styles */
.chat-messages {
    height: 400px;
    overflow-y: auto;
    padding: 1.5rem;
    border-radius: 1rem;
    background: var(--light-color);
}

.message {
    margin-bottom: 1rem;
    padding: 1rem;
    border-radius: 1rem;
    max-width: 80%;
    animation: messageAppear 0.3s ease-out;
}

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

.message.system {
    background: white;
    margin-right: auto;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.message.user {
    background: linear-gradient(135deg, var(--primary-color), var(--info-color));
    color: white;
    margin-left: auto;
    box-shadow: 0 2px 5px rgba(68, 102, 238, 0.2);
}

@media (max-width: 768px) {
    .hero-section {
        padding: 2rem 0;
    }

    .category-card {
        margin-bottom: 1.5rem;
    }

    .feature-card {
        margin-bottom: 1.5rem;
    }
}

.contributors {
    text-align: right;
}

.contributor-item {
    margin-bottom: 0.5rem;
}

.contributor-link {
    color: var(--secondary-color);
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-block;
}

.contributor-link:hover {
    color: var(--primary-color);
    transform: translateX(-5px);
}

.contributor-link i {
    color: #0077b5;
}

/* About page styles */
.about-container .hero-section {
    background: linear-gradient(135deg, rgba(68, 102, 238, 0.1) 0%, rgba(46, 204, 113, 0.05) 100%);
    padding: 3rem 0;
    text-align: center;
    border-radius: 2rem;
}

.mission-text {
    font-size: 1.2rem;
    line-height: 1.8;
    color: var(--secondary-color);
}

.team-members {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.team-member {
    text-align: center;
    padding: 1.5rem;
    border-radius: 1rem;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.95));
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.team-member:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.member-info h4 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.member-info p {
    color: var(--secondary-color);
    margin-bottom: 1rem;
}

.social-link {
    color: #0077b5;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border-radius: 2rem;
    background: rgba(0, 119, 181, 0.1);
    transition: all 0.3s ease;
}

.social-link:hover {
    background: rgba(0, 119, 181, 0.2);
    transform: translateY(-2px);
}

@media (max-width: 768px) {
    .contributors {
        text-align: center;
        margin-top: 1rem;
    }

    .team-members {
        grid-template-columns: 1fr;
    }
}

.symptom-card, .result-card {
    transition: all 0.3s ease;
    overflow: hidden;
}

.symptom-card:hover, .result-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1) !important;
}

.symptoms-list {
    max-height: 400px;
    overflow-y: auto;
    padding-right: 10px;
}

.symptom-item {
    padding: 0.75rem;
    border-radius: 0.5rem;
    margin-bottom: 0.5rem;
    transition: all 0.3s ease;
    cursor: pointer;
    background: rgba(255, 255, 255, 0.5);
}

.symptom-item:hover {
    background: rgba(68, 102, 238, 0.1);
    transform: translateX(5px);
}

.symptom-hover {
    background: rgba(68, 102, 238, 0.1);
    transform: translateX(5px);
}

.form-check-input {
    cursor: pointer;
    transition: all 0.2s ease;
}

.form-check-input:checked {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    animation: checkmark 0.3s ease-in-out;
}

@keyframes checkmark {
    0% {
        transform: scale(0);
    }
    50% {
        transform: scale(1.2);
    }
    100% {
        transform: scale(1);
    }
}

.diagnosis-btn {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, var(--primary-color), var(--info-color));
    border: none;
    transition: all 0.5s ease;
}

.diagnosis-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(68, 102, 238, 0.3);
}

.diagnosis-btn .button-effect {
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        45deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.3) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    transform: rotate(45deg);
    animation: buttonShine 2s infinite;
}