/**
 * GALLERY & VISUAL ENHANCEMENTS CSS
 * For clinic photos, service visuals, and image-rich sections
 * 
 * @package DrNaela
 * @version 2.0.0
 */

/* ====================
   GALLERY SECTION - PREMIUM
   ==================== */

.gallery-premium {
    padding: var(--space-xl) 0;
    position: relative;
    overflow: hidden;
}

.gallery-grid-premium {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 1.5rem;
    padding: 2rem 0;
}

/* Grid Item Sizes */
.gallery-item-large {
    grid-column: span 6;
    height: 500px;
}

.gallery-item-medium {
    grid-column: span 4;
    height: 350px;
}

.gallery-item-small {
    grid-column: span 3;
    height: 300px;
}

/* Gallery Item Styling */
.gallery-item-large,
.gallery-item-medium,
.gallery-item-small {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.gallery-item-large:hover,
.gallery-item-medium:hover,
.gallery-item-small:hover {
    transform: translateY(-10px);
    z-index: 2;
}

.gallery-item-large img,
.gallery-item-medium img,
.gallery-item-small img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease, filter 0.4s ease;
}

.gallery-item-large:hover img,
.gallery-item-medium:hover img,
.gallery-item-small:hover img {
    transform: scale(1.1);
    filter: brightness(1.1);
}

/* Gallery Overlay */
.gallery-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 2rem;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
    color: white;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.gallery-item-large:hover .gallery-overlay,
.gallery-item-medium:hover .gallery-overlay,
.gallery-item-small:hover .gallery-overlay {
    transform: translateY(0);
}

.gallery-overlay.glass-card {
    backdrop-filter: blur(20px) saturate(180%);
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.gallery-overlay h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: white;
}

.gallery-overlay p {
    font-size: 1rem;
    opacity: 0.9;
    margin: 0;
}

.gallery-icon {
    position: absolute;
    top: -3rem;
    right: 2rem;
    font-size: 3rem;
    opacity: 0;
    transition: opacity 0.4s ease, transform 0.4s ease;
}

.gallery-item-large:hover .gallery-icon,
.gallery-item-medium:hover .gallery-icon,
.gallery-item-small:hover .gallery-icon {
    opacity: 1;
    transform: translateY(-10px);
}

/* ====================
   SERVICE CARDS - VISUAL
   ==================== */

.services-grid-premium {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    padding: 2rem 0;
}

.service-card-visual {
    position: relative;
    height: 450px;
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.service-card-visual:hover {
    transform: translateY(-15px);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.2);
}

/* Service Card Background Image */
.service-card-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.service-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.service-card-visual:hover .service-card-image img {
    transform: scale(1.15);
}

/* Service Card Overlay Content */
.service-card-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 0%, transparent 70%);
    transition: background 0.4s ease;
}

.service-card-visual:hover .service-card-overlay {
    background: linear-gradient(to top, rgba(46, 80, 144, 0.95) 0%, rgba(136, 201, 193, 0.7) 100%);
}

.service-card-overlay.glass-card {
    backdrop-filter: blur(10px) saturate(150%);
    background: rgba(255, 255, 255, 0.1);
}

.service-card-overlay h3 {
    font-size: 1.75rem;
    font-weight: 700;
    color: white;
    margin-bottom: 0.75rem;
}

.service-card-overlay p {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 1rem;
}

.service-features {
    list-style: none;
    padding: 0;
    margin: 1rem 0;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s ease, transform 0.4s ease;
}

.service-card-visual:hover .service-features {
    opacity: 1;
    transform: translateY(0);
}

.service-features li {
    color: white;
    font-size: 0.95rem;
    padding: 0.4rem 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.service-features li::before {
    content: '✓';
    color: #88C9C1;
    font-weight: bold;
}

/* ====================
   HERO WITH BACKGROUND IMAGE
   ==================== */

.hero-premium {
    position: relative;
    min-height: 90vh;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.hero-bg-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.4) blur(2px);
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(46, 80, 144, 0.8) 0%, rgba(136, 201, 193, 0.6) 100%);
    z-index: 2;
}

