/* ---------------- General layout ---------------- */
html {
  scroll-behavior: smooth;
  font-size: clamp(14px, 1.5vw, 18px); /* Fluid base font size */
  max-width: 100%;
  overflow-x: hidden;
}

body {
  background-color: #fff !important;
  margin: 0;
  font-family: Arial, sans-serif;
  overflow-x: hidden;
}

main {
  margin-top: 0;
  padding-top: 0;
  width: 100%;
  max-width: 100%;
}

header {
  margin: 0;
  padding: 0;
}

header h1 {
  margin: 0;
  padding: 0;
}

.move {
  margin-bottom: clamp(15px, 3vw, 30px);
}

/* ---------------- Hero Section ---------------- */
.hero-section {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: clamp(20px, 5vw, 40px);
  padding: clamp(12px, 3vw, 32px) clamp(12px, 3vw, 32px);
  background: transparent;
  width: 100%;
  box-sizing: border-box;
  position: relative;
  margin: 0 auto;
  overflow: visible; /* Allow logo to animate outside bounds */
}

/* When the Android tool is opened, allow the hero section to grow and scroll */
.hero-section.tool-open {
  overflow: visible;
  min-height: auto;
}

.hero-section header {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  transform: none;
  position: relative;
  z-index: 2;
  pointer-events: none;
  transition: z-index 0s 1.8s;
}

.hero-section header .logo-hero {
  pointer-events: auto;
}

.hero-section .logo-hero {
  pointer-events: auto;
  opacity: 0;
  visibility: visible;
  transition: opacity 3.2s ease, transform 1.8s cubic-bezier(0.4, 0, 0.2, 1), z-index 0s 1.8s;
  transform-origin: 50% 50%;
  max-width: min(70vw, 300px);
  width: 100%;
  height: auto;
  border-radius: 10px;
  margin: 0 auto;
  display: block;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) translateZ(0);
  z-index: 5;
  will-change: transform, max-width, opacity;
  backface-visibility: hidden;
}

.hero-section .logo-hero.show {
  opacity: 1 !important;
}

/* Animate logo to move to title position */
.hero-section .logo-hero.moving-to-title {
  transform-origin: 50% 50%;
  /* Fallback path if JS doesn't compute offset: center only */
  transform: translate(-50%, calc(-50% - 30vh));
  opacity: 1;
}

/* Move logo behind buttons after fade out */
.hero-section header.hidden,
.hero-section .logo-hero.hidden {
  z-index: 0 !important;
  pointer-events: none !important;
  opacity: 0 !important;
}



#jumbotron {
  background-color: rgba(165, 170, 181, 0.95);
  border-radius: 15px;
  padding: clamp(25px, 5vw, 40px);
  margin-top: clamp(25px, 5vw, 40px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(10px);
  width: 100%;
  box-sizing: border-box;
}

.move-text {
  margin: clamp(12px, 2.5vw, 15px) 0;
  font-size: clamp(1.1rem, 2.5vw, 1.3rem);
  line-height: 1.8;
}

#quote {
  font-size: clamp(1rem, 2.5vw, 1.8rem);
  font-style: italic;
  font-weight: bold;
  margin: clamp(15px, 3vw, 30px) 0;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
  padding: 0 clamp(12px, 3vw, 30px);
  text-align: center;
  max-width: min(90vw, 800px);
  color: #394084 !important;
}

/* ---------------- Fade-in Animation ---------------- */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Radio wave animation for background */
@keyframes radioWave {
  0% {
    opacity: 0.4;
    transform: translate(-50%, -50%) scale(0.6);
  }
  50% {
    opacity: 0.2;
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(1.8);
  }
}


.fade-in {
  position: relative;
  opacity: 0;
  filter: blur(4px);
  transition:
    opacity 2.5s cubic-bezier(0.4, 0, 0.2, 1),
    filter 2.5s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: opacity, filter;
  transition-delay: var(--fade-delay, 0s);
}

