:root {
    --primary-blue: #0077b6;
    --light-blue: #caf0f8;
    --medical-white: #ffffff;
    --text-dark: #2b2d42;
    --success-green: #2a9d8f;
    --warning-orange: #e9c46a;
    --danger-red: #e76f51;
    --gray-bg: #f8f9fa;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--gray-bg);
    color: var(--text-dark);
    line-height: 1.6;
}

/* Utilities */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.btn {
    display: inline-block;
    padding: 12px 24px;
    border-radius: 50px;
    font-weight: bold;
    text-decoration: none;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    border: none;
}

.btn-primary {
    background-color: var(--primary-blue);
    color: white;
    box-shadow: 0 4px 6px rgba(0, 119, 182, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 119, 182, 0.4);
}

section {
    padding: 80px 0;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--light-blue) 0%, white 100%);
    text-align: center;
    padding: 100px 0;
    position: relative;
    overflow: hidden;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 20px;
    color: var(--primary-blue);
}

.hero p {
    font-size: 1.25rem;
    color: #555;
    margin-bottom: 40px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.input-group {
    display: flex;
    justify-content: center;
    gap: 10px;
    max-width: 600px;
    margin: 0 auto;
    flex-wrap: wrap;
}

.input-group input {
    padding: 15px 20px;
    border-radius: 50px;
    border: 2px solid #ddd;
    flex: 1;
    min-width: 280px;
    font-size: 1rem;
    outline: none;
    transition: border-color 0.3s;
}

.input-group input:focus {
    border-color: var(--primary-blue);
}

.doctor-icon {
    font-size: 5rem;
    color: var(--primary-blue);
    margin-bottom: 20px;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0); }
}

/* Diagnose Module */
.diagnose-section {
    background-color: white;
    min-height: 100px; /* Avoid collapse if hidden content */
}

.diagnose-container {
    max-width: 800px;
    margin: 0 auto;
    background: white;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    padding: 40px;
    display: none; /* Hidden by default */
    border-top: 5px solid var(--primary-blue);
}

.loading-view {
    text-align: center;
    padding: 40px;
}

.heartbeat-loader {
    font-size: 3rem;
    color: var(--danger-red);
    animation: heartbeat 1.5s infinite;
    margin-bottom: 20px;
}

@keyframes heartbeat {
    0% { transform: scale(1); }
    14% { transform: scale(1.3); }
    28% { transform: scale(1); }
    42% { transform: scale(1.3); }
    70% { transform: scale(1); }
}

.results-view {
    display: none;
}

.overall-score {
    text-align: center;
    margin-bottom: 40px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.score-circle {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: var(--light-blue);
    color: var(--primary-blue);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    font-weight: bold;
    margin: 0 auto 15px;
    border: 4px solid var(--primary-blue);
}

.result-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 25px;
    padding: 20px;
    background: var(--gray-bg);
    border-radius: 12px;
    transition: transform 0.2s;
}

.result-item:hover {
    transform: translateY(-2px);
}

.result-icon {
    font-size: 1.5rem;
    margin-right: 20px;
    width: 40px;
    text-align: center;
}

.result-content {
    flex: 1;
}

.result-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.result-title {
    font-weight: bold;
    font-size: 1.1rem;
}

.status-badge {
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 0.85rem;
    font-weight: bold;
    color: white;
}

.status-green { background-color: var(--success-green); }
.status-orange { background-color: var(--warning-orange); color: #333; }
.status-red { background-color: var(--danger-red); }

.doctor-comment {
    font-style: italic;
    color: #666;
    font-size: 0.95rem;
    position: relative;
    padding-left: 15px;
    border-left: 3px solid var(--primary-blue);
}

/* Features Section */
.features {
    background-color: var(--gray-bg);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.feature-card {
    background: white;
    padding: 30px;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s;
}

.feature-card:hover {
    transform: translateY(-5px);
}

.feature-icon {
    font-size: 2.5rem;
    color: var(--primary-blue);
    margin-bottom: 20px;
}

.feature-card h3 {
    margin-bottom: 15px;
    color: var(--text-dark);
}

/* Examples Section */
.examples {
    background-color: white;
}

.section-title {
    text-align: center;
    margin-bottom: 50px;
    color: var(--primary-blue);
    font-size: 2rem;
}

.example-card {
    background: white;
    border: 1px solid #eee;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.example-header {
    background: var(--light-blue);
    padding: 15px;
    font-weight: bold;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.example-body {
    padding: 20px;
}

.example-result {
    display: flex;
    align-items: center;
    margin-top: 10px;
    font-size: 0.9rem;
}

.example-result i {
    margin-right: 10px;
}

.check-green { color: var(--success-green); }
.check-orange { color: var(--warning-orange); }

/* Footer */
footer {
    background-color: var(--text-dark);
    color: white;
    padding: 50px 0;
    text-align: center;
}

footer a {
    color: var(--light-blue);
    text-decoration: none;
}

.disclaimer {
    font-size: 0.9rem;
    opacity: 0.7;
    margin-top: 20px;
}

@media (max-width: 768px) {
    .hero h1 { font-size: 2rem; }
    .hero p { font-size: 1rem; }
    .feature-card { padding: 20px; }
}
