/*
 * Custom CSS for Drone Competition Team Website
 */

:root {
  /* Enhanced blue color palette */
  --primary: #1e88e5;
  --primary-light: #42a5f5;
  --primary-dark: #0d47a1;
  --secondary: #f5f7fa;
  --accent: #00c853;
  --accent-light: #69f0ae;
  --text-dark: #37474f;
  --text-light: #eceff1;
  --border-color: #e3f2fd;
  --success: #00c853;
  --warning: #ffd600;
  --danger: #f44336;
  --gradient-primary: linear-gradient(135deg, var(--primary), var(--primary-dark));
  --gradient-accent: linear-gradient(135deg, var(--accent), #00b0ff);
  --box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  
  /* Animation properties */
  --animation-timing: cubic-bezier(0.175, 0.885, 0.32, 1.275);
  --transition-normal: all 0.4s ease;
  --transition-slow: all 0.6s ease;
  --transition-fast: all 0.2s ease;
}

/* Base Styles */
body {
  font-family: 'Roboto', 'Helvetica Neue', sans-serif;
  color: var(--text-dark);
  line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: all 0.3s ease;
}

a:hover {
  color: var(--primary-dark);
}

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

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

.btn {
  position: relative;
  overflow: hidden;
  border-radius: 50px;
  font-weight: 600;
  letter-spacing: 0.5px;
  transition: all 0.4s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  z-index: 1;
}

.btn::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(255, 255, 255, 0.1);
  z-index: -1;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.5s ease;
}

.btn:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}

.btn-primary {
  background: var(--gradient-primary);
  border: none;
  color: white;
}

