/* ==========================================
   Brooks Dog Training Academy - Custom Styles
   ========================================== */

/* ==========================================
   Root Variables
   ========================================== */
:root {
    --primary-color: #2563eb;
    --primary-dark: #1e40af;
    --secondary-color: #10b981;
    --dark-color: #1f2937;
    --light-color: #f9fafb;
    --text-color: #374151;
    --border-radius: 12px;
    --transition: all 0.3s ease;
}

/* ==========================================
   Global Styles
   ========================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    line-height: 1.2;
}

a {
    text-decoration: none;
    transition: var(--transition);
}

img {
    max-width: 100%;
    height: auto;
}

/* ==========================================
   Navigation
   ========================================== */
.navbar {
    padding: 1rem 0;
    transition: var(--transition);
}

.navbar-brand {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--dark-color) !important;
}

.navbar-nav .nav-link {
    font-weight: 500;
    padding: 0.5rem 1rem !important;
    color: var(--text-color) !important;
    position: relative;
}

.navbar-nav .nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 50%;
    background-color: var(--primary-color);
    transition: var(--transition);
    transform: translateX(-50%);
}

.navbar-nav .nav-link:hover::after,
.navbar-nav .nav-link.active::after {
    width: 60%;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    color: var(--primary-color) !important;
}

/* ==========================================
   Buttons
   ========================================== */
.btn {
    font-weight: 500;
    padding: 0.75rem 1.5rem;
    border-radius: var(--border-radius);
    transition: var(--transition);
    border: none;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
    box-shadow: 0 4px 6px rgba(37, 99, 235, 0.2);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(37, 99, 235, 0.3);
}

.btn-outline-primary {
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

.btn-outline-primary:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-2px);
}

/* ==========================================
   Hero Section
   ========================================== */
.hero-section {
    position: relative;
    padding-top: 80px;
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    overflow: hidden;
}

.hero-shapes {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
}

.shape {
    position: absolute;
    border-radius: 50%;
    opacity: 0.1;
}

.shape-1 {
    width: 500px;
    height: 500px;
    background: var(--primary-color);
    top: -200px;
    right: -100px;
}

.shape-2 {
    width: 300px;
    height: 300px;
    background: var(--secondary-color);
    bottom: -100px;
    left: -50px;
}

.hero-image-wrapper {
    position: relative;
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-20px);
    }
}

.stat-item h3 {
    font-size: 2.5rem;
}

/* ==========================================
   Section Spacing
   ========================================== */
section {
    scroll-margin-top: 80px;
}

/* ==========================================
   About Section
   ========================================== */
.about-image-wrapper {
    position: relative;
}

.about-image-wrapper::before {
    content: '';
    position: absolute;
    top: 20px;
    left: 20px;
    width: 100%;
    height: 100%;
    border: 3px solid var(--primary-color);
    border-radius: var(--border-radius);
    z-index: -1;
}

.feature-icon {
    transition: var(--transition);
}

.feature-icon:hover {
    transform: scale(1.1);
}

/* ==========================================
   Service Cards
   ========================================== */
.service-card {
    transition: var(--transition);
    border-radius: var(--border-radius);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1) !important;
}

.service-icon {
    transition: var(--transition);
}

.service-card:hover .service-icon {
    transform: scale(1.1) rotate(5deg);
}

.hover-lift {
    transition: var(--transition);
}

/* ==========================================
   Testimonials
   ========================================== */
.testimonials .card {
    border-radius: var(--border-radius);
    transition: var(--transition);
}

.testimonials .card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1) !important;
}

/* ==========================================
   Contact Section
   ========================================== */
.contact-info .contact-icon {
    transition: var(--transition);
}

.contact-info .contact-icon:hover {
    transform: scale(1.1);
}

.social-links a {
    transition: var(--transition);
}

.social-links a:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

#contactForm .form-control,
#contactForm .form-select {
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    padding: 0.75rem 1rem;
    transition: var(--transition);
}

#contactForm .form-control:focus,
#contactForm .form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(37, 99, 235, 0.1);
}

/* ==========================================
   Footer
   ========================================== */
footer a {
    transition: var(--transition);
}

footer a:hover {
    color: white !important;
    transform: translateX(5px);
}

/* ==========================================
   Back to Top Button
   ========================================== */
#backToTop {
    opacity: 0;
    transition: var(--transition);
    z-index: 1000;
}

#backToTop:not(.d-none) {
    opacity: 1;
}

#backToTop:hover {
    transform: translateY(-5px);
}

/* ==========================================
   Animations
   ========================================== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

/* ==========================================
   Utility Classes
   ========================================== */
.shadow-sm {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08) !important;
}

.shadow {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1) !important;
}

.shadow-lg {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15) !important;
}

.rounded-4 {
    border-radius: var(--border-radius) !important;
}

/* ==========================================
   Responsive Design
   ========================================== */
@media (max-width: 991.98px) {
    .navbar-nav .nav-link::after {
        display: none;
    }
    
    .navbar-nav .nav-item {
        text-align: center;
    }
    
    .navbar-nav .btn {
        margin-top: 1rem;
        display: inline-block;
    }
    
    .hero-section {
        padding-top: 100px;
    }
    
    .stat-item {
        text-align: center;
    }
}

@media (max-width: 767.98px) {
    h1.display-3 {
        font-size: 2.5rem;
    }
    
    h2.display-5 {
        font-size: 2rem;
    }
    
    .stat-item h3 {
        font-size: 2rem;
    }
}

@media (max-width: 575.98px) {
    .btn-lg {
        padding: 0.6rem 1.2rem;
        font-size: 1rem;
    }
    
    .service-icon {
        width: 60px !important;
        height: 60px !important;
    }
}

/* ==========================================
   Print Styles
   ========================================== */
@media print {
    .navbar,
    #backToTop,
    .hero-shapes {
        display: none;
    }
}

/* ==========================================
   Accessibility
   ========================================== */
.btn:focus,
.form-control:focus,
.form-select:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Smooth scrolling for the entire page */
html {
    scroll-behavior: smooth;
}

/* Loading Animation */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Form Success/Error Messages */
.alert-custom {
    padding: 1rem;
    border-radius: 8px;
    font-weight: 500;
}

.alert-success-custom {
    background-color: #d1fae5;
    color: #065f46;
    border: 1px solid #6ee7b7;
}

.alert-error-custom {
    background-color: #fee2e2;
    color: #991b1b;
    border: 1px solid #fca5a5;
}
