:root {
  /* Градієнт фону (коричнево-зелена палітра) */
  --color-1: #5c6b4a;
  --color-2: #6b7c4e;
  --color-3: #5d7a4a;
  --color-4: #6b8c5a;
  --color-5: #7d6b4a;
  --color-6: #5c4a3a;

  /* Текст і скло на градієнті */
  --text-color: #ffffff;
  --glass-bg: rgba(255, 255, 255, 0.12);
  --glass-border: 1px solid rgba(255, 255, 255, 0.25);
  --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.35);

  /* Кнопки — яскраве золото, щоб було добре видно */
  --btn-bg-gold: #e6a020;
  --btn-text-on-gold: #1a1206;
  --btn-bg-hover: #d49210;

  /* Картки та текст (якщо потрібно) */
  --bg-main: #f4f1e8;
  --bg-card: #ead8b1;
  --card-border: 2px solid #7c5e3a;
  --card-shadow: 0 6px 12px rgba(44, 26, 11, 0.2);
  --text-primary: #2c1a0b;
  --text-heading: #1e3a26;
  --nav-bg: #1e3a26;
  --nav-text: #ffffff;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Inter", sans-serif;
}

html {
  scroll-padding-top: 120px; /* Offset for fixed navbar when scrolling to anchors */
}

body {
  background: linear-gradient(
    135deg,
    var(--color-1),
    var(--color-2),
    var(--color-3),
    var(--color-4),
    var(--color-5),
    var(--color-6)
  );
  background-size: 400% 400%;
  animation: gradientBG 15s ease infinite;
  color: var(--text-color);
  overflow-x: hidden;
}

