/* ====================================
   GLOBAL RESET & BASE STYLES
   ==================================== */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    color: #1e293b; /* Deep navy/slate for readability */
    line-height: 1.6;
}

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

/* ====================================
   COLOR PALETTE
   ==================================== */

:root {
    --primary-teal: #0d9488;
    --primary-teal-light: #14b8a6;
    --primary-teal-dark: #0f766e;
    --deep-navy: #1e293b;
    --slate: #475569;
    --light-gray: #f8fafc;
    --white: #ffffff;
    --shadow: rgba(0, 0, 0, 0.1);
    --shadow-hover: rgba(0, 0, 0, 0.15);
}

/* ====================================
   NAVBAR STYLES
   ==================================== */

.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: var(--white);
    box-shadow: 0 2px 10px var(--shadow);
    z-index: 1000;
    transition: all 0.3s ease;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding: 16px 24px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-teal);
    text-decoration: none;
    transition: color 0.3s ease;
    height: auto;
    max-height: 50px;
    line-height: 1;
}

.logo:hover {
    color: var(--primary-teal-dark);
}

.logo i {
    font-size: 1.8rem;
    flex-shrink: 0;
}

.nav-links {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    list-style: none;
    flex-wrap: nowrap;
    white-space: nowrap;
}

.nav-links a {
    color: var(--slate);
    text-decoration: none;
    font-family: 'Poppins', sans-serif;
    font-size: 1rem;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
    line-height: 1;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-teal);
    transition: width 0.3s ease;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--primary-teal);
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

.btn-cta {
    background-color: var(--primary-teal);
    color: var(--white) !important;
    padding: 10px 24px;
    border-radius: 50px;
    transition: all 0.3s ease !important;
    box-shadow: 0 4px 12px rgba(13, 148, 136, 0.3);
}

.btn-cta::after {
    display: none !important;
}

.btn-cta:hover {
    background-color: var(--primary-teal-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(13, 148, 136, 0.4);
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--deep-navy);
    cursor: pointer;
}

/* ====================================
   MOBILE MENU STYLES
   ==================================== */

.mobile-menu {
    display: none;
    position: fixed;
    top: 0;
    right: 0;
    width: 100%;
    height: 100%;
    background-color: var(--white);
    z-index: 2000;
    padding: 80px 32px;
}

.mobile-menu.active {
    display: flex;
    flex-direction: column;
}

.close-menu {
    position: absolute;
    top: 24px;
    right: 24px;
    background: none;
    border: none;
    font-size: 2rem;
    color: var(--deep-navy);
    cursor: pointer;
}

.mobile-nav-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 24px;
    margin-top: 40px;
}

.mobile-link {
    font-size: 1.25rem;
    color: var(--deep-navy);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.mobile-link:hover,
.mobile-link.active {
    color: var(--primary-teal);
}

.mobile-cta {
    margin-top: 20px;
    text-align: center;
    display: inline-block;
}

/* ====================================
   HERO SECTION STYLES
   ==================================== */

.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background-image: url('https://images.unsplash.com/photo-1629909613654-28e377c37b09');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    margin-top: 72px;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.8) 0%, rgba(13, 148, 136, 0.6) 100%);
}

.hero-content {
    position: relative;
    z-index: 10;
    text-align: center;
    color: var(--white);
    padding: 60px 24px;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 24px;
    line-height: 1.2;
    opacity: 0;
    animation: fadeInUp 0.8s ease forwards;
}

.hero-subtitle {
    font-size: 1.25rem;
    max-width: 700px;
    margin: 0 auto 40px;
    opacity: 0.9;
    opacity: 0;
    animation: fadeInUp 0.8s ease 0.2s forwards;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
    opacity: 0;
    animation: fadeInUp 0.8s ease 0.4s forwards;
}

.btn-primary,
.btn-secondary {
    padding: 14px 36px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    border: 2px solid transparent;
}

.btn-primary {
    background-color: var(--primary-teal);
    color: var(--white);
    box-shadow: 0 4px 16px rgba(13, 148, 136, 0.4);
}

.btn-primary:hover {
    background-color: var(--primary-teal-dark);
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(13, 148, 136, 0.5);
}

.btn-secondary {
    background-color: transparent;
    color: var(--white);
    border-color: var(--white);
}

.btn-secondary:hover {
    background-color: var(--white);
    color: var(--primary-teal);
    transform: translateY(-3px);
}

