/* ================================
   MAIN STYLES FOR LUX HEALTH SYSTEMS
   ================================ */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* ================================
   ACCESSIBILITY STYLES
   ================================ */

/* Skip link for screen readers */
.skip-link {
    position: absolute;
    top: -40px;
    left: 6px;
    background: #000;
    color: #fff;
    padding: 8px;
    text-decoration: none;
    border-radius: 4px;
    z-index: 1000;
    font-weight: bold;
}

.skip-link:focus {
    top: 6px;
}

/* Hide skip link on mobile devices */
@media (max-width: 800px) {
    .skip-link {
        display: none;
    }
}

/* Visually hidden content for screen readers */
.visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

/* Focus styles for better keyboard navigation */
*:focus {
    outline: 2px solid #5a4fcf;
    outline-offset: 2px;
}

button:focus,
a:focus {
    outline: 3px solid #5a4fcf;
    outline-offset: 2px;
}

html {
  overflow-x: visible;
}

body {
  margin: 0;
  padding: 0;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: url('assets/background2.png') no-repeat center center fixed;
  background-size: cover;
  overflow-x: visible;
}

.main-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  overflow-x: visible;
  width: 100%;
}

/* Prevent overscroll on mobile */
@media (max-width: 800px) {
  .main-content {
    min-height: 100vh;
    max-height: 100vh;
    overflow-y: auto;
    padding-bottom: 20px;
  }
}

.how-it-works-img {
  display: block;
  margin: 40px auto 0 auto;
  max-width: 95vw;
  width: 420px;
}

