/* Janatha Dental Clinic - Comprehensive Redesign */

:root {
    --primary: #0284c7; 
    --primary-dark: #0369a1;
    --primary-light: #e0f2fe;
    --secondary: #0ea5e9; 
    --whatsapp: #25D366;
    
    --text-main: #0f172a;
    --text-muted: #475569;
    --text-light: #f8fafc;
    
    --bg-main: #ffffff;
    --bg-light: #f8fafc; 
    --bg-dark: #0f172a;
    --blue-gradient: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);

    --border: #e2e8f0;

    --shadow-sm: 0 1px 3px rgba(0,0,0,0.1);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -1px rgba(0,0,0,0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -2px rgba(0,0,0,0.05);
    
    --radius-sm: 0.5rem;
    --radius-md: 1rem;
    --radius-lg: 1.5rem;
    
    --transition: all 0.3s ease;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    font-family: 'Familjen Grotesk', 'Inter', sans-serif;
    color: var(--text-main);
    background-color: var(--bg-main);
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, h4, .logo-text, .hero-title { font-family: 'Familjen Grotesk', 'Outfit', sans-serif; }
a { text-decoration: none; color: inherit; }
img { max-width: 100%; height: auto; display: block; }
ul { list-style: none; }

.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }
.section-padding { padding: 5rem 0; }
.text-center { text-align: center; }
.w-100 { width: 100%; }
.mt-2 { margin-top: 1rem; }
.mt-4 { margin-top: 2rem; }
.bg-light { background-color: var(--bg-light); }

/* Responsive Visibility Rules */
@media (min-width: 769px) {
    .desktop-only { display: block !important; }
    .desktop-only.btn { display: inline-flex !important; }
    .mobile-only { display: none !important; }
    .mobile-only.btn { display: none !important; }
}

@media (max-width: 768px) {
    .desktop-only { display: none !important; }
    .desktop-only.btn { display: none !important; }
    .mobile-only { display: block !important; }
    .mobile-only.btn { display: inline-flex !important; }
}

/* Unmissable Pulsing & Shimmering CTA Animation */
@keyframes ctaPulseGlow {
    0% { box-shadow: 0 0 0 0 rgba(2, 132, 199, 0.7); transform: scale(1); }
    50% { box-shadow: 0 0 25px 8px rgba(2, 132, 199, 0.45); transform: scale(1.02); }
    100% { box-shadow: 0 0 0 0 rgba(2, 132, 199, 0.7); transform: scale(1); }
}