.fade-in[data-fade-group="cta-item"] {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 1.8s ease, visibility 1.8s ease, filter 1.8s ease;
}

.fade-in[data-fade-group="cta-item"].visible,
.fade-in.visible[data-fade-group="cta-item"],
[data-fade-group="cta-item"].fade-in.visible,
[data-fade-group="cta-item"][style*="opacity: 1"] {
  opacity: 1 !important;
  visibility: visible !important;
  filter: none !important;
  pointer-events: auto !important;
}

/* Ensure buttons are visible when fade-in class is removed */
.cta-button:not(.fade-in),
.call-now-button:not(.fade-in) {
  opacity: 1 !important;
  visibility: visible !important;
  pointer-events: auto !important;
}

/* Ensure buttons are clickable when visible class is added, even if fade-in is still present */
.cta-button.visible,
.call-now-button.visible,
[data-fade-group="cta-item"].visible {
  pointer-events: auto !important;
  opacity: 1 !important;
  visibility: visible !important;
}

/* Override fade-in pointer-events for visible buttons - highest specificity */
.fade-in[data-fade-group="cta-item"].visible,
.fade-in.visible[data-fade-group="cta-item"],
.call-now-button.fade-in.visible,
.cta-button.fade-in.visible {
  pointer-events: auto !important;
}

/* Ensure call buttons are always clickable when not hidden */
.call-now-button:not(.hidden),
.call-now-container .call-now-button {
  pointer-events: auto !important;
}

.fade-in::before {
  content: "";
  position: absolute;
  inset: 0;
  background: #fff;
  opacity: 1;
  pointer-events: none !important;
  transition: opacity 3s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: -1;
  border-radius: inherit;
}

/* Ensure cta-item buttons don't have problematic ::before pseudo-elements */
.fade-in[data-fade-group="cta-item"]::before {
  display: none !important;
  content: none !important;
}

.fade-in.visible {
  opacity: 1 !important;
  filter: blur(0) brightness(1);
}

.fade-in.visible::before {
  opacity: 0 !important;
}

/* Override for cta-item elements */
.fade-in[data-fade-group="cta-item"]::before {
  display: none !important;
  opacity: 0 !important;
}


.fade-in:not(.visible) {
  transition-delay: 0s !important;
}

.hero-section.fade-in::before {
  opacity: 0 !important;
  display: none !important;
}

.hero-section.fade-in {
  opacity: 1 !important;
  visibility: visible !important;
  filter: none !important;
}

body.pre-scroll main > *:not(.hero-section),
body.pre-scroll #overlaySentinel {
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

/* ---------------- Section Styling ---------------- */
section {
  margin: clamp(40px, 8vw, 100px) auto;
  padding: clamp(30px, 5vw, 60px) clamp(20px, 4vw, 40px);
  max-width: min(95vw, 1200px);
  width: 100%;
  box-sizing: border-box;
}

/* ---------------- About Section ---------------- */
.about-section {
  background-color: #fff;
  border: 2px solid #000;
  border-radius: 10px;
  box-shadow: 2px 2px 4px rgb(0, 0, 0);
  margin: 0 auto 60px auto;
  max-width: 800px;
  padding: 30px;
}

/* ---------------- NFC Tool Section ---------------- */
.nfc-tool-section {
  background-color: transparent;
  border: none;
  border-radius: 0;
  box-shadow: none;
  margin: 0;
  max-width: min(95vw, 600px);
  width: 100%;
  padding: clamp(18px, 3vw, 35px) clamp(15px, 3vw, 30px);
  box-sizing: border-box;
  opacity: 0;
  visibility: hidden;
  transition: opacity 1.8s ease, visibility 1.8s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 1;
  pointer-events: none;
}

/* When tool is open, switch from absolute centering to normal flow so the page can scroll */
.nfc-tool-section.tool-open {
  position: static;
  top: auto;
  left: auto;
  transform: none;
  margin: 0 auto;
}

