/* CSS Variables */
:root {
    --primary-blue: var(--color-primary-600);
    --primary-orange: var(--color-accent-500);
    --secondary-blue: var(--color-primary-800);
    --secondary-orange: var(--color-accent-700);
    --text-dark: var(--color-neutral-900);
    --text-light: var(--color-neutral-600);
    --background-light: var(--color-neutral-200);
    --background-white: var(--color-neutral-50);
    --border-color: var(--color-neutral-300);
    --shadow-light: 0 2px 10px rgba(0,0,0,0.1);
    --shadow-medium: 0 4px 20px rgba(0,0,0,0.15);
    --transition: all 0.3s ease;
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Times New Roman', Times, serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--background-white);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Times New Roman', Times, serif;
    font-weight: bold;
    margin-bottom: 1rem;
    color: var(--text-dark);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

p {
    margin-bottom: 1rem;
    color: var(--text-dark);
}

.markdown-body h3 {
    all: unset;
    display: block;
    font-family: 'Times New Roman', Times, serif;
    font-size: 1.25rem;
    line-height: 1.5;
    margin: 0 0 0.5rem;
    color: var(--primary-blue);
}

a {
    text-decoration: none;
    color: var(--primary-blue);
    transition: var(--transition);
}

a:hover {
    color: var(--primary-orange);
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 25px;
    font-weight: bold;
    text-align: center;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    font-size: 1rem;
    margin: 5px;
}

.btn-primary {
    background-color: var(--primary-orange);
    color: white;
}

.btn-primary:hover {
    background-color: var(--secondary-orange);
    color: white;
    transform: translateY(-2px);
    box-shadow: var(--shadow-medium);
}

.btn-secondary {
    background-color: var(--primary-blue);
    color: white;
}

.btn-secondary:hover {
    background-color: var(--secondary-blue);
    color: white;
    transform: translateY(-2px);
    box-shadow: var(--shadow-medium);
}

.btn-whatsapp {
    background-color: #25D366;
    color: white;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.btn-whatsapp:hover {
    background-color: #128C7E;
    color: white;
    transform: translateY(-2px);
}

.btn-phone {
    background-color: var(--primary-blue);
    color: white;
}

.btn-phone:hover {
    background-color: var(--secondary-blue);
    color: white;
    transform: translateY(-2px);
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background-color: var(--background-white);
    box-shadow: var(--shadow-light);
    z-index: 1000;
    padding: 15px 0;
    transition: var(--transition);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 15px;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    position: relative;
    z-index: 2;
}

.logo {
    height: 50px;
    width: auto;
}

.brand-text {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary-blue);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 30px;
}

.nav-link {
    color: var(--text-dark);
    font-weight: 500;
    transition: var(--transition);
    padding: 10px 0;
    position: relative;
}

.nav-link:hover {
    color: var(--primary-orange);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-orange);
    transition: var(--transition);
}

.nav-link:hover::after {
    width: 100%;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 4px;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background-color: var(--text-dark);
    transition: var(--transition);
}

/* Hero Section */
.hero {
    height: 100vh;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    margin-bottom: 0;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--gradient-hero), url('../Assets/images/doctor-holding-hands-with-senior-patient.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: scroll;
}

/* Consistent red tint overlay across browsers */
.hero-overlay::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(242, 66, 54, 0.10);
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 2;
    color: white;
    max-width: 800px;
    padding: 0 20px;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: bold;
    margin-bottom: 1.5rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.6);
    color: var(--text-on-dark);
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2.5rem;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.6);
    color: var(--text-on-dark);
}

.hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
}

/* Section Styles */
section {
    padding: 80px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-title {
    font-size: 2.5rem;
    color: var(--primary-blue);
    margin-bottom: 20px;
}

.section-line {
    width: 80px;
    height: 4px;
    background-color: var(--primary-orange);
    margin: 0 auto;
    border-radius: 2px;
}

/* About Section */
.about {
    background-color: var(--background-light);
    margin-top: 0;
    padding: 36px 0;
    overflow: auto;
}

.about-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: 24px;
    align-items: center;
}

.about-text h3 {
    color: var(--primary-blue);
    margin-top: 12px;
    margin-bottom: 8px;
    line-height: 1.4;
}

.about-text p {
    font-size: 18px;
    line-height: 1.5;
    margin: 0 0 10px;
}

.about .section-header {
    margin-bottom: 28px;
}

.about-text {
    max-width: 900px;
    margin: 0 auto;
}

.about-image img {
    width: 100%;
    height: auto;
    border-radius: 10px;
    box-shadow: var(--shadow-medium);
}

/* Services Section */
.services { display: none; }

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.service-card {
    background-color: var(--background-white);
    padding: 30px;
    border-radius: 10px;
    text-align: center;
    box-shadow: var(--shadow-light);
    transition: var(--transition);
    border: 1px solid var(--border-color);
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-medium);
    border-color: var(--primary-blue);
}

