.offres-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Offers List - Responsive Grid */
.offers-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

@media (min-width: 768px) {
  .offers-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }
}

@media (min-width: 1024px) {
  .offers-list {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Offer Card */
.offer-card {
  background: #fff;
  border-radius: 1rem;
  padding: 1rem;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.02);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  position: relative;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.2s ease;
  overflow: hidden;
}

.offer-card.liking {
  animation: likeSlideUp 0.3s ease-out forwards;
}

.offer-card.rejecting {
  animation: rejectSlideDown 0.3s ease-out forwards;
}

@keyframes likeSlideUp {
  to {
    opacity: 0;
    transform: translateY(-20px);
  }
}

@keyframes rejectSlideDown {
  to {
    opacity: 0;
    transform: translateY(20px);
  }
}

.offer-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.06);
}

.offer-card.top-result {
  border-color: var(--primary-purple);
  box-shadow: 0 4px 12px rgba(106, 62, 235, 0.1);
}

@media (min-width: 768px) {
  .offer-card.top-result {
    grid-column: 1 / -1; /* Full width on tablet */
  }
}

@media (min-width: 1024px) {
  .offer-card.top-result {
    grid-column: auto; /* Normal width on desktop */
  }
}

/* Badges Area */
.card-badges,
.card-badges-simple {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  font-size: 0.7rem;
  margin-bottom: 0.25rem;
  min-height: 1.5rem;
  flex-wrap: wrap;
}

.card-badges-simple {
  justify-content: flex-end;
}

.badge-purple {
  background: var(--tag-purple-bg);
  color: var(--tag-purple-text);
  padding: 0.25rem 0.5rem;
  border-radius: 0.5rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.badge-yellow {
  background: var(--tag-yellow-bg);
  color: var(--tag-yellow-text);
  padding: 0.25rem 0.5rem;
  border-radius: 0.5rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.right-align {
  margin-left: auto;
}

/* Offer Title */
.offer-card h2 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-dark);
}

.offer-card h2.title-purple {
  color: var(--primary-purple);
}

/* Offer Body */
.offer-body {
  display: flex;
  gap: .5rem;
  align-items: center;
}

.offer-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.offer-info .company-name {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-dark);
  margin-bottom: 0;
}

.offer-info .location {
  font-size: 0.85rem;
  color: var(--text-grey);
}

.offer-info .location em {
  font-style: italic;
}

/* Offer Footer */
.offer-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 0.5rem;
}

.offer-actions {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.price {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text-dark);
}

.price .unit {
  font-size: 0.75rem;
  font-weight: 400;
  color: var(--text-grey);
}

/* Slide View */
.offers-slide {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  min-height: 500px;
  justify-content: center;
}

@media (min-width: 768px) {
  .offers-slide {
    max-width: 500px;
    margin: 0 auto;
  }
}

.slide-nav {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid #ddd;
  background: white;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-dark);
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.slide-nav:hover:not(:disabled) {
  border-color: var(--primary-purple);
  color: var(--primary-purple);
}

.slide-nav:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.slide-card {
  flex: 1;
  background: white;
  border-radius: 1rem;
  padding: 1.5rem;
  border: 2px solid var(--primary-purple);
  box-shadow: 0 4px 12px rgba(106, 62, 235, 0.1);
  max-width: 400px;
}

.slide-card h2 {
  font-size: 1.375rem;
  font-weight: 700;
  color: var(--primary-purple);
  margin: 0.5rem 0;
}

.slide-salary {
  margin: 1rem 0;
}

.slide-salary .price {
  font-size: 1.5rem;
}

.slide-location {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-grey);
  font-size: 0.9rem;
  margin-bottom: 1rem;
}

.slide-divider {
  height: 1px;
  background: #f1f5f9;
  margin: 1rem 0;
}

.slide-company {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

.slide-company .company-name {
  font-size: 1rem;
  font-weight: 600;
}

.slide-description {
  font-size: 0.875rem;
  color: var(--text-grey);
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.slide-more-btn {
  margin-bottom: 0.75rem;
}

/* Map View */
.map-view-container {
  display: flex;
  gap: 1rem;
  height: calc(100vh - 200px);
  min-height: 400px;
}

.map-sidebar {
  width: 320px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  overflow-y: auto;
  padding-right: 0.5rem;
}

.map-sidebar::-webkit-scrollbar {
  width: 4px;
}

.map-sidebar::-webkit-scrollbar-thumb {
  background: #ddd;
  border-radius: 2px;
}

.offer-card-mini {
  background: white;
  border-radius: 0.75rem;
  padding: 0.75rem;
  cursor: pointer;
  transition: all 0.2s ease;
  border: 1px solid transparent;
}

.offer-card-mini:hover {
  border-color: var(--primary-purple);
  box-shadow: 0 4px 12px rgba(106, 62, 235, 0.1);
}

.offer-card-mini .mini-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.offer-card-mini .mini-price {
  font-weight: 700;
  font-size: 0.875rem;
  color: var(--text-dark);
}

.offer-card-mini h3 {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 0.5rem;
  line-height: 1.3;
}

.offer-card-mini .mini-company {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: var(--text-dark);
  margin-bottom: 0.25rem;
}

.offer-card-mini .mini-company .company-logo {
  font-size: 1rem;
}

.offer-card-mini .mini-location {
  font-size: 0.75rem;
  color: var(--text-grey);
}

.map-area {
  flex: 1;
  background: var(--bg-body);
  border-radius: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px dashed #ddd;
}

.map-placeholder-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  color: var(--text-grey);
}

.map-placeholder-inner svg {
  opacity: 0.5;
}

.map-placeholder-inner p {
  font-size: 0.9rem;
}

/* Mobile: stack vertically */
@media (max-width: 767px) {
  .map-view-container {
    flex-direction: column-reverse;
    height: auto;
  }

  .map-sidebar {
    width: 100%;
    max-height: 300px;
  }

  .map-area {
    min-height: 300px;
  }
}

/* Like Toast */
.offres-page .like-toast {
  position: fixed;
  top: 5rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: linear-gradient(135deg, var(--primary-purple), #8B5CF6);
  color: white;
  padding: 0.75rem 1.25rem;
  border-radius: 2rem;
  box-shadow: 0 4px 20px rgba(106, 62, 235, 0.4);
  z-index: 1000;
  animation: toastSlideIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes toastSlideIn {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(-20px) scale(0.9);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0) scale(1);
  }
}

.offres-page .like-toast-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  animation: heartPulse 0.6s ease-in-out infinite;
}