/* When visible, allow pointer events but ensure call buttons are on top */
.nfc-tool-section.visible {
  pointer-events: auto;
}

.nfc-tool-section.visible .call-now-container {
  pointer-events: auto !important;
  position: relative;
  z-index: 30;
}

/* Ensure hidden Android interface doesn't block anything */
.nfc-tool-section #androidNFCInterface.hidden {
  position: absolute !important;
  left: -9999px !important;
  top: -9999px !important;
  width: 0 !important;
  height: 0 !important;
  pointer-events: none !important;
  display: none !important;
  visibility: hidden !important;
  overflow: hidden !important;
  z-index: -1 !important;
}

.nfc-tool-section.visible,
.nfc-tool-section[style*="opacity: 1"] {
  opacity: 1 !important;
  visibility: visible !important;
  display: flex !important;
  pointer-events: auto;
}

/* Background radio wave effect */
.nfc-tool-section.visible::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 400px;
  height: 400px;
  border: 2px solid rgba(57, 64, 132, 0.3);
  border-radius: 50%;
  pointer-events: none;
  z-index: -1;
  opacity: 0;
  animation: radioWave 2s ease-out 0.5s infinite;
}

.nfc-tool-section.visible::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 400px;
  height: 400px;
  border: 2px solid rgba(57, 64, 132, 0.25);
  border-radius: 50%;
  pointer-events: none;
  z-index: -1;
  opacity: 0;
  animation: radioWave 2s ease-out 1s infinite;
}

/* Override fade-in class for nfc-tool-section - but allow background radio waves when visible */
.nfc-tool-section.fade-in::before {
  display: none !important;
  opacity: 0 !important;
}

.nfc-tool-section.fade-in.visible::before,
.nfc-tool-section.visible::before {
  display: block !important;
}

.nfc-tool-section.fade-in.visible::after,
.nfc-tool-section.visible::after {
  display: block !important;
}

/* Logo title container - where logo moves to */
.logo-title-container {
  width: 100%;
  margin-top: 0;
  margin-bottom: clamp(14px, 2.5vw, 22px);
  text-align: center;
  position: relative;
  min-height: clamp(30px, 5vw, 50px);
  display: flex;
  align-items: center;
  justify-content: center;
}

.logo-title {
  width: clamp(100px, 15vw, 150px);
  max-width: 150px;
  height: auto;
  border-radius: 10px;
  opacity: 0;
  visibility: hidden;
  display: block;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 10;
}

.logo-title.visible {
  opacity: 1;
  visibility: visible;
}

.hero-section .logo-hero,
.logo-title {
  background: transparent !important;
  background-color: transparent !important;
  mix-blend-mode: normal;
}

.cta-stack {
  display: flex;
  flex-direction: column;
  gap: clamp(8px, 1.5vw, 12px);
  margin-bottom: clamp(14px, 2.5vw, 22px);
  width: 100%;
  max-width: min(320px, 85vw);
  margin: 0 auto;
  align-items: stretch;
  position: relative;
  z-index: 1;
}

.cta-button {
  display: flex;
  align-items: center;
  gap: clamp(8px, 1.5vw, 12px);
  padding: clamp(12px, 2.5vw, 18px) clamp(16px, 3vw, 28px);
  min-height: 44px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.78);
  color: rgb(57, 64, 132);
  text-decoration: none;
  font-size: clamp(0.85rem, 1.8vw, 1rem);
  font-weight: 600;
  box-shadow: 0 12px 20px rgba(57, 64, 132, 0.15);
  transition:
    box-shadow 0.25s ease,
    background 0.25s ease,
    color 0.25s ease,
    transform 0.25s ease;
  cursor: pointer;
  border: 2px solid rgba(57, 64, 132, 0.45);
  position: relative;
  overflow: visible;
  backdrop-filter: blur(14px) saturate(120%);
  -webkit-backdrop-filter: blur(14px) saturate(120%);
  pointer-events: auto !important;
  z-index: 10;
  -webkit-tap-highlight-color: rgba(57, 64, 132, 0.2);
  touch-action: manipulation;
  width: 100%;
  box-sizing: border-box;
  margin: 0;
  transform: translateZ(0);
  will-change: transform;
}



