/* ============================================================
   PhotoBox v2 — Design System
   Reemplaza la estética cyan/tech por una paleta fotográfica
   profesional: negro profundo + oro cálido + blanco limpio
   ============================================================ */

/* --- Variables --- */
:root {
  --gold: #C9973A;
  --gold-light: #E8B85A;
  --gold-dark: #8B6520;
  --dark: #111318;
  --dark2: #151820;
  --dark3: #1E2230;
  --dark4: #252A3A;
  --border: rgba(201,151,58,0.2);
  --border-subtle: rgba(255,255,255,0.07);
  --text: #F0EDE8;
  --text-muted: #9A9590;
  --text-dim: #5A5550;
  --radius: 12px;
  --radius-sm: 8px;
  --radius-lg: 16px;
}

/* --- Base --- */
* { font-family: 'Inter', sans-serif; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
body {
  background: var(--dark);
  background-image: radial-gradient(ellipse at 20% 0%, rgba(201,151,58,0.06) 0%, transparent 60%),
                    radial-gradient(ellipse at 80% 100%, rgba(100,120,200,0.04) 0%, transparent 60%);
  color: var(--text);
  margin: 0; padding: 0;
  min-height: 100vh;
  overscroll-behavior: none;
}

/* --- Glass cards --- */
.glass {
  background: rgba(21,24,32,0.85);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
}

/* --- Buttons --- */
.btn-primary {
  background: linear-gradient(135deg, var(--gold-light) 0%, var(--gold) 100%);
  color: #0D0F14;
  border: none;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  letter-spacing: 0.02em;
}
.btn-primary:hover { box-shadow: 0 0 20px rgba(201,151,58,0.35); filter: brightness(1.08); }
.btn-primary:active { transform: scale(0.98); }
.btn-primary:disabled { background: #2A2E3A; color: #555; cursor: not-allowed; box-shadow: none; }

.btn-secondary {
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  transition: all 0.2s;
}
.btn-secondary:hover { background: rgba(255,255,255,0.1); border-color: rgba(255,255,255,0.15); color: var(--text); }

.btn-danger {
  background: linear-gradient(135deg, #E05050, #B03030);
  color: white;
  border: none;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-danger:hover { box-shadow: 0 0 15px rgba(220,80,80,0.3); }
.btn-success {
  background: linear-gradient(135deg, #3DAA6A, #2A8050);
  color: white;
  border: none;
  font-weight: 600;
  cursor: pointer;
}

/* --- Typography --- */
.section-title {
  font-size: clamp(18px, 3vw, 24px);
  font-weight: 700;
  color: var(--text);
  margin: 0 0 16px;
  letter-spacing: -0.02em;
}

/* --- Input fields --- */
.input-field {
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: var(--text);
  padding: 10px 14px;
  width: 100%;
  font-size: 14px;
  transition: border-color 0.2s;
  -webkit-appearance: none;
}
.input-field:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(201,151,58,0.15);
}
.input-field::placeholder { color: var(--text-dim); }

/* --- Admin section titles --- */
.admin-section-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--gold);
  margin: 24px 0 12px;
  padding: 10px 14px;
  background: rgba(201,151,58,0.08);
  border-left: 3px solid var(--gold);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* --- Spinner --- */
.spinner {
  border: 3px solid rgba(255,255,255,0.08);
  border-top: 3px solid var(--gold);
  border-radius: 50%;
  width: 40px; height: 40px;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes fadeOut { to { opacity: 0; transform: scale(0.9); } }
.fade-out { animation: fadeOut 0.4s ease forwards; }

/* ============================================================
   ALBUM MANAGER — Dashboard
   ============================================================ */
#album-manager-view { padding: 8px 0; }

.album-list-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: var(--dark3);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  transition: border-color 0.2s, background 0.2s;
  cursor: pointer;
}
.album-list-item:hover { border-color: var(--border); background: var(--dark4); }
.album-list-item-name {
  flex: 1;
  font-weight: 600;
  font-size: 15px;
  color: var(--text);
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.album-list-item-actions { display: flex; gap: 8px; flex-shrink: 0; }

/* ============================================================
   GALLERY VIEW — Client side
   ============================================================ */
.profile-header {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 16px;
  padding: 22px 26px;
  background: rgba(22,26,36,0.75);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 18px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.4), inset 0 1px 0 rgba(255,255,255,0.08);
  flex-wrap: wrap;
}
.profile-pic {
  width: 110px;
  height: 110px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--gold);
  box-shadow: 0 0 0 4px rgba(201,151,58,0.15);
  flex-shrink: 0;
}
.profile-info {
  flex: 1;
  min-width: 120px;
}
.profile-info h2 {
  margin: 0 0 4px;
  font-size: 28px;
  font-weight: 900;
  color: #fff;
  letter-spacing: -0.025em;
  text-shadow: 0 1px 8px rgba(0,0,0,0.5);
}
.profile-info p {
  margin: 0;
  font-size: 12px;
  color: rgba(255,255,255,0.5);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-weight: 600;
}
.profile-cta-btns {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-left: auto;
}
.profile-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 15px 28px;
  border-radius: 50px;
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
  transition: all 0.2s;
  white-space: nowrap;
  font-family: 'Inter', sans-serif;
  cursor: pointer;
  border: none;
}
.profile-cta-dl {
  background: linear-gradient(135deg, #E8B85A, #C9973A);
  color: #080A0E;
  box-shadow: 0 4px 0 #7A5010, 0 6px 20px rgba(201,151,58,0.3);
  position: relative;
  top: 0;
}
.profile-cta-dl:hover {
  top: -2px;
  box-shadow: 0 6px 0 #7A5010, 0 10px 24px rgba(201,151,58,0.4);
  filter: brightness(1.08);
}
.profile-cta-dl:active { top: 3px; box-shadow: 0 1px 0 #7A5010; }
.profile-cta-support {
  background: linear-gradient(180deg, #FF7A2E 0%, #E8621A 50%, #C84B0A 100%);
  border: none !important;
  color: #fff;
  font-weight: 800;
  box-shadow: 0 4px 0 #7A2800, 0 6px 24px rgba(232,98,26,0.45), 0 0 0 1px rgba(255,122,46,0.3);
  position: relative;
  top: 0;
  text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}
.profile-cta-support:hover {
  top: -2px;
  box-shadow: 0 6px 0 #8B2D06, 0 10px 28px rgba(200,75,10,0.45);
  filter: brightness(1.08);
}
.profile-cta-support:active {
  top: 3px;
  box-shadow: 0 1px 0 #8B2D06;
}
@media(max-width:600px) {
  .profile-cta-btns { width: 100%; }
  .profile-cta-btn { flex: 1; justify-content: center; }
}

.album-title-box {
  margin-bottom: 20px;
  padding: 24px 16px;
  background: var(--dark3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-align: center;
  position: relative;
  overflow: hidden;
}
.album-title-box::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(201,151,58,0.06) 0%, transparent 60%);
  pointer-events: none;
}
.album-title {
  margin: 0;
  font-size: clamp(24px, 5vw, 42px);
  font-weight: 900;
  color: var(--text);
  letter-spacing: -0.03em;
  position: relative;
}

/* Selection bar */
.selection-bar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(13,15,20,0.95);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  margin-bottom: 16px;
}
.selection-bar.cart-mode { border-color: rgba(201,151,58,0.3); }

/* Download box */
.download-box {
  background: var(--dark3);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 16px;
}
.download-box h3 {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.download-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: var(--dark4);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
}
.download-btn:hover { border-color: var(--gold); color: var(--gold); }

/* AI search box */
.ai-search-box {
  text-align: center;
  padding: 24px;
  margin-bottom: 16px;
  border-radius: var(--radius);
  background: linear-gradient(135deg, #1a2550 0%, #0D1A3A 100%);
  border: 1px solid rgba(99,150,240,0.3);
  position: relative;
  overflow: hidden;
  transition: transform 0.2s;
}
.ai-search-box:hover { transform: translateY(-1px); }
.ai-search-box::before {
  content: 'AI';
  font-weight: 900;
  font-size: 120px;
  color: rgba(255,255,255,0.03);
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  letter-spacing: -0.05em;
}
.ai-search-box * { position: relative; z-index: 2; }
.ai-search-box h3 {
  font-size: 18px;
  font-weight: 800;
  color: #fff;
  margin: 0 0 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}
.ai-search-box p { font-size: 13px; color: rgba(255,255,255,0.7); margin-bottom: 16px; }
.ai-search-btn {
  display: inline-block;
  padding: 12px 28px;
  background: linear-gradient(135deg, #4A80F0, #2A5ACC);
  color: white;
  border-radius: 50px;
  font-weight: 700;
  font-size: 14px;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
}
.ai-search-btn:hover { box-shadow: 0 0 20px rgba(74,128,240,0.4); filter: brightness(1.1); }

/* Gallery grid — masonry */
.gallery-grid {
  column-count: 2;
  column-gap: 10px;
}
@media (min-width: 640px) { .gallery-grid { column-count: 3; } }
@media (min-width: 1024px) { .gallery-grid { column-count: 4; } }
@media (min-width: 1280px) { .gallery-grid { column-count: 5; } }

.gallery-item {
  position: relative;
  border-radius: var(--radius-sm);
  overflow: hidden;
  cursor: pointer;
  border: 1px solid rgba(255,255,255,0.06);
  transition: transform 0.15s, border-color 0.15s;
  background: var(--dark3);
  margin-bottom: 10px;
  break-inside: avoid;
  width: 100%;
}
.gallery-item:hover { transform: scale(1.01); border-color: rgba(201,151,58,0.3); }
.gallery-item:active { transform: scale(0.97); }
.gallery-item img, .gallery-item video { width: 100%; display: block; }
.gallery-checkbox {
  position: absolute;
  top: 8px; left: 8px;
  width: 22px; height: 22px;
  cursor: pointer;
  z-index: 5;
  accent-color: var(--gold);
}
.gallery-badge {
  position: absolute;
  top: 8px; right: 8px;
  background: rgba(201,151,58,0.9);
  color: #0D0F14;
  padding: 3px 9px;
  border-radius: 20px;
  font-size: 10px;
  font-weight: 800;
  z-index: 5;
  letter-spacing: 0.05em;
}
.gallery-discount-badge {
  position: absolute;
  bottom: 8px; left: 8px;
  background: rgba(61,170,106,0.9);
  color: white;
  padding: 3px 9px;
  border-radius: 20px;
  font-size: 10px;
  font-weight: 700;
  z-index: 5;
}

/* Preview grid (admin) */
.preview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 12px;
}
.preview-item {
  position: relative;
  border-radius: var(--radius-sm);
  overflow: hidden;
  aspect-ratio: 1;
  background: var(--dark3);
  border: 1px solid var(--border-subtle);
}
.preview-item img, .preview-item video { width: 100%; height: 100%; object-fit: cover; }
.preview-delete {
  position: absolute;
  top: 4px; right: 4px;
  background: rgba(220,80,80,0.9);
  border: none;
  color: white;
  width: 26px; height: 26px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
  transition: background 0.2s;
}
.preview-delete:hover { background: #E03030; }

/* Lightbox */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.96);
  z-index: 9999;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}
.lightbox.active { display: flex; }
.lightbox-img { max-width: 94vw; max-height: 88vh; object-fit: contain; border-radius: 4px; }
.lightbox-video { max-width: 94vw; max-height: 88vh; object-fit: contain; }
.lightbox-close {
  position: fixed;
  top: 16px; right: 20px;
  font-size: 28px;
  color: rgba(255,255,255,0.6);
  cursor: pointer;
  z-index: 10000;
  background: none; border: none;
  transition: color 0.2s;
  line-height: 1;
}
.lightbox-close:hover { color: white; }
.lightbox-prev, .lightbox-next {
  position: fixed;
  top: 50%; transform: translateY(-50%);
  font-size: 28px;
  color: rgba(255,255,255,0.5);
  cursor: pointer;
  z-index: 10000;
  background: rgba(0,0,0,0.4);
  border: none;
  padding: 16px 12px;
  border-radius: 4px;
  transition: all 0.2s;
}
.lightbox-prev { left: 8px; }
.lightbox-next { right: 8px; }
.lightbox-prev:hover, .lightbox-next:hover { color: white; background: rgba(0,0,0,0.7); }

/* Download overlay */
#download-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.85);
  z-index: 9998;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 16px;
}
#download-overlay.active { display: flex; }

/* Modal */
.modal-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.88);
  z-index: 9000;
  align-items: center;
  justify-content: center;
}
.modal-backdrop.active { display: flex; }
.modal-box {
  background: var(--dark3);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 28px;
  max-width: 380px;
  width: 90%;
  text-align: center;
}

