/* ===== VARIABLES ===== */
:root {
  --primary-color: #ff6b6b;
  --secondary-color: #4ecdc4;
  --accent-color: #ffe66d;
  --dark-color: #2c3e50;
  --light-color: #ecf0f1;
  --white: #ffffff;
  --gray: #95a5a6;
  --success: #2ecc71;
  --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.15);
  --transition: all 0.3s ease;
}

/* ===== RESET & BASE ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Poppins", sans-serif;
  line-height: 1.6;
  color: var(--dark-color);
  background-color: var(--light-color);
  overflow-x: hidden;
}

html {
  scroll-behavior: smooth;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition);
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
  height: auto;
}

/* ===== UTILITIES ===== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.section__title {
  font-size: 2.5rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 1rem;
  color: var(--dark-color);
}

.section__subtitle {
  text-align: center;
  color: var(--gray);
  font-size: 1.1rem;
  margin-bottom: 3rem;
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-block;
  padding: 12px 30px;
  border-radius: 50px;
  font-weight: 600;
  transition: var(--transition);
  cursor: pointer;
  border: none;
  font-size: 1rem;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary-color), #ff8787);
  color: var(--white);
  box-shadow: var(--shadow);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-secondary {
  background: var(--white);
  color: var(--primary-color);
  border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
  background: var(--primary-color);
  color: var(--white);
}

/* ===== HEADER & NAVIGATION ===== */
.header {
  background: var(--white);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.nav {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0.9rem 20px;
  gap: 3rem;
  max-width: 1400px;
  margin: 0 auto;
}

.nav__logo {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  min-width: 180px;
}

.logo-icon {
  font-size: 1.5rem;
}

.nav__logo h1 {
  font-size: 1.6rem;
  color: #5568d3;
  font-weight: 600;
  margin: 0;
}

.nav__menu {
  display: flex;
  gap: 0.3rem;
  align-items: center;
  margin: 0;
}

.nav__link {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-weight: 400;
  transition: var(--transition);
  padding: 6px 14px;
  border-radius: 6px;
  color: #5f6368;
  font-size: 0.95rem;
}

.nav-icon {
  font-size: 1rem;
}

.nav__link:hover {
  background: #f8f9fa;
  color: #5568d3;
}

.nav__actions {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex: 1;
  justify-content: flex-end;
}

.nav__category {
  padding: 7px 14px;
  border: 1px solid #dadce0;
  border-radius: 6px;
  font-family: inherit;
  font-size: 0.9rem;
  background: var(--white);
  cursor: pointer;
  transition: var(--transition);
  color: #5f6368;
}

.nav__category:focus {
  outline: none;
  border-color: #5568d3;
}

.nav__category:hover {
  border-color: #5568d3;
}

.nav__search {
  padding: 7px 16px;
  border: 1px solid #dadce0;
  border-radius: 6px;
  font-family: inherit;
  font-size: 0.9rem;
  width: 320px;
  transition: var(--transition);
  color: #5f6368;
}

.nav__search::placeholder {
  color: #9aa0a6;
}

.nav__search:focus {
  outline: none;
  border-color: #5568d3;
}

.nav__search:hover {
  border-color: #5568d3;
}

.nav__search-btn {
  background: #5568d3;
  color: var(--white);
  border: none;
  padding: 7px 16px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 1rem;
  transition: var(--transition);
}

.nav__search-btn:hover {
  background: #4153b8;
}

.btn-cadastro {
  background: #5568d3;
  color: var(--white);
  padding: 7px;
  border-radius: 50%;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  transition: var(--transition);
}

.btn-cadastro:hover {
  background: #4153b8;
}

.nav__toggle {
  display: none;
  flex-direction: column;
  gap: 4px;
  background: none;
  border: none;
  cursor: pointer;
}

.nav__toggle span {
  width: 24px;
  height: 2px;
  background: #5f6368;
  border-radius: 2px;
  transition: var(--transition);
}

/* ===== HERO SECTION ===== */
.hero {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: var(--white);
  padding: 4rem 0;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1440 320"><path fill="%23ffffff" fill-opacity="0.1" d="M0,96L48,112C96,128,192,160,288,160C384,160,480,128,576,122.7C672,117,768,139,864,138.7C960,139,1056,117,1152,106.7C1248,96,1344,96,1392,96L1440,96L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z"></path></svg>')
    no-repeat bottom;
  background-size: cover;
}

.hero__content {
  position: relative;
  z-index: 1;
  text-align: center;
  animation: fadeInUp 1s ease;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero__title {
  font-size: 3rem;
  margin-bottom: 1.5rem;
  line-height: 1.2;
}

.hero__description {
  font-size: 1.25rem;
  margin-bottom: 2rem;
  opacity: 0.9;
}

.hero__cta {
  display: flex;
  gap: 1rem;
  justify-content: center;
  margin-bottom: 3rem;
}

.hero__stats {
  display: flex;
  justify-content: center;
  gap: 4rem;
  margin-top: 3rem;
}

.stat {
  text-align: center;
}

.stat__number {
  display: block;
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.stat__label {
  display: block;
  font-size: 0.9rem;
  opacity: 0.8;
}

/* ===== HERO ANUNCIOS ===== */
.hero--anuncios {
  background: linear-gradient(135deg, #22c55e 0%, #15803d 100%);
}

/* ===== CUPONS SECTION ===== */
.cupons {
  padding: 4rem 0;
  background: var(--light-color);
}

.cupons__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.cupom-card {
  background: var(--white);
  border-radius: 15px;
  padding: 1.5rem;
  box-shadow: var(--shadow);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
  animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.cupom-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.cupom-card__badge {
  position: absolute;
  top: 15px;
  right: 15px;
  background: linear-gradient(135deg, var(--primary-color), #ff8787);
  color: var(--white);
  padding: 8px 15px;
  border-radius: 20px;
  font-weight: 700;
  font-size: 0.85rem;
}

.cupom-card__header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

.cupom-card__logo {
  font-size: 2.5rem;
  width: 60px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--light-color);
  border-radius: 10px;
}

.cupom-card__store {
  font-size: 1.3rem;
  font-weight: 600;
}

.cupom-card__description {
  color: var(--gray);
  margin-bottom: 1.5rem;
  line-height: 1.5;
}

.cupom-card__code {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: var(--light-color);
  padding: 12px;
  border-radius: 10px;
  margin-bottom: 1rem;
  border: 2px dashed var(--primary-color);
}

.code-text {
  flex: 1;
  font-family: "Courier New", monospace;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--primary-color);
}

.btn-copy {
  background: var(--primary-color);
  color: var(--white);
  border: none;
  padding: 8px 20px;
  border-radius: 20px;
  cursor: pointer;
  font-weight: 600;
  transition: var(--transition);
}

.btn-copy:hover {
  background: #ff8787;
  transform: scale(1.05);
}

.cupom-card__footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--gray);
  font-size: 0.9rem;
}

.no-results {
  text-align: center;
  padding: 3rem;
  font-size: 1.2rem;
  color: var(--gray);
}

/* ===== COMO FUNCIONA ===== */
.como-funciona {
  background: var(--white);
  padding: 4rem 0;
}

.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 3rem;
}

.step {
  text-align: center;
  padding: 2rem;
  transition: var(--transition);
}

.step:hover {
  transform: translateY(-10px);
}

.step__icon {
  font-size: 4rem;
  margin-bottom: 1rem;
}

.step__title {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: var(--dark-color);
}

.step__description {
  color: var(--gray);
  line-height: 1.6;
}

/* ===== NEWSLETTER ===== */
.newsletter {
  background: linear-gradient(135deg, var(--secondary-color), #45b7af);
  color: var(--white);
  padding: 4rem 0;
}

.newsletter__content {
  text-align: center;
  max-width: 600px;
  margin: 0 auto;
}

.newsletter__title {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.newsletter__description {
  font-size: 1.1rem;
  margin-bottom: 2rem;
  opacity: 0.9;
}

.newsletter__form {
  display: flex;
  gap: 1rem;
  justify-content: center;
  margin-bottom: 1rem;
}

.newsletter__input {
  flex: 1;
  padding: 15px 25px;
  border: none;
  border-radius: 50px;
  font-family: inherit;
  font-size: 1rem;
}

.newsletter__input:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.3);
}

.newsletter__privacy {
  font-size: 0.9rem;
  opacity: 0.8;
}

/* ===== FOOTER ===== */
.footer {
  background: var(--dark-color);
  color: var(--white);
  padding: 3rem 0 1rem;
}

.footer__content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer__title {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.footer__subtitle {
  font-size: 1.1rem;
  margin-bottom: 1rem;
}

.footer__text {
  opacity: 0.8;
  line-height: 1.6;
}

.footer__links {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.footer__links a {
  opacity: 0.8;
  transition: var(--transition);
}

.footer__links a:hover {
  opacity: 1;
  color: var(--primary-color);
}

.footer__bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  opacity: 0.8;
}

/* ===== TOAST NOTIFICATION ===== */
.toast {
  position: fixed;
  bottom: -100px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--success);
  color: var(--white);
  padding: 15px 30px;
  border-radius: 50px;
  display: flex;
  align-items: center;
  gap: 10px;
  box-shadow: var(--shadow-lg);
  transition: bottom 0.3s ease;
  z-index: 10000;
}

.toast.show {
  bottom: 30px;
}

.toast__icon {
  font-size: 1.5rem;
  font-weight: 700;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .nav {
    flex-wrap: wrap;
  }

  .nav__menu {
    position: fixed;
    top: 60px;
    left: -100%;
    width: 100%;
    height: calc(100vh - 60px);
    background: var(--white);
    flex-direction: column;
    justify-content: flex-start;
    padding: 2rem;
    transition: var(--transition);
    box-shadow: var(--shadow);
  }

  .nav__menu.active {
    left: 0;
  }

  .nav__actions {
    order: 3;
    width: 100%;
    margin-top: 0.5rem;
  }

  .nav__search {
    flex: 1;
  }

  .nav__toggle {
    display: flex;
  }

  .hero__title {
    font-size: 2rem;
  }

  .hero__description {
    font-size: 1rem;
  }

  .hero__cta {
    flex-direction: column;
    align-items: center;
  }

  .hero__stats {
    flex-direction: column;
    gap: 2rem;
  }

  .section__title {
    font-size: 2rem;
  }

  .cupons__grid {
    grid-template-columns: 1fr;
  }

  .filter__controls {
    flex-direction: column;
  }

  .filter__search {
    max-width: 100%;
  }

  .newsletter__form {
    flex-direction: column;
  }

  .stat__number {
    font-size: 2rem;
  }
}

@media (max-width: 480px) {
  .hero__title {
    font-size: 1.5rem;
  }

  .nav__logo h1 {
    font-size: 1.5rem;
  }

  .cupom-card__badge {
    font-size: 0.75rem;
    padding: 6px 12px;
  }

  .step__icon {
    font-size: 3rem;
  }
}
