/* Minimal Mobile-Friendly Admin Top Bar & Visual Editor Styles - El Arabe Arquitecto */

.admin-body {
  background-color: #0c0d0e;
  color: #e5e5e5;
  font-family: var(--font-sans, 'Inter', sans-serif);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  margin: 0;
  overflow-x: hidden;
}

/* MINIMAL TOP ADMIN BAR */
.admin-top-bar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 48px;
  background: rgba(14, 14, 14, 0.98);
  border-bottom: 1.5px solid #d4af37;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1rem;
  box-shadow: 0 4px 20px rgba(0,0,0,0.8);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.top-bar-brand {
  display: flex;
  align-items: center;
}

.admin-bar-logo {
  height: 32px;
  width: auto;
  object-fit: contain;
}

/* CENTER TABS */
.top-bar-tabs {
  display: flex;
  gap: 0.4rem;
}

.top-tab-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #aaa;
  padding: 0.35rem 0.85rem;
  border-radius: 6px;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  transition: all 0.25s ease;
}

.top-tab-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
}

.top-tab-btn.active {
  background: #d4af37;
  color: #111;
  border-color: #d4af37;
}

.badge-count {
  background: rgba(0, 0, 0, 0.35);
  color: inherit;
  font-size: 0.68rem;
  padding: 0.08rem 0.4rem;
  border-radius: 10px;
  font-weight: 700;
}

/* RIGHT ACTIONS */
.top-bar-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-top-save {
  background: #25D366;
  color: #ffffff;
  border: none;
  padding: 0.38rem 0.85rem;
  border-radius: 6px;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  transition: all 0.25s ease;
}

.btn-top-save:hover {
  background: #20ba59;
  transform: translateY(-1px);
}

.btn-top-logout {
  background: rgba(220, 39, 67, 0.15);
  color: #ff4d6d;
  border: 1px solid rgba(220, 39, 67, 0.3);
  padding: 0.38rem 0.7rem;
  border-radius: 6px;
  font-size: 0.78rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.25s ease;
}

.btn-top-logout:hover {
  background: #dc2743;
  color: #ffffff;
}

/* MAIN WRAPPER */
.admin-main-wrapper {
  margin-top: 48px;
  min-height: calc(100vh - 48px);
  display: flex;
  flex-direction: column;
}

/* LOGIN CARD */
.login-card {
  margin: 4rem auto;
  background: rgba(20, 21, 23, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  padding: 2.5rem 2rem;
  width: 90%;
  max-width: 400px;
  box-shadow: 0 20px 50px rgba(0,0,0,0.6);
}

.login-header {
  text-align: center;
  margin-bottom: 1.75rem;
}

.login-icon {
  font-size: 2rem;
  color: #d4af37;
  margin-bottom: 0.75rem;
  background: rgba(212, 175, 55, 0.1);
  width: 55px;
  height: 55px;
  line-height: 55px;
  border-radius: 50%;
  display: inline-block;
}

.login-header h2 {
  font-size: 1.4rem;
  margin: 0 0 0.4rem 0;
  color: #ffffff;
}

.login-header p {
  color: #888;
  font-size: 0.8rem;
  margin: 0;
}

.login-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.admin-form-group {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.admin-form-group label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #aaa;
  font-weight: 500;
}

.admin-form-group input,
.admin-form-group select {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 6px;
  padding: 0.75rem 0.9rem;
  color: #ffffff;
  font-size: 0.85rem;
  outline: none;
}

.admin-form-group input:focus {
  border-color: #d4af37;
}

.login-error-msg {
  background: rgba(220, 39, 67, 0.15);
  border: 1px solid rgba(220, 39, 67, 0.4);
  color: #ff4d6d;
  padding: 0.65rem;
  border-radius: 6px;
  font-size: 0.78rem;
  text-align: center;
}

.btn-primary-admin {
  background: #ffffff;
  color: #111;
  border: none;
  padding: 0.85rem 1.25rem;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  transition: all 0.25s ease;
}

.btn-primary-admin:hover {
  background: #d4af37;
}

.login-footer-info {
  margin-top: 1.25rem;
  text-align: center;
  color: #666;
}

/* VISUAL EDITOR IFRAME */
.admin-view-panel {
  width: 100%;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.visual-editor-iframe {
  width: 100%;
  height: calc(100vh - 48px);
  border: none;
  background: #000;
}

/* CONSULTAS TABLE */
.panel-card {
  background: rgba(20, 21, 23, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 1.5rem;
  box-shadow: 0 10px 30px rgba(0,0,0,0.4);
  margin-bottom: 2rem;
}

.panel-header {
  margin-bottom: 1.25rem;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  padding-bottom: 1rem;
}

.panel-header h3 {
  font-size: 1.2rem;
  margin: 0 0 0.2rem 0;
  color: #fff;
}

.panel-header p {
  margin: 0;
  font-size: 0.8rem;
  color: #888;
}

.consultas-table-wrapper {
  overflow-x: auto;
}

.consultas-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.8rem;
}

.consultas-table th,
.consultas-table td {
  padding: 0.75rem;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.consultas-table th {
  color: #d4af37;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  background: rgba(255,255,255,0.02);
}

.consultas-table tr:hover {
  background: rgba(255,255,255,0.03);
}

/* TOAST NOTIFICATION */
.toast-notification {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  background: rgba(18, 18, 18, 0.95);
  border: 1px solid #d4af37;
  color: #fff;
  padding: 0.85rem 1.25rem;
  border-radius: 8px;
  font-size: 0.82rem;
  box-shadow: 0 10px 30px rgba(0,0,0,0.6);
  z-index: 20000;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  pointer-events: none;
}

.toast-notification.active {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.loading-spinner {
  text-align: center;
  padding: 2rem;
  color: #aaa;
  font-size: 0.85rem;
}

/* RESPONSIVE MOBILE OPTIMIZATIONS */
@media (max-width: 600px) {
  .admin-top-bar {
    padding: 0 0.6rem;
  }
  .admin-bar-logo {
    height: 26px;
  }
  .tab-label {
    display: none;
  }
  .save-label {
    display: none;
  }
  .top-tab-btn {
    padding: 0.35rem 0.65rem;
    font-size: 0.9rem;
  }
  .btn-top-save {
    padding: 0.38rem 0.65rem;
    font-size: 0.9rem;
  }
}
