/* panel-inicio.css: the Inicio tab (account overview, "perfil completo", the
   last 7 days).

   GENERATED: do not edit public/panel-inicio.css by hand. It is the files of
   estilos/panel/inicio/ joined in name order by scripts/unir-estilos.mjs, so
   the dashboard still loads one file and the cascade keeps this order. */

/* Home Tab Styles */
.welcome-box {
  background: linear-gradient(135deg, rgba(13, 15, 23, 0.8) 0%, rgba(225, 29, 72, 0.04) 100%);
  border: 1px solid var(--card-border);
  border-radius: 16px;
  padding: 28px 32px;
  margin-bottom: 28px;
  line-height: 1.6;
}

.welcome-box h2 {
  font-family: var(--font-title);
  font-size: 1.35rem;
  font-weight: 800;
  margin-bottom: 10px;
}

.welcome-box p {
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 28px;
}

.stat-card {
  background: rgba(13, 15, 23, 0.5);
  border: 1px solid var(--card-border);
  border-radius: 16px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: border-color 0.25s;
}

.stat-card:hover {
  border-color: rgba(255, 255, 255, 0.15);
}

.stat-num {
  font-family: var(--font-title);
  font-size: 2rem;
  font-weight: 800;
  color: var(--text-primary);
}

.stat-desc {
  font-size: 0.85rem;
  color: var(--text-secondary);
  font-weight: 500;
}

/* Inicio: account overview, "perfil completo" and analytics
   (public/panel-visitas.js, loadHomeOverview) */
.home-welcome {
  padding: 22px 28px;
}

.home-welcome h2 {
  margin-bottom: 4px;
}

.home-welcome p:empty {
  display: none;
}

.home-overview {
  margin-bottom: 28px;
}

.home-section-title {
  font-family: var(--font-title);
  font-size: 1.1rem;
  font-weight: 700;
  margin: 0 0 14px;
}

.home-section-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}

.home-section-head .home-section-title {
  margin: 0;
}

.home-more-btn {
  border: 1px solid var(--accent-color);
  border-radius: 999px;
  padding: 4px 14px;
  background: rgba(225, 29, 72, 0.12);
  color: var(--text-primary);
  font: inherit;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
}

.home-more-btn:hover {
  background: rgba(225, 29, 72, 0.25);
}

.home-cards {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 28px;
}

.home-card {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  padding: 18px 20px;
  border: 1px solid var(--card-border);
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(225, 29, 72, 0.10) 0%, rgba(13, 15, 23, 0.6) 100%);
}

.home-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 6px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.home-card-icon {
  width: 20px;
  height: 20px;
  color: var(--text-secondary);
}

.home-card-icon-btn {
  display: inline-flex;
  padding: 2px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  cursor: pointer;
}

.home-card-icon-btn:hover .home-card-icon {
  color: var(--text-primary);
}

.home-card-value {
  font-family: var(--font-title);
  font-size: 1.45rem;
  font-weight: 800;
  color: var(--text-primary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.home-card-link {
  font-size: 1.05rem;
  line-height: 2.05rem;
}

.home-card-sub {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.home-copy-btn {
  align-self: flex-start;
  padding: 0;
  border: 0;
  background: transparent;
  font: inherit;
  font-size: 0.8rem;
  color: var(--accent-color);
  font-weight: 600;
  cursor: pointer;
}

.home-copy-btn:hover {
  text-decoration: underline;
}

/* Inicio: the two columns, box titles and the "perfil completo" bar and notice. */
.home-columns {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
  align-items: start;
  gap: 20px;
  margin-bottom: 28px;
}

.home-columns-analytics {
  grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
}

.home-box-title {
  font-family: var(--font-title);
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0 0 12px;
}

.home-box-title-spaced {
  margin-top: 24px;
}

.home-box-sub {
  margin: -8px 0 14px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.home-accent {
  color: var(--accent-color);
}

.home-progress-row {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 16px;
}

.home-progress-percent {
  flex: none;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.home-progress-bar {
  flex: 1;
  height: 12px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.home-progress-bar span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: 6px;
  background: var(--accent-color);
  transition: width 0.4s ease;
}

.home-progress-alert {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 14px 16px;
  margin-bottom: 16px;
  border: 1px solid var(--card-border);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
}

.home-progress-alert strong {
  display: block;
  font-size: 0.95rem;
  color: var(--text-primary);
}

.home-progress-alert p {
  margin: 2px 0 0;
  font-size: 0.82rem;
  color: var(--text-muted);
}

.home-progress-alert-icon {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #f59e0b;
  color: #111;
  font-weight: 800;
  font-size: 0.85rem;
}

.home-progress-alert.complete .home-progress-alert-icon {
  background: #22c55e;
}

/* Inicio: the steps left to complete the profile (each one opens its setting). */
.home-checklist {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.home-step {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 14px;
  border: 1px solid var(--card-border);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-primary);
  font: inherit;
  font-size: 0.86rem;
  font-weight: 600;
}

button.home-step {
  cursor: pointer;
}

button.home-step:hover {
  border-color: var(--accent-color);
}

button.home-step:focus-visible,
.home-action-btn:focus-visible,
.home-more-btn:focus-visible,
.home-copy-btn:focus-visible,
.home-card-icon-btn:focus-visible {
  outline: 2px solid var(--accent-color);
  outline-offset: 2px;
}

.home-step.done {
  color: var(--text-muted);
}

.home-step-mark {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.25);
}

.home-step.done .home-step-mark {
  border-color: #22c55e;
  background: #22c55e;
}

.home-step-check {
  width: 12px;
  height: 12px;
  color: #fff;
}

.home-step-chevron {
  width: 18px;
  height: 18px;
  margin-right: -4px;
  color: var(--text-muted);
}

/* Inicio: the "Conectar con Discord" button (.home-action-btn). */
.home-action-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 11px 14px;
  border: 1px solid transparent;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-primary);
  font: inherit;
  font-size: 0.88rem;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
}

.home-action-btn:hover {
  border-color: var(--card-border);
  background: rgba(255, 255, 255, 0.1);
}

.home-action-btn svg {
  flex: none;
  width: 18px;
  height: 18px;
}

.home-discord-btn {
  justify-content: center;
  background: #5865f2;
}

.home-discord-btn:hover {
  background: #4752c4;
}

.home-discord-btn.connected {
  background: rgba(88, 101, 242, 0.18);
}

.home-discord-btn .home-discord-gear {
  display: none;
  margin-left: auto;
  opacity: 0.8;
}

.home-discord-btn.connected {
  justify-content: flex-start;
}

.home-discord-btn.connected .home-discord-gear {
  display: block;
}

.home-discord-btn.connected:hover {
  background: rgba(88, 101, 242, 0.3);
}

/* Linked, but the profile cannot show the status (discord-connect.js). */
.home-discord-btn.connected.needs-attention {
  background: rgba(240, 178, 50, 0.14);
  box-shadow: inset 0 0 0 1px rgba(240, 178, 50, 0.45);
}

.home-discord-btn.connected.needs-attention:hover {
  background: rgba(240, 178, 50, 0.24);
}

.home-discord-btn.needs-attention #home-discord-status::before {
  content: "⚠ ";
  color: #f0b232;
}

#home-discord-result:empty {
  display: none;
}