/* Checkbox fields */
.checkbox-field {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 0;
  cursor: pointer;
}
.checkbox-field input[type=checkbox] { accent-color: var(--gold); width: 16px; height: 16px; }
.checkbox-field label { font-size: 14px; color: var(--text-muted); cursor: pointer; }

/* Support box */
.support-box {
  text-align: center;
  padding: 24px;
  background: var(--dark3);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  margin-top: 24px;
  cursor: pointer;
}
.support-box h3 { font-size: 16px; font-weight: 700; color: var(--gold); margin: 0 0 12px; }

/* Footer */
.footer-credit { text-align: center; padding: 28px 20px; color: rgba(255,255,255,0.3); font-size: 12px; border-top: 1px solid rgba(255,255,255,0.06); margin-top: 8px; }
.footer-credit-name { color: var(--gold-light); font-weight: 600; }
.footer-credit-developer { color: var(--text-dim); }
.footer-credit-line { color: var(--text-dim); }

/* Cart badge */
.cart-mode .selection-bar { border-color: rgba(201,151,58,0.4); }

/* Scrollbar */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--dark); }
::-webkit-scrollbar-thumb { background: var(--dark4); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--gold-dark); }

/* Responsive nav top bar */
@media (max-width: 640px) {
  .album-title { font-size: 26px; }
  .gallery-grid { column-count: 2; }
}