@keyframes ctaShimmerBeam {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

.btn-animated-cta {
    position: relative !important;
    overflow: hidden !important;
    width: 100% !important;
    background: linear-gradient(90deg, #0284c7 0%, #38bdf8 25%, #ffffff 50%, #38bdf8 75%, #0284c7 100%) !important;
    background-size: 200% 100% !important;
    color: #ffffff !important;
    font-size: 1.15rem !important;
    font-weight: 800 !important;
    padding: 1.1rem 1.5rem !important;
    border-radius: 14px !important;
    border: none !important;
    cursor: pointer !important;
    animation: ctaShimmerBeam 2.5s infinite linear, ctaPulseGlow 2s infinite ease-in-out !important;
    transition: all 0.3s ease !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.btn-animated-cta:hover {
    transform: translateY(-3px) scale(1.03) !important;
}

/* Glass Form Container & Header */
.glass-form {
    position: relative;
    background: #ffffff;
    border-radius: 28px;
    padding: 2.25rem 2rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    color: var(--text-main);
    z-index: 1;
}

.form-header-gradient {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 120px;
    background: linear-gradient(180deg, rgba(224, 242, 254, 0.6) 0%, rgba(255, 255, 255, 0) 100%);
    border-radius: 28px 28px 0 0;
    pointer-events: none;
    z-index: 0;
}

.form-pill-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: rgba(30, 58, 138, 0.08);
    color: #1d4ed8;
    font-weight: 700;
    font-size: 0.75rem;
    padding: 0.4rem 1rem;
    border-radius: 30px;
    letter-spacing: 0.5px;
    margin-bottom: 1rem;
}

.form-dual-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.85rem;
    margin-top: 1rem;
}

.btn-whatsapp-green {
    background: #22c55e !important;
    color: #ffffff !important;
    font-weight: 800 !important;
    font-size: 1.05rem !important;
    padding: 1rem !important;
    border-radius: 14px !important;
    text-align: center !important;
    text-decoration: none !important;
    box-shadow: 0 4px 14px rgba(34, 197, 94, 0.3) !important;
    transition: all 0.3s ease !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}
.btn-whatsapp-green:hover { background: #16a34a !important; transform: translateY(-2px); }

.btn-outline-call {
    background: #ffffff !important;
    color: #0f172a !important;
    border: 1.5px solid #cbd5e1 !important;
    font-weight: 800 !important;
    font-size: 1.05rem !important;
    padding: 1rem !important;
    border-radius: 14px !important;
    text-align: center !important;
    text-decoration: none !important;
    transition: all 0.3s ease !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}
.btn-outline-call:hover { border-color: var(--primary) !important; color: var(--primary) !important; transform: translateY(-2px); }

/* Everything Handled Grid */
.handled-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 2rem; margin-top: 3rem;
}
.handled-card {
    background: white; border-radius: var(--radius-md); overflow: hidden;
    box-shadow: var(--shadow-sm); border: 1px solid var(--border); transition: var(--transition);
}
.handled-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.handled-card-img { width: 100%; height: 200px; object-fit: cover; }
.handled-card-content { padding: 1.5rem; }
.handled-bad-tag { color: #dc2626; font-size: 0.85rem; font-weight: 600; margin-bottom: 0.3rem; display: block; }
.handled-card-content h3 { font-size: 1.35rem; font-weight: 700; color: #0f172a; margin-bottom: 0.5rem; }
.handled-card-content p { font-size: 0.925rem; color: #475569; line-height: 1.5; }

/* Cosmetic & Restorative Dentistry Cards */
.category-block { margin-bottom: 3.5rem; }
.category-title-bar { display: flex; align-items: center; gap: 1rem; margin-bottom: 1.5rem; }
.category-icon {
    width: 48px; height: 48px; border-radius: 12px; background: #e0f2fe; color: #0284c7;
    display: flex; align-items: center; justify-content: center; font-size: 1.5rem;
}
.category-info h3 { font-size: 1.75rem; font-weight: 800; color: #0f172a; }
.category-info p { font-size: 0.95rem; color: #64748b; }

.treatment-cards-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1.5rem;
}
.treatment-item-card {
    background: white; border-radius: var(--radius-md); padding: 1.75rem;
    border: 1px solid #f1f5f9; box-shadow: var(--shadow-sm); transition: var(--transition);
    display: flex; flex-direction: column; justify-content: space-between;
}
.treatment-item-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: #cbd5e1; }
.treatment-icon-small {
    width: 40px; height: 40px; border-radius: 10px; background: #f0f9ff; color: #0284c7;
    display: flex; align-items: center; justify-content: center; font-size: 1.25rem; margin-bottom: 1rem;
}
.treatment-item-card h4 { font-size: 1.25rem; font-weight: 700; color: #0f172a; margin-bottom: 0.4rem; }
.treatment-item-card p { font-size: 0.9rem; color: #475569; margin-bottom: 1.5rem; }
.treatment-card-footer { display: flex; justify-content: space-between; align-items: center; border-top: 1px solid #f1f5f9; pt-3; font-size: 0.85rem; }
.treatment-tag { color: #64748b; font-weight: 500; }
.treatment-cta-link { color: #ea580c; font-weight: 700; text-decoration: none; display: flex; align-items: center; gap: 0.25rem; }
.treatment-cta-link:hover { color: #c2410c; }

/* Floating WhatsApp */
.floating-whatsapp {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background-color: var(--whatsapp);
    color: white;
    width: 65px;
    height: 65px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    box-shadow: 0 4px 10px rgba(37, 211, 102, 0.4);
    z-index: 9999;
    transition: var(--transition);
}
.floating-whatsapp:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 6px 15px rgba(37, 211, 102, 0.6);
}

/* Header */
.header {
    position: fixed; top: 0; left: 0; width: 100%;
    background-color: rgba(255, 255, 255, 0.98); backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border); z-index: 1000; transition: var(--transition);
}
.header.scrolled { box-shadow: var(--shadow-sm); }
.header-content { display: flex; justify-content: space-between; align-items: center; height: 80px; }
.logo { display: flex; align-items: center; gap: 0.75rem; }
.logo i { font-size: 2.5rem; color: var(--primary); }
.logo-text h1 { font-size: 1.25rem; font-weight: 700; line-height: 1.1; color: var(--primary-dark); }
.logo-text span { font-size: 0.85rem; color: var(--text-muted); font-weight: 500; text-transform: uppercase; letter-spacing: 1px; }
.header-contact { display: flex; align-items: center; gap: 1.5rem; }
.contact-info { text-align: right; }
.contact-info .label { display: block; font-size: 0.75rem; color: var(--text-muted); margin-bottom: 0.1rem; }
.contact-info .phone-number { font-size: 1.125rem; font-weight: 700; color: var(--primary); display: flex; align-items: center; gap: 0.5rem; }

/* Hero */
.hero-full {
    position: relative; min-height: 90vh; padding-top: 100px; display: flex; align-items: center;
}
.hero-bg-image {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background-size: cover; background-position: center; z-index: -2;
}
.hero-overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(to right, rgba(15, 23, 42, 0.9) 0%, rgba(15, 23, 42, 0.6) 50%, rgba(15, 23, 42, 0.3) 100%);
    z-index: -1;
}
.hero-container {
    display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 3rem; align-items: center; color: white;
}
.trust-badge { margin-bottom: 1rem; }
.trust-badge span {
    background: rgba(255,255,255,0.2); backdrop-filter: blur(4px);
    padding: 0.4rem 1rem; border-radius: 2rem; font-size: 0.875rem; font-weight: 600; letter-spacing: 1px;
}
.hero-title { font-size: 4rem; font-weight: 800; line-height: 1.1; margin-bottom: 1rem; text-transform: uppercase; }
.hero-subtitle { font-size: 1.75rem; font-weight: 400; color: #e2e8f0; margin-bottom: 1.5rem; }
.hero-trust-strip {
    font-size: 1.125rem; font-weight: 500; background: rgba(0,0,0,0.4);
    padding: 1rem; border-left: 4px solid var(--primary); margin-bottom: 2rem; border-radius: 0 4px 4px 0;
}

/* Form */
.glass-form {
    background: white; border-radius: var(--radius-md); padding: 2rem;
    box-shadow: 0 20px 25px -5px rgba(0,0,0,0.2); color: var(--text-main);
}
.form-header { text-align: center; margin-bottom: 1.5rem; }
.form-header h3 { font-size: 1.5rem; font-weight: 700; color: var(--primary-dark); }
.form-header p { font-size: 0.9rem; color: var(--text-muted); }
.input-group { margin-bottom: 1rem; }
.input-group input, .input-group select {
    width: 100%; padding: 1rem; border: 1px solid var(--border); border-radius: var(--radius-sm);
    font-family: inherit; font-size: 1rem; background-color: var(--bg-light); transition: var(--transition);
}
.input-group input:focus, .input-group select:focus { outline: none; border-color: var(--primary); background-color: white; }
.btn-submit { font-size: 1.125rem; padding: 1rem; }

/* Stats Bar */
.stats-bar {
    background: var(--primary-dark);
    color: white;
    padding: 2.5rem 0;
}
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    text-align: center;
}
.stat-item h3 { font-size: 2.5rem; font-weight: 800; color: var(--secondary); margin-bottom: 0.5rem; }
.stat-item p { font-size: 1.1rem; font-weight: 500; text-transform: uppercase; letter-spacing: 1px; }

/* Section Headers */
.section-header { margin-bottom: 3rem; }
.subheading { display: block; font-size: 0.875rem; font-weight: 700; color: var(--primary); text-transform: uppercase; letter-spacing: 2px; margin-bottom: 0.5rem; }
.section-header h2 { font-size: 2.5rem; font-weight: 800; margin-bottom: 1rem; text-transform: uppercase;}
.section-header p { color: var(--text-muted); font-size: 1.125rem; }

/* Meet Doctor */
.doctor-profile {
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 4rem;
    align-items: center;
    background: white;
    padding: 3rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
}
.doctor-img img {
    width: 100%;
    height: 400px;
    object-fit: cover;
    object-position: top center;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-md);
}
.doctor-bio h3 { font-size: 2.5rem; color: var(--primary-dark); margin-bottom: 0.25rem; }
.doctor-title { display: block; font-weight: 600; font-size: 1.1rem; color: var(--secondary); margin-bottom: 1rem; text-transform: uppercase; letter-spacing: 1px;}
.doctor-bio p { color: var(--text-muted); font-size: 1.15rem; margin-bottom: 1.5rem; line-height: 1.8; }
.doctor-highlights li { display: flex; align-items: center; gap: 0.5rem; font-size: 1.05rem; font-weight: 500; margin-bottom: 0.75rem; }
.doctor-highlights i { color: var(--whatsapp); font-size: 1.5rem; }

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
}
.team-card {
    text-align: center;
    background: white;
    padding: 1.5rem;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
}
.team-card img {
    width: 120px; height: 120px; object-fit: cover; object-position: top center; border-radius: 50%;
    box-shadow: var(--shadow-md); border: 4px solid white; margin: 0 auto 1rem auto;
}
.team-card h4 { font-size: 1.125rem; color: var(--primary-dark); margin-bottom: 0.25rem; }
.team-card p { font-size: 0.9rem; color: var(--text-muted); font-weight: 500; }

/* Services Layout */
.services-list { display: flex; flex-direction: column; gap: 4rem; }
.service-row { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center; }
.service-row.reverse .service-row-img { order: 2; }
.service-row.reverse .service-row-content { order: 1; }
.service-row-img img { border-radius: var(--radius-lg); box-shadow: var(--shadow-md); }
.service-row-content h3 { font-size: 2rem; margin-bottom: 1rem; color: var(--primary-dark); }
.service-row-content p { font-size: 1.125rem; color: var(--text-muted); margin-bottom: 1.5rem; }
.service-checkmarks { margin-bottom: 2rem; }
.service-checkmarks li { display: flex; align-items: center; gap: 0.75rem; font-size: 1.05rem; font-weight: 500; margin-bottom: 0.75rem; }
.service-checkmarks i { color: var(--whatsapp); font-size: 1.5rem; }

/* Horizontal Scroll Tracks */
.scroll-wrapper { width: 100%; position: relative; }
.ba-grid, .facility-grid, .awards-grid {
    display: flex;
    overflow-x: auto;
    gap: 1.5rem;
    padding-bottom: 1.5rem;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none; /* Firefox */
    cursor: grab;
}
.ba-grid:active, .facility-grid:active, .awards-grid:active { cursor: grabbing; }
.ba-grid::-webkit-scrollbar, .facility-grid::-webkit-scrollbar, .awards-grid::-webkit-scrollbar { display: none; }

.ba-grid > *, .facility-grid > *, .awards-grid > * { flex: 0 0 auto; }

/* Before/After Cards */
.ba-card { width: 300px; background: white; border-radius: var(--radius-sm); overflow: hidden; box-shadow: var(--shadow-sm); border: 1px solid var(--border); transition: var(--transition); }
.ba-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }

/* Facility Grid (Perfectly Aligned) */
.facility-grid img { 
    width: 350px; 
    height: 262px; /* 4:3 aspect */
    object-fit: cover; 
    border-radius: 8px; 
    box-shadow: var(--shadow-sm);
    transition: var(--transition); 
}
.facility-grid img:hover { transform: scale(1.02); box-shadow: var(--shadow-lg); }

/* Awards Grid */
.awards-grid img { width: 250px; height: auto; border-radius: 4px; box-shadow: var(--shadow-sm); border: 1px solid var(--border); }

/* Reviews */
.reviews-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 2rem; }
.review-card {
    background: white; padding: 2rem; border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm); border: 1px solid var(--border);
}
.review-header { display: flex; align-items: center; gap: 1rem; margin-bottom: 1rem; }
.author-avatar {
    width: 45px; height: 45px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 1.25rem;
}
.review-meta strong { display: block; color: var(--text-main); font-size: 1rem; line-height: 1.2; }
.review-stars { color: #fbbf24; font-size: 1.1rem; margin-top: 0.2rem; }
.review-text { color: var(--text-muted); font-size: 1rem; line-height: 1.6; }

/* FAQ */
.faq-container { max-width: 800px; margin: 0 auto; }
.faq-item { background: white; margin-bottom: 1rem; border-radius: var(--radius-sm); border: 1px solid var(--border); overflow: hidden; }
.faq-question {
    width: 100%; text-align: left; padding: 1.5rem; background: none; border: none;
    font-size: 1.125rem; font-weight: 600; color: var(--text-main); cursor: pointer;
    display: flex; justify-content: space-between; align-items: center; font-family: inherit;
}
.faq-question i { transition: var(--transition); }
.faq-answer { padding: 0 1.5rem; max-height: 0; overflow: hidden; transition: max-height 0.3s ease-out; }
.faq-answer p { padding-bottom: 1.5rem; color: var(--text-muted); }
.faq-item.active .faq-question i { transform: rotate(180deg); color: var(--primary); }
.faq-item.active .faq-answer { max-height: 300px; } /* Arbitrary large max-height for animation */

/* Bottom CTA & Footer */
.bottom-cta { background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%); color: white; }
.bottom-cta h2 { font-size: 2.5rem; margin-bottom: 1rem; }
.bottom-cta p { font-size: 1.25rem; opacity: 0.9; margin-bottom: 2.5rem; }
.cta-buttons { display: flex; justify-content: center; gap: 1rem; }
.bottom-cta .btn-outline { border-color: rgba(255, 255, 255, 0.5); color: white; }
.bottom-cta .btn-outline:hover { border-color: white; background: rgba(255, 255, 255, 0.1); }
.bottom-cta .btn-primary { background-color: white; color: var(--primary-dark); }

.footer { background-color: var(--bg-dark); color: var(--text-light); padding-top: 4rem; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 4rem; margin-bottom: 3rem; }
.footer-info p { margin-top: 1.5rem; color: #94a3b8; max-width: 300px; }
.footer h4 { font-size: 1.125rem; margin-bottom: 1.5rem; font-weight: 600; }
.footer-contact p { display: flex; gap: 0.75rem; color: #94a3b8; margin-bottom: 1rem; line-height: 1.5; }
.footer-contact i { color: var(--secondary); font-size: 1.25rem; margin-top: 0.25rem; }
.footer-hours ul li { display: flex; justify-content: space-between; color: #94a3b8; margin-bottom: 0.75rem; padding-bottom: 0.75rem; border-bottom: 1px solid rgba(255,255,255,0.1); }
.footer-hours span { font-weight: 600; color: white; }
.footer-bottom { background-color: #020617; padding: 1.5rem 0; text-align: center; color: #64748b; font-size: 0.875rem; }

/* Responsive */
@media (max-width: 992px) {
    .hero-container { grid-template-columns: 1fr; text-align: center; }
    .hero-overlay { background: rgba(15, 23, 42, 0.75); }
    .hero-trust-strip { border-left: none; border-top: 4px solid var(--primary); border-radius: 4px; }
    
    .stats-grid { grid-template-columns: 1fr 1fr; }
    .doctor-profile { grid-template-columns: 1fr; gap: 2rem; }
    
    .service-row { grid-template-columns: 1fr; gap: 2rem; }
    .service-row.reverse .service-row-img { order: 1; }
    .service-row.reverse .service-row-content { order: 2; }
    
    .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
    .desktop-only { display: none !important; }
    .desktop-only.btn { display: none !important; }
    .mobile-only { display: block !important; }
    .mobile-only.btn { display: inline-flex !important; white-space: nowrap !important; flex-shrink: 0 !important; }
    .header-content { height: 65px; padding: 0 0.85rem; justify-content: space-between; gap: 0.5rem; }
    .logo img { height: 36px !important; }
    .logo-text span { display: none !important; }
    .logo-text strong { font-size: 0.9rem !important; line-height: 1.1; display: block; }
    
    .hero-full { min-height: auto; padding-top: 85px; padding-bottom: 3rem; }
    .hero-title { font-size: 2.2rem; margin-top: 1rem; }
    .hero-subtitle { font-size: 1.15rem; }
    
    .stats-bar { padding: 2rem 0; }
    .stats-grid { grid-template-columns: 1fr 1fr; gap: 1.5rem 1rem; }
    .stat-item h3 { font-size: 1.8rem; }
    .stat-item p { font-size: 0.85rem; line-height: 1.2; }
    
    .glass-form { padding: 1.5rem; }
    .cta-buttons { flex-direction: column; }
    .footer-grid { grid-template-columns: 1fr; gap: 2rem; }
    .floating-whatsapp { bottom: 1.5rem; right: 1.5rem; width: 55px; height: 55px; font-size: 2rem; }
}