.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    color: var(--white);
    text-align: center;
    font-size: 0.875rem;
    opacity: 0.7;
    animation: bounce 2s infinite;
}

.scroll-indicator i {
    display: block;
    margin-top: 8px;
    font-size: 1.5rem;
}

/* ====================================
   ANIMATIONS
   ==================================== */

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

@keyframes bounce {
    0%, 100% {
        transform: translateX(-50%) translateY(0);
    }
    50% {
        transform: translateX(-50%) translateY(-10px);
    }
}

/* ====================================
   PLACEHOLDER SECTION STYLES
   ==================================== */

.section {
    padding: 100px 0;
}

.section.bg-light {
    background-color: var(--light-gray);
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--deep-navy);
    text-align: center;
    margin-bottom: 16px;
}

.section-subtitle {
    text-align: center;
    color: var(--slate);
    font-size: 1.125rem;
    margin-bottom: 60px;
}

/* ====================================
   SERVICES SECTION (SLIDER)
   ==================================== */

.slider-container {
    position: relative;
    margin-top: 60px;
    overflow: hidden;
    padding: 20px 0;
}

.slider-track {
    display: flex;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform;
}

.service-card {
    background-color: var(--white);
    border-radius: 16px;
    padding: 32px;
    box-shadow: 0 4px 20px var(--shadow);
    transition: all 0.3s ease;
    text-align: center;
    flex-shrink: 0;
    width: calc(33.333% - 24px);
    margin: 0 12px;
    display: flex;
    flex-direction: column;
}

@media (max-width: 768px) {
    .service-card {
        width: calc(50% - 24px);
    }
}

@media (max-width: 480px) {
    .service-card {
        width: calc(100% - 48px);
        margin: 0 24px;
    }
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 30px var(--shadow-hover);
}

.service-image {
    width: 180px;
    height: 180px;
    margin: 0 auto 32px; /* Increased margin-bottom for issue 2 fix! */
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid var(--primary-teal-light);
    transition: all 0.3s ease;
}

.service-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.service-card:hover .service-image {
    border-color: var(--primary-teal);
    transform: scale(1.05);
}

.service-title {
    font-size: 1.375rem;
    font-weight: 600;
    color: var(--deep-navy);
    margin-bottom: 16px;
}

.service-description {
    color: var(--slate);
    line-height: 1.7;
    margin-bottom: 24px;
    flex-grow: 1;
}

.service-link {
    color: var(--primary-teal);
    font-weight: 500;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
}

.service-link:hover {
    color: var(--primary-teal-dark);
    gap: 12px;
}

/* Slider Arrows */
.slider-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: var(--white);
    border: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    color: var(--primary-teal);
    font-size: 1.25rem;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s ease;
}

.slider-arrow:hover {
    background-color: var(--primary-teal);
    color: var(--white);
    transform: translateY(-50%) scale(1.1);
}

.slider-arrow--left {
    left: 0;
}

.slider-arrow--right {
    right: 0;
}

/* Pagination Dots */
.slider-pagination {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 40px;
}

.slider-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: #d1d5db;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.slider-dot:hover {
    background-color: var(--primary-teal-light);
}

.slider-dot.active {
    background-color: var(--primary-teal);
    transform: scale(1.2);
}

/* ====================================
   FADE-IN SCROLL ANIMATION
   ==================================== */

.fade-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ====================================
   FOOTER
   ==================================== */

.footer {
    background-color: var(--deep-navy);
    color: var(--white);
    padding: 40px 0;
    text-align: center;
}

/* ====================================
   RESPONSIVE STYLES (MOBILE FIRST)
   ==================================== */

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    
    .mobile-menu-btn {
        display: block;
    }
    
    .hero-title {
        font-size: 2.25rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        width: 100%;
        max-width: 300px;
        margin: 0 auto;
    }
    
    .btn-primary,
    .btn-secondary {
        width: 100%;
    }
    
    .service-card {
        width: calc(50% - 24px);
    }
    
    .service-image {
        width: 140px;
        height: 140px;
    }
    
    .slider-arrow {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 1.875rem;
    }
    
    .service-card {
        width: calc(100% - 48px);
        margin: 0 24px;
    }
    
    .service-image {
        width: 160px;
        height: 160px;
    }
}

/* ====================================
   BEFORE/AFTER SLIDER
   ==================================== */