@keyframes gradientBG {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

a {
  text-decoration: none;
  color: inherit;
}
ul {
  list-style: none;
}

/* --- Utility Classes --- */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.glass {
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: var(--glass-border);
  box-shadow: var(--glass-shadow);
  border-radius: 20px;
}

.glass-panel {
  background: rgba(0, 0, 0, 0.15);
  backdrop-filter: blur(10px);
  border: var(--glass-border);
  border-radius: 20px;
  padding: 40px;
  box-shadow: var(--glass-shadow);
}

@media (max-width: 768px) {
  .glass-panel {
    padding: 25px 20px;
  }
}

/* Added extra padding for text content in panels */
.text-content-pad p {
  padding: 0 20px;
}

.glass-panel ul {
  color: var(--text-color);
}

.glass-panel ul li {
  margin-bottom: 10px;
  line-height: 1.8;
}

.glass-panel h3 {
  color: var(--text-color);
}

.glass-panel h2 {
  color: var(--text-color);
}

.btn {
  padding: 12px 24px;
  border-radius: 50px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
  font-size: 1rem;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.btn-primary {
  background: var(--btn-bg-gold);
  color: var(--btn-text-on-gold);
}

.btn-primary:hover {
  background: var(--btn-bg-hover);
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.25);
}

.btn-outline {
  background: transparent;
  border: 2px solid #fff;
  color: #fff;
}

.btn-outline:hover {
  background: rgba(255, 255, 255, 0.1);
}

.btn-light {
  background: #fff;
  color: var(--color-4);
  font-size: 1.1rem;
  padding: 15px 35px;

  &:hover {
    background: rgba(255, 255, 255, 0.85);
  }
}

/* Header App Store Button */
.btn-app-store-nav {
  background: var(--btn-bg-gold);
  color: var(--btn-text-on-gold);
  padding: 10px 20px;
  font-size: 0.9rem;
  border: none;
  font-weight: 600;
}

.btn-app-store-nav:hover {
  background: var(--btn-bg-hover);
  color: var(--btn-text-on-gold);
}

.section-title {
  font-size: 2.5rem;
  text-align: center;
  margin-bottom: 50px;
  font-weight: 900;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

@media (max-width: 768px) {
  .section-title {
    margin-bottom: 30px;
  }
}

/* --- Navbar --- */
.navbar {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  width: 90%;
  max-width: 1200px;
  height: 70px;
  z-index: 1001;
  border-radius: 50px;
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 100%;
}

.logo {
  font-size: 1.5rem;
  font-weight: 700;
}

.nav-menu {
  display: flex;
  gap: 30px;
}

.nav-link {
  font-weight: 500;
  opacity: 0.8;
  transition: 0.3s;
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-link i {
  font-size: 0.9rem;
}

.nav-link:hover {
  opacity: 1;
}

.menu-toggle {
  display: none;
  cursor: pointer;
  width: 30px;
  height: 30px;
  position: relative;
  z-index: 1001;
  align-items: center;
  justify-content: center;
}

.bar {
  display: block;
  width: 25px;
  height: 3px;
  background: #fff;
  transition: 0.3s;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

.menu-toggle .bar:nth-child(1) {
  top: 50%;
  margin-top: -6px;
}

.menu-toggle .bar:nth-child(2) {
  top: 50%;
  margin-top: -1.5px;
}

.menu-toggle .bar:nth-child(3) {
  top: 50%;
  margin-top: 3px;
}

.menu-toggle.is-active .bar:nth-child(1) {
  top: 50%;
  margin-top: -1.5px;
  transform: translateX(-50%) rotate(45deg);
}

.menu-toggle.is-active .bar:nth-child(2) {
  opacity: 0;
}

.menu-toggle.is-active .bar:nth-child(3) {
  top: 50%;
  margin-top: -1.5px;
  transform: translateX(-50%) rotate(-45deg);
}

/* --- Hero Section --- */
.hero {
  display: flex;
  align-items: center;
  padding-top: 140px; /* More space for fixed header */
}

@media (max-width: 768px) {
  .hero {
    padding-top: 120px;
    min-height: auto;
    padding-bottom: 40px;
  }
}

.hero-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 50px;
}

.hero-content {
  flex: 1;
}

.hero-title {
  font-size: 4rem;
  line-height: 1.1;
  margin-bottom: 25px;
  text-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.hero-subtitle {
  font-size: 1.2rem;
  margin-bottom: 35px;
  opacity: 0.9;
  line-height: 1.6;
  padding-right: 20px;
}

.hero-buttons {
  display: flex;
  gap: 15px;
}

.hero-image {
  flex: 1;
  display: flex;
  justify-content: center;
}

.app-card {
  width: 300px;
  height: 400px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 30px;
  transform: rotate(-5deg);
  transition: 0.5s;
  background: rgba(255, 255, 255, 0.15);
}

.app-card:hover {
  transform: rotate(0deg) scale(1.05);
}

.app-icon {
  width: 120px;
  height: 120px;
  background: linear-gradient(45deg, var(--color-4), var(--color-1));
  border-radius: 25px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  margin-bottom: 20px;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);

  img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
  }
}

/* --- Features --- */
section {
  padding: 80px 0;
}

@media (max-width: 768px) {
  section {
    padding: 40px 0;
  }
}

.section-desc {
  font-size: 1.2rem;
  line-height: 1.8;
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.section-desc:not(:last-child) {
  margin-bottom: 20px;
}

.privacy-page .section-desc {
  text-align: left !important;
  max-width: 100% !important;
  margin: 0 !important;
}

.privacy-page .glass-panel {
  text-align: left !important;
}

.privacy-page .section-title,
.privacy-page h1,
.privacy-page h2 {
  text-align: center !important;
}

.privacy-page h3 {
  text-align: center !important;
}

.privacy-page section {
  padding: 40px 0 !important;
}

.support-page .section-desc {
  text-align: left !important;
  max-width: 100% !important;
  margin: 0 !important;
}

.support-page .glass-panel {
  text-align: left !important;
}

.support-page .section-title,
.support-page h1,
.support-page h2 {
  text-align: center !important;
}

.support-page h3 {
  text-align: center !important;
}

.support-page section {
  padding: 40px 0 !important;
}

.contact-info {
  background: rgba(255, 255, 255, 0.05);
  padding: 20px;
  border-radius: 15px;
  margin: 20px 0;
}

.contact-info p {
  margin: 10px 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.contact-info i {
  font-size: 1.2rem;
  width: 25px;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
}

.feature-card {
  padding: 50px 30px; /* Increased padding as requested */
  text-align: center;
  transition: 0.3s;
}

@media (max-width: 768px) {
  .feature-card {
    padding: 30px 20px;
  }
}

.feature-card p {
  margin-top: 15px;
  padding: 0 10px; /* Extra horizontal padding for text */
  line-height: 1.6;
}

.feature-card:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-10px);
}

.icon-box {
  font-size: 3rem;
  margin-bottom: 25px;
  color: #fff;
}

/* --- Gallery (Updated) --- */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr); /* 4 columns on desktop */
  gap: 30px;
  max-width: 1200px;
  margin: 0 auto;
}