@keyframes heartPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.2); }
}

.offres-page .like-toast span {
  font-size: 0.875rem;
  font-weight: 500;
}

.offres-page .like-toast strong {
  font-weight: 700;
}

.offres-page .sparkle-toast {
  color: #FFD700;
  animation: sparklePulse 0.5s ease-in-out infinite;
}

@keyframes sparklePulse {
  0%, 100% { opacity: 1; transform: rotate(0deg); }
  50% { opacity: 0.6; transform: rotate(10deg); }
}

/* Empty Results */
.offres-page .empty-results {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 1rem;
  text-align: center;
  background: white;
  border-radius: 1rem;
  width: 100%;
  max-width: 400px;
  margin: 0 auto;
  grid-column: 1 / -1;
}

.offres-page .empty-results span {
  font-size: 2.5rem;
  margin-bottom: 0.75rem;
}

.offres-page .empty-results p {
  color: var(--text-muted);
  font-size: 1rem;
  margin: 0;
}

/* ─── Filter Overlay ─────────────────────────────────────────────────────── */
.filter-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  z-index: 299;
  animation: fadeIn 0.2s ease;
}

/* ─── Filter Panel (slide-in from right) ─────────────────────────────────── */
.filter-panel {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(360px, 92vw);
  background: white;
  z-index: 300;
  display: flex;
  flex-direction: column;
  box-shadow: -4px 0 32px rgba(0, 0, 0, 0.12);
  transform: translateX(110%);
  transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}

.filter-panel.open {
  transform: translateX(0);
}

.filter-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.25rem 1rem;
  border-bottom: 1px solid #f1f5f9;
  flex-shrink: 0;
}

.filter-panel-header h3 {
  font-size: 1rem;
  font-weight: 700;
}

.filter-panel-close {
  background: var(--bg-body);
  border: none;
  border-radius: 50%;
  width: 2rem;
  height: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  cursor: pointer;
  color: var(--text-grey);
  transition: background 0.2s;
}

.filter-panel-close:hover {
  background: #e2e8f0;
  color: var(--text-dark);
}

.filter-panel-body {
  flex: 1;
  overflow-y: auto;
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.filter-section-title {
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--text-dark);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.5rem;
}

.filter-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-grey);
  margin-bottom: -0.25rem;
}

.filter-hr {
  border: none;
  border-top: 1px solid #f1f5f9;
  margin: 0.25rem 0;
}

.filter-slider-wrap {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 0 0.25rem;
}

/* Min/max input fields */
.filter-amounts {
  display: flex;
  gap: 0.75rem;
}

.filter-amount-field {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  position: relative;
}

.filter-amount-field::before {
  content: attr(data-label);
  font-size: 0.7rem;
  color: var(--text-grey);
  font-weight: 500;
}

.filter-amount-field::after {
  content: attr(data-unit);
  position: absolute;
  right: 0.5rem;
  bottom: 0.5rem;
  font-size: 0.75rem;
  color: var(--text-grey);
  pointer-events: none;
}

.filter-amount-field input {
  padding: 0.5rem 1.5rem 0.5rem 0.625rem;
  border: 1.5px solid #e2e8f0;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  font-family: inherit;
  color: var(--text-dark);
  outline: none;
  width: 100%;
  transition: border-color 0.2s;

  /* Hide browser spin arrows */
  -moz-appearance: textfield;
  appearance: textfield;
}

.filter-amount-field input::-webkit-outer-spin-button,
.filter-amount-field input::-webkit-inner-spin-button {
  -webkit-appearance: none;
}

.filter-amount-field input:focus {
  border-color: var(--primary-purple);
}

.filter-panel-sticky {
  flex-shrink: 0;
  padding: 1rem 1.25rem;
  border-top: 1px solid #f1f5f9;
  background: white;
}