.before-after-container {
    max-width: 800px;
    margin: 40px auto 0;
}

.before-after-wrapper {
    position: relative;
    width: 100%;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.2);
    cursor: ew-resize;
    aspect-ratio: 4 / 3;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

.image-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    pointer-events: none;
    user-select: none;
}

.image-label {
    position: absolute;
    bottom: 24px;
    padding: 10px 24px;
    background: rgba(0, 0, 0, 0.75);
    color: white;
    font-weight: 600;
    border-radius: 50px;
    font-size: 0.95rem;
    backdrop-filter: blur(10px);
    letter-spacing: 0.5px;
    white-space: nowrap; /* Fix: prevent text from wrapping when slider moves! */
}

.before-image .image-label {
    right: 24px;
}

.after-image .image-label {
    right: 24px; /* Fix: move after label to the bottom-right corner! */
}

.after-image {
    width: 50%; /* Start at 50% */
    z-index: 2;
}

/* Slider Handle */
.slider-handle {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 4px;
    z-index: 10;
    left: 50%; /* Start at 50% */
    transform: translateX(-50%);
    pointer-events: none; /* Let clicks pass through to wrapper */
}

.slider-line {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 100%;
    background: white;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.4);
}

.slider-circle {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 56px;
    height: 56px;
    background: var(--primary-teal);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    box-shadow: 0 6px 20px rgba(13, 148, 136, 0.6);
}

.slider-circle i {
    color: white;
    font-size: 1.1rem;
}

/* ====================================
   OUR TEAM SECTION
   ==================================== */

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

.team-card {
    background: var(--white);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px var(--shadow);
    transition: all 0.4s ease;
    display: flex;
    flex-direction: column;
}

.team-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px var(--shadow-hover);
}

.team-image {
    position: relative;
    height: 350px;
    overflow: hidden;
}

.team-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.team-card:hover .team-image img {
    transform: scale(1.1);
}

.team-socials {
    position: absolute;
    bottom: -50px;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: center;
    gap: 15px;
    padding: 20px;
    background: linear-gradient(to top, rgba(13, 148, 136, 0.9), transparent);
    transition: bottom 0.4s ease;
}

.team-card:hover .team-socials {
    bottom: 0;
}

.team-socials a {
    width: 40px;
    height: 40px;
    background: var(--white);
    color: var(--primary-teal);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: all 0.3s ease;
}

.team-socials a:hover {
    background: var(--primary-teal-dark);
    color: var(--white);
    transform: translateY(-3px);
}

.team-info {
    padding: 30px;
    text-align: center;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.team-name {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--deep-navy);
    margin-bottom: 5px;
}

.team-specialty {
    color: var(--primary-teal);
    font-weight: 600;
    font-size: 0.95rem;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.team-bio {
    color: var(--slate);
    font-size: 0.95rem;
    line-height: 1.6;
    flex-grow: 1;
}

.view-profile-btn {
    width: 100%;
    margin-top: auto;
    padding: 12px 24px;
    background: var(--primary-teal);
    color: white;
    border: none;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.view-profile-btn:hover {
    background: var(--primary-teal-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(13, 148, 136, 0.3);
}

/* Doctor Profile Modal Styles */
.dr-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(8px);
    z-index: 9999;
    display: none;
    justify-content: center;
    align-items: center;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.dr-modal-overlay.active {
    display: flex;
    opacity: 1;
}

.dr-modal-content {
    background: white;
    border-radius: 24px;
    max-width: 900px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.3);
    position: relative;
    transform: scale(0.9);
    transition: transform 0.4s ease;
}

.dr-modal-overlay.active .dr-modal-content {
    transform: scale(1);
}

.dr-modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #f8fafc;
    border: none;
    font-size: 2rem;
    color: var(--deep-navy);
    cursor: pointer;
    z-index: 1;
    transition: all 0.3s ease;
}

.dr-modal-close:hover {
    background: var(--primary-teal);
    color: white;
    transform: rotate(90deg);
}

.dr-modal-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
}

