:root {
  --primary-color: #f84464;
  --secondary-color: #2b3148;
  --accent-color: #00f2ff;
  --bg-dark: #0f111a;
  --bg-card: rgba(255, 255, 255, 0.05);
  --glass-border: rgba(255, 255, 255, 0.08);
  --text-main: #ffffff;
  --text-muted: #9fa3a9;
  --neon-blue: #00e5ff;
  --neon-pink: #ff0055;
  --gradient-main: linear-gradient(45deg, #f84464, #ff0055);
  --transition-smooth: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background-color: var(--bg-dark);
  color: var(--text-main);
  overflow-x: hidden;
  line-height: 1.6;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: var(--bg-dark);
}
::-webkit-scrollbar-thumb {
    background: #333;
    border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color);
}

/* Glassmorphism utility */
.glass-card {
  background: var(--bg-card);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  transition: var(--transition-smooth);
}

.glass-card:hover {
  border-color: var(--primary-color);
  box-shadow: 0 8px 32px 0 rgba(248, 68, 100, 0.2);
  transform: translateY(-5px);
}

/* Navbar styles */
.navbar {
    background: rgba(15, 17, 26, 0.7) !important;
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border-bottom: 1px solid var(--glass-border);
    padding: 1rem 0;
    transition: var(--transition-smooth);
}

.navbar.scrolled {
    padding: 0.6rem 0;
    background: rgba(10, 11, 16, 0.95) !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.navbar-brand {
  font-weight: 800;
  color: var(--primary-color) !important;
  font-size: 1.5rem;
  letter-spacing: -1px;
}

.navbar-brand img {
    height: 38px;
    transition: var(--transition-smooth);
}

.navbar-brand:hover img {
    transform: scale(1.05);
}

.nav-link {
    color: var(--text-main) !important;
    font-weight: 500;
    margin: 0 12px;
    padding: 8px 0 !important;
    position: relative;
    font-size: 0.95rem;
    letter-spacing: 0.3px;
    opacity: 0.8;
    transition: var(--transition-smooth);
}

.nav-link:hover {
    opacity: 1;
    color: var(--primary-color) !important;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--gradient-main);
    transition: var(--transition-smooth);
    transform: translateX(-50%);
    border-radius: 2px;
}

.nav-link:hover::after, .nav-link.active::after {
    width: 80%;
}

.nav-link.active {
    opacity: 1;
    color: var(--primary-color) !important;
}

/* Search Bar Enhanced */
.search-container {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 6px 18px;
    display: flex;
    align-items: center;
    width: 450px;
    transition: var(--transition-smooth);
}

.search-container:hover {
    background: rgba(255, 255, 255, 0.07);
    border-color: rgba(255, 255, 255, 0.2);
}

.search-container input {
    background: transparent;
    border: none;
    color: white;
    width: 100%;
    padding: 8px;
    font-size: 0.9rem;
}

.search-container input::placeholder {
    color: var(--text-muted);
}

.search-container input:focus {
  outline: none;
}

.search-container:focus-within {
    border-color: var(--primary-color);
    box-shadow: 0 0 15px rgba(248, 68, 100, 0.2);
}

/* Carousel */
.carousel-item img {
  height: 400px;
  object-fit: cover;
  border-radius: 20px;
}

.carousel {
  border-radius: 20px;
  overflow: hidden;
  margin-bottom: 3rem;
}

/* Movie Card */
.movie-card {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  cursor: pointer;
  margin-bottom: 2rem;
  background: var(--bg-card);
  transition: var(--transition-smooth);
}

.movie-card:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4), 0 0 20px rgba(248, 68, 100, 0.2);
}

.movie-poster-wrapper {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  aspect-ratio: 2/3;
}

.movie-poster-wrapper img {
  transition: transform 0.5s ease;
  width: 100%;
}

.movie-card:hover .movie-poster-wrapper img {
  transform: scale(1.1);
}

