/* Custom CSS for Dr. Ramin Mirza Website */

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Custom Animations */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
        opacity: 0.7;
    }
    50% {
        transform: translateY(-20px);
        opacity: 1;
    }
}

@keyframes spin-slow {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* Animation Classes */
.animate-float {
    animation: float 6s ease-in-out infinite;
}

.animate-spin-slow {
    animation: spin-slow 20s linear infinite;
}

/* Particle Animation */
.particle {
    animation: float 8s ease-in-out infinite;
}

.particle:nth-child(1) { animation-delay: 0s; }
.particle:nth-child(2) { animation-delay: 1s; }
.particle:nth-child(3) { animation-delay: 2s; }
.particle:nth-child(4) { animation-delay: 3s; }
.particle:nth-child(5) { animation-delay: 4s; }

/* Custom Gradient Text */
.gradient-text {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f5f9;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #2563eb, #1e40af);
}

/* Gallery hover effects */
.gallery-item {
    transition: all 0.3s ease;
}

.gallery-item:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.gallery-item img {
    transition: transform 0.3s ease;
}

.gallery-item:hover img {
    transform: scale(1.1);
}

/* Custom animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

/* Custom button hover effects */
.btn-hover {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-hover::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.btn-hover:hover::before {
    left: 100%;
}

/* Custom card hover effects */
.card-hover {
    transition: all 0.3s ease;
}

.card-hover:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

/* Custom gradient backgrounds */
.gradient-blue {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.gradient-green {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.gradient-purple {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #3b82f6;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #2563eb;
}

/* Mobile optimizations */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.5rem;
    }
}

/* Print styles */
@media print {
    .no-print {
        display: none !important;
    }
}

/* Loading animation */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255,255,255,.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Custom form styles */
.form-input:focus {
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
    border-color: #3b82f6;
}

/* Custom navigation styles */
.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -2px;
    left: 50%;
    background-color: #3b82f6;
    transition: all 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
    left: 0;
}

/* Custom service card styles */
.service-card {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, transparent, rgba(255,255,255,0.1), transparent);
    transform: translateX(-100%);
    transition: transform 0.6s;
}

.service-card:hover::before {
    transform: translateX(100%);
}

/* Custom footer styles */
.footer-link {
    transition: all 0.3s ease;
}

.footer-link:hover {
    color: #3b82f6;
    transform: translateX(5px);
}

/* Custom hero section styles */
.hero-bg {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    position: relative;
}

.hero-bg::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="50" cy="50" r="1" fill="white" opacity="0.1"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.1;
}

/* Custom section spacing */
.section-padding {
    padding: 5rem 0;
}

@media (max-width: 768px) {
    .section-padding {
        padding: 3rem 0;
    }
}

/* Image alignment fixes */
.aspect-video {
    display: flex;
    align-items: center;
    justify-content: center;
}

.aspect-video iframe,
.aspect-video img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

/* Video card alignment */
.video-card .aspect-video {
    position: relative;
    overflow: hidden;
}

.video-card .aspect-video iframe {
    width: 100%;
    height: 100%;
    border: none;
}

/* Service card image alignment */
.service-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

/* Hero section image alignment */
.hero-image {
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

/* Hero image alignment - simple fix */
.hero-section img {
    object-fit: cover;
    object-position: center;
}

/* Hero image container alignment */
.hero-section .flex {
    align-items: center;
}

/* Gallery image alignment */
.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

/* General image alignment */
img {
    max-width: 100%;
    height: auto;
    object-fit: cover;
    object-position: center;
}

/* Fix for iframe alignment */
iframe {
    display: block;
    margin: 0 auto;
}