.dr-modal-left {
    padding: 40px 30px;
    background: linear-gradient(135deg, #f0fdfa 0%, #e0f2fe 100%);
    border-radius: 24px 0 0 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
}

.dr-modal-photo {
    width: 220px;
    height: 220px;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: 0 10px 25px rgba(13, 148, 136, 0.2);
    border: 6px solid white;
}

.dr-modal-stats {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    width: 100%;
}

.dr-stat-item {
    background: white;
    padding: 20px;
    border-radius: 16px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.dr-stat-item i {
    font-size: 1.8rem;
    color: var(--primary-teal);
    margin-bottom: 10px;
}

.dr-stat-item h4 {
    color: var(--deep-navy);
    font-size: 0.95rem;
    margin: 0;
}

.dr-modal-right {
    padding: 40px;
}

.dr-modal-name {
    font-size: 2.2rem;
    color: var(--deep-navy);
    margin-bottom: 5px;
}

.dr-modal-title {
    font-size: 1.2rem;
    color: var(--primary-teal);
    font-weight: 600;
    margin-bottom: 30px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.dr-modal-section {
    margin-bottom: 30px;
}

.dr-modal-section-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.1rem;
    color: var(--deep-navy);
    margin-bottom: 15px;
    font-weight: 700;
}

.dr-modal-section-title i {
    color: var(--primary-teal);
}

.dr-modal-text {
    color: var(--slate);
    line-height: 1.7;
    font-size: 1rem;
}

.dr-modal-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.dr-modal-list li {
    color: var(--slate);
    padding: 10px 0;
    padding-left: 28px;
    position: relative;
    font-size: 1rem;
}

.dr-modal-list li:before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--primary-teal);
    font-weight: bold;
    font-size: 1.2rem;
}

/* Modal Responsive */
@media (max-width: 768px) {
    .dr-modal-grid {
        grid-template-columns: 1fr;
    }
    
    .dr-modal-left {
        border-radius: 24px 24px 0 0;
        padding: 30px 20px;
    }
    
    .dr-modal-photo {
        width: 180px;
        height: 180px;
    }
    
    .dr-modal-right {
        padding: 30px 20px;
    }
    
    .dr-modal-name {
        font-size: 1.8rem;
    }
}

/* ====================================
   TEAM SLIDER (ISOLATED - NO CONFLICTS)
   ==================================== */

.team-slider-container {
    position: relative;
    margin-top: 60px;
    overflow: hidden;
    padding: 20px 0;
}

.team-slider-track {
    display: flex;
    transition: transform 0.8s cubic-bezier(0.25, 1, 0.5, 1);
    will-change: transform;
}

.team-card {
    background: var(--white);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px var(--shadow);
    transition: all 0.3s ease;
    flex-shrink: 0;
    width: calc(33.333% - 24px);
    margin: 0 12px;
}

.team-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--white);
    border: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    color: var(--primary-teal);
    font-size: 1.25rem;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s ease;
}

.team-arrow:hover {
    background: var(--primary-teal);
    color: var(--white);
    transform: translateY(-50%) scale(1.1);
}

.team-arrow-left {
    left: 0;
}

.team-arrow-right {
    right: 0;
}

.team-dots-container {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 40px;
}

.team-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #d1d5db;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.team-dot:hover {
    background: var(--primary-teal-light);
}

.team-dot.active {
    background: var(--primary-teal);
    transform: scale(1.2);
}

/* TEAM SLIDER RESPONSIVE BREAKPOINTS */
@media (max-width: 768px) {
    .team-card {
        width: calc(50% - 24px);
    }
}

@media (max-width: 480px) {
    .team-card {
        width: calc(100% - 48px);
        margin: 0 24px;
    }
}

/* ====================================
   TESTIMONIALS SECTION
   ==================================== */

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

.testimonial-card {
    background: var(--white);
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 10px 30px var(--shadow);
    position: relative;
    transition: all 0.3s ease;
}

.testimonial-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px var(--shadow-hover);
}

.testimonial-rating {
    color: #fbbf24; /* Golden star color */
    margin-bottom: 20px;
    font-size: 0.9rem;
}

.testimonial-text {
    color: var(--slate);
    font-style: italic;
    line-height: 1.8;
    margin-bottom: 30px;
    font-size: 1.05rem;
    position: relative;
    z-index: 1;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 15px;
}

.testimonial-author img {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--primary-teal-light);
}

.author-name {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--deep-navy);
}

.author-role {
    color: var(--primary-teal);
    font-size: 0.85rem;
    font-weight: 600;
}

.quote-icon {
    position: absolute;
    bottom: 30px;
    right: 30px;
    font-size: 3rem;
    color: rgba(13, 148, 136, 0.05);
    z-index: 0;
}

/* ====================================
   FINAL CTA SECTION
   ==================================== */