.movie-rating {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(0, 0, 0, 0.8);
  padding: 5px 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid var(--glass-border);
}

.movie-info h5 {
  margin-top: 1rem;
  font-size: 1.1rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.movie-info p {
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* Buttons */
.btn-book {
  background: var(--gradient-main);
  color: white;
  border: none;
  padding: 10px 25px;
  border-radius: 10px;
  font-weight: 600;
  transition: var(--transition-smooth);
  box-shadow: 0 4px 15px rgba(248, 68, 100, 0.3);
}

.btn-book:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(248, 68, 100, 0.5);
  color: white;
}

.btn-book:active {
  transform: translateY(1px);
}

/* Footer */
footer {
  background: #000;
  padding: 4rem 0 2rem;
  margin-top: 5rem;
}

.footer-logo {
  color: var(--primary-color);
  font-size: 2rem;
  font-weight: 800;
}

/* Seat Selection */
.seat-container {
  perspective: 1000px;
}

.screen {
  background: var(--accent-color);
  height: 70px;
  width: 100%;
  margin: 15px 0;
  transform: rotateX(-45deg);
  box-shadow: 0 3px 10px rgba(0, 242, 255, 0.7);
  border-radius: 5px;
}

.seat {
  height: 22px;
  width: 25px;
  margin: 3px;
  border-top-left-radius: 10px;
  border-top-right-radius: 10px;
  background: #444451;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.seat.selected {
  background: var(--primary-color);
  box-shadow: 0 0 10px var(--primary-color);
}

.seat.occupied {
  background: #fff;
  cursor: not-allowed;
}

.seat:nth-of-type(2) {
  margin-right: 18px;
}

.seat:nth-last-of-type(2) {
  margin-left: 18px;
}

.seat:not(.occupied):hover {
  transform: scale(1.2);
  background: #777;
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in {
  animation: fadeIn 0.8s ease-out forwards;
}

/* Utility */
.section-title {
  font-weight: 700;
  margin-bottom: 2rem;
  position: relative;
  display: inline-block;
}

.section-title::after {
  content: "";
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 50%;
  height: 4px;
  background: var(--primary-color);
  border-radius: 2px;
}

/* Mobile Responsive Adjustments */
@media (max-width: 991.98px) {
    .search-container {
        width: 100%;
        margin-bottom: 1rem;
    }
    
    .carousel-item img {
        height: 250px;
    }

    .booking-summary {
        position: fixed !important;
        bottom: 0;
        left: 0;
        right: 0;
        top: auto !important;
        z-index: 1000;
        border-radius: 20px 20px 0 0 !important;
        padding: 1rem !important;
        margin: 0 !important;
        box-shadow: 0 -10px 30px rgba(0,0,0,0.5);
    }

    .booking-summary .d-flex.gap-3.mb-4,
    .booking-summary .border-top.border-secondary:not(:last-of-type) {
        display: none !important;
    }

    .booking-summary .border-top.border-secondary:last-of-type {
        margin-top: 0 !important;
        padding-top: 0 !important;
        border: none !important;
    }

    .booking-summary #main-action-btn {
        margin-top: 10px !important;
    }

    #booking-sidebar {
        margin-top: 0 !important;
    }

    .container.py-5 {
        padding-bottom: 150px !important;
    }

    #seat-layout {
        overflow-x: auto;
        padding-bottom: 1rem;
        -webkit-overflow-scrolling: touch;
        display: block !important;
        white-space: nowrap;
    }

    .seat-row {
        justify-content: flex-start !important;
        min-width: max-content;
        padding: 0 1rem;
    }

    .seat {
        height: 18px;
        width: 20px;
        margin: 2px;
    }

    .theatre-item {
        padding: 1.5rem !important;
    }

    .time-slot {
        padding: 8px 12px;
        font-size: 0.8rem;
    }
}

@media (max-width: 576px) {
    .section-title {
        font-size: 1.25rem;
    }
    
    .movie-card {
        margin-bottom: 1.5rem;
    }
}
