/* Alpine Adventure Lodge - Custom CSS */
/* ==================================== */

/* CSS Custom Properties (Variables) */
:root {
  --primary-color: #1e3a8a;
  --secondary-color: #f8fafc;
  --accent-color: #3b82f6;
  --dark-blue: #1e40af;
  --light-blue: #dbeafe;
  --text-dark: #1f2937;
  --text-light: #6b7280;
  --white: #ffffff;
  --success: #059669;
  --warning: #d97706;
  --danger: #dc2626;
  --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  --border-radius: 8px;
  --transition: all 0.3s ease;
  --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-heading: 'Playfair Display', serif;
}

/* Bootstrap 5 Overrides */
.btn-primary {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
  font-weight: 600;
  padding: 12px 24px;
  border-radius: var(--border-radius);
  transition: var(--transition);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.btn-primary:hover {
  background-color: var(--dark-blue);
  border-color: var(--dark-blue);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-outline-primary {
  color: var(--primary-color);
  border-color: var(--primary-color);
}

.btn-outline-primary:hover {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
}

.text-primary {
  color: var(--primary-color) !important;
}

.bg-primary {
  background-color: var(--primary-color) !important;
}

/* Global Styles */
* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-primary);
  line-height: 1.6;
  color: var(--text-dark);
  background-color: var(--secondary-color);
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 1rem;
}

p {
  color: var(--text-light);
  margin-bottom: 1rem;
}

a {
  text-decoration: none;
  transition: var(--transition);
}

img {
  max-width: 100%;
  height: auto;
}

/* Animation Classes */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.slide-in-left {
  opacity: 0;
  transform: translateX(-50px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.slide-in-left.visible {
  opacity: 1;
  transform: translateX(0);
}

.slide-in-right {
  opacity: 0;
  transform: translateX(50px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.slide-in-right.visible {
  opacity: 1;
  transform: translateX(0);
}

/* Header & Navigation */
.navbar {
  background-color: rgba(30, 58, 138, 0.95) !important;
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow);
  transition: var(--transition);
  padding: 1rem 0;
}

.navbar.scrolled {
  background-color: var(--primary-color) !important;
  padding: 0.5rem 0;
}

.navbar-brand {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--white) !important;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.navbar-nav .nav-link {
  color: var(--white) !important;
  font-weight: 500;
  margin: 0 0.5rem;
  padding: 0.5rem 1rem !important;
  border-radius: var(--border-radius);
  transition: var(--transition);
  position: relative;
}

.navbar-nav .nav-link:hover {
  background-color: rgba(255, 255, 255, 0.1);
  transform: translateY(-2px);
}

.navbar-nav .nav-link.active {
  background-color: rgba(255, 255, 255, 0.2);
}

.navbar-toggler {
  border: none;
  padding: 0.25rem 0.5rem;
}

.navbar-toggler:focus {
  box-shadow: none;
}

.navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 1%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='m4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* Hero Section */
.hero {
  height: 100vh;
  min-height: 600px;
  background: linear-gradient(rgba(30, 58, 138, 0.3), rgba(30, 58, 138, 0.5)), url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 800" fill="%23f8fafc"><polygon points="0,800 1200,800 1200,200 800,300 400,100 0,400"/></svg>');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--white);
  position: relative;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, rgba(30, 58, 138, 0.8), rgba(59, 130, 246, 0.6));
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 800px;
  padding: 2rem;
}

.hero h1 {
  font-size: 4rem;
  font-weight: 800;
  margin-bottom: 1.5rem;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
  color: var(--white);
}

.hero p {
  font-size: 1.3rem;
  margin-bottom: 2rem;
  color: var(--light-blue);
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

.hero .btn {
  font-size: 1.1rem;
  padding: 15px 35px;
  margin: 0.5rem;
  border-radius: 50px;
  box-shadow: var(--shadow-lg);
}

/* Sections */
.section {
  padding: 5rem 0;
}

.section-title {
  font-size: 2.5rem;
  text-align: center;
  margin-bottom: 3rem;
  position: relative;
  color: var(--primary-color);
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
  border-radius: 2px;
}

/* Cards */
.card {
  border: none;
  border-radius: 15px;
  box-shadow: var(--shadow);
  transition: var(--transition);
  overflow: hidden;
  background: var(--white);
}

.card:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-lg);
}

.card-img-top {
  height: 250px;
  object-fit: cover;
  transition: var(--transition);
}

.card:hover .card-img-top {
  transform: scale(1.05);
}

.card-body {
  padding: 2rem;
}

.card-title {
  color: var(--primary-color);
  font-weight: 700;
  margin-bottom: 1rem;
}

.card-text {
  color: var(--text-light);
  line-height: 1.6;
}

/* Room Cards */
.room-card {
  position: relative;
  overflow: hidden;
  border-radius: 15px;
  margin-bottom: 2rem;
}

.room-card .card-img-overlay {
  background: linear-gradient(to top, rgba(30, 58, 138, 0.8), transparent);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.room-card h5 {
  color: var(--white);
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.room-card p {
  color: var(--light-blue);
  margin-bottom: 1rem;
}

.room-price {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--white);
}

/* Features Section */
.features {
  background: linear-gradient(135deg, var(--secondary-color), var(--light-blue));
}

.feature-icon {
  width: 80px;
  height: 80px;
  background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  color: var(--white);
  font-size: 2rem;
  transition: var(--transition);
}

.feature-item:hover .feature-icon {
  transform: rotate(360deg) scale(1.1);
}

/* Gallery */
.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: 15px;
  margin-bottom: 1.5rem;
  cursor: pointer;
}

.gallery-item img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  transition: var(--transition);
}

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