/* --- Fix contraste editor admin --- */
#admin-view label,
#admin-view .text-gray-400,
#admin-view .text-gray-300,
#admin-view .text-gray-200,
#admin-view p,
#admin-view span:not(.gallery-badge) {
  color: var(--text-muted) !important;
}
#admin-view h1,
#admin-view h2,
#admin-view h3,
#admin-view .section-title,
#admin-view .admin-section-title {
  color: var(--text) !important;
}
#admin-view .input-field,
#admin-view input[type=text],
#admin-view input[type=email],
#admin-view input[type=number],
#admin-view input[type=file],
#admin-view select,
#admin-view textarea {
  color: var(--text) !important;
  background: rgba(255,255,255,0.05) !important;
  border-color: var(--border-subtle) !important;
}
#admin-view .checkbox-field label { color: var(--text) !important; }
#admin-view a { color: var(--text-muted); }

/* ============================================================
   MOBILE RESPONSIVE — Ajustes adicionales
   ============================================================ */
@media (max-width: 768px) {
  .card { padding: 16px; }
  #admin-view .grid { grid-template-columns: 1fr !important; }
  .profile-header { flex-direction: column; text-align: center; }
  .album-title-box { padding: 16px; }
  .download-box { padding: 14px; }
  .selection-bar { padding: 10px 12px; }
  .glass.p-4, .glass.p-6 { padding: 14px !important; }
  #landing-admin-block .grid { grid-template-columns: 1fr !important; }
  #coach-admin-block .grid { grid-template-columns: 1fr !important; }
  .preview-grid { grid-template-columns: repeat(auto-fill, minmax(90px, 1fr)); gap: 8px; }
  #qr-grid { grid-template-columns: repeat(2, 1fr) !important; }
}
@media (max-width: 480px) {
  .album-card-v2 { break-inside: avoid; }
  #album-list { grid-template-columns: 1fr !important; }
  .gallery-grid { column-count: 2 !important; }
  .lightbox-prev { left: 2px; padding: 12px 8px; }
  .lightbox-next { right: 2px; padding: 12px 8px; }
}
/* ============================================================
   ACTION BAR — Compact CTA row (mobile-first)
   ============================================================ */
