/* =====================
   Revvr - Custom Styles
   ===================== */

:root {
  --revvr-primary:   #1a3c5e;
  --revvr-secondary: #0e2740;
  --revvr-accent:    #f59e0b;
  --revvr-teal:      #0d9488;
  --revvr-bg:        #f8fafc;
}

body {
  background-color: var(--revvr-bg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  color: #1e293b;
}

/* ---- Navbar ---- */
.navbar.bg-primary { background-color: var(--revvr-primary) !important; }

/* ---- Hero section ---- */
.hero-section {
  position: relative;
  background-color: var(--revvr-primary);
  background-size: cover;
  background-position: center top;
  background-repeat: no-repeat;
  min-height: 520px;
  display: flex;
  align-items: center;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(10,28,48,.55) 0%, rgba(10,28,48,.72) 100%);
  width: 100%;
}

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

.hero-input {
  border: none;
  box-shadow: 0 2px 8px rgba(0,0,0,.15);
}

/* ---- Listing cards ---- */
.listing-card {
  transition: transform .2s ease, box-shadow .2s ease;
  border-radius: 12px !important;
  overflow: hidden;
}

.listing-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0,0,0,.12) !important;
}

.listing-card-img-wrap {
  position: relative;
  overflow: hidden;
  height: 200px;
}

.listing-card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .3s ease;
}

.listing-card:hover .listing-card-img {
  transform: scale(1.04);
}

.category-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  font-size: .7rem;
}

.listing-title-clamp {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ---- Category cards on home ---- */
.cat-card-home {
  transition: transform .2s, box-shadow .2s;
  cursor: pointer;
  border-radius: 12px !important;
}

.cat-card-home:hover {
  transform: translateY(-4px);
  box-shadow: 0 6px 20px rgba(0,0,0,.1) !important;
}

/* ---- Gallery ---- */
.gallery-thumb {
  width: 72px;
  height: 56px;
  object-fit: cover;
  cursor: pointer;
  opacity: .7;
  transition: opacity .15s;
  border: 2px solid transparent;
  flex-shrink: 0;
}

.gallery-thumb:hover,
.gallery-thumb.active {
  opacity: 1;
  border-color: var(--revvr-primary);
}

/* ---- Booking widget sticky ---- */
@media (min-width: 992px) {
  .booking-sticky { position: sticky; top: 80px; }
}

/* ---- Messages ---- */
.message-bubble {
  max-width: 320px;
  word-break: break-word;
  font-size: .9rem;
  line-height: 1.5;
}

.message-bubble.mine {
  background-color: var(--revvr-primary);
  color: #fff;
  border-radius: 18px 18px 4px 18px;
}

.message-bubble.theirs {
  background-color: #e2e8f0;
  color: #1e293b;
  border-radius: 18px 18px 18px 4px;
}

.conv-item.hover-bg-light:hover {
  background-color: #f1f5f9;
}

/* ---- Availability calendar ---- */
.availability-cal {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  max-width: 320px;
}

.avail-day {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .75rem;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 500;
  user-select: none;
  border: 1px solid transparent;
}

.avail-day.available  { background: #dcfce7; color: #15803d; border-color: #86efac; }
.avail-day.blocked    { background: #fee2e2; color: #dc2626; border-color: #fca5a5; }
.avail-day.past       { background: #f1f5f9; color: #94a3b8; cursor: default; }
.avail-day.header     { font-weight: 700; font-size: .7rem; background: none; cursor: default; color: #64748b; }

/* ---- Stars ---- */
.stars { display: inline-flex; gap: 1px; }

/* ---- Admin ---- */
.btn-xs { font-size: .7rem; padding: 2px 6px; }

/* ---- Form borders ---- */
.border-dashed { border-style: dashed !important; }

/* ---- Listing form steps ---- */
.step-btn.active { background-color: var(--revvr-primary) !important; border-color: var(--revvr-primary) !important; color: #fff !important; }
.step-btn        { background-color: transparent; border: 1px solid #dee2e6; color: #6c757d; font-size: .85rem; }

/* ---- Upload drop zone ---- */
#drop-zone {
  transition: background .2s, border-color .2s;
  cursor: pointer;
  border-color: #ced4da !important;
}
#drop-zone.dragover {
  background: #eff6ff;
  border-color: var(--revvr-primary) !important;
}

/* ---- Photo preview grid item ---- */
.photo-preview-item {
  position: relative;
}
.photo-preview-item img {
  width: 100%;
  height: 80px;
  object-fit: cover;
  border-radius: 6px;
}
.photo-preview-item .remove-photo {
  position: absolute;
  top: 4px;
  right: 4px;
  background: rgba(0,0,0,.6);
  color: white;
  border: none;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  font-size: .6rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

/* ---- Category image cards ---- */
.cat-img-card {
  position: relative;
  height: 160px;
  border-radius: 12px;
  overflow: hidden;
  background-color: #1e3a5f;
  background-size: cover;
  background-position: center;
  transition: transform .25s ease, box-shadow .25s ease;
}

.cat-img-card:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 10px 28px rgba(0,0,0,.4);
}

.cat-img-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,.72) 0%, rgba(0,0,0,.15) 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  padding: 14px 8px;
  color: #fff;
  text-align: center;
  font-size: .85rem;
}

/* ---- Scenic strip ---- */
.scene-strip {
  position: relative;
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  min-height: 320px;
  display: flex;
  align-items: center;
}

.scene-strip-overlay {
  position: absolute;
  inset: 0;
  background: rgba(10, 25, 47, 0.52);
  display: flex;
  align-items: center;
  width: 100%;
}

.scene-strip-overlay > .container { position: relative; z-index: 1; }

/* ---- How it works cards ---- */
.hiw-img-wrap {
  position: relative;
  height: 200px;
  overflow: hidden;
}

.hiw-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .35s ease;
}

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

.hiw-step-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--revvr-accent);
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0,0,0,.25);
}

/* ---- Trust section ---- */
.trust-section {
  position: relative;
  background-size: cover;
  background-position: center;
  min-height: 360px;
  display: flex;
  align-items: center;
}

.trust-overlay {
  position: absolute;
  inset: 0;
  background: rgba(10, 25, 47, 0.78);
  width: 100%;
  display: flex;
  align-items: center;
}

.trust-overlay > .container { position: relative; z-index: 1; }

.trust-icon-wrap {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  background: rgba(255,255,255,.1);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* ---- Responsive tweaks ---- */
@media (max-width: 767px) {
  .hero-section { min-height: 440px; }
  .display-3 { font-size: 2rem; }
  .display-4 { font-size: 1.8rem; }
  .cat-img-card { height: 120px; }
  .scene-strip  { background-attachment: scroll; }
  .trust-section { background-attachment: scroll; }
}

/* ---- Utilities ---- */
.rounded-4 { border-radius: 1rem !important; }
.object-fit-cover { object-fit: cover; }
.text-primary { color: var(--revvr-primary) !important; }
.bg-primary   { background-color: var(--revvr-primary) !important; }
.btn-primary  { background-color: var(--revvr-primary); border-color: var(--revvr-primary); }
.btn-primary:hover { background-color: var(--revvr-secondary); border-color: var(--revvr-secondary); }
.btn-outline-primary { color: var(--revvr-primary); border-color: var(--revvr-primary); }
.btn-outline-primary:hover { background-color: var(--revvr-primary); border-color: var(--revvr-primary); }