.gallery-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(30, 58, 138, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: var(--transition);
}

.gallery-item:hover .gallery-overlay {
  opacity: 1;
}

.gallery-overlay i {
  color: var(--white);
  font-size: 3rem;
}

/* Forms */
.form-control {
  border: 2px solid #e5e7eb;
  border-radius: var(--border-radius);
  padding: 12px 16px;
  font-size: 1rem;
  transition: var(--transition);
}

.form-control:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(30, 58, 138, 0.25);
}

.form-label {
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 0.5rem;
}

.form-floating .form-control {
  height: calc(3.5rem + 2px);
  line-height: 1.25;
}

.form-floating label {
  color: var(--text-light);
}

.form-control.is-invalid {
  border-color: var(--danger);
  box-shadow: 0 0 0 0.2rem rgba(220, 38, 38, 0.25);
}

.form-control.is-valid {
  border-color: var(--success);
  box-shadow: 0 0 0 0.2rem rgba(5, 150, 105, 0.25);
}

.invalid-feedback {
  color: var(--danger);
  font-size: 0.875rem;
  margin-top: 0.25rem;
}

.valid-feedback {
  color: var(--success);
  font-size: 0.875rem;
  margin-top: 0.25rem;
}

/* Booking Form */
.booking-form {
  background: var(--white);
  border-radius: 15px;
  padding: 2rem;
  box-shadow: var(--shadow-lg);
  margin-top: -100px;
  position: relative;
  z-index: 10;
}

/* Testimonials */
.testimonial {
  background: var(--white);
  border-radius: 15px;
  padding: 2rem;
  text-align: center;
  box-shadow: var(--shadow);
  transition: var(--transition);
  position: relative;
}

.testimonial:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.testimonial::before {
  content: '"';
  position: absolute;
  top: -20px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 4rem;
  color: var(--primary-color);
  opacity: 0.3;
}

.testimonial-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  margin: 0 auto 1rem;
  object-fit: cover;
  border: 4px solid var(--light-blue);
}

.testimonial-name {
  font-weight: 700;
  color: var(--primary-color);
  margin-bottom: 0.25rem;
}

.testimonial-role {
  color: var(--text-light);
  font-size: 0.9rem;
}

/* Footer */
.footer {
  background: linear-gradient(135deg, var(--primary-color), var(--dark-blue));
  color: var(--white);
  padding: 3rem 0 1rem;
}

.footer h5 {
  color: var(--white);
  margin-bottom: 1.5rem;
  font-weight: 700;
}

.footer p, .footer a {
  color: var(--light-blue);
  transition: var(--transition);
}

.footer a:hover {
  color: var(--white);
  text-decoration: none;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  margin-top: 2rem;
  padding-top: 1rem;
  text-align: center;
  color: var(--light-blue);
}

.social-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  margin: 0 0.5rem;
  transition: var(--transition);
}

.social-links a:hover {
  background: var(--white);
  color: var(--primary-color);
  transform: translateY(-3px);
}

/* Back to Top Button */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 50px;
  height: 50px;
  background: var(--primary-color);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
  z-index: 1000;
  box-shadow: var(--shadow-lg);
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  background: var(--dark-blue);
  transform: translateY(-3px);
  color: var(--white);
}

/* Loading Spinner */
.loading {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  border-top-color: var(--white);
  animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Mobile Optimizations */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 2.5rem;
  }
  
  .hero p {
    font-size: 1.1rem;
  }
  
  .section {
    padding: 3rem 0;
  }
  
  .section-title {
    font-size: 2rem;
  }
  
  .booking-form {
    margin-top: -50px;
    padding: 1.5rem;
  }
  
  .navbar-collapse {
    background: var(--primary-color);
    border-radius: var(--border-radius);
    margin-top: 1rem;
    padding: 1rem;
  }
  
  .hero {
    background-attachment: scroll;
  }
}

@media (max-width: 576px) {
  .hero {
    height: 80vh;
    min-height: 500px;
  }
  
  .hero h1 {
    font-size: 2rem;
  }
  
  .hero p {
    font-size: 1rem;
  }
  
  .hero .btn {
    padding: 12px 24px;
    font-size: 1rem;
  }
  
  .card-body {
    padding: 1.5rem;
  }
  
  .feature-icon {
    width: 60px;
    height: 60px;
    font-size: 1.5rem;
  }
  
  .back-to-top {
    bottom: 20px;
    right: 20px;
    width: 45px;
    height: 45px;
  }
}

/* Print Styles */
@media print {
  .navbar,
  .back-to-top,
  .btn {
    display: none !important;
  }
  
  .hero {
    background: none !important;
    color: var(--text-dark) !important;
    height: auto !important;
    padding: 2rem 0;
  }
  
  .section {
    padding: 1rem 0;
  }
}