.action-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 20px;
  padding: 14px;
  background: rgba(20,24,34,0.7);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 16px;
  box-shadow: 0 4px 24px rgba(0,0,0,0.3), inset 0 1px 0 rgba(255,255,255,0.06);
}
.action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 18px 24px;
  border-radius: 50px;
  font-size: 15px;
  font-weight: 800;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  font-family: 'Inter', sans-serif;
  white-space: nowrap;
  flex: 1;
  min-width: 140px;
}
/* Primary — Download (gold 3D) */
.action-btn-primary {
  background: linear-gradient(180deg, #F0C84A 0%, #C9973A 60%, #A87820 100%);
  color: #080A0E;
  box-shadow: 0 4px 0 #7A5010, 0 6px 20px rgba(201,151,58,0.3);
  position: relative;
  top: 0;
}
.action-btn-primary:hover {
  top: -2px;
  box-shadow: 0 6px 0 #7A5010, 0 10px 28px rgba(201,151,58,0.4);
  filter: brightness(1.06);
}
.action-btn-primary:active {
  top: 3px;
  box-shadow: 0 1px 0 #7A5010;
}
/* Ghost — AI Search */
.action-btn-ghost {
  background: linear-gradient(180deg, #1FE8F5 0%, #00B8C8 60%, #008A96 100%);
  border: none;
  color: #03141A;
  font-weight: 800;
  box-shadow: 0 4px 0 #005F6A, 0 6px 20px rgba(0,184,200,0.3);
  position: relative;
  top: 0;
  text-shadow: none;
}
.action-btn-ghost:hover {
  top: -2px;
  box-shadow: 0 6px 0 #005F6A, 0 10px 28px rgba(0,184,200,0.4);
  filter: brightness(1.06);
  color: #03141A;
  border-color: transparent;
  background: linear-gradient(180deg, #1FE8F5 0%, #00B8C8 60%, #008A96 100%);
}
/* Coach — purple 3D */
.action-btn-coach {
  background: linear-gradient(180deg, #A855F7 0%, #8B30D4 60%, #6D20B0 100%);
  border: none;
  color: #fff;
  font-weight: 800;
  box-shadow: 0 4px 0 #4A1080, 0 6px 20px rgba(139,48,212,0.3);
  position: relative;
  top: 0;
}
.action-btn-coach:hover {
  top: -2px;
  box-shadow: 0 6px 0 #4A1080, 0 10px 28px rgba(139,48,212,0.4);
  filter: brightness(1.06);
}
/* Mobile: stack vertically on small screens */
@media (max-width: 480px) {
  .action-btn {
    flex: 1 1 100%;
    padding: 16px;
    font-size: 15px;
    border-radius: 12px;
  }
  .action-bar {
    gap: 8px;
    padding: 12px;
  }
}
/* Tablet: 2 per row */
@media (min-width: 481px) and (max-width: 768px) {
  .action-btn {
    flex: 1 1 calc(50% - 5px);
  }
}
/* Coach duplicate removed */
@media (max-width: 480px) {
  .action-btn { flex: 1 1 100%; padding: 16px; font-size: 15px; border-radius: 12px; }
  .action-bar { gap: 8px; padding: 12px; }
  .donate-btn-stripe { padding: 14px 20px; font-size: 14px; width: 100%; }
  .donate-btns { width: 100%; }
  .donate-btn-row { width: 100%; justify-content: center; }
}
@media (min-width: 481px) and (max-width: 768px) {
  .action-btn { flex: 1 1 calc(50% - 5px); }
}

/* === JERSEY SEARCH BUTTON === */
.action-btn-jersey {
  background: linear-gradient(180deg, #34D399 0%, #10B981 60%, #059669 100%);
  border: none;
  color: #012E1F;
  font-weight: 800;
  box-shadow: 0 4px 0 #02542E, 0 6px 20px rgba(16,185,129,0.3);
  position: relative;
  top: 0;
}
.action-btn-jersey:hover {
  top: -2px;
  box-shadow: 0 6px 0 #02542E, 0 10px 28px rgba(16,185,129,0.4);
  filter: brightness(1.06);
}

/* ============================================================
   TOOLTIPS — hover desktop + tap mobile
   ============================================================ */
.btn-tooltip-wrap {
  position: relative;
  flex: 1;
  min-width: 140px;
}
.btn-tooltip-wrap .action-btn {
  width: 100%;
}
.tt-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  font-size: 13px;
  font-style: normal;
  color: rgba(255,255,255,0.5);
  cursor: pointer;
  margin-left: 4px;
  border-radius: 50%;
  flex-shrink: 0;
  transition: color 0.2s;
  vertical-align: middle;
  -webkit-tap-highlight-color: transparent;
}
.tt-icon:hover { color: rgba(255,255,255,0.9); }

.tooltip-box {
  position: absolute;
  bottom: calc(100% + 10px);
  left: 50%;
  transform: translateX(-50%);
  width: 260px;
  background: linear-gradient(135deg, rgba(180,120,10,0.97), rgba(140,85,5,0.97));
  border: 1.5px solid rgba(255,210,80,0.4);
  border-radius: 14px;
  padding: 14px 16px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.55;
  color: #fff;
  box-shadow: 0 8px 32px rgba(0,0,0,0.55), inset 0 1px 0 rgba(255,255,255,0.1);
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.18s ease, transform 0.18s ease;
  transform: translateX(-50%) translateY(4px);
  z-index: 100;
  text-align: left;
  white-space: normal;
}
/* Arrow */
.tooltip-box::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-top-color: rgba(12,14,20,0.97);
}
/* Desktop: show on hover */
.btn-tooltip-wrap:hover .tooltip-box {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}
/* Mobile/tap: show on .active */
.tooltip-box.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}
/* Mobile: stack vertical - ajustar posicion */
@media (max-width: 480px) {
  .tooltip-box {
    width: 200px;
    left: 0;
    transform: translateX(0) translateY(4px);
  }
  .tooltip-box::after { left: 30%; }
  .btn-tooltip-wrap:hover .tooltip-box {
    transform: translateX(0) translateY(0);
  }
  .tooltip-box.active {
    transform: translateX(0) translateY(0);
  }
}