.gallery-item {
  width: 100%;
  max-width: 300px;
  max-height: 533px;
  /* Aspect ratio for vertical screenshots */
  aspect-ratio: 9 / 16;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
  border-radius: 20px;
  margin: 0 auto;

  img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
  }
}

.screen-placeholder {
  color: rgba(255, 255, 255, 0.5);
  font-weight: bold;
  font-size: 1.5rem;
}

/* --- FAQ (Fixed) --- */
.accordion-item {
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  margin-bottom: 10px;
}

.accordion-header {
  width: 100%;
  background: none;
  border: none;
  padding: 25px 20px;
  text-align: left;
  color: white;
  font-size: 1.2rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  outline: none;
}

@media (max-width: 768px) {
  .accordion-header {
    padding: 20px 15px;
    font-size: 1.1rem;
  }
}

.accordion-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease-out;
}

.content-inner {
  padding: 0 20px 25px 20px;
  line-height: 1.6;
  opacity: 0.9;
}

.content-inner ul {
  list-style: disc;
  margin-left: 20px;
  margin-top: 10px;
  margin-bottom: 15px;
}

.content-inner ul li {
  margin-bottom: 8px;
  line-height: 1.6;
}

@media (max-width: 768px) {
  .content-inner {
    padding: 0 15px 20px 15px;
  }
}

.accordion-item.active .icon i {
  transform: rotate(45deg);
  transition: transform 0.3s;
}

/* --- CTA (Updated Spacing) --- */
.cta-box {
  text-align: center;
  padding: 80px 40px; /* Increased padding */
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
}

@media (max-width: 768px) {
  .cta-box {
    padding: 40px 20px;
    gap: 20px;
  }
}

.cta-box h2 {
  font-size: 3rem;
}

.cta-box p {
  font-size: 1.2rem;
  margin-bottom: 10px;
}

/* --- Footer (Updated) --- */
.footer {
  padding: 40px 0;
  background: rgba(0, 0, 0, 0.2);
  margin-top: 50px;
}

@media (max-width: 768px) {
  .footer {
    padding: 30px 0;
    margin-top: 30px;
  }
}

.footer-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}

.footer-info h4 {
  font-size: 1.5rem;
  margin-bottom: 5px;
}

.copyright-text {
  opacity: 0.6;
  font-size: 0.9rem;
  text-align: center;
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.copyright-link {
  color: inherit;
  text-decoration: none;
  opacity: 0.8;
  transition: opacity 0.3s;
  margin-left: 8px;
}

.copyright-link:hover {
  opacity: 1;
  text-decoration: underline;
}

.developer-text {
  opacity: 0.6;
  font-size: 0.9rem;
  margin-top: 5px;
}

.footer-links {
  display: flex;
  gap: 25px;
}

.footer-links a {
  opacity: 0.7;
  transition: 0.3s;
  font-size: 0.95rem;
}

.footer-links a:hover {
  opacity: 1;
  text-decoration: underline;
}

/* --- Mobile Responsiveness --- */
@media (max-width: 768px) {
  .nav-menu {
    position: absolute;
    top: 80px;
    left: 20px;
    right: 20px;
    background: rgba(28, 107, 226, 0.95);
    backdrop-filter: blur(20px);
    flex-direction: column;
    padding: 30px;
    border-radius: 20px;
    display: none;
    align-items: center;
    gap: 20px;
    z-index: 1000;
  }

  .nav-menu.active {
    display: flex;
  }

  .nav-menu .nav-link {
    font-size: 1.2rem;
    padding: 10px 0;
  }

  .navbar {
    top: 10px;
    width: 95%;
    height: 60px;
  }

  .menu-toggle {
    display: flex;
  }

  /* Hide the header button inside menu on mobile if needed, or keep it */
  .btn-app-store-nav {
    display: none;
  }

  .hero-container {
    flex-direction: column;
    text-align: center;
  }

  .hero-title {
    font-size: 2.8rem;
  }
  .hero-subtitle {
    padding-right: 0;
  }
  .hero-buttons {
    justify-content: center;
  }

  .app-card {
    width: 250px;
    height: 350px;
    padding: 20px;
  }

  .gallery-grid {
    grid-template-columns: 1fr; /* 1 column on mobile */
  }
}

@media (min-width: 769px) and (max-width: 1024px) {
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr); /* 2 columns on tablet */
  }

  .footer-container {
    flex-direction: column;
    text-align: center;
    gap: 30px;
  }

  .footer-links {
    justify-content: center;
  }

  .container {
    padding: 0 15px;
  }
}