.cta-button:link,
.cta-button:visited {
  color: rgb(57, 64, 132);
  -webkit-text-fill-color: rgb(57, 64, 132);
  text-decoration: none;
  pointer-events: auto;
}

.cta-button:focus,
.cta-button:active {
  color: rgb(45, 52, 110);
  -webkit-text-fill-color: rgb(45, 52, 110);
}

.cta-button:hover,
.cta-button:focus-visible {
  box-shadow: 0 12px 20px rgba(57, 64, 132, 0.20);
  background: rgba(255, 255, 255, 0.92);
  color: rgb(45, 52, 110);
  -webkit-text-fill-color: rgb(45, 52, 110);
}

.cta-button:active {
  box-shadow: 0 12px 20px rgba(57, 64, 132, 0.20);
  background: rgba(255, 255, 255, 0.98);
}


.cta-icon {
  font-size: clamp(1rem, 2.2vw, 1.4rem);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: clamp(32px, 4.5vw, 44px);
  height: clamp(32px, 4.5vw, 44px);
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0.68) 100%);
  color: rgb(57, 64, 132);
  box-shadow: inset 0 0 0 1px rgba(57, 64, 132, 0.32), 0 4px 10px rgba(57, 64, 132, 0.15);
  flex-shrink: 0;
  position: relative;
  z-index: 1;
}

.cta-icon .icon-svg {
  width: clamp(20px, 3.5vw, 28px);
  height: clamp(20px, 3.5vw, 28px);
}

.cta-text {
  flex: 1;
  text-align: left;
  letter-spacing: 0.01em;
  color: inherit;
  position: relative;
  z-index: 1;
}

.call-now-container {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: clamp(6px, 1.5vw, 10px);
  margin-top: clamp(14px, 2.5vw, 22px);
  margin-bottom: clamp(10px, 2vw, 18px);
  flex-wrap: wrap;
  width: 100%;
  max-width: min(320px, 85vw);
  margin-left: auto;
  margin-right: auto;
  position: relative;
  z-index: 30;
  pointer-events: auto !important;
  isolation: isolate;
}

.call-now-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: clamp(10px, 2vw, 16px) clamp(20px, 4vw, 36px);
  min-height: 44px;
  min-width: 120px;
  font-size: clamp(0.85rem, 1.8vw, 1rem);
  font-weight: 600;
  color: rgb(57, 64, 132);
  background: rgba(255, 255, 255, 0.78);
  border-radius: clamp(18px, 4.5vw, 26px);
  text-decoration: none;
  transition: box-shadow 0.25s ease, background 0.25s ease, color 0.25s ease, transform 0.25s ease;
  box-shadow: 0 8px 18px rgba(57, 64, 132, 0.15);
  border: 2px solid rgba(57, 64, 132, 0.45);
  backdrop-filter: blur(14px) saturate(120%);
  -webkit-backdrop-filter: blur(14px) saturate(120%);
  pointer-events: auto !important;
  z-index: 25;
  position: relative;
  -webkit-tap-highlight-color: rgba(57, 64, 132, 0.2);
  touch-action: manipulation;
  flex: 1 1 auto;
  min-width: calc(50% - 3px);
  transform: translateZ(0);
  cursor: pointer;
  isolation: isolate;
  overflow: visible;
}


.call-now-button:link,
.call-now-button:visited {
  color: rgb(57, 64, 132);
  -webkit-text-fill-color: rgb(57, 64, 132);
  text-decoration: none;
  pointer-events: auto;
}