.hero-content {
    position: relative;
    z-index: 3;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-text {
    color: white;
}

.hero-badge {
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    padding: 0.5rem 1.5rem;
    border-radius: var(--radius-full);
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.hero-title {
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    color: white;
}

.hero-subtitle {
    font-size: 1.25rem;
    opacity: 0.95;
    margin-bottom: 2rem;
    line-height: 1.6;
}

.hero-cta-group {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 3rem;
}

.hero-trust-badges {
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
}

.hero-trust-badges .badge {
    text-align: center;
}

.hero-trust-badges .badge .counter {
    font-size: 2.5rem;
    font-weight: 800;
    color: white;
    display: block;
}

.hero-trust-badges .badge p {
    font-size: 0.9rem;
    opacity: 0.9;
    margin: 0.5rem 0 0 0;
}

/* Hero Image */
.hero-image {
    position: relative;
}

.hero-doctor-image {
    width: 100%;
    border-radius: var(--radius-lg);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.4);
}

.hero-image-badge {
    position: absolute;
    top: 2rem;
    right: 2rem;
    background: white;
    color: #2E5090;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-full);
    font-weight: 700;
    font-size: 0.95rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

/* ====================
   ABOUT SECTION WITH IMAGE
   ==================== */

.about-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    padding: 4rem 0;
}

.about-image-container {
    position: relative;
}

.about-image-wrapper {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.about-image-wrapper img {
    width: 100%;
    border-radius: var(--radius-lg);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

.floating-badge {
    position: absolute;
    background: white;
    padding: 1rem 1.5rem;
    border-radius: var(--radius-lg);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    text-align: center;
}

.floating-badge.badge-1 {
    top: 2rem;
    right: -2rem;
}

.floating-badge.badge-2 {
    bottom: 2rem;
    left: -2rem;
}

.floating-badge .counter {
    font-size: 2rem;
    font-weight: 800;
    color: #2E5090;
    display: block;
}

.floating-badge p {
    font-size: 0.85rem;
    color: #666;
    margin: 0.5rem 0 0 0;
}

.credentials-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    margin: 2rem 0;
}

.credential-item {
    padding: 1.5rem;
    text-align: center;
    transition: transform 0.3s ease;
}

.credential-item:hover {
    transform: translateY(-5px);
}

.credential-icon {
    font-size: 2.5rem;
    display: block;
    margin-bottom: 1rem;
}

.credential-item h4 {
    font-size: 1.1rem;
    font-weight: 700;
    color: #2E5090;
    margin-bottom: 0.5rem;
}

.credential-item p {
    font-size: 0.9rem;
    color: #666;
    line-height: 1.5;
}

/* ====================
   FLOATING CTA BAR
   ==================== */

.floating-cta-bar {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9998;
    max-width: 900px;
    width: 90%;
    padding: 1.5rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideUpFade 0.6s ease forwards;
    animation-delay: 1s;
    opacity: 0;
}

@keyframes slideUpFade {
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

.floating-cta-bar.hidden {
    display: none;
}

.cta-content {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.cta-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #2E5090;
}

.cta-offer {
    font-size: 0.95rem;
    color: #88C9C1;
    font-weight: 600;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
}

/* ====================
   MOBILE CTA BAR
   ==================== */

.mobile-cta-sticky {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    padding: 1rem;
    z-index: 9999;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.1);
    gap: 0.5rem;
}

.mobile-cta-sticky .btn {
    flex: 1;
    text-align: center;
    padding: 1rem;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 0.95rem;
    border: none;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.mobile-cta-sticky .btn:active {
    transform: scale(0.95);
}

/* ====================
   TRUST BADGES SECTION
   ==================== */

.trust-badges {
    padding: 4rem 0;
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
}

.trust-title {
    text-align: center;
    font-size: 1.5rem;
    font-weight: 700;
    color: #2E5090;
    margin-bottom: 3rem;
}

.badges-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 2rem;
    align-items: center;
    justify-items: center;
}

.badge-item {
    text-align: center;
    transition: transform 0.3s ease;
}

.badge-item:hover {
    transform: scale(1.1);
}

.badge-item img {
    height: 80px;
    width: auto;
    object-fit: contain;
    margin-bottom: 1rem;
    filter: grayscale(100%);
    opacity: 0.7;
    transition: filter 0.3s ease, opacity 0.3s ease;
}

.badge-item:hover img {
    filter: grayscale(0%);
    opacity: 1;
}

.badge-item p {
    font-size: 0.85rem;
    color: #666;
    font-weight: 600;
}

/* ====================
   RESPONSIVE - TABLET
   ==================== */

@media (max-width: 1024px) {
    .gallery-item-large {
        grid-column: span 12;
        height: 400px;
    }
    
    .gallery-item-medium {
        grid-column: span 6;
        height: 300px;
    }
    
    .gallery-item-small {
        grid-column: span 4;
        height: 250px;
    }
    
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .hero-cta-group {
        justify-content: center;
    }
    
    .hero-trust-badges {
        justify-content: center;
    }
    
    .about-layout {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    
    .credentials-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ====================
   RESPONSIVE - MOBILE
   ==================== */

@media (max-width: 768px) {
    .gallery-grid-premium {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .gallery-item-large,
    .gallery-item-medium,
    .gallery-item-small {
        grid-column: span 1;
        height: 300px;
    }
    
    .services-grid-premium {
        grid-template-columns: 1fr;
    }
    
    .service-card-visual {
        height: 400px;
    }
    
    .hero-premium {
        min-height: 100vh;
    }
    
    .hero-content {
        padding: 2rem 1rem;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-cta-group {
        flex-direction: column;
        width: 100%;
    }
    
    .hero-cta-group .btn {
        width: 100%;
    }
    
    .hero-trust-badges {
        flex-direction: column;
        gap: 1rem;
    }
    
    .about-image-wrapper {
        margin-bottom: 2rem;
    }
    
    .floating-badge.badge-1,
    .floating-badge.badge-2 {
        position: static;
        margin: 1rem 0;
    }
    
    .credentials-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    /* Hide desktop floating bar on mobile */
    .floating-cta-bar {
        display: none;
    }
    
    /* Show mobile CTA bar */
    .mobile-cta-sticky {
        display: flex;
    }
    
    /* Add padding to body to prevent content hiding */
    body {
        padding-bottom: 80px;
    }
    
    .badges-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }
    
    .badge-item img {
        height: 60px;
    }
}

/* ====================
   PRINT STYLES
   ==================== */

@media print {
    .floating-cta-bar,
    .mobile-cta-sticky,
    .gallery-icon,
    .hero-overlay {
        display: none;
    }
    
    .hero-bg-image {
        filter: none;
    }
}

/* ====================
   ACCESSIBILITY
   ==================== */

/* Reduced motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .floating,
    .floating-slow,
    .pulse-glow {
        animation: none;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .glass-card,
    .glass-card-dark {
        backdrop-filter: none;
        background: white;
        border: 2px solid black;
    }
    
    .gallery-overlay,
    .service-card-overlay {
        background: black;
        color: white;
    }
}

/* ====================
   LAZY LOADING STATES
   ==================== */

img[loading="lazy"] {
    opacity: 0;
    transition: opacity 0.3s ease;
}

img[loading="lazy"].loaded {
    opacity: 1;
}

/* Skeleton loading for images */
.skeleton-loader {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s ease-in-out infinite;
}

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

