/* =========================
   QR GENERATOR – PREMIUM UI
   ========================= */

#qrApp {
  max-width: 980px;
  margin: 0 auto; 
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Inter, Arial, sans-serif;
}

#qrApp * {
  box-sizing: border-box;
}

/* ====== LAYOUT ====== */
.qr-generator {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 24px;
  align-items: start;
}

/* Mobile */
@media (max-width: 768px) {
  .qr-generator {
    grid-template-columns: 1fr;
  }
  #qrColor {
	width: 100%!important; 
}
}
/* Mobile tap polish */
.qr-tab-btn,
#downloadDesktop {
  -webkit-tap-highlight-color: transparent;
}
/* Hide on mobile */
@media screen and (max-width: 768px) {
  .hidemobile {
    display: none !important;  
  }
}
/* ====== FORM CARD ====== */
.qr-form {
  background: #ffffff;
  border-radius: 14px;
  padding: 20px 20px 0 20px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.06);
}

.qr-form label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 6px;
  color: #222;
}

.qr-form textarea,
.qr-form input[type="text"],
.qr-form input[type="color"],
.qr-form select,
.qr-form input[type="file"] {
  width: 100%;
  font-size: 14px;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid #ddd;
  background: #fff; 
  transition: border-color .2s, box-shadow .2s;
  margin-bottom:15px;
}

.qr-form textarea {
  min-height: 90px;
  resize: vertical;
}

.qr-form input:focus,
.qr-form textarea:focus,
.qr-form select:focus {
  outline: none;
  border-color: #4f46e5;
  box-shadow: 0 0 0 3px rgba(79,70,229,.15);
}

/* ====== BUTTON ====== */
#downloadDesktop {
  width: 100%;
  margin-top: 15px;
  background: linear-gradient(135deg,#4f46e5,#6366f1);
  color: #fff;
  border: none;
  padding: 12px 16px;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: transform .15s, box-shadow .15s, opacity .15s;
}

#downloadDesktop:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 20px rgba(79,70,229,.35);
}

#downloadDesktop:active {
  transform: translateY(0);
  opacity: .9;
}

/* ====== PREVIEW CARD ====== */
.qr-preview {
  background: #ffffff;
  border-radius: 14px;
  padding: 20px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.06);
  text-align: center;
}
/* ===== CLS FIX ===== */
#qrPreview {
  min-height: 256px;
  display: flex;
  align-items: center;
  justify-content: center;
}


#qrPreview img {
  display: block;
  margin: 0 auto;
  border-radius: 12px;
  background: #fff;
}

/* Placeholder */
#qrPreview img[alt="QR Code Preview"] {
  opacity: .55;
}

/* ====== LOGO OVERLAY (DESKTOP ONLY) ====== */
.logo-overlay {
  border-radius: 12px;
}
.logo-overlay img {
	width: 50px!important;
	height: 50px!important;
}
/* ====== MOBILE INFO TEXT ====== */
#mobileHint {
  margin-top: 12px;
  font-size: 13px;
  color: #666;
  text-align: center;
  line-height: 1.5;
}

/* ====== SMALL SCREENS POLISH ====== */
@media (max-width: 480px) {
  #qrApp {
    padding: 16px 12px;
  }

  .qr-form,
  .qr-preview {
    padding: 16px;
    border-radius: 12px;
  }

  #downloadDesktop {
    font-size: 14px;
    padding: 11px 14px;
  }
}
/* Input performance polish */
.qr-form input {
	width: 100%;
	margin-bottom: 15px;
}
.qr-form input,
.qr-form textarea,
.qr-form select {
  will-change: border-color, box-shadow;
}
.qr-form textarea:focus,
.qr-form input:focus,
.qr-form select:focus {
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

/* =========================
   QR TABS (WARNA / LOGO)
   ========================= */

.qr-tabs {
	margin-top: 25px !important; 
}

/* TAB NAV */
.qr-tab-nav {
  display: flex;
  gap: 6px;
  margin-bottom: 14px;
}

.qr-tab-btn {
  flex: 1;
  padding: 10px 0;
  border: none;
  border-radius: 10px;
  background: #fff;
  color: #544fe8;
  font-weight: 600;
  cursor: pointer;
  transition: background .2s, color .2s;
}

.qr-tab-btn.active { 
	background: #F3F5FE;
	color: #4f46e5;
}

button:hover { 
	background: #6062ef; 
}

/* TAB CONTENT */
.qr-tab-content { 
	display: none;
	border: 1px solid #e7e7e7;
	background: #f3f5fe;
	padding: 10px 15px;
	border-radius: 10px;

}

.qr-tab-content.active {
  display: block;
}

.qr-tab-content h4 {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
}

.qr-subtitle {
  margin: 4px 0 10px;
  font-size: 13px;
  color: #666;
}
.logo-upload small, #tab-logo small, #tab-warna small {
	font-weight: bold; 
} 
#tab-logo {
	padding-top: 20px;
	margin-bottom: 25px;
}
#tab-logo p {
	display: none;
}

