/* ------------------------- */
/* Global Styles             */
/* ------------------------- */
body {
  margin: 0;
  font-family: system-ui, sans-serif;
  color: #fff;
  position: relative;
  overflow-x: hidden;
  transition: background-color 0.3s linear;
}

/* Background Overlay */
body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url("images/AdobeStock_656944603.jpeg") center/cover no-repeat;
  opacity: 0.3;
  mix-blend-mode: multiply;
  pointer-events: none;
  z-index: 0;
}

h3 {
  color: black;
}

/* Sections and phones above overlay */
.section,
.phone-container {
  position: relative;
  z-index: 2;
}

/* ------------------------- */
/* Header                    */
/* ------------------------- */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  padding: 20px 0;
  box-sizing: border-box;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  background: rgba(255, 255, 255, 0.2);
  display: flex;
  justify-content: center; /* logo centered */
  align-items: center;
}

header .logo-panel {
  width: 100vw;
  display: flex;
  flex-direction: column;
  align-items: flex-start; /* left-aligned by default */
  justify-content: flex-start;
  padding-left: 5%;
  box-sizing: border-box;
}

/* Mobile (<520px): logo centered and smaller */
@media (max-width: 900px) {
  header .logo-panel {
    width: 100%;
    align-items: center;
    padding-left: 0;
    padding-right: 0;
  }
  header .logo {
    max-width: 220px;
  }
}

header .logo {
  max-width: 400px;
  height: auto;
}

/* Very small mobile (<480px) */
@media (max-width: 480px) {
  header {
    padding: 15px 0;
  }
  header .logo {
    max-width: 220px;
  }
}

/* ------------------------- */
/* Phone Containers          */
/* ------------------------- */
/* Desktop fixed phone */
.phone-container.desktop {
  position: fixed;
  top: 10px;
  right: 5%;
  width: 320px;
  height: 640px;
  z-index: 110;
  background: url('https://upload.wikimedia.org/wikipedia/commons/3/3a/IPhone_14_Pro_vector.svg') center/contain no-repeat;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Mobile inline phones */
.phone-container.mobile {
  display: none;
}

.phone-screen {
  width: 240px;
  height: 520px;
  overflow: hidden;
  border-radius: 1.5rem;
  background-color: #000;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}

.phone-screen img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  position: absolute;
  transition: opacity 0.5s ease;
}

.phone-screen img.active {
  opacity: 1;
  position: relative;
}

/* ------------------------- */
/* Sections                  */
/* ------------------------- */
.section {
  width: 100vw;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: flex-start; /* left-aligned by default */
  justify-content: flex-start;
  padding-left: 5%;
  padding-top: 200px;
  box-sizing: border-box;
  transition: opacity 0.4s ease;
}

.content {
  max-width: 600px;
  padding: 12px;
  background-color: rgba(255, 255, 255, 0.7);
  border-radius: 1.5rem;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.content.visible {
  opacity: 1;
  transform: translateY(0);
}

.section h2 {
  font-family: 'Playwrite US Modern', 'Helvetica Neue', sans-serif;
  font-size: 2rem;
  margin-bottom: 1rem;
  color: #000;
}

.section p {
  font-size: 0.9rem;
  line-height: 1.5;
  color: #000;
}

/* ------------------------- */
/* Responsive Styles         */
/* ------------------------- */
/* Tablet portrait (520–900px) */
@media (min-width: 520px) and (max-width: 900px) {
  .section {
    align-items: center;
    text-align: center;
    padding-left: 5%;
    padding-right: 5%;
    padding-top: 200px;
  }
  .content {
    max-width: 90%;
    margin-bottom: 20px;
  }
  .phone-container.desktop {
    display: none;
  }
  .phone-container.mobile {
    display: block;
    width: 200px;
    height: 400px;
    margin: 20px auto 40px;
  }
  .phone-screen {
    width: 100%;
    height: auto;
  }
}

/* Mobile (<520px) */
@media (max-width: 519px) {
  .section {
    align-items: center;
    text-align: center;
    padding-left: 5%;
    padding-right: 5%;
    padding-top: 120px;
  }
  .section h2 {
    font-size: 1.2rem;
  }
  .section p {
    font-size: 0.6rem;
    line-height: 1.2;
  }
  .content {
    max-width: 90%;
    margin-bottom: 20px;
  }
  .phone-container.desktop {
    display: none;
  }
  .phone-container.mobile {
    display: block;
    width: 200px;
    height: 400px;
    margin: 20px auto 40px;
  }
  .phone-screen {
    width: 100%;
    height: auto;
  }
}

.section:last-of-type {
  padding-bottom: 250px;
}

/* ------------------------- */
/* Bottom Bar                */
/* ------------------------- */
.bottom-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background-color: rgba(0,0,0,0.8);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: 15px 10px;
  z-index: 120;
  display: flex;
  justify-content: center;
  box-sizing: border-box;
}

.bottom-bar-content {
  max-width: 1000px;
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}

.app-store-badge {
  height: 40px;
  width: auto;
  display: inline-block;
}

.bottom-bar .download-btn {
  background-color: #3498db;
  color: #fff;
  text-decoration: none;
  padding: 10px 20px;
  border-radius: 1rem;
  font-weight: bold;
  transition: background-color 0.3s ease;
}

.bottom-bar .download-btn:hover {
  background-color: #2980b9;
}

.bottom-bar .terms-toggle,
.bottom-bar .privacy-toggle {
  color: #fff;
  font-size: 0.8rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 5px;
}

.bottom-bar .terms-toggle .arrow,
.bottom-bar .privacy-toggle .arrow {
  font-size: 0.7rem;
  display: inline-block;
  transition: transform 0.3s ease;
}

/* ------------------------- */
/* Overlay Modals            */
/* ------------------------- */
.terms-expanded,
.privacy-expanded {
  position: fixed;
  bottom: 60px;
  left: 50%;
  transform: translateX(-50%);
  width: 90%;
  max-width: 500px;
  background-color: rgba(0,0,0,0.95);
  color: #fff;
  font-size: 0.75rem;
  line-height: 1.4;
  padding: 20px;
  border-radius: 1rem;
  max-height: 300px;
  overflow-y: auto;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s ease, visibility 0.4s ease;
  z-index: 130;
}

.terms-expanded.visible,
.privacy-expanded.visible {
  opacity: 1;
  visibility: visible;
}

.terms-expanded.visible + .bottom-bar .terms-toggle .arrow,
.privacy-expanded.visible + .bottom-bar .privacy-toggle .arrow {
  transform: rotate(180deg);
}

/* Mobile overlay adjustments */
@media (max-width: 600px) {
  .bottom-bar-content {
    flex-direction: column;
    align-items: center;
    gap: 8px;
  }
  .bottom-bar .download-btn {
    width: 90%;
    text-align: center;
  }
  .terms-expanded,
  .privacy-expanded {
    bottom: 70px;
    max-height: 70vh;
    overflow-y: auto;
    padding: 15px;
    font-size: 0.7rem;
  }
}
