/* =========================================================
   PÁGINA DE CUPONS - ESTILO DE "TICKETS"
   ========================================================= */

body {
  background-color: #f7f7f7;
}

.coupons-main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 20px;
}

.coupons-header-section {
  text-align: center;
  margin-bottom: 40px;
}

.coupons-header-section h1 {
  font-size: 2.2rem;
  color: #333;
  margin-bottom: 10px;
}

.coupons-header-section p {
  color: #666;
  font-size: 1.1rem;
}

/* --- GRID --- */
.coupons-grid-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 25px;
  justify-items: center;
}

.loading-coupons {
  text-align: center;
  width: 100%;
  grid-column: 1 / -1;
  padding: 50px 0;
  color: #888;
  font-size: 1.2rem;
}

/* --- CARTÃO TIPO TICKET --- */
.coupon-card {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  width: 100%;
  max-width: 360px;
  position: relative;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid #f0f0f0;
}

.coupon-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(255, 87, 34, 0.15);
}

/* Header do Ticket (Laranja) */
.coupon-header {
  background: linear-gradient(135deg, #ff5722 0%, #ff8a65 100%);
  color: white;
  padding: 25px 20px;
  text-align: center;
  position: relative;
}

/* Corte característico de Ticket */
.coupon-header::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 0;
  width: 100%;
  height: 20px;
  background-image: radial-gradient(circle at 10px 0, transparent 10px, #fff 11px);
  background-size: 25px 20px;
  background-repeat: repeat-x;
}

.coupon-discount {
  font-size: 2.5rem;
  font-weight: 800;
  line-height: 1;
  text-shadow: 1px 1px 3px rgba(0,0,0,0.2);
}

.coupon-store {
  margin-top: 8px;
  font-size: 1rem;
  font-weight: 600;
  opacity: 0.9;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Corpo do Ticket */
.coupon-body {
  padding: 30px 20px 20px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.coupon-title {
  font-size: 1.1rem;
  color: #333;
  font-weight: bold;
  margin-bottom: 8px;
  line-height: 1.4;
}

.coupon-validity {
  font-size: 0.85rem;
  color: #888;
  margin-bottom: 20px;
}

/* Área do Código */
.coupon-code-area {
  margin-top: auto;
  margin-bottom: 20px;
}

.coupon-code-box {
  background: #fff9f6;
  border: 2px dashed #ff8a65;
  border-radius: 6px;
  padding: 12px;
  text-align: center;
  font-family: monospace;
  font-size: 1.2rem;
  font-weight: bold;
  color: #ff5722;
  cursor: pointer;
  position: relative;
  transition: background 0.2s;
}

.coupon-code-box:hover {
  background: #ffebe5;
}

/* Alerta de Cópia */
.copied-alert {
  position: absolute;
  top: -30px;
  left: 50%;
  transform: translateX(-50%);
  background: #4caf50;
  color: white;
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 0.75rem;
  opacity: 0;
  transition: opacity 0.3s, top 0.3s;
  pointer-events: none;
}

.copied-alert.show {
  opacity: 1;
  top: -40px;
}

/* Botão de Resgate */
.btn-redeem {
  display: block;
  background: #ff5722;
  color: white;
  text-align: center;
  padding: 14px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  font-size: 1.05rem;
  transition: background 0.3s;
}

.btn-redeem:hover {
  background: #e64a19;
}

/* Responsividade */
@media (max-width: 480px) {
  .coupons-header-section h1 {
    font-size: 1.8rem;
  }
}