/* WARNA */
#qrColor {
	width: 80%;
	height: 30px;
	padding: 4px;
	border-radius: 10px;
	border: 1px solid #ddd;
	cursor: pointer;
}
#tab-warna img {
	min-width: 23px;
	min-height: 23px;
	box-sizing: unset;
	box-shadow: none;
	background: unset;
	padding: 0 6px 0 0;
	cursor: pointer;
	display: inline;
	margin-right: 5px;
}

/* LOGO TEMPLATE */
.logo-template-list {
  display: flex;
  gap: 8px;
  flex-wrap: wrap; 
  margin: 4px auto;
}

.logo-template-list img {
  width: 42px;
  height: 42px;
  padding: 6px;
  border-radius: 10px;
  border: 1px solid #ddd;
  cursor: pointer;
  background: #fff;
  transition: border-color .2s, box-shadow .2s;
}

.logo-template-list img:hover {
  border-color: #4f46e5;
  box-shadow: 0 0 0 3px rgba(79,70,229,.15);
}

/* UPLOAD LOGO */
.logo-upload input[type="file"] {
  width: 100%;
  margin-top: 6px;
}
/* HELPER Hint */
.tool-subtitle {
  font-size: 15px;
  color: #555;
  line-height: 1.6;
  margin-bottom: 18px;
}

.helper-text {
  display: block;
  font-size: 13px;
  color: #444;
  margin-top: 4px;
}

.helper-muted {
  display: block;
  font-size: 12.5px;
  color: #777;
  margin-top: 4px;
}

.section-hint {
  font-size: 13px;
  color: #666;
  margin-bottom: 10px;
}

.preview-caption { 
	font-weight: 600;
	margin-bottom: 6px !important;
	border-bottom: 1px solid #eee;
	padding-bottom: 10px;
}

.trust-note {
  margin-top: 18px; 
  color: #666;  
	font-style: italic;
	text-align:left;
	border-left: 5px solid #eee;
	padding-left: 15px;
	margin-left: 5px;
}
/* TEXT counter */
#qrCharCounter {
	text-align: right;
	font-style: italic;
	margin: -40px auto 5px auto;
	color: #666;
	font-size: 13px;
}
/* URL helper */
#qrUrlStatus { 
	font-style: italic;
	margin: -35px auto 5px auto;
	color: #666;
	font-size: 13px;
}
.helper { 
	font-style: italic;
	margin: -35px auto 5px auto;
	color: #666;
	font-size: 13px;
}
/* note */
.note {
	margin:15px 0;
	font-size: 15px;
	font-style: italic;
	background-color: #FFFFCC;
	border: 1px dashed #FF0000;
	border-radius:10px;
	color: #111;
	height: auto;
	padding: 15px;
	width: 100%;
	display: block;	
} 

/* list menu tool carousel */
.qr-tool-carousel-wrap{
  position:relative;
  display:flex;
  align-items:center;
  gap:6px;
  margin-bottom: 10px;
}
#qrToolCarousel a {
	font-size: 12px;
}
#qrToolCarousel a:hover {
	color: #000;
}
.qr-tool-carousel{
  display:flex;
  gap:8px;
  overflow-x:auto;
  scroll-behavior:smooth;
  background: #f7fafc;
  padding: 10px;
  border-radius: 10px;

  /* HILANGKAN SCROLLBAR */
  scrollbar-width:none;          /* Firefox */
  -ms-overflow-style:none;       /* IE & Edge lama */
}

.qr-tool-carousel::-webkit-scrollbar{
  display:none;                  /* Chrome, Safari, Opera */
}

.qr-tool-item {
	background: transparent;
	color: #5f5eed; 
	text-align: center;
	text-decoration: none;
	border-radius: 8px;
	display: flex;
	flex-direction: column;
	align-items: center;
	min-width: max-content;
	margin: 3px 5px;  
}

.qr-tool-item svg{
  width:22px;
  height:22px;
  margin-bottom:4px;
}
.qr-tool-item.active{
  background:#5f5eed;
  color:#ffffff;
  box-shadow:0 4px 12px rgba(0,0,0,0.15); 
  padding:5px;
  border-radius: 5px; 
} 

.qr-carousel-btn {
	background: #f7fafc;
	color: #5f5eed;
	border: none;
	padding: 6px 10px;
	cursor: pointer;
	border-radius: 6px;
}