.final-cta {
    background: linear-gradient(135deg, var(--deep-navy) 0%, var(--primary-teal-dark) 100%);
    padding: 100px 0;
    text-align: center;
    color: var(--white);
}

.cta-content h2 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 20px;
}

.cta-content p {
    font-size: 1.25rem;
    opacity: 0.9;
    max-width: 700px;
    margin: 0 auto 40px;
}

.btn-large {
    padding: 18px 48px;
    font-size: 1.1rem;
}

/* ====================================
   FOOTER SECTION
   ==================================== */

.footer {
    background-color: #0f172a; /* Even darker navy */
    color: var(--white);
    padding: 80px 0 30px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1.5fr 1.5fr;
    gap: 40px;
    margin-bottom: 60px;
}

.footer-logo {
    color: var(--white);
    margin-bottom: 20px;
}

.footer-description {
    color: #94a3b8;
    line-height: 1.8;
    margin-bottom: 25px;
}

.footer-socials {
    display: flex;
    gap: 15px;
}

.footer-socials a {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.footer-socials a:hover {
    background: var(--primary-teal);
    transform: translateY(-3px);
}

.footer h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 25px;
    position: relative;
    padding-bottom: 10px;
}

.footer h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 3px; /* Thicker accent line as per request! */
    background: var(--primary-teal);
}

.footer ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 15px;
}

.footer-links a {
    color: #94a3b8;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--primary-teal);
    padding-left: 5px;
}

.footer-hours li {
    display: flex;
    justify-content: space-between;
    margin-bottom: 12px;
    color: #94a3b8;
}

.emergency-text {
    margin-top: 20px;
    color: var(--primary-teal-light);
    font-size: 0.9rem;
    font-weight: 600;
}

.footer-contact li {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    color: #94a3b8;
}

.footer-contact a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-contact a:hover {
    color: var(--primary-teal);
}

.footer-contact i {
    color: var(--primary-teal);
    margin-top: 5px;
}

.footer-bottom {
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #64748b;
    font-size: 0.9rem;
}

.footer-legal {
    display: flex;
    gap: 20px;
}

.footer-legal a {
    color: #64748b;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-legal a:hover {
    color: var(--white);
}

@media (max-width: 1024px) {
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .footer-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }
}

/* ====================================
   APPOINTMENT PAGE (book.html)
   ==================================== */

.page-header {
    background: linear-gradient(135deg, var(--deep-navy) 0%, var(--primary-teal-dark) 100%);
    padding: 150px 0 80px;
    text-align: center;
    color: var(--white);
}

.page-header h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 15px;
}

.page-header p {
    font-size: 1.2rem;
    opacity: 0.9;
}

.booking-section {
    padding: 80px 0;
    margin-top: -60px;
}

.booking-container {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 40px;
    align-items: start;
}

.booking-info {
    background: var(--white);
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 10px 30px var(--shadow);
}

.booking-info h3 {
    font-size: 1.5rem;
    color: var(--deep-navy);
    margin-bottom: 25px;
}

.booking-features {
    list-style: none;
    margin-bottom: 30px;
}

.booking-features li {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 18px;
    color: var(--slate);
    font-weight: 500;
}

.booking-features li i {
    color: var(--primary-teal);
    font-size: 1.2rem;
}

.contact-box {
    padding: 20px;
    background: var(--light-gray);
    border-radius: 12px;
    border-left: 4px solid var(--primary-teal);
}

.contact-box p {
    font-size: 0.95rem;
    color: var(--deep-navy);
}

.contact-box i {
    color: var(--primary-teal);
    margin-right: 8px;
}

