/* ============================================================
   DroneRent — Dark Theme Styles
   ============================================================ */

:root {
  --drone-primary: #0d6efd;
  --drone-accent: #6610f2;
  --drone-glow: rgba(13, 110, 253, 0.3);
  --dark-bg: #0a0a0f;
  --card-bg: #151520;
  --card-border: #2a2a3a;
}

body {
  background: var(--dark-bg);
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
}

/* ======== NAVBAR ======== */
.navbar {
  backdrop-filter: blur(10px);
  background: rgba(10, 10, 15, 0.95) !important;
}

.navbar-brand {
  background: linear-gradient(135deg, var(--drone-primary), var(--drone-accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ======== HERO SECTION ======== */
.hero-section {
  min-height: 80vh;
  background: linear-gradient(135deg, #0a0a1a 0%, #1a1a3e 50%, #0a0a1a 100%);
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at 30% 50%, rgba(13, 110, 253, 0.08) 0%, transparent 50%),
              radial-gradient(circle at 70% 50%, rgba(102, 16, 242, 0.06) 0%, transparent 50%);
  animation: heroGlow 8s ease-in-out infinite alternate;
}

@keyframes heroGlow {
  0% { transform: translate(0, 0) rotate(0deg); }
  100% { transform: translate(-20px, 20px) rotate(5deg); }
}

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

.hero-title {
  font-size: 3.5rem;
  font-weight: 800;
  line-height: 1.1;
}

.hero-title span {
  background: linear-gradient(135deg, var(--drone-primary), var(--drone-accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ======== CARDS ======== */
.card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 16px;
  transition: all 0.3s ease;
  overflow: hidden;
}

.card:hover {
  border-color: var(--drone-primary);
  transform: translateY(-5px);
  box-shadow: 0 10px 40px rgba(13, 110, 253, 0.1);
}

.drone-card .card-img-top {
  height: 220px;
  object-fit: cover;
  background: linear-gradient(135deg, #1a1a3e, #0a0a1a);
}

.category-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  font-size: 0.75rem;
  padding: 4px 12px;
  border-radius: 20px;
  background: rgba(13, 110, 253, 0.2);
  backdrop-filter: blur(4px);
  border: 1px solid rgba(13, 110, 253, 0.3);
  color: #fff;
}

.price-tag {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--drone-primary);
}

.price-tag small {
  font-size: 0.8rem;
  font-weight: 400;
  color: #888;
}

/* ======== DRONE DETAIL ======== */
.drone-image-container {
  border-radius: 16px;
  overflow: hidden;
  background: linear-gradient(135deg, #1a1a3e, #0a0a1a);
  min-height: 400px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.spec-item {
  padding: 12px;
  background: rgba(255, 255, 255, 0.02);
  border-radius: 8px;
  border-left: 3px solid var(--drone-primary);
}

/* ======== STATS / FEATURES ======== */
.stat-card {
  padding: 2rem;
  text-align: center;
  border-radius: 16px;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  transition: all 0.3s ease;
}

.stat-card:hover {
  border-color: var(--drone-primary);
  transform: translateY(-3px);
}

.stat-icon {
  width: 60px;
  height: 60px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
  font-size: 1.5rem;
}

.stat-number {
  font-size: 2rem;
  font-weight: 700;
}

/* ======== FORM STYLING ======== */
.form-control, .form-select {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--card-border);
  border-radius: 10px;
  color: #fff;
  padding: 0.7rem 1rem;
}

.form-control:focus, .form-select:focus {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--drone-primary);
  box-shadow: 0 0 0 3px var(--drone-glow);
  color: #fff;
}

.form-label {
  font-weight: 500;
  font-size: 0.9rem;
}

/* ======== BUTTONS ======== */
.btn {
  border-radius: 10px;
  padding: 0.6rem 1.5rem;
  font-weight: 500;
  transition: all 0.3s ease;
}

.btn-primary {
  background: linear-gradient(135deg, var(--drone-primary), #0a58ca);
  border: none;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 20px rgba(13, 110, 253, 0.3);
}

.btn-glow {
  background: linear-gradient(135deg, var(--drone-primary), var(--drone-accent));
  border: none;
  box-shadow: 0 0 20px var(--drone-glow);
}

.btn-glow:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 40px var(--drone-glow);
}

/* ======== ADMIN SIDEBAR ======== */
.admin-sidebar {
  min-height: calc(100vh - 56px);
  background: var(--card-bg);
  border-right: 1px solid var(--card-border);
}

.admin-sidebar .nav-link {
  color: #888;
  border-radius: 10px;
  margin: 2px 0;
  padding: 0.7rem 1rem;
}

.admin-sidebar .nav-link:hover,
.admin-sidebar .nav-link.active {
  color: #fff;
  background: rgba(13, 110, 253, 0.1);
}

.admin-sidebar .nav-link i {
  width: 22px;
}

/* ======== BOOKING STATUS BADGES ======== */
.badge-status {
  padding: 6px 12px;
  border-radius: 20px;
  font-weight: 500;
  font-size: 0.8rem;
}

/* ======== RATING STARS ======== */
.stars {
  color: #ffc107;
  font-size: 0.85rem;
}

/* ======== ANIMATIONS ======== */
.fade-in {
  animation: fadeIn 0.6s ease;
}

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

/* ======== RESPONSIVE ======== */
@media (max-width: 768px) {
  /* Hero */
  .hero-section {
    min-height: auto;
    padding: 3rem 0 2rem;
  }
  .hero-title {
    font-size: 1.8rem;
  }
  .hero-content .col-lg-6:last-child {
    display: none; /* hide hero image on mobile */
  }

  /* Stats */
  .stat-number { font-size: 1.5rem; }
  .stat-card { padding: 1rem; }

  /* Cards */
  .card:hover {
    transform: none; /* disable hover lift on touch */
  }
  .drone-card .card-img-top { height: 180px; }

  /* Buttons */
  .btn { padding: 0.5rem 1rem; font-size: 0.9rem; }
  .btn-lg { font-size: 1rem; padding: 0.6rem 1.2rem; }

  /* Admin sidebar — collapse on mobile */
  .admin-sidebar {
    min-height: auto;
    border-right: none;
    border-bottom: 1px solid var(--card-border);
  }
  .admin-sidebar .nav {
    flex-direction: row !important;
    flex-wrap: wrap;
    gap: 4px;
  }
  .admin-sidebar .nav-link {
    padding: 0.4rem 0.7rem;
    font-size: 0.8rem;
  }

  /* Tables — horizontal scroll */
  .table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  .table th, .table td {
    white-space: nowrap;
    font-size: 0.8rem;
    padding: 0.5rem 0.6rem;
  }

  /* Forms */
  .form-control, .form-select {
    font-size: 16px; /* prevent iOS zoom */
  }

  /* Drone detail */
  .drone-image-container { min-height: 250px; }
  .price-calculator { position: static; }

  /* Badges & gaps */
  .d-flex.gap-1 { flex-wrap: wrap; }
  .badge { font-size: 0.7rem; }

  /* Navbar brand — shorter on small screens */
  .navbar-brand {
    font-size: 0.85rem;
  }
}

@media (max-width: 480px) {
  .hero-title { font-size: 1.5rem; }
  .container { padding-left: 12px; padding-right: 12px; }
  h4 { font-size: 1.2rem; }
  .card { border-radius: 12px; }
  .btn-group-sm .btn, .btn-sm { padding: 0.3rem 0.5rem; font-size: 0.75rem; }
}

/* ======== TIMELINE ======== */
.timeline {
  position: relative;
  padding-left: 30px;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 10px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--card-border);
}

.timeline-item {
  position: relative;
  margin-bottom: 1.5rem;
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: -24px;
  top: 4px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--drone-primary);
  border: 2px solid var(--dark-bg);
}

/* ======== SCROLLBAR ======== */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: var(--dark-bg);
}

::-webkit-scrollbar-thumb {
  background: #333;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #555;
}

/* ======== PRICE CALCULATOR ======== */
.price-calculator {
  position: sticky;
  top: 80px;
}

/* ======== TABLE ======== */
.table {
  --bs-table-bg: transparent;
  --bs-table-hover-bg: rgba(255, 255, 255, 0.03);
}

.table th {
  border-bottom-color: var(--card-border);
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.8rem;
  letter-spacing: 0.5px;
}
