/* home.css — index-only styles: background + arrow + overlay + subscribe + sliding footer */
:root{
  --reveal-duration: 420ms;
  --reveal-ease: cubic-bezier(.2,.9,.2,1);
}

/* Static full-page background image */
.home-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  background: url("assets/bg3.jpg") center / cover no-repeat;
}

/* Layer above background */
.home-layer {
  position: relative;
  z-index: 1;
  min-height: 140vh; /* gives scroll room */
}

/* ================= HOME HERO (fixed slogan that slides away on reveal) ================= */
.home-hero-fixed{
  position: fixed;
  inset: 0;
  z-index: 60; /* below overlay(70), footer(75), subscribe(80), arrow(90) */
  display: flex;
  align-items: center; /* vertical middle */
  pointer-events: none;

  transform: translateY(0);
  opacity: 1;
  transition: transform var(--reveal-duration) var(--reveal-ease),
              opacity var(--reveal-duration) var(--reveal-ease);
}

.home-hero-inner{
  width: min(1100px, 92%);
  margin: 0 auto;

  /* slightly towards the left */
  padding-left: clamp(6px, 2vw, 28px);

  /* keep it visually centered even with a fixed header */
  padding-top: 80px;
  padding-bottom: 40px;
}

.home-hero-text{
  margin: 0;
  color: #fff;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 0.98;

  font-size: clamp(44px, 6.2vw, 96px);

  /* subtle separation from the background image */
  text-shadow:
    0 2px 14px rgba(0,0,0,.35),
    0 1px 2px rgba(0,0,0,.25);

  max-width: 12.5ch;
}

/* Prevent breaking inside each line (keeps 3 lines, avoids 4th wrap) */
.home-hero-3lines > span{
  white-space: nowrap;
}

/* When revealed, slogan moves up and fully exits above the header */
body.subscribe-revealed .home-hero-fixed{
  transform: translateY(-120vh);
  opacity: 0;
}

/* Tight spacing exactly on the 3-line slogan */
.home-hero-3lines{
  margin: 0;
  line-height: 1.12;  /* tighter line spacing between the 3 lines */
}

/* Arrow button bottom-right */
.home-arrow {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 90;

  width: 54px;
  height: 54px;
  border-radius: 999px;
  border: 1px solid rgba(11,16,32,.18);
  background: rgba(251,248,242,.85);
  backdrop-filter: blur(10px);

  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;

  transition: transform 220ms ease, bottom var(--reveal-duration) var(--reveal-ease);
}

.home-arrow img {
  width: 22px;
  height: 22px;
  display: block;
  object-fit: contain;

  /* smooth flip */
  transform: scaleY(1);
  transition: transform var(--reveal-duration) var(--reveal-ease);
}

/* When scrolled down / revealed, flip arrow vertically (points up) */
body.subscribe-revealed .home-arrow img{
  transform: scaleY(-1);
}

.home-arrow:hover {
  transform: translateY(-2px);
}

/* Rising semi-transparent overlay (covers background, but bg stays static) */
.home-overlay {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 70;

  height: 65vh; /* how much of the image gets covered when revealed */
  background: rgba(251,248,242,.55);
  backdrop-filter: blur(10px);
  border-top: 2px solid rgba(11,16,32,.15);

  transform: translateY(110%);
  transition: transform var(--reveal-duration) var(--reveal-ease);
}

/* Subscribe UI: ends centered on screen when revealed */
.subscribe-center {
  position: fixed;
  left: 50%;
  top: 50%;
  z-index: 80;
  width: min(720px, 92%);

  /* Start off-screen below */
  transform: translate(-50%, 110vh);
  transition: transform var(--reveal-duration) var(--reveal-ease);

  opacity: 1;
  pointer-events: auto;
}

.subscribe-card {
  background: rgba(251,248,242,.92);
  border: 1px solid rgba(11,16,32,.15);
  border-radius: 16px;
  padding: 18px;
  backdrop-filter: blur(10px);
}

.subscribe-card h2 {
  margin: 0 0 8px;
  font-size: 18px;
  line-height: 1.2;
  text-align: center;
}

.subscribe-card p {
  margin: 0 0 14px;
  color: rgba(11,16,32,.70);
  font-size: 13px;
  text-align: center;
}

.subscribe-form {
  display: flex;
  gap: 10px;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
}

.subscribe-form input[type="email"] {
  height: 42px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid rgba(11,16,32,.15);
  background: rgba(11,16,32,.03);
  min-width: 280px;
  outline: none;
}

.subscribe-form input[type="email"]:focus {
  border-color: rgba(255,140,0,.55);
  box-shadow: 0 0 0 3px rgba(255,140,0,.18);
}

/* Footer: fixed + slides up only on reveal */
.home-footer {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 75;

  transform: translateY(110%);
  transition: transform var(--reveal-duration) var(--reveal-ease);

  background: rgba(251,248,242,.92);
  backdrop-filter: blur(10px);
  border-top: 2px solid rgba(11,16,32,.15);
}

.home-footer-inner {
  width: min(1100px, 92%);
  margin: 0 auto;
  padding: 14px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.footer-left {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.footer-contact {
  display: flex;
  align-items: center;
  gap: 10px;
}

.footer-contact .label {
  font-size: 13px;
  color: rgba(11,16,32,.70);
}

.footer-icon {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  border: 1px solid rgba(11,16,32,.15);
  background: rgba(11,16,32,.03);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.footer-icon img {
  width: 18px;
  height: 18px;
  display: block;
  object-fit: contain;
}

/* REVEAL state (scroll down or arrow click) */
body.subscribe-revealed .home-overlay {
  transform: translateY(0);
}

body.subscribe-revealed .subscribe-center {
  opacity: 1;
  pointer-events: auto;
  transform: translate(-50%, -50%);
}

body.subscribe-revealed .home-footer {
  transform: translateY(0);
}

/* Arrow rises together with overlay/footer */
body.subscribe-revealed .home-arrow {
  bottom: calc(22px + 65vh);
}

@media (max-width: 700px) {
  body.subscribe-revealed .home-arrow {
    bottom: calc(18px + 55vh);
  }
  .home-overlay { height: 55vh; }
}

@media (max-width: 600px) {
  .subscribe-form input[type="email"] {
    min-width: 200px;
    width: 100%;
  }
}