.service-icon {
    font-size: 3rem;
    margin-bottom: 20px;
    color: var(--primary-blue);
}

.service-card h3 {
    color: var(--primary-blue);
    margin-bottom: 15px;
    font-size: 1.25rem;
}

.service-card p {
    color: var(--text-light);
    margin-bottom: 0;
}

/* Palliative Care Section */
.palliative-care {
    background-color: var(--background-light);
}

.palliative-intro {
    text-align: center;
    margin-bottom: 50px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.palliative-intro h3 {
    color: var(--primary-blue);
    margin-bottom: 20px;
}

.palliative-content { display: block; }
.palliative-content.text-only h3 { color: var(--primary-blue); margin-top: 16px; }
.palliative-content.text-only ul { list-style: disc; padding-left: 20px; }

/* 通用 text-only 排版，供 intro 与 content 复用 */
.text-only { text-align: center; }
.text-only h3 { color: var(--primary-blue); margin-top: 16px; text-align: center; }
.text-only ul { list-style: disc; padding-left: 20px; display: inline-block; text-align: left; }
.text-only p { font-size: 18px; line-height: 1.5; margin: 0 0 10px; text-align: center; }

.palliative-services,
.palliative-explanation,
.care-team {
    background-color: var(--background-white);
    padding: 30px;
    border-radius: 10px;
    box-shadow: var(--shadow-light);
}

.palliative-services h3,
.palliative-explanation h3,
.care-team h3 {
    color: var(--primary-blue);
    margin-bottom: 20px;
}

.palliative-services ul,
.care-team ul {
    list-style: none;
    padding-left: 0;
}

.palliative-services li,
.care-team li {
    padding: 8px 0;
    padding-left: 25px;
    position: relative;
    color: var(--text-dark);
}

.palliative-services li::before,
.care-team li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--primary-orange);
    font-weight: bold;
}

/* CTA Section */
.cta {
    background: var(--gradient-cta);
    color: white;
    text-align: center;
}

.cta-title {
    color: white;
    margin-bottom: 15px;
}

.cta-subtitle {
    font-size: 1.1rem;
    margin-bottom: 30px;
    opacity: 0.95;
    color: var(--text-on-dark);
}

.cta-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 20px;
}

.icon-whatsapp svg {
    display: inline-block;
    width: 24px;
    height: 24px;
    fill: #FFFFFF;
}

.btn-whatsapp .btn-label {
    font-weight: 700;
}

.cta-extra {
    font-size: 1rem;
    opacity: 0.95;
    margin-top: 20px;
    color: var(--text-on-dark);
}

/* Contact Section */
.contact {
    background-color: var(--background-white);
}

.contact-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.contact-info h3 {
    color: var(--primary-blue);
    margin-bottom: 20px;
}

.contact-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.contact-item {
    background-color: var(--background-light);
    padding: 25px;
    border-radius: 10px;
    box-shadow: var(--shadow-light);
}

.contact-item strong {
    color: var(--primary-blue);
    display: block;
    margin-bottom: 10px;
}

.contact-item a {
    color: var(--primary-orange);
    font-weight: bold;
}

.contact-item a:hover {
    color: var(--secondary-orange);
}

/* Footer */
.footer {
    background-color: var(--background-white);
    color: var(--text-dark);
    padding: 50px 0 20px;
    border-top: 1px solid var(--border-color);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 30px;
}

.footer-section h4 {
    color: var(--primary-blue);
    margin-bottom: 20px;
}

.footer-section p,
.footer-section li {
    color: var(--text-dark);
    margin-bottom: 10px;
}

.footer-section ul {
    list-style: none;
    padding: 0;
}

.footer-section a {
    color: var(--primary-blue);
    transition: var(--transition);
}

.footer-section a:hover {
    color: var(--primary-orange);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
    color: var(--text-light);
}

.footer-bottom p {
    margin-bottom: 5px;
    font-size: 0.9rem;
}

/* Footer Logos */
.footer-logos {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    margin-top: 16px;
    max-width: 420px;
}

.footer-logo {
    width: 100%;
    height: auto;
    object-fit: contain;
}

/* Fine-tuned logo proportions for visual balance */
.footer-logo-top { max-width: clamp(180px, 40vw, 360px); }
.footer-logo-bottom { max-width: clamp(160px, 36vw, 320px); }

/* Footer contact list with icons */
.privacy-note { color: var(--text-light); margin-top: 10px; }
.contact-simple { list-style: disc; padding-left: 20px; margin: 0; }
.contact-simple li { margin-bottom: 8px; }

/* Utility Classes */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }

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

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

/* Scroll animations */
section {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease-out;
}

section.visible {
    opacity: 1;
    transform: translateY(0);
}
