/* Custom Fonts */
@font-face {
  font-family: "Hand";
  src: url("../res/fonts/The Hand Regular.otf");
}

@font-face {
  font-family: "Nunito";
  src: url("../res/fonts/Nunito-Regular.ttf");
}

html {
  height: 100%;
  overflow-x: hidden;
  /* Hide horizontal scrollbar for the entire page */
}

body {
  font-family: "Nunito", sans-serif;
  min-height: 100vh;
  /* Ensure body is at least viewport height */
  width: 100vw;
  color: #fff;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
  position: relative;
  /* Needed for z-index with fixed background */
  overflow-x: hidden;
  /* Redundant if on html, but good for safety */
}

/* New: Full-screen animated background */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  /* Place it behind content */
  /* More pleasing gradient: subtle transition from deep plum to soft orange */
  background: linear-gradient(135deg, #2D0A3D, #5E1A52, #A83C32, #FF8204);
  /* Deep purple, slightly lighter purple, reddish-orange, vibrant orange */
  background-size: 400% 400%;
  animation: gradientAnimation 20s ease infinite alternate;
  /* Slower, smoother, alternates direction */
}

@keyframes gradientAnimation {
  0% {
    background-position: 0% 50%;
  }

  100% {
    background-position: 100% 50%;
  }
}

/* Global Text Colors & Shadows (Overriding Bootstrap defaults) */
body,
body * {
  color: #fff !important;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
}

.lead {
  color: rgba(255, 255, 255, 0.9) !important;
}

/* Headings with Hand Font */
.hand-font {
  font-family: "Hand", cursive;
}

.title {
  font-size: 4.5rem;
  line-height: 1.1;
  text-shadow: 0 2px 5px rgba(0, 0, 0, 0.7);
}

.tagline {
  font-size: 2rem;
  color: #eee !important;
}

/* --- Header / Navbar --- */
.custom-navbar {
  background-color: rgba(33, 0, 36, 0.069);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.custom-navbar .navbar-brand {
  font-size: 2.5rem;
  color: #b7b7b7 !important;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.7);
}

.custom-navbar .nav-link {
  color: #fff !important;
  font-weight: 500;
  transition: color 0.3s ease, transform 0.2s ease;
}

.custom-navbar .nav-link:hover {
  color: #b7b7b7 !important;
  transform: translateY(-2px);
}

.navbar-toggler {
  border-color: rgba(255, 255, 255, 0.3) !important;
}

.navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg viewBox='0 0 30 30' xmlns='http://www.w3.org/2000/svg'%3e%3cpath stroke='rgba(255, 255, 255, 0.7)' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
}


/* --- App Section Layout --- */
.app-section {
  padding: 60px 0;
}

.app-details {
  padding: 20px;
}

/* Ensure app-media-container is a positioning context for absolute mascots */
.app-media-container {
  position: relative;
  z-index: 1;
  /* Ensure this container is above the body's ::before background */
}

/* Reverse order for Auraninja on medium/large screens */
.flex-md-row-reverse .app-media-container {
  order: 2;
}

.flex-md-row-reverse .app-details {
  order: 1;
}

@media (max-width: 767.98px) {

  .flex-md-row-reverse .app-media-container,
  .flex-md-row-reverse .app-details {
    order: unset;
  }
}

/* Section Divider */
.section-divider {
  border: 0;
  height: 1px;
  background-image: linear-gradient(to right, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.5), rgba(255, 255, 255, 0));
  margin: 80px 0;
}


/* --- Store Buttons --- */
.store-buttons {
  gap: 1rem;
}

.store-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 3.5rem;
  /* Consistent height for both buttons */
  border-radius: 10px;
  /* Consistent border-radius for both buttons */
  transition: transform 0.2s ease-in-out, box-shadow 0.2s ease;
  cursor: pointer;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  text-decoration: none;
  flex-shrink: 0;
  border: 1px solid rgba(255, 255, 255, 0.3);
  /* Consistent light grey border */
  background-color: transparent;
  /* Default background for generic store buttons */
  padding: 0.5rem 1rem;
  /* Default padding for consistent button feel, adjust as needed */
}

.store-button:hover {
  transform: scale(1.03);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.4);
  text-decoration: none;
}

/* This rule is no longer needed for the Google Play badge, but kept for other potential img elements in buttons */
.store-button img {
  height: 100%;
  /* Adjust as needed for specific image within a button */
  width: auto;
  object-fit: contain;
}

/* CUSTOMIZED GOOGLE PLAY BUTTON STYLES */
.store-button.google-play-custom {
  /* New class for the custom Google Play button */
  background-color: #000;
  /* Dark background like your web app button */
  padding-right: 1.5rem;
  /* Padding for the text side */
  /* Ensure icon doesn't shrink, text has space */
}

.store-button.google-play-custom .button-icon {
  /* Style for the icon inside the custom button */
  height: 2.5rem;
  /* Match web app icon size */
  width: 2.5rem;
  /* Match web app icon size */
  border-radius: 5px;
  /* Match web app icon border-radius */
  margin-right: 0.75rem;
  /* Space between icon and text */
  flex-shrink: 0;
}

.store-button.google-play-custom .button-text-container {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: .1;
  /* Tighter line height for text */
  flex-grow: 1;
  justify-content: center;
  width: 7rem;
}

.store-button.google-play-custom .label {
  font-size: 0.7rem;
  opacity: 0.8;
  margin-bottom: 0;
  line-height: 1;
}

.store-button.google-play-custom strong {
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff !important;
  line-height: 1;
}

/* Existing web-app-button styles, slightly adjusted for consistency */
.web-app-button {
  background-color: #000;
  padding-right: 1.5rem;
}