.corner-logo {
  position: fixed;
  right: 32px;
  bottom: 32px;
  z-index: 100;
  background: rgba(255,255,255,0.85);
  border-radius: 24px;
  box-shadow: 0 4px 24px rgba(90,79,207,0.10);
  padding: 13px 23px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.corner-logo-img {
  width: 180px;
  height: auto;
  display: block;
}

.contact-icon {
  position: fixed;
  top: 32px;
  right: 32px;
  z-index: 100;
  cursor: pointer;
  background: rgba(255,255,255,0.85);
  border: none;
  border-radius: 50%;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  padding: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.contact-icon:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

.contact-icon:focus {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

.contact-icon img {
  width: 32px;
  height: 32px;
  display: block;
}

.app-download-icon {
  position: fixed;
  top: 32px;
  right: 96px;
  z-index: 100;
  cursor: pointer;
  background: rgba(255,255,255,0.85);
  border: none;
  border-radius: 50%;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  padding: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.app-download-icon:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

.app-download-icon:focus {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

.app-download-icon img {
  width: 32px;
  height: 32px;
  display: block;
}

.howit-box {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.6s cubic-bezier(.4,0,.2,1);
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 320px;
  min-height: 220px;
  display: flex;
  align-items: center;
  background: rgba(255,255,255,0.97);
  color: #5a4fcf;
  border-radius: 18px;
  box-shadow: 0 4px 24px rgba(90,79,207,0.10);
  padding: 24px 20px;
  font-size: 1.08rem;
  font-family: inherit;
  z-index: 30;
  text-align: justify;
  font-weight: 500;
}
.how-it-works-container {
  position: relative;
  display: inline-block;
  overflow: visible;
}
.how-it-works-container:hover .howit-box {
  opacity: 1;
  pointer-events: auto;
}
.howit-box.left {
  left: -450px;
  right: auto;
  z-index: 31;
}
.howit-box.right {
  right: -450px;
  left: auto;
  z-index: 32;
}

/* Desktop specific styles for tooltips */
@media (min-width: 1024px) {
  .howit-box.left {
    left: -480px;
  }
  .howit-box.right {
    right: -480px;
  }
  
  .main-content {
    padding: 0 100px;
  }
}

@media (min-width: 1400px) {
  .howit-box.left {
    left: -520px;
  }
  .howit-box.right {
    right: -520px;
  }
}

/* Ensure tooltips are visible on desktop */
@media (min-width: 1024px) {
  .how-it-works-container {
    margin: 0 200px;
  }
}

/* Responsive text control */
.desktop-text {
  display: block;
}

.mobile-text {
  display: none;
}

/* Mobile: show short text, hide detailed text */
@media (max-width: 1023px) {
  .desktop-text {
    display: none;
  }
  
  .mobile-text {
    display: block;
  }
}

.back-button {
  position: fixed;
  top: 32px;
  left: 32px;
  z-index: 100;
  cursor: pointer;
  background: rgba(255,255,255,0.85);
  border: none;
  border-radius: 50%;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  padding: 12px;
  transition: box-shadow 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  color: #5a4fcf;
  width: 48px;
  height: 48px;
}

.back-button:hover {
  box-shadow: 0 4px 16px rgba(0,0,0,0.18);
}

@media (max-width: 600px) {
  .back-button { 
    top: 16px; 
    left: 16px; 
    padding: 8px; 
    width: 40px; 
    height: 40px; 
  }
}

/* Tablet breakpoint */
@media (max-width: 1024px) {
  .corner-logo {
    right: 24px;
    bottom: 24px;
    padding: 10px 18px;
  }
  
  .corner-logo-img {
    width: 150px;
  }
}

/* Mobile breakpoint */
@media (max-width: 800px) {
  body {
    background: url('assets/background_mobile.png') no-repeat center center;
    background-size: cover;
    background-repeat: no-repeat;
    height: 100vh;
    overflow-x: hidden;
    overflow-y: auto;
    position: relative;
  }
  
  html {
    height: 100%;
    overflow-x: hidden;
  }
  
  .contact-icon {
    position: fixed;
    top: 16px;
    right: 16px;
    z-index: 100;
    cursor: pointer;
    background: rgba(255,255,255,0.85);
    border: none;
    border-radius: 50%;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    padding: 8px;
    transition: box-shadow 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  
  .contact-icon:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.18);
  }
  
  .contact-icon img {
    width: 28px;
    height: 28px;
  }
  
  .app-download-icon {
    position: fixed;
    top: 16px;
    right: 72px;
    z-index: 100;
    cursor: pointer;
    background: rgba(255,255,255,0.85);
    border: none;
    border-radius: 50%;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    padding: 8px;
    transition: box-shadow 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  
  .app-download-icon:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.18);
  }
  
  .app-download-icon img {
    width: 28px;
    height: 28px;
  }

/* Small mobile breakpoint */
@media (max-width: 480px) {
  .contact-icon {
    top: 12px;
    right: 12px;
    padding: 6px;
  }
  
  .contact-icon img {
    width: 24px;
    height: 24px;
  }
  
  .app-download-icon {
    top: 12px;
    right: 60px;
    padding: 6px;
  }
  
  .app-download-icon img {
    width: 24px;
    height: 24px;
  }
  
  .corner-logo {
    left: 12px;
    top: 12px;
    padding: 6px 12px;
  }
  
  .corner-logo-img {
    width: 70px;
  }
}
  .how-it-works-container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    position: static;
    width: 100%;
    max-width: 100vw;
    box-sizing: border-box;
    padding-left: 0;
  }
  .how-it-works-img {
    width: 55vw;
    max-width: 322px;
    margin-top: 20px;
    margin-left: 0;
    margin-right: 0;
    display: block;
  }
  .howit-box {
    position: static;
    opacity: 1 !important;
    pointer-events: auto !important;
    min-height: unset;
    width: 90vw;
    max-width: 480px;
    margin: 15px auto 20px auto;
    display: block;
    transform: none;
    box-shadow: 0 2px 12px rgba(90,79,207,0.10);
    background: rgba(255,255,255,0.90);
    padding: 16px 18px;
    border-radius: 12px;
  }
  .howit-box p {
    margin: 0 0 12px 0;
    font-size: 0.95rem;
    line-height: 1.4;
  }
  .howit-box p:last-child {
    margin-bottom: 0;
  }
  .corner-logo {
    display: none;
  }
  .corner-logo-img {
    display: none;
  }
}