/* Form Styling */
.booking-form-card {
    background: var(--white);
    padding: 50px;
    border-radius: 20px;
    box-shadow: 0 15px 40px var(--shadow);
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 25px;
    margin-bottom: 25px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group.full-width {
    grid-column: 1 / -1;
}

.form-group label {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--deep-navy);
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-wrapper i {
    position: absolute;
    left: 18px;
    color: #94a3b8;
    transition: color 0.3s ease;
}

.input-wrapper input,
.input-wrapper select,
.input-wrapper textarea {
    width: 100%;
    padding: 14px 18px 14px 48px;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-family: inherit;
    font-size: 1rem;
    color: var(--deep-navy);
    transition: all 0.3s ease;
    background-color: #f8fafc;
}

.input-wrapper textarea {
    padding-top: 14px;
    resize: vertical;
}

.input-wrapper input:focus,
.input-wrapper select:focus,
.input-wrapper textarea:focus {
    outline: none;
    border-color: var(--primary-teal);
    background-color: var(--white);
    box-shadow: 0 0 0 4px rgba(13, 148, 136, 0.1);
}

.input-wrapper input:focus + i,
.input-wrapper select:focus + i,
.input-wrapper textarea:focus + i {
    color: var(--primary-teal);
}

/* Button & Loader States */
.btn-full {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 16px;
    font-size: 1.1rem;
    border: none;
    cursor: pointer;
}

.btn-loader {
    display: flex;
    align-items: center;
    gap: 10px;
}

.hidden {
    display: none !important;
}

.form-message {
    margin-top: 20px;
    padding: 15px;
    border-radius: 10px;
    text-align: center;
    font-weight: 500;
}

.form-message.success {
    background-color: #dcfce7;
    color: #166534;
    border: 1px solid #bbf7d0;
}

.form-message.error {
    background-color: #fee2e2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

/* Responsive Booking */
@media (max-width: 992px) {
    .booking-container {
        grid-template-columns: 1fr;
    }
    
    .booking-info {
        order: 2;
    }
    
    .booking-form-card {
        order: 1;
    }
}

@media (max-width: 640px) {
    .page-header h1 {
        font-size: 2.5rem;
    }
    
    .booking-form-card {
        padding: 30px 20px;
    }
    
    .form-grid {
        grid-template-columns: 1fr;
    }
}

/* ====================================
   ADMIN DASHBOARD (admin.html)
   ==================================== */

.login-card {
    max-width: 450px;
    margin: 100px auto;
    background: var(--white);
    padding: 50px;
    border-radius: 20px;
    box-shadow: 0 20px 50px var(--shadow);
    text-align: center;
}

.login-card h2 {
    font-size: 2rem;
    color: var(--deep-navy);
    margin-bottom: 10px;
}

.login-card p {
    color: var(--slate);
    margin-bottom: 30px;
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 40px;
}

.stat-card {
    background: var(--white);
    padding: 20px 30px;
    border-radius: 16px;
    box-shadow: 0 4px 15px var(--shadow);
    text-align: right;
}

.stat-label {
    display: block;
    font-size: 0.85rem;
    color: var(--slate);
    font-weight: 600;
    text-transform: uppercase;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-teal);
}

.dashboard-actions {
    display: flex;
    justify-content: space-between;
    margin-bottom: 25px;
    gap: 20px;
    flex-wrap: wrap;
}

.filters-container {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    flex-grow: 1;
}

.search-box {
    position: relative;
    flex-grow: 1;
    min-width: 250px;
    max-width: 400px;
}

.filter-select {
    padding: 12px 15px 12px 35px;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    font-family: 'Poppins', sans-serif;
    font-size: 0.95rem;
    color: var(--slate);
    background-color: var(--white);
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2394a3b8'%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: left 10px center;
    background-size: 18px;
    appearance: none;
    -webkit-appearance: none;
    transition: all 0.3s ease;
}

.filter-select:hover {
    border-color: var(--primary-teal);
}

.filter-select:focus {
    outline: none;
    border-color: var(--primary-teal);
    box-shadow: 0 0 0 3px rgba(13, 148, 136, 0.1);
}

.table-responsive-wrapper {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch; /* Forces native iOS physics deceleration */
    margin-top: 1rem;
    border-radius: 8px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

.table-responsive-wrapper table {
    min-width: 850px; /* Forces a stable baseline landscape layout context on mobile devices */
    width: 100%;
}

.search-box i {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
}

.search-box input {
    width: 100%;
    padding: 12px 15px 12px 45px;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    font-family: inherit;
}

.table-container {
    background: var(--white);
    border-radius: 20px;
    box-shadow: 0 10px 30px var(--shadow);
    overflow: hidden;
}

.appointments-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
}

.appointments-table th {
    background: #f8fafc;
    padding: 20px;
    font-weight: 600;
    color: var(--deep-navy);
    border-bottom: 2px solid #e2e8f0;
}

.appointments-table td {
    padding: 20px;
    border-bottom: 1px solid #f1f5f9;
    color: var(--slate);
    vertical-align: middle;
}

.appointments-table tr:last-child td {
    border-bottom: none;
}

.appointments-table tr:hover {
    background-color: #f8fafc;
}

.patient-name {
    font-weight: 600;
    color: var(--deep-navy);
    display: block;
}

.patient-email {
    font-size: 0.85rem;
    color: #64748b;
}

.patient-notes {
    font-size: 0.8rem;
    color: #6b7280; /* Subtle grey text */
    margin-top: 4px;
    max-width: 250px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis; /* Keeps long sentences neat with a ... trailing string */
    cursor: help;
}
/* Show the full note on hover */
.patient-notes:hover {
    white-space: normal;
    color: #1f2937;
}

.status-badge {
    padding: 6px 12px;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 600;
}

.status-pending { background: #fef3c7; color: #92400e; }
.status-confirmed { background: #dcfce7; color: #166534; }
.status-cancelled { background: #fee2e2; color: #991b1b; }

.btn-action {
    border: none;
    padding: 8px 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin: 0 4px;
}

.btn-confirm {
    background: #dcfce7;
    color: #166534;
}
.btn-confirm:hover {
    background: #166534;
    color: var(--white);
}

.btn-cancel {
    background: #fee2e2;
    color: #991b1b;
}
.btn-cancel:hover {
    background: #991b1b;
    color: var(--white);
}

.btn-delete {
    background: #fee2e2;
    color: #dc2626;
}

.btn-delete:hover {
    background: #dc2626;
    color: var(--white);
}

.text-center { text-align: center; }

@media (max-width: 768px) { 
    /* ===== RESET TO ROBUST MOBILE LAYOUT ===== */
    
    .slider-container, 
    .team-slider-container { 
        width: 100% !important; 
        max-width: 100% !important; 
        margin-left: 0 !important; 
        margin-right: 0 !important;
        padding: 0 !important;
        overflow: hidden !important; 
        position: relative !important;
    } 

    .slider-track .service-card, 
    .team-slider-track .team-card { 
        width: 100% !important; 
        min-width: 100% !important; 
        flex: 0 0 100% !important; 
        flex-shrink: 0 !important; 
        margin: 0 !important; 
        padding: 30px 20px !important; 
        box-sizing: border-box !important; 
        border-radius: 16px !important; /* Keep rounded corners for better UI */
    } 
 
    .slider-track, 
    .team-slider-track { 
        display: flex !important; 
        flex-direction: row !important; 
        flex-wrap: nowrap !important; 
        width: auto !important; /* Let children determine width */
    } 

    /* Navigation Fixes */
    .slider-arrow, .team-arrow {
        width: 36px !important;
        height: 36px !important;
        font-size: 0.8rem !important;
        top: 50% !important;
        transform: translateY(-50%) !important;
    }

    .slider-arrow--left, .team-arrow-left { left: -5px !important; }
    .slider-arrow--right, .team-arrow-right { right: -5px !important; }

    /* Team Image scaling fix */
    .team-image {
        height: 250px !important;
    }

    /* Final CTA Mobile Fix */
    .final-cta {
        padding: 60px 0 !important;
    }

    .cta-content h2 {
        font-size: 2rem !important;
    }

    .cta-content p {
        font-size: 1rem !important;
        margin-bottom: 30px !important;
    }

    .btn-large {
        padding: 15px 25px !important;
        font-size: 1rem !important;
        width: 100% !important;
        max-width: 300px !important;
        display: inline-block !important;
        white-space: normal !important; /* Allow text to wrap if necessary */
    }
}

/* Specific fix for ultra-small screens like iPhone SE (320px - 375px) */
@media (max-width: 480px) { 
    .slider-container, 
    .team-slider-container { 
        margin-left: -24px !important; 
        margin-right: -24px !important;
    }
    
    /* Ensure team images aren't too tall for small screens */
    .team-image {
        height: 280px !important;
    }

    .team-info {
        padding: 20px !important;
    }

    .btn-large {
        padding: 12px 20px !important;
        font-size: 0.95rem !important;
    }
}

/* Testimonials Grid */
.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 24px;
    margin-top: 20px;
}

.testimonials-form-wrapper {
    background: white;
    border-radius: 16px;
    padding: 32px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    border: 1px solid #e2e8f0;
    margin-top: 20px;
}

@media (max-width: 768px) {
    .testimonials-grid {
        grid-template-columns: 1fr;
    }
    
    .testimonials-form-wrapper {
        padding: 24px;
    }
}