/* Inicio: the last 7 days chart, narrow screens and reduced motion. */
.home-chart {
  height: 150px;
}

@media (max-width: 1280px) {
  .home-cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 1100px) {
  .home-columns,
  .home-columns-analytics {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .home-cards {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  .home-progress-bar span {
    transition: none;
  }
}

/* Phones: the three stat cards stack. */
@media (max-width: 768px) {
  .stats-grid {
    grid-template-columns: 1fr;
  }
}
/* Inicio with the colors of the menu (style C, docs/panel.md "Icons and
   colors per section"): the greeting with the avatar, a gradient square with
   a white icon on each account card and quick action, and the "perfil
   completo" bar green, since it is progress and red read as an error. */
.home-welcome {
  display: flex;
  align-items: center;
  gap: 18px;
  background:
    linear-gradient(135deg, rgba(59, 130, 246, 0.2) 0%, rgba(6, 182, 212, 0.08) 55%, rgba(13, 15, 23, 0.6) 100%);
}

.home-welcome-avatar {
  flex: none;
  width: 56px;
  height: 56px;
  overflow: hidden;
  border-radius: 50%;
  background: linear-gradient(135deg, #8b5cf6, #ec4899);
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.12);
}

.home-welcome-avatar img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.home-welcome-text {
  min-width: 0;
}

.home-card {
  --card-a: #64748b;
  --card-b: #334155;
  flex-direction: row;
  align-items: flex-start;
  gap: 14px;
  background: rgba(13, 15, 23, 0.5);
}

.home-card-user { --card-a: #f59e0b; --card-b: #f97316; }
.home-card-url { --card-a: #3b82f6; --card-b: #22d3ee; }
.home-card-joined { --card-a: #a855f7; --card-b: #ec4899; }
.home-card-views { --card-a: #0ea5e9; --card-b: #6366f1; }

.home-card-badge,
.home-quick-badge {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--card-a), var(--card-b));
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12);
  color: #fff;
}

.home-card-badge {
  width: 40px;
  height: 40px;
}

.home-card-badge svg {
  width: 22px;
  height: 22px;
}

.home-card-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.home-card-head {
  margin-bottom: 2px;
}

.home-progress-bar span {
  background: linear-gradient(90deg, #22c55e, #10b981);
}

/* Accesos rápidos: one row per action, its colored square, a chevron. */
.home-quick {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.home-quick-btn {
  --card-a: #64748b;
  --card-b: #334155;
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 8px 12px 8px 8px;
  border: 1px solid var(--card-border);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-primary);
  font: inherit;
  font-size: 0.88rem;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
}

.home-quick-btn:hover {
  border-color: rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.07);
}

.home-quick-btn:focus-visible {
  outline: 2px solid var(--accent-color);
  outline-offset: 2px;
}

.home-quick-colors { --card-a: #8b5cf6; --card-b: #ec4899; }
.home-quick-song { --card-a: #f59e0b; --card-b: #ef4444; }
.home-quick-link { --card-a: #ec4899; --card-b: #f97316; }
.home-quick-copy { --card-a: #3b82f6; --card-b: #06b6d4; }

.home-quick-badge {
  width: 32px;
  height: 32px;
  border-radius: 9px;
}

.home-quick-badge svg {
  width: 18px;
  height: 18px;
}

.home-quick-label {
  flex: 1;
  min-width: 0;
}

.home-quick-chevron {
  flex: none;
  width: 18px;
  height: 18px;
  color: var(--text-muted);
}

/* "Copiar enlace" in the link card's blue: the accent red was too dark on the
   card without its old red tint. */
.home-card-url .home-copy-btn {
  color: #7dd3fc;
}
