/* ── WRAPPER ── */
#hero-text {
  text-align: center;
  width: 100%;
  box-sizing: border-box;
}

/* ── HEADLINE ── */
#headline-wrap {
  position: relative;
  overflow: hidden;
  height: 1.5em;
  font-size: clamp(40px, 7vw, 100px);
  margin-bottom: 0.04em;
}

.phrase {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: inherit;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -2px;
  white-space: nowrap;
  opacity: 0;
  transform: translateY(-100%);
  will-change: transform, opacity;
}

.phrase.slide-in {
  animation: phraseIn 650ms cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.phrase.slide-out {
  animation: phraseOut 500ms cubic-bezier(0.4, 0, 1, 1) forwards;
}

/* ── ANIMATIONS ── */
@keyframes phraseIn {
  from { transform: translateY(-80px); opacity: 0; }
  to   { transform: translateY(0); opacity: 1; }
}

@keyframes phraseOut {
  from { transform: translateY(0); opacity: 1; }
  to   { transform: translateY(80px); opacity: 0; }
}

/* ── COLORS ── */
.phrase[data-color="red"]    { color: #EA4335; }
.phrase[data-color="green"]  { color: #34A853; }
.phrase[data-color="blue"]   { color: #c5e930; }
.phrase[data-color="yellow"] { color: #4285F4; }

/* ── STATIC LINE ── */
#static-wrap {
  display: flex;
  justify-content: center;
  overflow: hidden;
}

#static-line {
  font-size: clamp(40px, 7vw, 90px);
  font-weight: 700;
  line-height: 1.15;
  color: #202124;
  letter-spacing: -2px;
  display: inline-flex;
  align-items: center;
  animation: phraseIn 650ms 100ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

/* ── PAUSE BUTTON ── */
#pauseBtn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(0,0,0,0.07);
  border: none;
  margin-left: 10px;
  margin-bottom: -4px;
  cursor: pointer;
  color: #202124;
  transition: background 0.2s;
}

#pauseBtn:hover {
  background: rgba(0,0,0,0.14);
}

#pauseBtn svg {
  width: 13px;
  height: 13px;
  pointer-events: none;
}

/* ── SUBTEXT ── */
#hero-subtext {
  margin: 28px auto 0;
  font-size: clamp(15px, 2vw, 18px);
  font-weight: 400;
  color: #5f6368;
  line-height: 2;
  opacity: 0;
  animation: subIn 500ms 380ms ease forwards;
}

@keyframes subIn {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── CTA ROW ── */
#cta-row {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  margin-top: 32px;
  flex-wrap: wrap;
}

/* ── BUTTONS ── */
#btn-primary,
#btn-secondary {
  border: none;
  border-radius: 24px;
  padding: 14px 28px;
  font-size: 16px;
  font-family: 'Google Sans', sans-serif;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
}

/* primary */
#btn-primary {
  background: #c5e930;
  color: #0a0a0a;
}

#btn-primary:hover {
  background: #1a4d3b;
  box-shadow: 0 2px 10px rgba(26,115,232,0.35);
}

/* secondary */
#btn-secondary {
  background: #1a4d3b;
  color: #fff;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

#btn-secondary:hover {
  background: #e8eaed;
}

#btn-secondary svg {
  flex-shrink: 0;
}

/* ── TABLET ── */
@media (max-width: 768px) {
  #hero-text {
    padding: 48px 20px 32px;
  }

  .phrase,
  #static-line {
    letter-spacing: -1px;
  }

  #cta-row {
    gap: 10px;
    margin-top: 28px;
  }

  #btn-primary,
  #btn-secondary {
    padding: 12px 24px;
    font-size: 15px;
  }
}

/* ── MOBILE ── */
@media (max-width: 480px) {
  #headline-wrap {
    height: auto;
    min-height: 2.4em;
    font-size: clamp(32px, 10vw, 48px);
  }

  .phrase {
    font-size: inherit;
    white-space: normal;
    text-align: center;
    letter-spacing: -0.5px;
    padding: 4px 8px 0;
    align-items: flex-start;
  }

  #static-line {
    font-size: inherit;
    letter-spacing: -0.5px;
    flex-wrap: wrap;
    justify-content: center;
  }

  #pauseBtn {
    width: 26px;
    height: 26px;
    margin-left: 8px;
  }

  #hero-subtext {
    font-size: 15px;
    margin-top: 20px;
  }

  #cta-row {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
    margin-top: 24px;
  }

  #btn-primary,
  #btn-secondary {
    width: 100%;
    justify-content: center;
    padding: 14px 20px;
    font-size: 15px;
  }

  /* mobile logic */
  #btn-primary {
    display: none;
  }

  #btn-secondary {
    display: flex;
    background-color: #c5e930;
    color: #0a0a0a;
  }
}