.btn-primary:hover, 
.btn-primary:focus, 
.btn-primary:active {
  background: var(--gradient-primary) !important;
  filter: brightness(1.1);
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.btn-outline-primary {
  color: var(--primary);
  border: 2px solid var(--primary);
  background: transparent;
}

.btn-outline-primary:hover {
  background-color: var(--primary);
  border-color: var(--primary);
  color: white;
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.btn-accent {
  background: var(--gradient-accent);
  border: none;
  color: white;
}

.btn-accent:hover {
  filter: brightness(1.1);
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

/* Navigation */
.navbar {
  box-shadow: var(--box-shadow);
  padding: 1rem 0;
  transition: all 0.3s ease;
}

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

.navbar-brand {
  font-weight: 800;
  font-size: 1.6rem;
  letter-spacing: -0.5px;
  position: relative;
  color: white !important;
}

.navbar-brand::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 30px;
  height: 3px;
  background: var(--accent);
  transition: width 0.3s ease;
}

.navbar-brand:hover::after {
  width: 100%;
}

.navbar-dark .navbar-nav .nav-link {
  color: rgba(255, 255, 255, 0.9);
  font-weight: 600;
  position: relative;
  padding: 0.5rem 1rem;
  margin: 0 0.2rem;
  text-transform: uppercase;
  font-size: 0.9rem;
  letter-spacing: 0.5px;
}

.navbar-dark .navbar-nav .nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: all 0.3s ease;
  transform: translateX(-50%);
}

.navbar-dark .navbar-nav .nav-link:hover,
.navbar-dark .navbar-nav .nav-link.active {
  color: white;
}

.navbar-dark .navbar-nav .nav-link:hover::after,
.navbar-dark .navbar-nav .nav-link.active::after {
  width: 80%;
}

.nav-indicator {
  position: absolute;
  top: 0;
  right: -5px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: var(--accent);
  display: inline-block;
}

.navbar-dark .navbar-nav .nav-link {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

.navbar-toggler {
  border: none;
  padding: 0;
}

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

.navbar-toggler-icon {
  width: 24px;
  height: 24px;
}

/* Hero Section */
.hero {
  padding: 6rem 0;
  background: var(--gradient-primary);
  position: relative;
  overflow: hidden;
  box-shadow: var(--box-shadow);
}

.hero::before {
  content: '';
  position: absolute;
  top: -100px;
  right: -100px;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  z-index: 0;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -50px;
  left: -50px;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  z-index: 0;
}

.hero .container {
  position: relative;
  z-index: 1;
}

.hero h1 {
  font-size: 3rem;
  margin-bottom: 1.5rem;
  letter-spacing: -0.5px;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  animation: fadeInDown 1s ease-out;
}

.hero p {
  font-size: 1.35rem;
  margin-bottom: 2.5rem;
  opacity: 0.9;
  animation: fadeIn 1.2s ease-out 0.2s forwards;
}

.hero .btn {
  padding: 0.8rem 2rem;
  font-weight: 600;
  border-radius: 50px;
  text-transform: uppercase;
  letter-spacing: 1px;
  animation: fadeInUp 1.5s ease-out 0.4s forwards;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.hero img {
  animation: fadeInRight 1.2s ease-out 0.3s forwards;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
  border-radius: 10px;
  transform: rotate(2deg);
}

/* Card Styles */
.card {
  border: none;
  border-radius: 12px;
  box-shadow: var(--box-shadow);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  overflow: hidden;
  background: #fff;
  position: relative;
}

.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: var(--gradient-primary);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s ease;
}

.card:hover {
  transform: translateY(-8px) rotate(1deg);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.card:hover::before {
  transform: scaleX(1);
}

.card-body {
  padding: 1.5rem;
}

.card-header {
  font-weight: 700;
  background: transparent;
  border-bottom: 1px solid var(--border-color);
  padding: 1.25rem 1.5rem;
}

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

.card-text {
  color: var(--text-dark);
  opacity: 0.85;
}

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

.card.feature-card {
  text-align: center;
  padding: 2rem 1.5rem;
  border-radius: 16px;
}

.card.feature-card .icon-wrapper {
  width: 80px;
  height: 80px;
  margin: 0 auto 1.5rem;
  background: var(--gradient-accent);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 2rem;
  box-shadow: 0 10px 20px rgba(0, 200, 83, 0.2);
}

.card.feature-card:hover {
  transform: translateY(-10px);
}

/* Team Member Cards */
.team-slider .card {
  margin-bottom: 2rem;
  transition: all 0.5s ease;
  border-radius: 16px;
  position: relative;
  overflow: hidden;
}

.team-slider .card::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 50%;
  background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
  opacity: 0;
  transition: opacity 0.5s ease;
}

.team-slider .card:hover::after {
  opacity: 1;
}

.team-slider .card-img-top {
  transition: all 0.5s ease;
  height: 300px;
  object-fit: cover;
  border-radius: 16px 16px 0 0;
}

.team-slider .card:hover .card-img-top {
  transform: scale(1.08);
  filter: brightness(0.9);
}

.team-slider .card:hover .card-body {
  background-color: var(--primary);
  color: white;
}

.team-slider .card:hover .card-title,
.team-slider .card:hover .card-text {
  color: white;
}

.team-slider .card-body {
  transition: all 0.5s ease;
  position: relative;
  z-index: 1;
}

.team-slider .card-title {
  font-weight: 700;
  font-size: 1.25rem;
  margin-bottom: 0.25rem;
  transition: color 0.3s ease;
}

.team-slider .card-subtitle {
  color: var(--primary);
  font-weight: 600;
  margin-bottom: 0.75rem;
  transition: color 0.3s ease;
}

.team-slider .social-links {
  margin-top: 1rem;
  display: flex;
  gap: 0.5rem;
}

.team-slider .social-links a {
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--primary-light);
  color: white;
  transition: all 0.3s ease;
}

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

.team-slider .card.is-leader {
  transform: scale(1.05);
  border: 2px solid var(--accent);
}

.team-slider .card.is-leader::before {
  content: '★ Team Leader';
  position: absolute;
  top: 10px;
  right: 10px;
  background: var(--accent);
  color: white;
  padding: 5px 10px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
  z-index: 10;
}

/* Achievement Cards */
.achievement-card {
  border-radius: 10px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
  background-color: white;
}

.achievement-card:hover {
  transform: translateY(-5px) scale(1.02);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.achievement-icon {
  width: 45px;
  height: 45px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(45deg, #FFD700, #FFA500);
  color: white;
  border-radius: 50%;
  font-size: 1.2rem;
  box-shadow: 0 5px 15px rgba(255, 215, 0, 0.3);
}

/* Media Gallery */
.nav-pills .nav-link {
  color: var(--text-dark);
  border-radius: 30px;
  padding: 0.5rem 1.5rem;
}

.nav-pills .nav-link.active {
  background-color: var(--primary);
}

#gallery .card {
  cursor: pointer;
}

/* Form Styles */
.form-control:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 0.25rem rgba(74, 137, 220, 0.25);
}

/* Footer */
footer {
  background: linear-gradient(to right, #1a237e, #283593);
  color: white;
  position: relative;
  overflow: hidden;
}

footer::before {
  content: '';
  position: absolute;
  top: -50px;
  right: -50px;
  width: 150px;
  height: 150px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
}

footer::after {
  content: '';
  position: absolute;
  bottom: -80px;
  left: -80px;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.03);
}

footer h5 {
  color: white;
  font-weight: 700;
  letter-spacing: 1px;
  position: relative;
  display: inline-block;
  margin-bottom: 1.5rem;
}

footer h5::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 0;
  width: 40px;
  height: 3px;
  background: var(--accent);
}

