/* ═══════════════════════════════════════════════════════════════════════════
   OFM Hospital - Global Styles
   Single CSS file for all pages (Hub + Landing Pages)
   ═══════════════════════════════════════════════════════════════════════════ */

/* ─────────────────────────────────────────────────────────────────────────────
   BASE STYLES
   ───────────────────────────────────────────────────────────────────────────── */

html {
    scroll-behavior: smooth;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

/* Focus styles for accessibility */
*:focus-visible {
    outline: 2px solid #1F4E79;
    outline-offset: 2px;
}

/* Hide scrollbar utility */
.scrollbar-hide {
    -ms-overflow-style: none;
    scrollbar-width: none;
}
.scrollbar-hide::-webkit-scrollbar {
    display: none;
}

/* ─────────────────────────────────────────────────────────────────────────────
   HEADER & NAVIGATION
   ───────────────────────────────────────────────────────────────────────────── */

.glass-effect {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.header-scrolled {
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
}

/* Mobile menu animation */
.mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

.mobile-menu.open {
    max-height: 400px;
}

/* ─────────────────────────────────────────────────────────────────────────────
   HERO SECTIONS
   ───────────────────────────────────────────────────────────────────────────── */

/* Hub Hero gradient */
.hero-gradient-hub {
    background: linear-gradient(135deg, #0B1E35 0%, #1F4E79 50%, #153657 100%);
}

/* Branch-specific hero gradients */
.hero-gradient-dental {
    background: linear-gradient(135deg, #0B1E35 0%, #1F4E79 100%);
}

.hero-gradient-obesity {
    background: linear-gradient(135deg, #14532D 0%, #15803D 50%, #166534 100%);
}

.hero-gradient-rhinoplasty {
    background: linear-gradient(135deg, #881337 0%, #BE123C 50%, #9F1239 100%);
}

.hero-gradient-plastic {
    background: linear-gradient(135deg, #4C1D95 0%, #6D28D9 50%, #5B21B6 100%);
}

/* Text gradient effect */
.text-gradient {
    background: linear-gradient(135deg, #E8930C, #D4A574);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.text-gradient-green {
    background: linear-gradient(135deg, #22C55E, #14B8A6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.text-gradient-rose {
    background: linear-gradient(135deg, #F43F5E, #EC4899);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.text-gradient-violet {
    background: linear-gradient(135deg, #8B5CF6, #A855F7);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ─────────────────────────────────────────────────────────────────────────────
   BUTTONS & INTERACTIONS
   ───────────────────────────────────────────────────────────────────────────── */

/* Tap target for mobile accessibility */
.tap-target {
    min-height: 44px;
    min-width: 44px;
}

/* Button hover effects */
.btn-primary {
    transition: all 0.2s ease;
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(31, 78, 121, 0.3);
}

.btn-whatsapp {
    transition: all 0.2s ease;
}

.btn-whatsapp:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.3);
}

/* ─────────────────────────────────────────────────────────────────────────────
   CARDS & CONTAINERS
   ───────────────────────────────────────────────────────────────────────────── */

.card-hover {
    transition: all 0.3s ease;
}

.card-hover:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.1);
}

/* Glass card effect */
.glass-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

/* ─────────────────────────────────────────────────────────────────────────────
   FAQ ACCORDION
   ───────────────────────────────────────────────────────────────────────────── */

.faq-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out, padding 0.3s ease-out;
}

.faq-content.open {
    max-height: 500px;
}

.faq-icon {
    transition: transform 0.3s ease;
}

.faq-toggle[aria-expanded="true"] .faq-icon {
    transform: rotate(180deg);
}

/* ─────────────────────────────────────────────────────────────────────────────
   FORM STYLES
   ───────────────────────────────────────────────────────────────────────────── */

/* Treatment selection cards */
.treatment-option input:checked + div {
    border-color: #1F4E79;
    background-color: #EEF4F9;
}

/* Form step transitions */
.form-step {
    animation: fadeIn 0.3s ease-out;
}

.form-step.hidden {
    display: none;
}

/* Input focus states */
input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: #1F4E79;
    box-shadow: 0 0 0 3px rgba(31, 78, 121, 0.1);
}

/* Step indicator */
.step-indicator {
    transition: all 0.3s ease;
}

.step-indicator.active {
    background-color: #1F4E79;
}

.step-indicator.completed {
    background-color: #22C55E;
}

/* ─────────────────────────────────────────────────────────────────────────────
   STICKY ELEMENTS
   ───────────────────────────────────────────────────────────────────────────── */

/* Sticky mobile CTA */
.sticky-mobile-cta {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 40;
    transform: translateY(100%);
    transition: transform 0.3s ease;
    padding-bottom: env(safe-area-inset-bottom);
}

.sticky-mobile-cta.visible {
    transform: translateY(0);
}

/* WhatsApp floating widget */
.whatsapp-widget {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 50;
    transition: all 0.3s ease;
}

.whatsapp-widget:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 24px rgba(34, 197, 94, 0.4);
}

/* ─────────────────────────────────────────────────────────────────────────────
   COUNTDOWN & TRUST BARS
   ───────────────────────────────────────────────────────────────────────────── */

.countdown-bar {
    background: linear-gradient(90deg, #E8930C, #D4A574);
}

.trust-bar {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(8px);
}

/* ─────────────────────────────────────────────────────────────────────────────
   ANIMATIONS
   ───────────────────────────────────────────────────────────────────────────── */

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

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

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

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

/* Animation delays */
.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }
.delay-400 { animation-delay: 0.4s; }
.delay-500 { animation-delay: 0.5s; }

/* Animation classes */
.animate-fade-in { animation: fadeIn 0.6s ease-out forwards; }
.animate-fade-in-up { animation: fadeInUp 0.6s ease-out forwards; }
.animate-slide-up { animation: slideUp 0.5s ease-out forwards; }

/* Initially hidden for animation */
[class*="animate-"]:not(.animate-pulse) {
    opacity: 0;
}

/* ─────────────────────────────────────────────────────────────────────────────
   TIMELINE / JOURNEY SECTION
   ───────────────────────────────────────────────────────────────────────────── */

.timeline-line {
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(180deg, #1F4E79 0%, #E8930C 100%);
    transform: translateX(-50%);
}

.timeline-dot {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: white;
    z-index: 10;
}

/* ─────────────────────────────────────────────────────────────────────────────
   BEFORE/AFTER GALLERY
   ───────────────────────────────────────────────────────────────────────────── */

.before-after-slider {
    position: relative;
    overflow: hidden;
}

.before-after-slider input[type="range"] {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: ew-resize;
    z-index: 10;
}

/* ─────────────────────────────────────────────────────────────────────────────
   COMPARISON TABLE
   ───────────────────────────────────────────────────────────────────────────── */

.comparison-table {
    border-collapse: separate;
    border-spacing: 0;
}

.comparison-table th,
.comparison-table td {
    border-bottom: 1px solid #E5E7EB;
}

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

/* ─────────────────────────────────────────────────────────────────────────────
   TESTIMONIAL CARDS
   ───────────────────────────────────────────────────────────────────────────── */

.testimonial-card {
    position: relative;
}

.testimonial-card::before {
    content: '"';
    position: absolute;
    top: -10px;
    left: 20px;
    font-size: 80px;
    font-family: Georgia, serif;
    color: #E8930C;
    opacity: 0.2;
    line-height: 1;
}

/* ─────────────────────────────────────────────────────────────────────────────
   LOADING & SKELETON STATES
   ───────────────────────────────────────────────────────────────────────────── */

.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: skeleton 1.5s infinite;
}

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

/* ─────────────────────────────────────────────────────────────────────────────
   RESPONSIVE UTILITIES
   ───────────────────────────────────────────────────────────────────────────── */

/* Safe area for iOS notch */
.safe-area-bottom {
    padding-bottom: env(safe-area-inset-bottom);
}

.safe-area-top {
    padding-top: env(safe-area-inset-top);
}

/* Hide scrollbar but keep functionality */
.no-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.no-scrollbar::-webkit-scrollbar {
    display: none;
}

/* ─────────────────────────────────────────────────────────────────────────────
   PRINT STYLES
   ───────────────────────────────────────────────────────────────────────────── */

@media print {
    .no-print,
    .sticky-mobile-cta,
    .whatsapp-widget,
    header,
    .countdown-bar,
    .trust-bar {
        display: none !important;
    }
    
    body {
        font-size: 12pt;
        line-height: 1.5;
    }
    
    a[href]::after {
        content: " (" attr(href) ")";
    }
}

/* ─────────────────────────────────────────────────────────────────────────────
   BRANCH-SPECIFIC OVERRIDES
   ───────────────────────────────────────────────────────────────────────────── */

/* Dental page */
[data-page="dental"] .treatment-option input:checked + div {
    border-color: #0EA5E9;
    background-color: #F0F9FF;
}

/* Obesity page */
[data-page="obesity"] .treatment-option input:checked + div {
    border-color: #22C55E;
    background-color: #F0FDF4;
}

/* Rhinoplasty page */
[data-page="rhinoplasty"] .treatment-option input:checked + div {
    border-color: #F43F5E;
    background-color: #FFF1F2;
}

/* Plastic surgery page */
[data-page="plastic"] .treatment-option input:checked + div {
    border-color: #8B5CF6;
    background-color: #F5F3FF;
}