.call-now-button:hover {
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 8px 18px rgba(57, 64, 132, 0.20);
  color: rgb(45, 52, 110);
  -webkit-text-fill-color: rgb(45, 52, 110);
}

.call-now-button:active {
  box-shadow: 0 8px 18px rgba(57, 64, 132, 0.20);
  background: rgba(255, 255, 255, 0.98);
}

.initial-load .cta-button.fade-in,
.initial-load .call-now-button.fade-in {
  --fade-delay: 3s;
}

.subtitle {
  color: rgb(57, 64, 132);
  font-size: clamp(1rem, 2.5vw, 1.3rem);
  margin-bottom: clamp(20px, 4vw, 30px);
}

/* OS Buttons */
.os-buttons-container {
  display: flex;
  justify-content: center;
  gap: clamp(10px, 2.5vw, 30px);
  margin-bottom: clamp(20px, 4vw, 40px);
  flex-wrap: wrap;
  width: 100%;
}

.os-button {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background-color: transparent;
  border: none;
  border-radius: 0;
  padding: clamp(15px, 3vw, 30px);
  min-width: clamp(120px, 22vw, 180px);
  flex: 1 1 auto;
  max-width: 300px;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
  box-shadow: none;
  box-sizing: border-box;
}

.os-button:hover {
  background-color: rgba(57, 64, 132, 0.1);
  transform: none;
  box-shadow: none;
}

.android-button:hover .button-text,
.ios-button:hover .button-text {
  color: rgb(57, 64, 132);
}

.button-icon {
  font-size: clamp(2.5rem, 5vw, 4rem);
  margin-bottom: clamp(6px, 1.5vw, 10px);
}

.button-text {
  font-size: clamp(0.95rem, 2.2vw, 1.5rem);
  font-weight: bold;
  color: rgb(57, 64, 132);
  transition: color 0.3s ease;
  text-align: center;
}

.about-content h2 {
  color: rgb(57, 64, 132);
  margin-bottom: clamp(24px, 5vw, 40px);
  font-size: clamp(1.4rem, 4vw, 2.5rem);
}

.about-text {
  color: rgb(57, 64, 132);
  line-height: 1.9;
  font-size: clamp(0.95rem, 2vw, 1.15rem);
}

.about-text p {
  margin-bottom: clamp(16px, 3vw, 20px);
}

.about-text p:last-child {
  margin-bottom: 0;
}

/* ---------------- Contact Section ---------------- */
.contact-section {
  background-color: #fff;
  border: 2px solid #000;
  border-radius: 15px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
  margin: clamp(40px, 8vw, 80px) auto;
  max-width: min(95vw, 800px);
  width: 100%;
  padding: clamp(30px, 5vw, 50px) clamp(20px, 4vw, 40px);
  box-sizing: border-box;
}

.contact-form-container {
  width: 100%;
}

.contact-form-container h2 {
  color: rgb(57, 64, 132);
  margin-bottom: clamp(10px, 2vw, 20px);
  font-size: clamp(1.6rem, 4vw, 2.2rem);
  font-weight: bold;
}

.contact-subtitle {
  color: rgb(57, 64, 132);
  font-size: clamp(0.95rem, 2vw, 1.1rem);
  margin-bottom: clamp(20px, 4vw, 30px);
}

.contact-form {
  width: 100%;
}

.form-group {
  margin-bottom: 25px;
}

.form-group label {
  display: block;
  color: rgb(57, 64, 132);
  font-weight: bold;
  margin-bottom: 8px;
  font-size: 1rem;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 12px;
  border: 2px solid rgb(57, 64, 132);
  border-radius: 8px;
  font-size: 1rem;
  font-family: Arial, sans-serif;
  box-sizing: border-box;
  background-color: #fff;
  color: rgb(57, 64, 132);
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: rgb(45, 52, 110);
  box-shadow: 0 0 8px rgba(57, 64, 132, 0.3);
}

