/* ===== Estilo base ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Poppins", Arial, sans-serif;
}

body {
  background: linear-gradient(135deg, #6a11cb, #2575fc);
  color: #333;
}

/* ===== Barra de pesquisa ===== */
.search-bar {
  background: #fff;
  padding: 20px;
  box-shadow: 0 3px 10px rgba(0,0,0,0.1);
  margin: 20px auto;
  max-width: 1100px;
  border-radius: 12px;
}

.search-bar form {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: center;
}

.search-bar select,
.search-bar button {
  padding: 12px 15px;
  font-size: 1rem;
  border-radius: 8px;
  border: 1px solid #ccc;
  background: #fff;
  transition: all 0.3s ease;
}

.search-bar select:hover {
  border-color: #007bff;
}

.search-bar button {
  background: #007bff;
  color: #fff;
  border: none;
  cursor: pointer;
  font-weight: 600;
  box-shadow: 0 2px 6px rgba(0, 123, 255, 0.3);
}

.search-bar button:hover {
  background: #0056b3;
  box-shadow: 0 3px 10px rgba(0, 123, 255, 0.5);
}

/* ===== Container ===== */
.container {
  width: 95%;
  max-width: 1100px;
  margin: 30px auto;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
}

/* ===== Card de produto ===== */
.listing {
  background: #fff;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 4px 14px rgba(0,0,0,0.08);
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
}

.listing:hover {
  transform: translateY(-6px);
  box-shadow: 0 6px 18px rgba(0,0,0,0.12);
}

/* ===== Imagem ===== */
.offer-img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-bottom: 1px solid #eee;
}

/* ===== Informações ===== */
.listing-info {
  padding: 15px 18px 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

/* ===== Links dos cards ===== */
.listing-link {
  text-decoration: none;
  color: inherit;
  display: block;
  border-radius: 14px;
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.listing-link:hover {
  transform: translateY(-6px);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.12);
}

/* ===== Cards ===== */
.listing {
  background: #fff;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.offer-img {
  width: 100%;
  height: 190px;
  object-fit: cover;
  border-bottom: 1px solid #eee;
}


.listing-title {
    font-weight: 600;
    color: #222;
    margin-bottom: -2px;

    font-size: .99rem;       /* tamanho menor */
    white-space: nowrap;      /* mantém tudo em uma linha */
    overflow: hidden;         /* esconde texto que ultrapassar o container */
    text-overflow: ellipsis;  /* mostra "..." se o texto for longo */
    max-width: 96%;           /* limita espaço do título, preservando o botão Ver mais */
    margin-top: 10px;
}


.listing-sub {
  background: #f1f7ff;
  color: #0056b3;
  padding: 8px 10px;
  border-radius: 8px;
  text-align: center;
  font-weight: 600;
  margin-top: auto;
  transition: all 0.3s ease;
}

.listing-link:hover .listing-sub {
  background: #007bff;
  color: #fff;
}

/* ===== Efeito no hover geral ===== */
.listing-link:hover .company-name {
  color: #0056b3;
}


/* ===== Responsividade ===== */
@media (max-width: 600px) {
  .search-bar form {
    flex-direction: column;
  }

  .offer-img {
    height: 160px;
  }

  .company-name {
    font-size: 1.1rem;
  }
}

/* ===== Animação leve de entrada ===== */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(15px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.listing {
  animation: fadeUp 0.5s ease both;
}

.image-slider {
    overflow: hidden;
    width: 100%;
    height: 200px; /* altura fixa que você deseja */
}

.slider-track {
    display: flex;
    transition: transform 0.5s ease;
    height: 100%; /* garante que o track ocupe toda altura do slider */
}

.slide {
    min-width: 100%;
    box-sizing: border-box;
    height: 100%; /* cada slide ocupa toda altura */
}

.slide img {
    width: 100%;
    height: 100%; /* ocupa altura do slide */
    object-fit: cover; /* preenche o espaço sem deformar a imagem */
    display: block;
}


.btn-like {
    background: none;
    border: none;
    color: #ccc; /* cinza apagado */
    cursor: pointer;
    font-size: 1.2em;
    margin-left: 5px;
    transition: color 0.2s, transform 0.2s;
}

.btn-like:hover {
    transform: scale(1.2);
}

.btn-like.active {
    color: #ff4d4d; /* vermelho quando ativo */
}

.btn-ver-mais-index {
    display: inline-block;
    background-color: #007bff;
    color: #fff;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 5px;
    font-size: 0.9rem;
    cursor: default;      /* apenas visual */
    pointer-events: none; /* desativa clique */
    margin-left: auto; 
}


.floating-btn {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: #ff4d4d;
    color: #fff;
    padding: 15px 25px;
    border-radius: 50px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    z-index: 9999;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    cursor: pointer;
    animation: pulse 1.5s infinite;
}

.floating-btn .btn-text {
    color: #fff;
    text-decoration: none;
    font-size: 1rem;
}

.close-btn {
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
}

/* Pulsação */
@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

.offer-price {
    margin-top: 10px; /* aumentei o espaçamento acima */
    font-size: 15px;
    color: #333;
    line-height: 1.5; /* deixa o texto mais espaçado verticalmente */
}

.price-value {
    margin: 6px 0; /* separa um pouco mais */
    font-weight: 600;
    color: #1c8d36;
    font-size: 14px;
}

.stock-value {
    font-size: 15px;
    color: #000000;
    font-weight: 600;
    margin-top: 10px; /* aumenta o espaço acima */
}


.company-name {
    display: flex;
    align-items: center;
    width: 100%;
    gap: 10px;
}

/* Cidade e estado */
.company-location {
  font-size: 1.0rem;
  color: #000000;
  margin: 20px 0 10px 0; /* aumenta o espaço acima e abaixo */
  display: flex;
  align-items: center;
  gap: 6px; /* separa o emoji do texto */
}

.expires {
    color: red;
    font-weight: bold;
    font-size: 14px;
    white-space: nowrap; /* impede quebra de linha */
    overflow: hidden; /* evita overflow visual */
    text-overflow: ellipsis; /* adiciona "..." se ficar muito longo */
    display: inline-block; /* garante alinhamento em linha */
    vertical-align: middle; /* mantém alinhado ao texto vizinho */
    margin-top: 1px;
}

.expires.no-expiration {
    color: #00960c; /* cor que você quiser */
    font-style: normal; /* mantém o estilo normal ou itálico se quiser */
    font-weight: 600;   /* opcional: deixa mais destacado */
}