footer a {
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
  transition: all 0.3s ease;
  position: relative;
  display: inline-block;
}

footer a:hover {
  color: white;
  transform: translateX(5px);
}

footer p {
  color: rgba(255, 255, 255, 0.7);
  line-height: 1.7;
}

footer .list-unstyled li {
  margin-bottom: 0.75rem;
  position: relative;
}

/* Social Links */
.social-links {
  display: flex;
  gap: 0.75rem;
}

.social-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  color: white;
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.social-links a:hover {
  transform: translateY(-5px) rotate(10deg);
  background: var(--primary-light);
  border-color: var(--primary-light);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
}

footer hr {
  background-color: rgba(255, 255, 255, 0.1);
  opacity: 1;
}

/* Map Container */
.map-container {
  overflow: hidden;
}

.map-container iframe {
  width: 100%;
  height: 450px;
  border: 0;
}

/* Animated background items */
.bg-animated {
  position: relative;
  overflow: hidden;
}

.bg-animated::before, 
.bg-animated::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.05);
  z-index: 0;
  animation: float 12s infinite alternate var(--animation-timing);
}

.bg-animated::before {
  width: 400px;
  height: 400px;
  top: -200px;
  right: -200px;
  animation-delay: 0s;
}

.bg-animated::after {
  width: 300px;
  height: 300px;
  bottom: -150px;
  left: -150px;
  animation-delay: -4s;
}

.bg-animated .bg-shape {
  position: absolute;
  z-index: 0;
  opacity: 0.07;
}

.bg-animated .bg-shape-1 {
  top: 20%;
  right: 10%;
  width: 100px;
  height: 100px;
  border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
  background-color: var(--primary-light);
  animation: morphing 15s infinite alternate ease-in-out;
}

.bg-animated .bg-shape-2 {
  bottom: 15%;
  left: 10%;
  width: 80px;
  height: 80px;
  border-radius: 30% 70% 40% 60% / 60% 30% 70% 40%;
  background-color: var(--accent-light);
  animation: morphing 20s infinite alternate-reverse ease-in-out;
}

/* Custom Animations */
@keyframes morphing {
  0% {
    border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
  }
  25% {
    border-radius: 58% 42% 75% 25% / 76% 46% 54% 24%;
  }
  50% {
    border-radius: 50% 50% 33% 67% / 55% 27% 73% 45%;
  }
  75% {
    border-radius: 33% 67% 58% 42% / 63% 68% 32% 37%;
  }
  100% {
    border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes fadeInRight {
  from {
    opacity: 0;
    transform: translateX(20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes fadeInLeft {
  from {
    opacity: 0;
    transform: translateX(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes pulse {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
  100% {
    transform: scale(1);
  }
}

@keyframes float {
  0% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-8px);
  }
  100% {
    transform: translateY(0px);
  }
}

.animated {
  animation-duration: 1s;
  animation-fill-mode: both;
}

.fadeInUp {
  animation-name: fadeInUp;
}

.fadeInDown {
  animation-name: fadeInDown;
}

.fadeIn {
  animation-name: fadeIn;
}

.fadeInRight {
  animation-name: fadeInRight;
}

.fadeInLeft {
  animation-name: fadeInLeft;
}

.pulse {
  animation-name: pulse;
  animation-duration: 2s;
  animation-iteration-count: infinite;
}

.float {
  animation-name: float;
  animation-duration: 3s;
  animation-iteration-count: infinite;
  animation-timing-function: ease-in-out;
}

.delay-1 {
  animation-delay: 0.2s;
}

.delay-2 {
  animation-delay: 0.4s;
}

.delay-3 {
  animation-delay: 0.6s;
}

/* Media Queries */
@media (max-width: 992px) {
  .hero {
    text-align: center;
    padding: 4rem 0;
  }
  
  .hero img {
    margin-top: 2rem;
  }
}

@media (max-width: 768px) {
  .hero h1 {
    font-size: 2rem;
  }
  
  .hero p {
    font-size: 1.1rem;
  }
  
  .display-4 {
    font-size: 2.5rem;
  }
}

@media (max-width: 576px) {
  .hero {
    padding: 3rem 0;
  }
  
  .hero h1 {
    font-size: 1.8rem;
  }
  
  .display-4 {
    font-size: 2rem;
  }
}