.form-group textarea {
  resize: vertical;
  min-height: 120px;
}

.submit-btn {
  width: 100%;
  padding: 15px;
  background-color: rgb(57, 64, 132);
  color: #fff;
  border: 2px solid rgb(57, 64, 132);
  border-radius: 8px;
  font-size: 1.1rem;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s ease;
}

.submit-btn:hover {
  background-color: rgb(45, 52, 110);
  transform: translateY(-2px);
  box-shadow: 2px 4px 12px rgba(0, 0, 0, 0.3);
}

.form-status {
  display: none;
  margin-top: 20px;
  padding: 15px;
  border-radius: 8px;
  text-align: center;
}

.success-message {
  background-color: #d4edda;
  color: #155724;
  border: 2px solid #155724;
  padding: 15px;
  border-radius: 8px;
  font-weight: bold;
}

/* ---------------- Footer ---------------- */
.site-footer {
  background-color: rgb(255, 255, 255);
  color: rgb(50, 50, 50);
  width: 100%;
  border-top: 3px solid rgb(57, 64, 132);
  padding: clamp(25px, 5vw, 40px) clamp(15px, 4vw, 30px);
  box-sizing: border-box;
  margin-top: clamp(50px, 10vw, 100px);
}

.footer-content {
  display: flex;
  justify-content: flex-start;
  align-items: stretch;
  flex-wrap: nowrap;
  max-width: min(95vw, 1200px);
  margin: 0 auto;
  gap: clamp(20px, 4vw, 30px);
}

.footer-info {
  text-align: left;
  flex: 1 1 100%;
  min-width: min(320px, 100%);
  display: flex;
  flex-direction: column;
  gap: clamp(12px, 2.5vw, 18px);
}

.contact-info {
  color: rgb(57, 64, 132);
  font-size: clamp(0.85rem, 1.8vw, 0.95rem);
  line-height: 1.8;
  margin: 0;
}

.contact-info strong {
  color: rgb(57, 64, 132);
  font-size: clamp(1rem, 2vw, 1.1rem);
}

.contact-info a {
  color: rgb(57, 64, 132);
  text-decoration: none;
}

.contact-info a:hover {
  color: rgb(45, 52, 110);
  text-decoration: underline;
}

.dnfc-footer {
  color: rgb(57, 64, 132) !important;
  font-size: large;
  margin-bottom: 15px;
}

.footer-links {
  margin-top: 10px;
}

.footer-links,
.dnfc-footer {
  max-width: 100%;
}

.footer-links a {
  color: rgb(57, 64, 132);
  margin: 0 12px 0 0;
  font-size: 1rem;
  text-decoration: none;
  display: inline-block;
}

.footer-links a:last-child {
  margin-right: 0;
}

.footer-links a:hover {
  color: rgb(45, 52, 110);
  text-decoration: underline;
}

.logo-img {
  height: 30px;
  width: auto;
  border-radius: 6px;
  margin-right: 8px;
  vertical-align: middle;
}

/* ---------------- NFC Interface ---------------- */
.hidden {
  display: none !important;
  pointer-events: none !important;
  visibility: hidden !important;
}

#androidNFCInterface {
  position: relative;
  z-index: 1;
  pointer-events: auto;
  width: 100%;
  overflow: visible;
  contain: layout style;
}

#androidNFCInterface.hidden {
  pointer-events: none !important;
  display: none !important;
  visibility: hidden !important;
  position: absolute !important;
  left: -9999px !important;
  top: -9999px !important;
  width: 0 !important;
  height: 0 !important;
  overflow: hidden !important;
}

.nfc-interface-card {
  background-color: transparent;
  border: none;
  border-radius: 0;
  padding: clamp(15px, 3vw, 30px);
  margin-top: clamp(12px, 2.5vw, 20px);
  margin-bottom: clamp(12px, 2.5vw, 20px);
  width: 100%;
  box-sizing: border-box;
  position: relative;
  z-index: 1;
  overflow: visible;
  pointer-events: auto;
}