.web-app-button .web-app-icon {
  height: 2.5rem;
  width: 2.5rem;
  border-radius: 5px;
  margin-right: 0.75rem;
  flex-shrink: 0;
}

.web-app-button div {
  /* This now acts like .button-text-container */
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: .1;
  /* Tighter line height for text */
  flex-grow: 1;
  justify-content: center;
  width: 7rem;
}

.web-app-button .label {
  font-size: 0.7rem;
  opacity: 0.8;
  margin-bottom: 0;
  line-height: 1;
}

.web-app-button strong {
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff !important;
  line-height: 1;
}

.h4-dnin {
  color: #de82df !important;
}

.h4-anin {
  color: #87d96e !important;
}

/* --- Feature List --- */
.feature-list h4 {
  margin-bottom: 1.5rem;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}

.feature-list ul {
  max-width: 380px;
  margin-left: auto;
  margin-right: auto;
}

.feature-list li {
  font-size: 1.1rem;
  margin-bottom: 0.8rem;
  line-height: 1.4;
  color: rgba(255, 255, 255, 0.9) !important;
}

/* --- Embedded Iframe Container (NO PHONE IMITATION) --- */
.iframe-mockup {
  position: relative;
  width: 100%;
  height: 480px;
  background-color: #333;
  border-radius: 10px;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.5);
  overflow: hidden;
  margin: 0 auto;
  max-width: 680px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 20px;
  z-index: 2;
  /* Ensure iframe is above mascots */
}

.iframe-mockup iframe {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 166.66%;
  /* 100% / 0.60 = 166.66% */
  height: 166.66%;
  /* 100% / 0.60 = 166.66% */
  transform: translate(-50%, -50%) scale(0.60);
  /* Scale down to 60% */
  transform-origin: center center;
  border: none;
  background-color: white;
}

/* --- Mascot Backgrounds for Flutter Apps --- */
.decisioninja-mascot-bg,
.auraninja-mascot-bg {
  position: absolute;
  background-size: contain;
  background-repeat: no-repeat;
  opacity: 0.7;
  z-index: 0;
  /* Place behind the iframe-mockup */
  transform-origin: center center;
}

.decisioninja-mascot-bg {
  background-image: url('../res/icons/decisioninja_icon_old.png');
  width: 250px;
  height: 250px;
  top: 204px;
  left: -88px;
  transform: rotate(-15deg);
  /* Base rotation */
  animation: decisioninjaDash 2.5s ease-in-out infinite;
  /* Animation for dashing left, pausing, and returning */
}

@keyframes decisioninjaDash {
  0% {
    transform: translateX(0) rotate(-15deg);
    /* Start at original position */
  }

  20% {
    transform: translateX(-30px) rotate(-15deg);
    /* Dash left */
  }

  40% {
    transform: translateX(-30px) rotate(-15deg);
    /* Hold left position */
  }

  60% {
    transform: translateX(0) rotate(-15deg);
    /* Dash back to original */
  }

  100% {
    transform: translateX(0) rotate(-15deg);
    /* Hold original position */
  }
}


.auraninja-mascot-bg {
  background-image: url('../res/icons/auraninja_icon_old.png');
  width: 250px;
  height: 250px;
  bottom: -7px;
  right: -130px;
  transform: rotate(18deg);
  /* Maintain your initial rotation */
  animation: auraninjaFluctuate 1.5s ease-in-out infinite alternate;
  /* Even faster fluctuation (2s -> 1.5s) */
}

@keyframes auraninjaFluctuate {
  0% {
    transform: translateY(0) rotate(18deg);
    /* Starting position, keep existing rotation */
  }

  50% {
    transform: translateY(-15px) rotate(18deg);
    /* Move up slightly */
  }

  100% {
    transform: translateY(0) rotate(18deg);
    /* Return to start */
  }
}


/* --- Footer --- */
.footer-custom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 2rem !important;
  font-size: 0.9rem;
}

a[href^="mailto:"] {
  color: #ff85a2 !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.7);
  font-weight: 600;
  text-decoration: underline;
  transition: color 0.3s ease;
}

a[href^="mailto:"]:hover,
a[href^="mailto:"]:focus {
  color: #ff5c7a !important;
  text-shadow: 0 0 5px rgba(255, 92, 122, 0.7);
}

/* Responsive adjustments */
@media (min-width: 992px) {
  .title {
    font-size: 5.5rem;
  }
}

@media (max-width: 767.98px) {
  .app-section {
    padding: 40px 0;
    text-align: center;
  }

  .app-media-container {
    margin-bottom: 30px !important;
  }

  .title {
    font-size: 3.5rem;
  }

  .tagline {
    font-size: 1.5rem;
  }

  .store-buttons {
    flex-direction: column;
    gap: 0.75rem;
    align-items: center;
  }

  .store-button {
    width: 80%;
    max-width: 300px;
    margin: 0.375rem 0;
  }

  .store-buttons .store-button:first-child {
    margin-bottom: 0.75rem;
  }

  .store-buttons .store-button:last-child {
    margin-top: 0.75rem;
  }

  .store-buttons {
    gap: 0;
  }

  .feature-list ul {
    text-align: center;
    padding-left: 0;
  }

  .iframe-mockup {
    height: 380px;
    max-width: 100%;
    padding: 15px;
  }

  .iframe-mockup iframe {
    /* For smaller screens, you might want a different scale or adjust the container height */
    width: 166.66%;
    /* Still 100% / 0.60 */
    height: 166.66%;
    /* Still 100% / 0.60 */
    transform: translate(-50%, -50%) scale(0.60);
    /* Maintain 60% scale on mobile too */
  }

  /* Hide mascots on small screens if they might clutter the design */
  .decisioninja-mascot-bg,
  .auraninja-mascot-bg {
    display: none;
  }
}