/* When parent is hidden, ensure card doesn't block clicks */
#androidNFCInterface.hidden .nfc-interface-card {
  pointer-events: none !important;
  display: none !important;
}

.nfc-interface-card h3 {
  color: rgb(57, 64, 132);
  margin-bottom: clamp(10px, 2vw, 15px);
  font-size: clamp(1.2rem, 3vw, 1.8rem);
}

.instructions {
  color: rgb(57, 64, 132);
  margin-bottom: clamp(15px, 3vw, 25px);
  font-size: clamp(0.9rem, 1.8vw, 1.1rem);
}

/* Scanner Section */
.scanner-section {
  position: relative;
  width: 100%;
  max-width: min(85vw, 400px);
  margin: 0 auto clamp(15px, 3vw, 25px) auto;
  border: 3px solid rgb(57, 64, 132);
  border-radius: 10px;
  overflow: hidden;
  background-color: #000;
}

#qrVideo {
  width: 100%;
  height: auto;
  display: block;
}

#qrCanvas {
  width: 100%;
  height: auto;
  display: none;
}

#scanOverlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.scan-prompt {
  color: #fff;
  font-size: clamp(1rem, 2.5vw, 1.2rem);
  font-weight: bold;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
  background-color: rgba(57, 64, 132, 0.7);
  padding: clamp(8px, 2vw, 10px) clamp(15px, 3vw, 20px);
  border-radius: 5px;
}

/* Status Display */
.status-display {
  padding: clamp(10px, 2vw, 15px);
  border-radius: 8px;
  margin-bottom: clamp(12px, 2.5vw, 20px);
  text-align: center;
  font-weight: bold;
  font-size: clamp(0.85rem, 1.8vw, 1.1rem);
}

.status-display.info {
  background-color: #cce5ff;
  color: #004085;
  border: 2px solid #004085;
}

.status-display.success {
  background-color: #d4edda;
  color: #155724;
  border: 2px solid #155724;
}

.status-display.error {
  background-color: #f8d7da;
  color: #721c24;
  border: 2px solid #721c24;
}

/* URL Display */
.url-display {
  background-color: #f0f0f0;
  border: 2px solid rgb(57, 64, 132);
  border-radius: 8px;
  padding: clamp(12px, 2.5vw, 20px);
  margin-bottom: clamp(12px, 2.5vw, 20px);
  width: 100%;
  box-sizing: border-box;
}

.url-display p {
  margin-bottom: clamp(8px, 1.5vw, 10px);
  color: rgb(57, 64, 132);
}

.url-text {
  font-size: clamp(0.9rem, 1.8vw, 1rem);
  word-break: break-all;
  background-color: #fff;
  padding: clamp(8px, 1.5vw, 10px);
  border-radius: 5px;
  border: 1px solid #ccc;
}

.write-prompt {
  font-weight: bold;
  color: rgb(57, 64, 132);
  margin-top: clamp(8px, 1.5vw, 10px) !important;
}

/* Control Buttons */
.control-buttons {
  display: flex;
  justify-content: center;
  gap: clamp(8px, 1.8vw, 15px);
  flex-wrap: wrap;
  width: 100%;
}

.control-btn {
  padding: clamp(10px, 2vw, 15px) clamp(16px, 3.5vw, 30px);
  border: 2px solid rgb(57, 64, 132);
  border-radius: 8px;
  font-size: clamp(0.9rem, 1.8vw, 1.1rem);
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s ease;
  flex: 1 1 auto;
  min-width: clamp(100px, 22vw, 150px);
  max-width: 300px;
}

.primary-btn {
  background-color: rgb(57, 64, 132);
  color: #fff;
}

.primary-btn:hover {
  background-color: rgb(45, 52, 110);
  transform: translateY(-2px);
  box-shadow: 2px 2px 4px rgb(0, 0, 0);
}

.secondary-btn {
  background-color: #fff;
  color: rgb(57, 64, 132);
}

.secondary-btn:hover {
  background-color: rgb(57, 64, 132);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 2px 2px 4px rgb(0, 0, 0);
}

/* ---------------- NFC Modal ---------------- */
.nfc-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.nfc-modal-content {
  background-color: #fff;
  border-radius: 20px;
  padding: clamp(25px, 5vw, 40px);
  max-width: min(90vw, 400px);
  width: 90%;
  text-align: center;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  animation: slideUp 0.3s ease;
  box-sizing: border-box;
}

@keyframes slideUp {
  from {
    transform: translateY(50px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.nfc-icon {
  font-size: clamp(3.5rem, 8vw, 5rem);
  margin-bottom: clamp(15px, 3vw, 20px);
}

.nfc-modal-content h3 {
  color: rgb(57, 64, 132);
  margin-bottom: clamp(12px, 2vw, 15px);
  font-size: clamp(1.4rem, 3.5vw, 1.8rem);
}

.nfc-modal-content p {
  color: rgb(57, 64, 132);
  font-size: clamp(1rem, 2vw, 1.1rem);
  margin-bottom: clamp(20px, 4vw, 30px);
}

.nfc-animation {
  margin: 30px 0;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100px;
}

.nfc-pulse {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background-color: rgb(57, 64, 132);
  animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
  0% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.2);
    opacity: 0.7;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

/* ---------------- Utility classes ---------------- */
.text-center {
  text-align: center;
}

.text-light {
  color: #fff;
}

.rounded {
  border-radius: 0.5rem;
}

.img-fluid {
  max-width: 100%;
  height: auto;
  border: solid 1px rgb(0, 0, 0);
  box-shadow: 2px 2px 4px rgb(0, 0, 0);
}

/* ---------------- Responsive adjustments ---------------- */
/* Fluid typography and spacing handled by clamp() above, 
   these are additional fine-tuning for specific breakpoints */

@media (max-width: 768px) {
  .footer-content {
    flex-direction: column;
  }

  .footer-info {
    width: 100%;
  }

  .call-now-container {
    flex-direction: column;
    width: 100%;
  }

  .call-now-button {
    width: 100%;
    max-width: min(420px, 90vw);
  }
}

@media (min-width: 1024px) {
  .nfc-tool-section {
    padding: clamp(30px, 5vw, 50px) clamp(20px, 4vw, 40px);
  }
}

/* Additional container query support for even more fluid layouts */
@supports (container-type: inline-size) {
  .nfc-tool-section {
    container-type: inline-size;
  }
}


/* Mobile optimizations for Android devices */
@media (hover: none) and (pointer: coarse) {
  .cta-button,
  .nfc-function-btn,
  .control-btn {
    min-height: 48px;
    padding: clamp(16px, 3vw, 20px) clamp(20px, 4vw, 28px);
  }

  .fade-in {
    filter: none; /* Reduce motion on mobile for better performance */
  }
}

/* Accessibility and reduced motion support */
@media (prefers-reduced-motion: reduce) {
  .fade-in {
    transition: none !important;
    transform: none !important;
    filter: none !important;
    opacity: 1 !important;
  }

  .fade-in::before {
    transition: none !important;
    opacity: 0 !important;
  }

  .cta-button,
  .nfc-function-btn {
    transition: none !important;
  }

  .cta-button::before,
  .cta-button::after,
  .nfc-tool-section::before,
  .nfc-tool-section::after {
    animation: none !important;
  }

  /* Reduce radio wave animation intensity for accessibility */
  .nfc-tool-section::before,
  .nfc-tool-section::after {
    opacity: 0.1 !important;
  }
}

*, *::before, *::after {
  box-sizing: border-box;
}
