/* ============================================================================
   PERSONAL TRAINER PRO - Sport/Energy Design System
   Dark Theme: Deep Navy + Vibrant Orange/Pink Gradient Accents
   Font: Oswald (headings) + DM Sans (body)
   ============================================================================ */

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

/* --- Sport energy pulse --- */
@keyframes pulseEnergy {
  0%, 100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.4); }
  50% { box-shadow: 0 0 0 8px rgba(34, 197, 94, 0); }
}

/* --- Shimmer loading --- */
@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

/* --- CSS Variables / Design Tokens --- */
:root {
  --bg-primary: #0F172A;
  --bg-secondary: #1E293B;
  --bg-tertiary: #334155;
  --bg-hover: #1e293b;
  --bg-card: #1E293B;
  --bg-input: #0F172A;
  --bg-sidebar: #0B1120;
  
  --text-primary: #F1F5F9;
  --text-secondary: #94A3B8;
  --text-muted: #64748B;
  
  --accent: #22C55E;
  --accent-hover: #16A34A;
  --accent-light: rgba(34, 197, 94, 0.15);
  --accent-gradient: linear-gradient(135deg, #22C55E, #059669);
  
  --orange: #F59E0B;
  --orange-light: rgba(245, 158, 11, 0.15);
  --pink: #F72585;
  --pink-light: rgba(247, 37, 133, 0.12);
  --purple: #7209B7;
  --purple-light: rgba(114, 9, 183, 0.12);
  --blue: #3B82F6;
  --blue-light: rgba(59, 130, 246, 0.12);
  --amber: #F59E0B;
  --amber-light: rgba(245, 158, 11, 0.12);
  --red: #EF4444;
  --red-light: rgba(239, 68, 68, 0.12);
  --green: #22C55E;
  --green-light: rgba(34, 197, 94, 0.12);
  --success: #22C55E;
  --danger: #EF4444;
  --warning: #F59E0B;
  
  --border: #334155;
  --border-light: #475569;
  --radius: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3), 0 2px 4px -2px rgba(0, 0, 0, 0.2);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.4), 0 4px 6px -4px rgba(0, 0, 0, 0.3);
  
  --sidebar-width: 240px;
  --sidebar-collapsed: 68px;
  --topbar-height: 60px;
  
  --font: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-heading: 'Oswald', sans-serif;
}

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 15px; scroll-behavior: smooth; scroll-padding-top: 72px; }

body {
  font-family: var(--font);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow: hidden;
  height: 100vh;
}
body:has(.landing-page) { overflow: visible; height: auto; }

body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;

/* Touch targets mínimos WCAG 2.1 — Mobile */
.btn, .btn-sm, .btn-primary, .btn-secondary,
.btn-ghost, .btn-confirm-payment, .btn-generate,
.btn-plan, .btn-plan-primary, .btn-plan-secondary {
  min-height: 44px;
  padding-top: max(10px, 0.625rem);
  padding-bottom: max(10px, 0.625rem);
}

.icon-btn, .btn-edit-question, .btn-delete-question,
.exercise-expand-btn, .modal-close, .nav-drawer-close,
.drawer-close {
  min-width: 44px;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.nav-drawer-link {
  min-height: 44px;
  display: flex;
  align-items: center;
}

input, select, textarea {
  min-height: 44px;
}

/* Aumentar área de toque sem mudar visual */
.icon-btn {
  position: relative;
}
.icon-btn::after {
  content: '';
  position: absolute;
  inset: -6px;
}
  opacity: 0.06;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='1'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 256px 256px;
}

#root { height: 100vh; }
#root:has(.landing-page) { overflow-y: auto; height: auto; min-height: 100vh; }

/* --- Scrollbar --- */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--bg-tertiary); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--accent); }

/* --- App Layout --- */
.app-layout { display: flex; height: 100vh; height: 100dvh; overflow: hidden; }

/* --- Sidebar --- */
.sidebar {
  width: var(--sidebar-width);
  min-width: var(--sidebar-width);
  background: var(--bg-sidebar);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  transition: width 0.25s ease, min-width 0.25s ease;
  z-index: 100;
  overflow: hidden;
}
.sidebar-closed .sidebar { width: var(--sidebar-collapsed); min-width: var(--sidebar-collapsed); }

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 20px 18px;
  border-bottom: 1px solid var(--border);
  height: var(--topbar-height);
  white-space: nowrap;
}
.sidebar-logo {
  width: 36px; height: 36px;
  min-width: 36px;
  background: var(--accent-gradient);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  overflow: hidden;
}
.sidebar-logo-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: calc(var(--radius) - 2px);
}

/* --- Branding banner no Dashboard --- */
.branding-banner-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 64px 48px;
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.88) 0%, rgba(15, 23, 42, 0.6) 50%, rgba(34, 197, 94, 0.15) 100%);
}
.branding-banner {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: 24px;
  min-height: 300px;
}
.branding-banner-logo {
  width: 120px;
  height: 120px;
  border-radius: 24px;
  object-fit: cover;
  border: 2px solid var(--border);
}
.branding-banner-name {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
}
.branding-banner-sub {
  font-size: 1rem;
  color: var(--text-secondary);
  margin-top: 4px;
}
.sidebar-title { font-size: 1.05rem; font-weight: 600; color: var(--text-primary); letter-spacing: 0.5px; text-transform: uppercase; font-family: var(--font-heading); }

.sidebar-nav {
  flex: 1;
  padding: 12px 10px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  overflow-y: auto;
}
.sidebar-footer { padding: 10px; border-top: 1px solid var(--border); }

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: var(--radius);
  color: var(--text-secondary);
  background: none;
  border: none;
  cursor: pointer;
  font-family: var(--font);
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.15s ease;
  width: 100%;
  text-align: left;
  white-space: nowrap;
}
.nav-item:hover { background: var(--bg-hover); color: var(--text-primary); }
.nav-item-active { background: var(--accent-light); color: var(--accent); position: relative; }
.nav-item-active::before {
  content: '';
  position: absolute;
  left: 0; top: 50%;
  transform: translateY(-50%);
  width: 3px; height: 20px;
  background: var(--accent-gradient);
  border-radius: 0 3px 3px 0;
}
.nav-item-active:hover { background: var(--accent-light); color: var(--accent); }
.nav-label { overflow: hidden; text-overflow: ellipsis; }
.sidebar-toggle { margin-top: 0; display: none; }

.sidebar-overlay {
  display: none;
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.6);
  z-index: 90;
}

/* --- Main Content --- */
.main-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  overflow-y: auto;
  min-width: 0;
  -webkit-overflow-scrolling: touch;
}

/* --- Topbar --- */
.topbar {
  height: var(--topbar-height);
  min-height: var(--topbar-height);
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  padding: 0 24px;
  gap: 16px;
}
.mobile-menu-btn { display: none; }
.topbar-search {
  position: relative;
  flex: 1;
  max-width: 400px;
}
.search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
}
.topbar-search-input {
  padding-left: 40px !important;
  height: 40px;
  background: var(--bg-input) !important;
  border-color: var(--border) !important;
}
.topbar-right { margin-left: auto; display: flex; align-items: center; }
.topbar-date {
  font-size: 0.85rem;
  color: var(--text-secondary);
  text-transform: capitalize;
}

/* --- Page Content --- */
.page-content {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 0;
}

/* --- Page Container --- */
.page-container { padding: 24px; max-width: 1400px; }
.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 24px;
  gap: 16px;
  flex-wrap: wrap;
}
.page-title { font-size: 1.75rem; font-weight: 600; letter-spacing: 0.5px; text-transform: uppercase; font-family: var(--font-heading); }
.page-title-dashboard { font-family: 'Oswald', sans-serif !important; }
.page-subtitle { font-size: 0.85rem; color: var(--text-secondary); margin-top: 2px; }
.page-header-actions { display: flex; align-items: center; gap: 12px; }

/* --- Cards --- */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: all 0.25s ease;
}
.card-padding { padding: 20px; }
.card-hover:hover {
  border-color: var(--accent);
  box-shadow: 0 8px 25px -8px rgba(34, 197, 94, 0.15);
  transform: translateY(-2px);
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font);
  font-weight: 600;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
  font-size: 0.85rem;
  line-height: 1;
}
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-sm { padding: 6px 12px; font-size: 0.8rem; }
.btn-md { padding: 10px 20px; font-size: 0.85rem; }
.btn-full { width: 100%; justify-content: center; }

.btn-primary { background: var(--accent-gradient); color: #fff; }
.btn-primary:hover:not(:disabled) { background: var(--accent-gradient); filter: brightness(1.15); box-shadow: 0 4px 15px rgba(255, 107, 53, 0.3); }

.btn-secondary { background: var(--bg-tertiary); color: var(--text-primary); }
.btn-secondary:hover:not(:disabled) { background: var(--border-light); }

.btn-ghost { background: transparent; color: var(--text-secondary); }
.btn-ghost:hover:not(:disabled) { background: var(--bg-hover); color: var(--text-primary); }

.btn-danger { background: var(--red); color: #fff; }
.btn-danger:hover:not(:disabled) { background: #DC2626; }

/* --- Badges --- */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 100px;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.5;
}
.badge-default { background: var(--bg-tertiary); color: var(--text-secondary); }
.badge-success { background: var(--accent-light); color: var(--accent); }
.badge-warning { background: var(--amber-light); color: var(--amber); }
.badge-danger { background: var(--red-light); color: var(--red); }
.badge-info { background: var(--blue-light); color: var(--blue); }
.badge-neutral {
  background: rgba(255,255,255,0.06);
  border: 0.5px solid rgba(255,255,255,0.1);
  color: rgba(255,255,255,0.5);
}
.badge-green {
  background: rgba(34,197,94,0.08);
  border: 0.5px solid rgba(34,197,94,0.2);
  color: #22C55E;
}
.badge-red {
  background: rgba(239,68,68,0.1);
  border: 0.5px solid rgba(239,68,68,0.25);
  color: #EF4444;
}
.badge-purple {
  background: rgba(99,102,241,0.08);
  border: 0.5px solid rgba(99,102,241,0.2);
  color: #818CF8;
}

/* --- Form Elements --- */
.form-group { margin-bottom: 16px; display: flex; flex-direction: column; }
.form-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.form-hint { font-size: 0.75rem; color: var(--text-muted); margin-top: 4px; }
.form-error { font-size: 0.75rem; color: var(--red); margin-top: 4px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 16px; }

.input-field {
  width: 100%;
  padding: 10px 14px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-primary);
  font-family: var(--font);
  font-size: 0.9rem;
  transition: border-color 0.2s;
  outline: none;
}
.input-field:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-light); }
.input-field::placeholder { color: var(--text-muted); }
.input-error { border-color: var(--red) !important; }
.input-error:focus { box-shadow: 0 0 0 3px var(--red-light); }

.input-sm { max-width: 90px; }

select.input-field { cursor: pointer; appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2394A3B8' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 36px; }
select.input-field option { background: #1E293B; color: #fff; }
textarea.input-field { resize: vertical; min-height: 80px; }

.workout-form .form-label {
  font-size: 11px;
  color: rgba(255,255,255,0.35);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 8px;
  display: block;
}
.workout-form .input-field {
  width: 100%;
  padding: 10px 14px;
  background: rgba(255,255,255,0.04);
  border: 0.5px solid rgba(255,255,255,0.1);
  border-radius: 6px;
  color: #fff;
  font-family: 'DM Sans', sans-serif;
  font-size: 14px;
  transition: border-color 0.15s;
  outline: none;
}
.workout-form .input-field:focus { border-color: rgba(34,197,94,0.35); }
.workout-form .input-field::placeholder { color: rgba(255,255,255,0.2); }
.workout-form select.input-field {
  cursor: pointer;
  appearance: none;
  background: rgba(255,255,255,0.04);
  border: 0.5px solid rgba(255,255,255,0.1);
  border-radius: 6px;
  color: #fff;
  font-family: 'DM Sans', sans-serif;
  font-size: 14px;
  padding: 10px 32px 10px 14px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2' stroke-opacity='0.3'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 12px;
}
.workout-form select.input-field option {
  background: #1E293B;
  color: #fff;
}
.workout-form .exercise-search-wrap { position: relative; }
.workout-form .exercise-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.workout-form .method-current-bar {
  background: rgba(255,255,255,0.03);
  border: 0.5px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.workout-form .method-current-badge {
  background: rgba(34,197,94,0.1);
  border: 0.5px solid rgba(34,197,94,0.2);
  color: #22C55E;
  font-size: 11px;
  padding: 3px 10px;
  border-radius: 4px;
  flex-shrink: 0;
}
.workout-form .method-current-desc {
  font-size: 12px;
  color: rgba(255,255,255,0.3);
  flex: 1;
}
.workout-form .method-current-bar .btn-ghost {
  background: transparent;
  border: 0.5px solid rgba(255,255,255,0.1);
  color: rgba(255,255,255,0.4);
  font-size: 12px;
  padding: 6px 12px;
  border-radius: 5px;
  cursor: pointer;
  transition: 0.15s;
  font-family: 'DM Sans', sans-serif;
}
.workout-form .method-current-bar .btn-ghost:hover {
  border-color: rgba(34,197,94,0.3);
  color: #22C55E;
}
.workout-form .exercise-notes-input {
  background: rgba(255,255,255,0.04);
  border: 0.5px solid rgba(255,255,255,0.08);
  border-radius: 6px;
  color: rgba(255,255,255,0.6);
  font-size: 13px;
  padding: 10px 14px;
  font-style: italic;
  width: 100%;
  outline: none;
  transition: border-color 0.15s;
}
.workout-form .exercise-notes-input:focus { border-color: rgba(34,197,94,0.35); }
.workout-form .exercise-notes-input::placeholder { color: rgba(255,255,255,0.25); }
.workout-form .btn-add-exercise {
  background: rgba(34,197,94,0.1);
  border: 0.5px solid rgba(34,197,94,0.25);
  color: #22C55E;
  font-size: 13px;
  font-weight: 500;
  padding: 12px;
  border-radius: 8px;
  width: 100%;
  cursor: pointer;
  transition: 0.15s;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-family: 'DM Sans', sans-serif;
}
.workout-form .btn-add-exercise:hover { background: rgba(34,197,94,0.18); }
.workout-form .btn-add-exercise:disabled { opacity: 0.4; cursor: not-allowed; }

@media (max-width: 768px) {
  .workout-form .exercise-form-row { grid-template-columns: 1fr; }
  .workout-form .method-current-bar { flex-wrap: wrap; }
  .workout-form .method-current-bar .btn-ghost { margin-left: auto; }
  .workout-modal-footer { flex-direction: column; }
  .workout-modal-footer .btn-cancel,
  .workout-modal-footer .btn-save { width: 100%; justify-content: center; }
}

.workout-modal-footer { display: flex; gap: 12px; }
.workout-modal-footer .btn-cancel {
  background: transparent;
  border: 0.5px solid rgba(255,255,255,0.1);
  color: rgba(255,255,255,0.4);
  font-size: 13px;
  padding: 10px 24px;
  border-radius: 6px;
  cursor: pointer;
  transition: 0.15s;
  font-family: 'DM Sans', sans-serif;
}
.workout-modal-footer .btn-cancel:hover { color: #fff; border-color: rgba(255,255,255,0.2); }
.workout-modal-footer .btn-save {
  background: #22C55E;
  color: #0F172A;
  font-weight: 700;
  font-size: 13px;
  padding: 10px 24px;
  border-radius: 6px;
  border: none;
  cursor: pointer;
  transition: 0.15s;
  font-family: 'DM Sans', sans-serif;
}

.input-with-icon { position: relative; display: flex; }
.input-with-icon .input-field { padding-right: 40px; }
.input-with-icon .icon-btn { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); }

/* --- Icon Button --- */
.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px; height: 34px;
  border-radius: var(--radius);
  background: none;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.15s;
}
.icon-btn:hover { background: var(--bg-hover); color: var(--text-primary); }
.icon-btn-danger:hover { background: var(--red-light); color: var(--red); }

/* --- Avatar --- */
.avatar {
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 700;
  user-select: none;
}
.avatar-photo {
  border-radius: 50%;
  object-fit: cover;
  border: 1.5px solid rgba(34,197,94,0.3);
}
.avatar-initials {
  background: rgba(255,255,255,0.06);
  border: 0.5px solid rgba(255,255,255,0.12);
  border-radius: 50%;
  color: rgba(255,255,255,0.5);
  font-family: Oswald, sans-serif;
  font-weight: 500;
}

/* --- Modal --- */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 200;
  padding: 20px;
  animation: fadeIn 0.15s ease;
}
.modal-content {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 600px;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-lg);
  animation: slideUp 0.2s ease;
}
@media (max-width: 480px) {
  .modal-content { max-width: calc(100vw - 32px); }
}
.modal-sm { max-width: 420px; }
.modal-content-large { max-width: 800px; }

/* --- Monthly Report --- */
.report-content { display: flex; flex-direction: column; gap: 16px; }

.report-period-row {
  display: flex;
  gap: 12px;
  align-items: flex-end;
}
.report-period-row .form-group { flex: 1; }

.report-section { padding: 4px 0; }
.report-section-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 10px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border);
  font-family: var(--font-heading);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.report-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

.report-stat {
  background: var(--bg-primary);
  border-radius: var(--radius);
  padding: 14px;
  text-align: center;
}
.report-stat-value {
  display: block;
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--accent);
}
.report-stat-label {
  display: block;
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.report-workout-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.report-workout-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-secondary);
  padding: 6px 10px;
  background: var(--bg-primary);
  border-radius: var(--radius);
}
.report-workout-ex-count {
  margin-left: auto;
  font-size: 0.75rem;
  color: var(--text-muted);
}
.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border);
}
.modal-title { font-size: 18px; font-weight: 500; letter-spacing: 0.05em; text-transform: uppercase; font-family: var(--font-heading); }
.modal-close {
  display: flex; align-items: center; justify-content: center;
  width: 32px; height: 32px;
  border-radius: var(--radius);
  background: none; border: none;
  color: var(--text-secondary);
  cursor: pointer;
}
.modal-close:hover { background: var(--bg-hover); color: var(--text-primary); }
.modal-body { padding: 24px; overflow-y: auto; overflow-x: hidden; flex: 1; word-break: break-word; }
.modal-profile {
  background: #0B1120;
  border: 0.5px solid rgba(255,255,255,0.08);
  border-radius: 12px;
}
.modal-profile .modal-header {
  border-bottom: 0.5px solid rgba(255,255,255,0.08);
}
.modal-profile .modal-title {
  font-family: Oswald, sans-serif;
  font-size: 18px;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: none;
}
.modal-profile .modal-close {
  color: rgba(255,255,255,0.3);
}
.modal-profile .modal-close:hover {
  color: #fff;
  background: none;
}

/* --- Profile Modal Sections --- */
.profile-block {
  background: rgba(255,255,255,0.02);
  border: 0.5px solid rgba(255,255,255,0.06);
  border-radius: 10px;
  padding: 16px 20px;
  margin-bottom: 16px;
}
.profile-block-row {
  display: flex;
  align-items: center;
  gap: 14px;
}
.profile-block-info {
  flex: 1;
  min-width: 0;
}
.profile-block-name {
  font-family: Oswald, sans-serif;
  font-size: 18px;
  font-weight: 500;
  color: #fff;
  margin: 0;
}
.profile-block-contact {
  font-size: 12px;
  color: rgba(255,255,255,0.35);
  margin: 3px 0 0;
}
.profile-block-badges {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 8px;
}
.profile-block-badges .badge {
  font-size: 10px;
  padding: 3px 10px;
  border-radius: 4px;
}
.profile-section {
  background: rgba(255,255,255,0.02);
  border: 0.5px solid rgba(255,255,255,0.06);
  border-radius: 10px;
  padding: 16px 20px;
  margin-bottom: 12px;
  overflow: hidden;
}
.profile-section-label {
  font-size: 10px;
  color: rgba(255,255,255,0.25);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  border-bottom: 0.5px solid rgba(255,255,255,0.06);
  padding-bottom: 8px;
  margin-bottom: 12px;
}
.profile-section-text {
  font-size: 13px;
  color: rgba(255,255,255,0.35);
  margin: 0;
}
.profile-empty {
  text-align: center;
  padding: 20px;
  font-size: 13px;
  color: rgba(255,255,255,0.25);
  font-style: italic;
}
.profile-workout-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 0.5px solid rgba(255,255,255,0.04);
}
.profile-workout-item:last-child {
  border-bottom: none;
}
.profile-workout-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #22C55E;
  flex-shrink: 0;
}
.profile-workout-details { flex: 1; min-width: 0; }
.workout-name {
  font-size: 13px;
  font-weight: 500;
  color: #fff;
  margin-right: 6px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 100%;
}
.workout-meta {
  font-size: 11px;
  color: rgba(255,255,255,0.3);
}
.profile-workout-name {
  font-size: 13px;
  font-weight: 500;
  color: #fff;
}
.profile-workout-meta {
  font-size: 11px;
  color: rgba(255,255,255,0.3);
  margin-top: 2px;
}
.profile-measurements-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
}
.profile-measurement-row {
  display: flex;
  justify-content: space-between;
  padding: 6px 0;
  border-bottom: 0.5px solid rgba(255,255,255,0.04);
}
.profile-measurement-label {
  font-size: 12px;
  color: rgba(255,255,255,0.35);
}
.profile-measurement-value {
  font-size: 12px;
  font-weight: 500;
  color: #fff;
}
.profile-measurement-delta {
  margin-left: 6px;
  font-size: 11px;
}
.profile-measurement-delta.delta-up { color: #22C55E; }
.profile-measurement-delta.delta-down { color: #EF4444; }
.profile-measurement-delta.delta-neutral { color: rgba(255,255,255,0.25); }
.profile-access-row {
  display: flex;
  gap: 20px;
  align-items: flex-start;
  flex-wrap: wrap;
}
.profile-qr-container {
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
}
.profile-qr-container canvas {
  display: block;
}
.profile-input-label {
  font-size: 10px;
  color: rgba(255,255,255,0.25);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 8px;
}
.profile-input-row {
  display: flex;
  gap: 8px;
  align-items: center;
}
.profile-input {
  background: rgba(255,255,255,0.04);
  border: 0.5px solid rgba(255,255,255,0.1);
  border-radius: 6px;
  color: rgba(255,255,255,0.6);
  font-size: 12px;
  padding: 9px 14px;
  font-family: DM Sans, sans-serif;
  flex: 1;
  min-width: 0;
  outline: none;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.profile-input:focus {
  border-color: rgba(34,197,94,0.35);
}
.profile-btn {
  background: rgba(255,255,255,0.06);
  border: 0.5px solid rgba(255,255,255,0.1);
  color: rgba(255,255,255,0.5);
  border-radius: 5px;
  padding: 7px 14px;
  font-size: 12px;
  font-family: DM Sans, sans-serif;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: 0.15s;
}
.profile-btn:hover {
  border-color: rgba(34,197,94,0.3);
  color: #22C55E;
}
.profile-btn-primary {
  background: #22C55E;
  color: #0F172A;
  font-weight: 700;
  font-size: 12px;
  padding: 9px 18px;
  border-radius: 5px;
  border: none;
  cursor: pointer;
  font-family: DM Sans, sans-serif;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.profile-access-actions {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}
.profile-section-divider {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 0.5px solid rgba(255,255,255,0.06);
}
.profile-toggle-label {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
}
.profile-toggle-row {
  display: flex;
  align-items: center;
  gap: 8px;
}
.profile-toggle-switch {
  position: relative;
  width: 44px;
  height: 24px;
  background: rgba(255,255,255,0.1);
  border-radius: 12px;
  transition: background 0.2s;
  flex-shrink: 0;
}
.profile-toggle-switch[data-active="true"] {
  background: #22C55E;
}
.profile-toggle-knob {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 20px;
  height: 20px;
  background: #fff;
  border-radius: 50%;
  transition: left 0.2s;
}
.profile-toggle-switch[data-active="true"] .profile-toggle-knob {
  left: 22px;
}
.profile-toggle-text {
  font-size: 13px;
  color: rgba(255,255,255,0.5);
  white-space: nowrap;
}
.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  padding: 16px 24px;
  border-top: 1px solid var(--border);
}

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

/* --- Spinner --- */
.spinner { display: inline-flex; align-items: center; justify-content: center; }
.spinner-icon { animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* --- Toast --- */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column-reverse;
  gap: 8px;
  pointer-events: none;
}
.toast {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  pointer-events: auto;
  animation: toastIn 0.3s ease;
  min-width: 300px;
  max-width: 420px;
}
.toast-success { border-left: 3px solid var(--accent); }
.toast-error { border-left: 3px solid var(--red); }
.toast-info { border-left: 3px solid var(--blue); }
.toast-icon { display: flex; flex-shrink: 0; }
.toast-success .toast-icon { color: var(--accent); }
.toast-error .toast-icon { color: var(--red); }
.toast-info .toast-icon { color: var(--blue); }
.toast-message { flex: 1; font-size: 0.85rem; font-weight: 500; }
.toast-close {
  display: flex; align-items: center; justify-content: center;
  width: 24px; height: 24px;
  border-radius: 4px; background: none; border: none;
  color: var(--text-muted); cursor: pointer; flex-shrink: 0;
}
.toast-close:hover { background: var(--bg-hover); }
@keyframes toastIn { from { opacity: 0; transform: translateX(40px); } to { opacity: 1; transform: translateX(0); } }

/* --- Empty State --- */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  text-align: center;
}
.empty-state-icon { color: var(--text-muted); margin-bottom: 16px; opacity: 0.5; }

/* --- Pagination --- */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 24px;
  padding: 12px 0;
}
.pagination-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg-secondary);
  color: var(--text-primary);
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
}
.pagination-btn:hover:not(:disabled) {
  border-color: var(--accent);
  color: var(--accent);
}
.pagination-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.pagination-info {
  color: var(--text-secondary);
  font-size: 14px;
}

/* --- Exercise Library Dropdown --- */
.exercise-lib-dropdown {
  position: absolute;
  top: calc(100% - 8px);
  left: 0;
  right: 0;
  z-index: 100;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
  margin-top: 4px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.4);
  max-height: 320px;
  display: flex;
  flex-direction: column;
}
.exercise-lib-filter {
  padding: 8px;
  border-bottom: 1px solid var(--border);
}
.exercise-lib-filter select {
  width: 100%;
  padding: 6px 8px;
  font-size: 0.8rem;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-primary);
}
.exercise-lib-list {
  overflow-y: auto;
  flex: 1;
}
.exercise-lib-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 12px;
  cursor: pointer;
  transition: background 0.15s;
  border-bottom: 1px solid var(--border);
}
.exercise-lib-item:last-child { border-bottom: none; }
.exercise-lib-item:hover { background: rgba(34,197,94,0.1); }
.exercise-lib-name { font-size: 0.85rem; font-weight: 500; }
.exercise-lib-meta { font-size: 0.75rem; color: var(--text-secondary); }
.exercise-lib-empty { padding: 16px; text-align: center; color: var(--text-secondary); font-size: 0.85rem; }
.empty-state-title { font-size: 1.1rem; font-weight: 600; margin-bottom: 8px; }
.empty-state-description { color: var(--text-secondary); font-size: 0.9rem; margin-bottom: 20px; max-width: 400px; }

/* --- Alert --- */
.alert {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: var(--radius);
  margin-bottom: 16px;
  font-size: 0.85rem;
  font-weight: 500;
}
.alert-error { background: var(--red-light); color: var(--red); border: 1px solid rgba(239, 68, 68, 0.3); }

/* --- Spacing Helpers --- */
.mb-sm { margin-bottom: 8px; }
.mb-md { margin-bottom: 16px; }
.mb-lg { margin-bottom: 24px; }
.mt-lg { margin-top: 24px; }
.text-muted { color: var(--text-secondary); font-size: 0.85rem; }

/* --- Filters --- */
.filters-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}
.search-wrapper {
  position: relative;
  flex: 1;
  min-width: 200px;
}
.search-wrapper .search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: rgba(255,255,255,0.25);
  pointer-events: none;
}
.search-input {
  padding-left: 36px !important;
  background: rgba(255,255,255,0.04) !important;
  border: 0.5px solid rgba(255,255,255,0.08) !important;
  border-radius: 6px !important;
  color: #fff !important;
  font-family: DM Sans, sans-serif !important;
  font-size: 13px !important;
  height: auto !important;
}
.search-input:focus {
  border-color: rgba(34,197,94,0.35) !important;
}
.filter-select { max-width: 200px; }
.custom-select-arrow::after {
  content: '';
  display: block;
  width: 0;
  height: 0;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 4px solid rgba(255,255,255,0.3);
  transition: transform 0.2s;
}
.custom-select-arrow.open::after {
  transform: rotate(180deg);
}

/* --- Dashboard --- */
.dashboard-stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}
.stat-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px !important;
}
.stat-icon {
  width: 48px; height: 48px;
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.stat-icon-blue { background: var(--blue-light); color: var(--blue); }
.stat-icon-green { background: var(--accent-light); color: var(--accent); }
.stat-icon-purple { background: var(--purple-light); color: var(--purple); }
.stat-icon-amber { background: var(--amber-light); color: var(--amber); }
.stat-info { display: flex; flex-direction: column; }
.stat-value { font-size: 1.65rem; font-weight: 600; letter-spacing: 0.3px; font-family: var(--font-heading); line-height: 1.2; }
.stat-label { font-size: 0.8rem; color: var(--text-secondary); }

.dashboard-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
.dashboard-grid > .card:last-child { grid-column: 2; }

/* --- Dashboard Charts Grid --- */
.dashboard-charts-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 16px;
  margin-top: 24px;
  margin-bottom: 24px;
}
.dashboard-charts-grid .card { overflow: hidden; }

/* --- Upcoming list --- */
.upcoming-list { display: flex; flex-direction: column; }
.upcoming-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}
.upcoming-item:last-child { border-bottom: none; }
.upcoming-date {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 44px;
  background: var(--bg-tertiary);
  border-radius: var(--radius);
  padding: 6px 8px;
}
.upcoming-day { font-size: 1.1rem; font-weight: 700; line-height: 1; }
.upcoming-month { font-size: 0.7rem; color: var(--text-secondary); text-transform: uppercase; }
.upcoming-info { flex: 1; min-width: 0; }
.upcoming-name { font-weight: 600; font-size: 0.9rem; display: block; }
.upcoming-detail { font-size: 0.8rem; color: var(--text-muted); }

/* --- Summary list --- */
.summary-list { display: flex; flex-direction: column; gap: 14px; }
.summary-item { display: flex; align-items: center; gap: 10px; color: var(--text-secondary); font-size: 0.9rem; }
.summary-item svg { flex-shrink: 0; color: var(--accent); }
.summary-item strong { color: var(--text-primary); }

/* --- Students Grid --- */
.students-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

@media (max-width: 640px) {
  .students-grid { grid-template-columns: 1fr; }
}

/* --- Mobile: workout card header wrap + OBS overflow + title ellipsis --- */
@media (max-width: 640px) {
  .workout-card-header {
    flex-wrap: wrap;
    gap: 8px;
  }

  .workout-card-title-row h3 {
    font-size: 13px !important;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    max-width: calc(100% - 160px);
  }

  .workout-card-actions button,
  .workout-card-actions .icon-btn {
    width: 32px !important;
    height: 32px !important;
    font-size: 14px !important;
  }

  .workout-card-notes {
    overflow: hidden;
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: normal;
    max-width: 100%;
    margin: 8px 0;
    padding: 12px;
    font-size: 12px;
    line-height: 1.6;
  }

}

/* --- Mobile: page titles Oswald --- */
@media (max-width: 640px) {
  .page-title {
    font-family: 'Oswald', sans-serif !important;
    font-size: 28px !important;
  }
}

/* --- Mobile: student card header wrap (ações abaixo do nome) --- */
@media (max-width: 480px) {
  .student-card-header {
    flex-wrap: wrap;
    gap: 8px;
  }
  .student-card-actions {
    width: 100%;
    justify-content: flex-end;
    gap: 2px;
  }
  .student-card-name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
}

.student-card {
  padding: 20px;
  background: rgba(255,255,255,0.03);
  border: 0.5px solid rgba(255,255,255,0.08);
  border-radius: 12px;
  transition: border-color 0.2s, background 0.2s;
}
.student-card:hover {
  border-color: rgba(34,197,94,0.25);
  background: rgba(34,197,94,0.02);
}
.student-card-header { display: flex; align-items: center; gap: 14px; margin-bottom: 12px; }
.student-card-info { flex: 1; min-width: 0; }
.student-card-name { font-family: Oswald, sans-serif; font-size: 17px; font-weight: 500; color: #fff; margin: 0; }
.student-card-email { font-size: 12px; color: rgba(255,255,255,0.3); overflow: hidden; text-overflow: ellipsis; margin: 2px 0 0; }
.student-card-actions { display: flex; gap: 4px; }
.student-card-actions .icon-btn { color: rgba(255,255,255,0.2); transition: color 0.15s; }
.student-card-actions .icon-btn:hover { background: none; }
.student-card-actions .icon-btn:first-child:hover,
.student-card-actions .icon-btn:nth-child(2):hover { color: #22C55E; }
.student-card-actions .icon-btn-danger:hover { color: #EF4444; background: none; }
.student-card-badges { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.student-card-badges .badge {
  font-size: 10px;
  padding: 3px 10px;
  border-radius: 4px;
  letter-spacing: 0.06em;
}
.student-card-divider {
  border: none;
  border-top: 0.5px solid rgba(255,255,255,0.06);
  margin: 14px 0 12px;
}
.student-card-stats { display: flex; align-items: center; gap: 16px; margin-bottom: 10px; }
.stat-mini { display: flex; align-items: center; gap: 6px; font-size: 12px; color: rgba(255,255,255,0.35); }
.stat-mini svg { color: rgba(255,255,255,0.2); }
.student-card-notes { font-size: 12px; color: rgba(255,255,255,0.25); border-top: 0.5px solid rgba(255,255,255,0.06); padding-top: 10px; margin-top: 4px; }

/* --- Workouts Grid --- */
.workouts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.workout-card {
  padding: 20px;
  background: transparent;
}
.workout-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 0.5px solid rgba(255,255,255,0.06);
  padding-bottom: 16px;
  margin-bottom: 16px;
}
.workout-card-title-row { display: flex; align-items: center; gap: 10px; }
.workout-icon {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #22C55E;
  flex-shrink: 0;
}
.workout-card-title-row h3 { font-family: Oswald, sans-serif; font-size: 14px; font-weight: 500; color: #fff; letter-spacing: 0.05em; text-transform: uppercase; margin: 0; }
.workout-card-actions { display: flex; gap: 4px; }
.workout-card-actions .icon-btn { color: rgba(255,255,255,0.25); font-size: 14px; transition: color 0.15s; }
.workout-card-actions .icon-btn:hover { color: #22C55E; background: none; }
.workout-card-actions .icon-btn-danger:hover { color: #EF4444; background: none; }
.workout-card-title-row .badge-success {
  background: rgba(34,197,94,0.1);
  border: 0.5px solid rgba(34,197,94,0.25);
  color: #22C55E;
  font-size: 10px;
  padding: 3px 10px;
  border-radius: 4px;
  letter-spacing: 0.08em;
}

.anamnese-icon-btn {
  color: rgba(255,255,255,0.25);
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: color 0.15s;
}
.anamnese-icon-btn:hover { color: #22C55E; }
.anamnese-icon-btn-danger:hover { color: #EF4444; }

.workout-exercise-list { display: flex; flex-direction: column; gap: 6px; max-height: 400px; overflow-y: auto; }
.workout-exercise-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  border-bottom: 0.5px solid rgba(255,255,255,0.04);
  transition: background 0.15s;
}
.workout-exercise-item:last-child { border-bottom: none; }
.workout-exercise-item:hover { background: var(--bg-hover); }
.exercise-number {
  width: 22px; height: 22px;
  border-radius: 50%;
  background: rgba(255,255,255,0.06);
  color: rgba(255,255,255,0.4);
  font-size: 11px;
  font-family: Oswald, sans-serif;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.exercise-details { flex: 1; min-width: 0; }
.exercise-name { font-size: 13px; font-weight: 500; color: #fff; display: block; }
.exercise-meta { font-size: 11px; color: rgba(255,255,255,0.3); letter-spacing: 0.03em; }
.workout-exercise-item .video-link {
  font-size: 11px;
  color: rgba(34,197,94,0.6);
  display: inline-flex;
  align-items: center;
  gap: 3px;
  text-decoration: none;
  transition: color 0.15s;
}
.workout-exercise-item .video-link:hover { color: #22C55E; text-decoration: underline; }
.workout-exercise-item .badge-warning {
  background: rgba(251,191,36,0.1);
  border: 0.5px solid rgba(251,191,36,0.2);
  color: #FBBF24;
  font-size: 10px;
  padding: 2px 8px;
  border-radius: 3px;
  letter-spacing: 0.05em;
}
.workout-card-notes {
  margin-top: 12px;
  padding: 14px 16px;
  background: rgba(34,197,94,0.05);
  border: 0.5px solid rgba(34,197,94,0.15);
  border-radius: 8px;
  font-size: 12px;
  color: rgba(255,255,255,0.5);
  line-height: 1.7;
  display: flex;
  align-items: flex-start;
  gap: 8px;
}
.exercise-notes {
  display: block;
  margin-top: 6px;
  padding: 6px 10px;
  background: rgba(255,255,255,0.03);
  border-left: 2px solid rgba(34,197,94,0.3);
  border-radius: 0 6px 6px 0;
  font-size: 11px;
  color: rgba(255,255,255,0.4);
  line-height: 1.6;
  font-style: italic;
}

/* --- Cards section title --- */
.card-section-title {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 16px;
  font-family: var(--font-heading);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* --- Exercise Builder --- */
/* --- Exercise Builder --- */
.exercise-builder {
  background: var(--bg-secondary);
  border-radius: var(--radius);
  padding: 16px;
  margin-top: 12px;
}
.exercise-builder-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}
.exercise-builder-count {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

/* Add exercise card */
.exercise-add-card {
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px;
}
.exercise-search-row {
  position: relative;
  margin-bottom: 10px;
}

/* --- Search (legado removido, usar .workout-form .exercise-search-wrap) --- */
.exercise-search-input::placeholder { color: var(--text-muted); }
.exercise-search-clear {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
}

/* Exercise params row */
.exercise-params-row {
  display: flex;
  gap: 8px;
  align-items: flex-end;
  flex-wrap: wrap;
}
.exercise-param {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 70px;
}
.exercise-param-label {
  font-size: 0.7rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.exercise-param-input {
  padding: 7px 8px;
  font-size: 0.85rem;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-primary);
  width: 100%;
  box-sizing: border-box;
  transition: border-color 0.2s;
}
.exercise-param-input:focus {
  border-color: var(--accent);
  outline: none;
}
.exercise-param-unit {
  display: flex;
  align-items: center;
  gap: 4px;
}
.exercise-param-unit .exercise-param-input { width: auto; flex: 1; }
.exercise-param-unit span {
  font-size: 0.8rem;
  color: var(--text-muted);
}
.exercise-add-btn {
  white-space: nowrap;
  height: 34px;
  align-self: flex-end;
}

/* Exercise list */
.exercise-list-builder {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.exercise-item-builder {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: var(--bg-secondary);
  border: 0.5px solid var(--border);
  border-radius: 8px;
}
.exercise-item-builder.builder-superset {
  border-left: 3px solid var(--purple, #8B5CF6);
}
.builder-ex-number {
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--bg-tertiary);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.72rem; font-weight: 600;
  flex-shrink: 0; color: var(--text-muted);
}
.builder-ex-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.builder-ex-name {
  font-size: 0.88rem; font-weight: 500; color: var(--text-primary);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.builder-ex-meta {
  font-size: 0.75rem;
  color: var(--text-muted);
}
.builder-ex-actions {
  display: flex;
  gap: 4px;
  align-items: center;
  flex-shrink: 0;
}

.builder-ss-label:hover { background: rgba(139,92,246,0.1); }
.builder-ss-label input { accent-color: var(--purple, #8B5CF6); }
.builder-drop-select {
  font-size: 0.75rem;
  padding: 4px 6px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-primary);
  cursor: pointer;
}

.ai-page-title { font-family: Oswald, sans-serif; font-size: 32px; font-weight: 500; color: #fff; margin: 0; line-height: 1.1; }
@media (max-width: 640px) {
  .ai-page-title { font-size: 24px; }
}
@media (max-width: 480px) {
  .ai-page-title { font-size: 20px; }
}

/* --- AI Layout --- */
.ai-layout { display: grid; grid-template-columns: 360px 1fr; gap: 24px; align-items: start; }
.ai-sidebar { display: flex; flex-direction: column; gap: 16px; position: sticky; top: 24px; }
.ai-main { min-width: 0; }

.ai-section {
  background: rgba(255,255,255,0.02);
  border: 0.5px solid rgba(255,255,255,0.06);
  border-radius: 10px;
  padding: 20px 24px;
  margin-bottom: 12px;
}
.ai-card {
  background: rgba(255,255,255,0.02);
  border: 0.5px solid rgba(255,255,255,0.06);
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 12px;
}
.chip-group { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  padding: 5px 12px;
  border-radius: 100px;
  font-size: 0.78rem;
  font-weight: 500;
  font-family: var(--font);
  background: var(--bg-input);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.15s;
}
.chip:hover { border-color: var(--accent); color: var(--text-primary); }
.chip-active { background: var(--accent-light); border-color: var(--accent); color: var(--accent); }

.generating-state { text-align: center; padding: 40px 20px; }
.generating-state p { margin-top: 16px; font-weight: 600; }
.generating-hint { font-weight: 400 !important; color: var(--text-muted); font-size: 0.85rem; }
.generated-actions { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.generated-btns { display: flex; gap: 8px; }
@media (max-width: 768px) {
  .generated-actions { flex-direction: column; align-items: stretch; gap: 12px; }
  .generated-btns { flex-wrap: wrap; }
  .generated-btns .btn { flex: 1; min-width: 140px; }
}
@media (max-width: 480px) {
  .generated-btns .btn { min-width: 100%; }

  .settings-grid { grid-template-columns: 1fr !important; }
  .settings-section { padding: 16px; }
  .settings-page-title { font-size: 28px; }
}

/* --- Progress / Metrics --- */
.metrics-summary-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}
.metric-card { text-align: center; padding: 16px 12px !important; }
.metric-label { font-size: 0.72rem; color: var(--text-muted); text-transform: uppercase; font-weight: 600; margin-bottom: 6px; }
.metric-value { font-size: 1.5rem; font-weight: 600; letter-spacing: 0.3px; font-family: var(--font-heading); line-height: 1.2; }
.metric-delta { font-size: 0.75rem; font-weight: 600; margin-top: 4px; color: var(--text-secondary); }
.delta-positive { color: var(--accent); }
.delta-negative { color: var(--red); }

/* --- Chart --- */
.chart-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.chart-select { max-width: 180px; }
.chart-container { display: flex; gap: 12px; height: 240px; }
.chart-y-axis { display: flex; flex-direction: column; justify-content: space-between; font-size: 0.7rem; color: var(--text-muted); padding: 10px 0; min-width: 40px; text-align: right; }
.chart-area { flex: 1; overflow-x: auto; }
.chart-svg { width: 100%; height: 100%; min-width: 300px; }

/* --- Table --- */
.table-container { overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; font-size: 0.85rem; }
.data-table th {
  padding: 10px 12px;
  text-align: left;
  font-weight: 600;
  color: var(--text-secondary);
  border-bottom: 2px solid var(--border);
  font-size: 0.75rem;
  text-transform: uppercase;
  white-space: nowrap;
}
.data-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}

/* --- Sessions --- */
.sessions-list { display: flex; flex-direction: column; gap: 8px; }
.session-item { display: flex; align-items: center; gap: 16px; padding: 16px 20px; }
.session-date-badge {
  display: flex; flex-direction: column;
  align-items: center;
  min-width: 50px;
  background: var(--bg-tertiary);
  border-radius: var(--radius);
  padding: 6px 10px;
}
.session-day { font-size: 1.2rem; font-weight: 700; line-height: 1; }
.session-month { font-size: 0.7rem; color: var(--text-secondary); text-transform: uppercase; }
.session-info { flex: 1; min-width: 0; }
.session-student { font-weight: 600; font-size: 0.9rem; }
.session-meta { display: flex; gap: 14px; font-size: 0.8rem; color: var(--text-muted); margin-top: 2px; }
.session-meta span { display: flex; align-items: center; gap: 4px; }
.session-actions { display: flex; gap: 4px; }

/* --- View Toggle --- */
.view-toggle { display: flex; background: var(--bg-tertiary); border-radius: var(--radius); padding: 2px; }
.view-toggle-btn {
  display: flex; align-items: center; justify-content: center;
  width: 34px; height: 34px;
  background: none; border: none;
  border-radius: 6px; color: var(--text-secondary); cursor: pointer;
}
.view-toggle-btn.active { background: var(--bg-card); color: var(--text-primary); }

/* --- Calendar --- */
.calendar { padding: 16px; }
.calendar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}
.calendar-header h3 { font-size: 1rem; font-weight: 700; }
.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
}
.calendar-weekday {
  text-align: center;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  padding: 8px 4px;
}
.calendar-day {
  min-height: 80px;
  padding: 6px;
  border-radius: 6px;
  background: var(--bg-hover);
  transition: background 0.15s;
}
.calendar-day-empty { background: transparent; }
.calendar-today { background: var(--accent-light); border: 1px solid var(--accent); }
.calendar-day-num { font-size: 0.8rem; font-weight: 600; display: block; margin-bottom: 4px; }
.calendar-sessions { display: flex; flex-direction: column; gap: 2px; }
.calendar-session-dot {
  font-size: 0.65rem;
  padding: 1px 5px;
  border-radius: 3px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  cursor: default;
}
.calendar-dot-done { background: var(--accent-light); color: var(--accent); }
.calendar-dot-scheduled { background: var(--amber-light); color: var(--amber); }
.calendar-dot-cancelled { background: var(--red-light); color: var(--red); }
.calendar-more { font-size: 0.65rem; color: var(--text-muted); padding: 1px 5px; }

/* --- AI Chat --- */
.chat-container {
  height: calc(100vh - var(--topbar-height) - 40px);
  height: calc(100dvh - var(--topbar-height) - 40px);
  display: flex;
  flex-direction: column;
}

.chat-card {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding: 0 !important;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  -webkit-overflow-scrolling: touch;
}

.chat-message {
  display: flex;
  gap: 10px;
  max-width: 85%;
}

.chat-msg-user {
  align-self: flex-end;
  flex-direction: row-reverse;
}

.chat-msg-assistant {
  align-self: flex-start;
}

.chat-avatar {
  flex-shrink: 0;
  margin-top: 2px;
}

.chat-ai-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--accent-light);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
}

.chat-bubble {
  background: var(--bg-tertiary);
  border-radius: var(--radius-lg);
  padding: 12px 16px;
  min-width: 60px;
}

.chat-msg-user .chat-bubble {
  background: var(--accent);
  color: #fff;
}

.chat-msg-error .chat-bubble {
  background: var(--red-light);
  color: var(--red);
}

.chat-bubble-text {
  font-size: 0.9rem;
  line-height: 1.55;
  white-space: pre-wrap;
  word-break: break-word;
}

.chat-bubble-time {
  font-size: 0.68rem;
  color: var(--text-muted);
  margin-top: 4px;
  text-align: right;
}

.chat-msg-user .chat-bubble-time {
  color: rgba(255, 255, 255, 0.7);
}

.chat-input-area {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  padding: 14px 20px;
  border-top: 1px solid var(--border);
  background: var(--bg-card);
  position: sticky;
  bottom: 0;
  flex-shrink: 0;
  z-index: 10;
  padding-bottom: env(safe-area-inset-bottom, 12px);
}

.chat-input {
  flex: 1;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 10px 14px;
  color: var(--text-primary);
  font-family: var(--font);
  font-size: 0.9rem;
  resize: none;
  outline: none;
  transition: border-color 0.15s;
  line-height: 1.4;
}

.chat-input:focus {
  border-color: var(--accent);
}

.chat-input::placeholder {
  color: var(--text-muted);
}

.chat-send-btn {
  width: 42px;
  height: 42px;
  border-radius: 50% !important;
  padding: 0 !important;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* --- Ollama Info (Settings) --- */
.settings-ollama-info {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  background: var(--accent-light);
  border: 1px solid var(--accent);
  border-radius: var(--radius-lg);
  padding: 14px 16px;
  margin-bottom: 4px;
}

.settings-ollama-icon {
  font-size: 1.4rem;
  line-height: 1;
  flex-shrink: 0;
}

.settings-ollama-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.settings-ollama-desc {
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.45;
  margin: 0;
}

.settings-ollama-link {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 4px;
}

.settings-ollama-link a {
  color: var(--accent);
  text-decoration: none;
}

.settings-ollama-link a:hover {
  text-decoration: underline;
}

/* --- Ollama Badge (Sidebar) --- */
.nav-badge-ollama {
  font-size: 0.6rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  background: var(--accent-light);
  color: var(--accent);
  padding: 1px 6px;
  border-radius: 4px;
  margin-left: auto;
  white-space: nowrap;
}

/* --- LM Studio Badge (Sidebar) --- */
.nav-badge-lmstudio {
  font-size: 0.6rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  background: rgba(59, 130, 246, 0.15);
  color: #93C5FD;
  padding: 1px 6px;
  border-radius: 4px;
  margin-left: auto;
  white-space: nowrap;
}

/* --- LM Studio Info (Settings) --- */
.settings-lmstudio-info {
  background: rgba(59, 130, 246, 0.15) !important;
  border-color: #3B82F6 !important;
}

/* --- Responsive --- */
@media (max-width: 1024px) {
  .dashboard-stats-grid { grid-template-columns: repeat(2, 1fr); }
  .dashboard-grid { grid-template-columns: 1fr; }
  .dashboard-grid > .card:last-child { grid-column: auto; }
  .dashboard-charts-grid { grid-template-columns: 1fr 1fr; }
  .ai-layout { grid-template-columns: 1fr; }
  .ai-sidebar { position: static; }
  .metrics-summary-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 768px) {
  .branding-banner,
  .branding-banner-overlay { min-height: 160px; }
  .branding-banner-overlay { padding: 24px 20px; gap: 12px; }
  .branding-banner-logo { width: 64px; height: 64px; border-radius: 14px; }
  .branding-banner-name { font-size: 1.1rem; }
  .branding-banner-sub { font-size: 0.85rem; }
  .sidebar {
    position: fixed;
    left: 0; top: 0; bottom: 0;
    transform: translateX(-100%);
    transition: transform 0.25s ease;
    z-index: 100;
  }
  .sidebar-mobile-open { transform: translateX(0); }
  .sidebar-overlay.show, .sidebar-overlay { display: block; }
  .sidebar-closed .sidebar { min-width: var(--sidebar-width); }
  .mobile-menu-btn { display: flex; }
  .page-header { flex-direction: column; }
  .filters-row { flex-direction: column; }
  .filter-select { max-width: 100%; }
  .students-grid { grid-template-columns: 1fr; }
  .workouts-grid { grid-template-columns: 1fr; }
  .metrics-summary-grid { grid-template-columns: repeat(2, 1fr); }
  .dashboard-charts-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .settings-grid { grid-template-columns: 1fr; }
  .report-summary-grid { grid-template-columns: repeat(2, 1fr); }
  .page-container { padding: 16px; }
  .topbar { padding: 0 16px; }
  .topbar-search { max-width: none; }
  .topbar-date { display: none; }
  .session-item { flex-wrap: wrap; }
  .chat-container { height: calc(100vh - 100px); }
  .chat-message { max-width: 92%; }
  .chat-messages { scroll-behavior: smooth; }
}

/* --- Mobile: filters grid compacto --- */
@media (max-width: 640px) {
  .filters-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }
  .search-wrapper {
    grid-column: 1 / -1;
    min-width: 0;
  }
  .filter-select {
    width: 100%;
    font-size: 13px;
    padding: 10px 12px;
  }
}

/* --- PWA Install Banner --- */
.install-banner {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--bg-sidebar);
  border-bottom: 1px solid var(--accent);
  padding: 10px 20px;
  animation: slideDown 0.3s ease;
}

@keyframes slideDown {
  from { transform: translateY(-100%); }
  to { transform: translateY(0); }
}

.install-banner-content {
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: 600px;
  margin: 0 auto;
  color: var(--text-primary);
}

.install-banner-text {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.install-banner-text strong {
  font-size: 0.9rem;
  font-weight: 600;
}

.install-banner-text span {
  font-size: 0.78rem;
  color: var(--text-secondary);
}

/* --- Settings Page --- */
.settings-page-title {
  font-family: Oswald, sans-serif;
  font-size: 32px;
  font-weight: 500;
  color: #fff;
  margin: 0;
  line-height: 1.1;
}
.settings-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.settings-section {
  background: rgba(255,255,255,0.02);
  border: 0.5px solid rgba(255,255,255,0.06);
  border-radius: 10px;
  padding: 20px 24px;
}
.settings-section .form-label {
  font-size: 11px;
  color: rgba(255,255,255,0.35);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 8px;
  display: block;
}
.settings-section .input-field {
  background: rgba(255,255,255,0.04);
  border: 0.5px solid rgba(255,255,255,0.1);
  border-radius: 6px;
  color: #fff;
  font-family: 'DM Sans', sans-serif;
  font-size: 14px;
  padding: 10px 14px;
  width: 100%;
}
.settings-section .input-field:focus {
  border-color: rgba(34,197,94,0.35);
  box-shadow: none;
}
.settings-section .settings-test-area .btn {
  background: transparent;
  border: 0.5px solid rgba(34,197,94,0.25);
  color: #22C55E;
  font-size: 12px;
  padding: 9px 16px;
  border-radius: 5px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
}
.settings-section .settings-test-area .btn:hover:not(:disabled) {
  background: rgba(34,197,94,0.08);
}
.settings-plan-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}
.settings-plan-name {
  font-family: Oswald, sans-serif;
  font-size: 20px;
  color: #22C55E;
  font-weight: 500;
}
.btn-cancel-plan {
  background: transparent;
  border: 0.5px solid rgba(239,68,68,0.25);
  color: rgba(239,68,68,0.6);
  font-size: 12px;
  padding: 8px 16px;
  border-radius: 5px;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  transition: all 0.15s;
}
.btn-cancel-plan:hover {
  border-color: #EF4444;
  color: #EF4444;
}
.btn-clear-cache {
  background: transparent;
  border: 0.5px solid rgba(255,255,255,0.1);
  color: rgba(255,255,255,0.4);
  font-size: 12px;
  padding: 9px 16px;
  border-radius: 5px;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  transition: all 0.15s;
  width: 100%;
}
.btn-clear-cache:hover {
  border-color: #EF4444;
  color: #EF4444;
}
.btn-save-settings {
  background: #22C55E;
  color: #0F172A;
  font-weight: 700;
  font-size: 13px;
  padding: 11px 24px;
  border-radius: 6px;
  border: none;
  width: 100%;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: filter 0.15s;
}
.btn-save-settings:hover {
  filter: brightness(1.1);
}
.settings-toggle-row {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
}
.settings-toggle-track {
  position: relative;
  width: 44px;
  height: 24px;
  background: rgba(255,255,255,0.1);
  border-radius: 12px;
  transition: background 0.2s;
  flex-shrink: 0;
}
.settings-toggle-track.active {
  background: #22C55E;
}
.settings-toggle-knob {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 20px;
  height: 20px;
  background: #fff;
  border-radius: 50%;
  transition: left 0.2s;
}
.settings-toggle-track.active .settings-toggle-knob {
  left: 22px;
}
.settings-toggle-label {
  font-size: 13px;
  color: rgba(255,255,255,0.5);
  user-select: none;
}
.settings-logo-preview {
  width: 64px;
  height: 64px;
  border-radius: 8px;
  object-fit: cover;
  border: 0.5px solid rgba(255,255,255,0.1);
  flex-shrink: 0;
}
.settings-logo-placeholder {
  width: 64px;
  height: 64px;
  border-radius: 8px;
  background: rgba(255,255,255,0.04);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0.5px solid rgba(255,255,255,0.1);
  flex-shrink: 0;
}
.settings-brand-btn {
  font-size: 12px;
  color: rgba(255,255,255,0.5);
  background: transparent;
  border: none;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  transition: color 0.15s;
}
.settings-brand-btn:hover {
  color: #22C55E;
}
.settings-brand-btn-remove {
  font-size: 12px;
  color: rgba(239,68,68,0.6);
  background: transparent;
  border: none;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  transition: color 0.15s;
}
.settings-brand-btn-remove:hover {
  color: #EF4444;
}
.settings-brand-hint {
  font-size: 12px;
  color: rgba(255,255,255,0.3);
  line-height: 1.5;
  margin-top: 4px;
}
.settings-brand-section-title {
  font-size: 11px;
  color: rgba(255,255,255,0.35);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 12px;
  display: block;
}
.settings-banner-preview {
  width: 100%;
  max-height: 120px;
  border-radius: 8px;
  object-fit: cover;
  border: 0.5px solid rgba(255,255,255,0.08);
  flex-shrink: 0;
}
.settings-banner-placeholder {
  width: 160px;
  max-height: 90px;
  border-radius: 8px;
  background: rgba(255,255,255,0.04);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0.5px solid rgba(255,255,255,0.08);
  flex-shrink: 0;
  aspect-ratio: 16/9;
}

@media (max-width: 1024px) {
  .settings-grid { grid-template-columns: repeat(2, 1fr); }
}

.settings-test-area {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 4px;
}

.settings-test-result {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
  padding: 6px 12px;
  border-radius: var(--radius);
  font-weight: 500;
}

.settings-test-result.test-ok {
  background: var(--accent-light);
  color: var(--accent);
}

.settings-test-result.test-fail {
  background: var(--red-light);
  color: var(--red);
}

.settings-data-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 24px;
}

.settings-data-actions .btn {
  flex: 0 0 auto;
}

.plan-card-row { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.plan-card-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }

.completion-type-row { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.completion-type-label { min-width: 70px; font-size: 0.82rem; font-weight: 500; color: var(--text-primary); white-space: nowrap; }
.completion-type-bar-track { flex: 1; height: 20px; background: var(--bg-tertiary); border-radius: 10px; overflow: hidden; }
.completion-type-bar-fill { height: 100%; border-radius: 10px; transition: width 0.4s ease; min-width: 4px; }
.completion-type-value { min-width: 70px; font-size: 0.82rem; font-weight: 600; color: var(--text-primary); text-align: right; white-space: nowrap; }
.completion-type-value .text-muted { font-weight: 400; font-size: 0.75rem; }

.settings-danger-zone {
  border: 1px solid var(--red);
  border-radius: var(--radius-lg);
  padding: 16px;
  background: rgba(239, 68, 68, 0.05);
}

.settings-danger-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--red);
  margin-bottom: 12px;
}

.settings-clear-warning {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 10px;
  line-height: 1.5;
}

.settings-clear-warning strong {
  color: var(--red);
}

.settings-clear-buttons {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

.settings-clear-confirm .input-field {
  width: 100%;
  max-width: 280px;
}

/* ============================================================================
   MESSAGING — Comunicação em Massa
   ============================================================================ */
.btn-xs { padding: 3px 10px; font-size: 0.75rem; }

.messaging-textarea {
  width: 100%;
  min-height: 120px;
  font-family: inherit;
  resize: vertical;
  line-height: 1.6;
}

.messaging-summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  padding: 12px 16px;
  background: var(--accent-light);
  border-radius: var(--radius);
  font-size: 0.9rem;
}

.messaging-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.messaging-preview {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: 400px;
  overflow-y: auto;
}

.messaging-preview-item {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 16px;
}

.messaging-preview-item p {
  margin: 0;
}

/* ============================================================================
   WORKOUT EXECUTER — Registro de Carga por Sessão
   ============================================================================ */
.wexec-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}
.wexec-student-name {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--accent);
}
.wexec-date {
  font-size: 0.85rem;
  color: var(--text-muted);
}
.wexec-exercises {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-height: 50vh;
  overflow-y: auto;
  padding-right: 4px;
}
.wexec-exercise {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 16px;
}
.wexec-ex-name {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
  font-size: 0.9rem;
}
.wexec-last {
  font-size: 0.75rem;
  color: var(--text-muted);
  background: var(--bg-input);
  padding: 2px 8px;
  border-radius: 100px;
}
.wexec-serie {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 0;
  border-top: 1px solid var(--border);
}
.wexec-serie:first-child { border-top: none; }
.wexec-serie-fail {
  background: rgba(239, 68, 68, 0.06);
  border-radius: 4px;
  padding: 4px 8px;
  margin: 0 -8px;
}
.wexec-serie-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  width: 48px;
  flex-shrink: 0;
}
.wexec-serie-inputs {
  display: flex;
  gap: 8px;
  align-items: center;
  flex: 1;
}
.wexec-input-label {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 0.75rem;
  color: var(--text-secondary);
}
.wexec-input {
  width: 56px !important;
  text-align: center;
  padding: 4px 6px !important;
  font-size: 0.85rem;
}
.wexec-check-label {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 0.75rem;
  color: var(--text-secondary);
  cursor: pointer;
}
.wexec-meta {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}
.wexec-meta-row {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}
.wexec-humor {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.wexec-footer {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.wexec-history-table {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 300px;
  overflow-y: auto;
}
.wexec-history-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 10px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.82rem;
  gap: 8px;
}
.wexec-history-date {
  color: var(--text-muted);
  flex-shrink: 0;
  font-size: 0.78rem;
}
.wexec-history-series {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  flex: 1;
  justify-content: center;
}
.wexec-history-serie {
  background: var(--bg-input);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.75rem;
}
.wexec-history-max {
  color: var(--accent);
  font-weight: 600;
  flex-shrink: 0;
  font-size: 0.78rem;
}

/* Badge de progressão automática */
.badge-progressao {
  background: rgba(34, 197, 94, 0.2) !important;
  color: var(--accent) !important;
  animation: pulse-progressao 2s ease-in-out infinite;
  cursor: help;
}
@keyframes pulse-progressao {
  0%, 100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.4); }
  50% { box-shadow: 0 0 0 4px rgba(34, 197, 94, 0); }
}

.progression-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.progression-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 10px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  gap: 8px;
}
.progression-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.progression-ex-name {
  font-size: 0.85rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.progression-student {
  font-size: 0.75rem;
  color: var(--text-muted);
}
.progression-badge-tag {
  flex-shrink: 0;
}

@media (max-width: 480px) {
  .dashboard-stats-grid { grid-template-columns: 1fr; }
  .metrics-summary-grid { grid-template-columns: 1fr; }
  .calendar-day { min-height: 60px; }
  .calendar-session-dot { font-size: 0.6rem; }
  .branding-banner,
  .branding-banner-overlay { min-height: 120px; }
  .branding-banner-overlay { padding: 16px; gap: 10px; }
  .branding-banner-logo { width: 48px; height: 48px; border-radius: 10px; }
  .branding-banner-name { font-size: 0.95rem; }
  .branding-banner-sub { font-size: 0.78rem; }

  .ai-section { padding: 16px; }

  /* Aumentar fontes pequenas no mobile */
  .badge,
  .nav-drawer-section,
  .tf-logo-sub,
  .metric-label,
  .section-eyebrow,
  .exercise-meta,
  .student-card-email,
  .detail-label {
    font-size: 11px !important;
  }

  .exercise-name,
  .workout-card-title-row h3,
  .student-card-notes {
    font-size: 14px !important;
  }

  .nav-drawer-link {
    font-size: 14px !important;
  }

  .metric-value {
    font-size: 24px !important;
  }

  [class*="eyebrow"],
  [class*="section-label"] {
    font-size: 10px !important;
  }
}

/* ============================================================
   PLANOS E ASSINATURAS
   ============================================================ */

.plan-usage-banner {
  background: var(--bg-secondary);
  border: 0.5px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px 20px;
  margin-bottom: 1.5rem;
}

.plan-usage-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.plan-usage-title {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-secondary);
}

.plan-usage-bars {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.plan-usage-item-header {
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.plan-usage-bar {
  height: 4px;
  background: var(--bg-tertiary);
  border-radius: 2px;
  overflow: hidden;
}

.plan-usage-bar-fill {
  height: 100%;
  border-radius: 2px;
  transition: width 0.4s ease, background 0.3s;
}

.plan-cards-row {
  display: flex;
  gap: 12px;
  margin-top: 0.5rem;
}

.plan-card {
  flex: 1;
  background: var(--bg-primary);
  border: 0.5px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px;
  text-align: left;
  position: relative;
}

.plan-card-highlight {
  border-color: var(--accent);
  background: var(--accent-light);
}

.plan-card-badge {
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--accent);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 600;
  padding: 2px 10px;
  border-radius: 20px;
  white-space: nowrap;
}

.plan-card-name {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.plan-card-price {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 12px;
}

.plan-card-price span {
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--text-muted);
}

.plan-card-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.plan-card-features li {
  font-size: 0.8rem;
  color: var(--text-secondary);
  padding-left: 16px;
  position: relative;
}

.plan-card-features li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 600;
}

@media (max-width: 480px) {
  .plan-cards-row { flex-direction: column; }
}

/* --- Chat back button (mobile) --- */
.chat-back-btn { display: none; }

/* --- Toggle Switch --- */
.toggle-switch {
  cursor: pointer;
}
.toggle-switch:hover {
  opacity: 0.9;
}

/* --- Missing grid components --- */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
  gap: 16px;
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}
.exercise-form-row {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

@media (max-width: 768px) {
  .cards-grid { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .modal-header { padding: 14px 16px; }
  .modal-body { padding: 16px; }
  .exercise-form-row { flex-direction: column; align-items: stretch; }
  .exercise-form-row .input-sm { max-width: 100%; }
  .chat-back-btn { display: flex; }
}

@media (min-width: 769px) {
  .chat-back-btn { display: none; }
}

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

/* ============================================================
   MÉTODOS DE TREINO — classes novas (sem conflito)
   ============================================================ */

.new-exercise-form {
  background: var(--bg-primary);
  border: 0.5px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 14px;
}

.method-current-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: var(--bg-secondary);
  border: 0.5px solid var(--border);
  border-radius: 8px;
  padding: 8px 12px;
}

.method-current-info {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
}

.method-current-badge {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 20px;
  white-space: nowrap;
  flex-shrink: 0;
}

.method-current-label {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-primary);
  white-space: nowrap;
}

.method-current-desc {
  font-size: 0.75rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.method-panel {
  background: var(--bg-secondary);
  border: 0.5px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
}

.method-cat-tabs {
  display: flex;
  background: var(--bg-primary);
  padding: 3px;
  gap: 3px;
  border-bottom: 0.5px solid var(--border);
}

.method-cat-tab {
  flex: 1;
  padding: 5px 0;
  font-size: 0.72rem;
  font-weight: 500;
  font-family: var(--font);
  text-align: center;
  border-radius: 6px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: all .15s;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.method-cat-tab-active {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.method-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 6px;
  padding: 10px;
}

.method-btn {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  padding: 8px 10px;
  border-radius: 8px;
  font-family: var(--font);
  cursor: pointer;
  border: 0.5px solid var(--border);
  background: var(--bg-primary);
  color: var(--text-muted);
  transition: all 0.15s;
  text-align: left;
}

.method-btn:hover { border-color: var(--accent); color: var(--text-primary); }
.method-btn-active { background: var(--bg-tertiary); }

.method-btn-label {
  font-size: 0.8rem;
  font-weight: 500;
  color: inherit;
}

.method-btn-short {
  font-size: 0.68rem;
  color: var(--text-muted);
}

.method-extras {
  background: var(--bg-secondary);
  border: 0.5px solid var(--border);
  border-radius: 8px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.method-extras-title {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: .04em;
}

.method-hint {
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.method-row {
  display: flex;
  gap: 12px;
}

.method-pill-row { display: flex; gap: 6px; flex-wrap: wrap; }

.method-pill {
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.78rem;
  font-family: var(--font);
  cursor: pointer;
  border: 0.5px solid var(--border);
  background: var(--bg-primary);
  color: var(--text-muted);
  transition: all .15s;
}

.method-pill-active {
  background: var(--accent-gradient);
  color: #fff;
  border-color: transparent;
}

.drop-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.drop-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  white-space: nowrap;
  min-width: 48px;
}

.exercise-item-grouped {
  background: transparent;
  border: none;
  border-bottom: 0.5px solid var(--border);
  border-radius: 0;
  padding: 8px 10px;
}

.exercise-item-grouped:last-child { border-bottom: none; }

.builder-ex-letter {
  width: 20px; height: 20px;
  border-radius: 4px;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.7rem; font-weight: 700;
  flex-shrink: 0;
}

.builder-ex-method-badge {
  font-size: 0.72rem; font-weight: 600;
}

.builder-ex-notes {
  font-size: 0.72rem; color: var(--text-muted); font-style: italic;
}

.exercise-group-block {
  border: 1.5px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
}

.exercise-group-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 12px;
  background: var(--bg-primary);
  border-bottom: 0.5px solid var(--border);
}

.exercise-group-badge {
  font-size: 0.72rem; font-weight: 600;
  padding: 2px 10px; border-radius: 20px;
}

.exercise-search-dropdown {
  position: absolute; top: 100%; left: 0; right: 0;
  background: var(--bg-secondary);
  border: 0.5px solid var(--border);
  border-radius: 8px;
  z-index: 100;
  box-shadow: 0 8px 24px rgba(0,0,0,0.3);
  overflow: hidden;
}

.exercise-search-item {
  display: flex; justify-content: space-between; align-items: center;
  padding: 8px 12px; background: none; border: none;
  border-bottom: 0.5px solid var(--border);
  cursor: pointer; width: 100%; text-align: left;
  font-family: var(--font); transition: background 0.1s;
}

.exercise-search-item:last-child { border-bottom: none; }
.exercise-search-item:hover { background: var(--bg-tertiary); }
.exercise-search-name { font-size: 0.85rem; color: var(--text-primary); font-weight: 500; }
.exercise-search-group { font-size: 0.75rem; color: var(--text-muted); }

.btn-xs { padding: 3px 8px; font-size: 0.72rem; border-radius: 6px; }

@media (max-width: 480px) {
  .method-grid { grid-template-columns: repeat(2, 1fr); }
  .method-cat-tab { font-size: 0.65rem; }
  .method-current-desc { display: none; }
}

/* ============================================================================
   LANDING PAGE — Editorial Design (janderlabs referência)
   ============================================================================ */

/* Canvas partículas */
#particle-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

/* Landing Wrapper */
.landing-page {
  background: var(--bg-primary);
  min-height: 100vh;
  overflow-x: hidden;
  overflow-y: auto;
}

/* Navbar */
.landing-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 0.5px solid rgba(255,255,255,0.06);
}
.landing-nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.landing-nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  cursor: pointer;
}
.landing-nav-logo-icon {
  width: 32px; height: 32px;
  background: var(--accent-gradient);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.7rem;
  color: #fff;
  letter-spacing: 0;
  font-family: var(--font-heading);
  text-transform: uppercase;
}
.landing-nav-logo-text {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: 0.3px;
  font-family: var(--font-heading);
  text-transform: uppercase;
}
.landing-nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
}
.landing-nav-link {
  font-size: 12px;
  font-weight: 500;
  color: rgba(255,255,255,0.45);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  transition: color 0.2s;
  cursor: pointer;
  background: none;
  border: none;
  font-family: var(--font);
}
.landing-nav-link:hover { color: var(--accent); }
.landing-nav-locale {
  font-size: 11px;
  color: rgba(255,255,255,0.25);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  white-space: nowrap;
}

/* Section numbering */
.section-label {
  display: block;
  font-size: 11px;
  color: rgba(255,255,255,0.3);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 8px;
  font-weight: 400;
}

/* Section divider */
.landing-section {
  padding-top: 60px;
}
.landing-section + .landing-section {
  border-top: 0.5px solid rgba(255,255,255,0.06);
}

/* Hero */
.landing-hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 120px 24px 80px;
  overflow: hidden;
}
.landing-hero-content {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}
.landing-hero h1 {
  font-family: var(--font-heading);
  font-size: clamp(3rem, 8vw, 5.5rem);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  line-height: 1.05;
  color: var(--text-primary);
  margin-bottom: 20px;
}
.landing-hero p {
  font-size: clamp(1rem, 2vw, 1.15rem);
  color: var(--text-secondary);
  line-height: 1.6;
  max-width: 560px;
  margin-bottom: 36px;
}
.landing-hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.landing-hero-actions .btn-primary-custom {
  background: var(--accent);
  color: #0F172A;
  font-weight: 700;
  padding: 12px 28px;
  border-radius: 6px;
  border: none;
  font-size: 0.85rem;
  cursor: pointer;
  font-family: var(--font);
  transition: opacity 0.2s;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.landing-hero-actions .btn-primary-custom:hover { opacity: 0.85; }
.landing-hero-actions .btn-secondary-custom {
  background: transparent;
  color: rgba(255,255,255,0.6);
  border: 0.5px solid rgba(255,255,255,0.15);
  padding: 12px 28px;
  border-radius: 6px;
  font-size: 0.85rem;
  cursor: pointer;
  font-family: var(--font);
  transition: border-color 0.2s, color 0.2s;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.landing-hero-actions .btn-secondary-custom:hover {
  border-color: rgba(255,255,255,0.3);
  color: var(--text-primary);
}

/* Feature cards */
.landing-features-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.landing-feature-card {
  background: rgba(255,255,255,0.03);
  border: 0.5px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  padding: 18px;
  transition: border-color 0.2s, background 0.2s;
}
.landing-feature-card:hover {
  border-color: rgba(34,197,94,0.35);
  background: rgba(34,197,94,0.04);
}
.landing-feature-number {
  display: block;
  font-size: 11px;
  color: rgba(255,255,255,0.25);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 12px;
}
.landing-feature-icon {
  width: 36px; height: 36px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
  color: var(--accent);
  background: var(--accent-light);
}
.landing-feature-title {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
  font-family: var(--font-heading);
  text-transform: uppercase;
  letter-spacing: 0.3px;
  margin-bottom: 6px;
}
.landing-feature-desc {
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* Inner content wrapper */
.landing-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Section titles */
.landing-section-title {
  font-family: var(--font-heading);
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-primary);
  margin-bottom: 16px;
}
.landing-section-sub {
  font-size: 0.9rem;
  color: var(--text-secondary);
  max-width: 500px;
  line-height: 1.5;
  margin-bottom: 40px;
}

/* About section */
.landing-about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}
.landing-about-text p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 16px;
}
.landing-about-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.landing-about-stat {
  border-left: 0.5px solid var(--accent);
  padding-left: 16px;
}
.landing-about-stat-value {
  font-size: 2rem;
  font-weight: 600;
  color: var(--text-primary);
  font-family: var(--font-heading);
  letter-spacing: 0.5px;
  line-height: 1.1;
}
.landing-about-stat-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 4px;
}

/* Plans section */
.landing-plans-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.landing-plan-card {
  background: rgba(255,255,255,0.03);
  border: 0.5px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  padding: 24px;
  transition: border-color 0.2s;
}
.landing-plan-card:hover {
  border-color: rgba(34,197,94,0.35);
}
.landing-plan-card.featured {
  border-color: rgba(34,197,94,0.25);
  background: rgba(34,197,94,0.04);
}
.landing-plan-name {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-primary);
  margin-bottom: 4px;
}
.landing-plan-price {
  font-size: 2rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
  font-family: var(--font-heading);
  letter-spacing: 0.5px;
}
.landing-plan-price span { font-size: 1rem; color: var(--text-muted); font-family: var(--font); }
.landing-plan-desc {
  font-size: 0.82rem;
  color: var(--text-secondary);
  margin-bottom: 20px;
}
.landing-plan-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 24px;
}
.landing-plan-features li {
  font-size: 0.82rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 8px;
}
.landing-plan-features li::before {
  content: '—';
  color: var(--accent);
  font-weight: 600;
}

/* Auth section */
.landing-auth-wrap {
  display: flex;
  justify-content: center;
  padding: 20px 0 40px;
}
.landing-auth-box {
  width: 100%;
  max-width: 400px;
  background: rgba(255,255,255,0.03);
  border: 0.5px solid rgba(255,255,255,0.08);
  border-radius: 12px;
  padding: 32px 28px;
}
.landing-auth-box .login-title {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text-primary);
  font-family: var(--font-heading);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
  text-align: center;
}
.landing-auth-box .login-subtitle {
  font-size: 0.82rem;
  color: var(--text-secondary);
  margin-bottom: 24px;
  text-align: center;
}
.landing-auth-box .input-field {
  width: 100%;
  padding: 12px 14px;
  background: rgba(255,255,255,0.04);
  border: 0.5px solid rgba(255,255,255,0.1);
  border-radius: 6px;
  color: var(--text-primary);
  font-family: var(--font);
  font-size: 0.9rem;
  outline: none;
  transition: border-color 0.2s;
}
.landing-auth-box .input-field:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px var(--accent-light);
}
.landing-auth-box .input-field::placeholder { color: var(--text-muted); }
.landing-auth-box .form-group { margin-bottom: 16px; }
.landing-auth-box .form-label {
  font-size: 11px;
  font-weight: 600;
  color: rgba(255,255,255,0.4);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 6px;
  display: block;
}
.landing-auth-btn {
  width: 100%;
  padding: 12px;
  background: var(--accent);
  color: #0F172A;
  font-weight: 700;
  border: none;
  border-radius: 6px;
  font-size: 0.85rem;
  cursor: pointer;
  font-family: var(--font);
  transition: opacity 0.2s;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.landing-auth-btn:hover { opacity: 0.85; }
.landing-auth-btn:disabled { opacity: 0.5; cursor: not-allowed; }
.landing-auth-links {
  display: flex;
  justify-content: space-between;
  margin-top: 16px;
}
.landing-auth-link {
  background: none;
  border: none;
  color: rgba(255,255,255,0.35);
  font-size: 0.78rem;
  cursor: pointer;
  font-family: var(--font);
  transition: color 0.2s;
  padding: 0;
}
.landing-auth-link:hover { color: var(--accent); }
.landing-auth-error {
  background: rgba(239,68,68,0.1);
  border: 0.5px solid rgba(239,68,68,0.2);
  color: var(--red);
  font-size: 0.8rem;
  padding: 10px 14px;
  border-radius: 6px;
  margin-bottom: 16px;
  text-align: center;
}
.landing-auth-success {
  background: rgba(34,197,94,0.1);
  border: 0.5px solid rgba(34,197,94,0.2);
  color: var(--accent);
  font-size: 0.8rem;
  padding: 10px 14px;
  border-radius: 6px;
  margin-bottom: 16px;
  text-align: center;
}

/* Footer */
.landing-footer {
  border-top: 0.5px solid rgba(255,255,255,0.06);
  padding: 32px 24px;
  text-align: center;
}
.landing-footer p {
  font-size: 11px;
  color: rgba(255,255,255,0.2);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* Responsive */
@media (max-width: 1024px) {
  .landing-features-grid { grid-template-columns: repeat(2, 1fr); }
  .landing-about-grid { grid-template-columns: 1fr; gap: 32px; }
  .landing-plans-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  .landing-nav-links { display: none; }
  .landing-nav-locale { display: none; }
  .landing-features-grid { grid-template-columns: 1fr 1fr; }
  .landing-plans-grid { grid-template-columns: 1fr; max-width: 380px; margin: 0 auto; }
  .landing-hero { padding: 100px 20px 60px; }
  .landing-about-stats { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 480px) {
  .landing-features-grid { grid-template-columns: 1fr; }
  .landing-hero-actions { flex-direction: column; }
  .landing-hero-actions a,
  .landing-hero-actions button { width: 100%; justify-content: center; }
}

/* ============================================================================
   LANDING PAGE — Scroll Reveal Animations
   ============================================================================ */

.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-left {
  opacity: 0;
  transform: translateX(-40px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal-left.visible { opacity: 1; transform: translateX(0); }

.reveal-right {
  opacity: 0;
  transform: translateX(40px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal-right.visible { opacity: 1; transform: translateX(0); }

.reveal-scale {
  opacity: 0;
  transform: scale(0.92);
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal-scale.visible { opacity: 1; transform: scale(1); }

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }

/* Scroll progress bar */
#scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 2px;
  width: 0%;
  background: #22C55E;
  z-index: 9999;
  transition: width 0.1s linear;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .reveal, .reveal-left, .reveal-right, .reveal-scale {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}

/* ============================================================================
   DASHBOARD — Editorial Redesign (Landing Page Identity)
   ============================================================================ */

/* --- Background dot grid --- */
.dash-dot-grid {
  background-image: radial-gradient(rgba(34,197,94,0.03) 1px, transparent 1px);
  background-size: 32px 32px;
}

/* --- Sidebar editorial --- */
.sidebar { background: rgba(255,255,255,0.02); border-right: 0.5px solid rgba(255,255,255,0.06); }
.sidebar-brand { border-bottom: 0.5px solid rgba(255,255,255,0.06); padding: 18px 16px; }
.sidebar-title {
  font-family: Oswald, sans-serif;
  font-size: 18px;
  color: #22C55E;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-weight: 500;
}
.sidebar-logo { background: transparent; color: #22C55E; }
.sidebar-logo-img { border-radius: 6px; }

/* Nav separadores editoriais */
.nav-group-sep {
  font-size: 10px;
  color: rgba(255,255,255,0.2);
  letter-spacing: 0.2em;
  padding: 16px 20px 6px;
  pointer-events: none;
  user-select: none;
  font-weight: 600;
  text-transform: uppercase;
}
.nav-item {
  padding: 8px 14px;
  margin: 0 6px;
  border-radius: 6px;
  color: rgba(255,255,255,0.45);
  font-family: DM Sans, sans-serif;
  font-size: 0.85rem;
  font-weight: 500;
}
.nav-item:hover {
  background: rgba(255,255,255,0.03);
  color: rgba(255,255,255,0.8);
}
.nav-item-active {
  color: #22C55E !important;
  border-left: 2px solid #22C55E;
  background: rgba(34,197,94,0.06) !important;
  border-radius: 0 6px 6px 0;
}
.nav-item-active::before { display: none; }

/* Sidebar footer user */
.sidebar-footer { border-top: 0.5px solid rgba(255,255,255,0.06); }
.sidebar-user-name {
  font-size: 12px;
  color: rgba(255,255,255,0.4);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-weight: 500;
  padding: 12px 16px 4px;
}

/* --- Topbar editorial --- */
.topbar {
  background: rgba(15,23,42,0.92) !important;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 0.5px solid rgba(255,255,255,0.06) !important;
}
.topbar-date {
  font-size: 11px;
  color: rgba(255,255,255,0.3);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 500;
}
.topbar-search-input {
  background: rgba(255,255,255,0.04) !important;
  border: 0.5px solid rgba(255,255,255,0.08) !important;
  border-radius: 6px !important;
  color: rgba(255,255,255,0.6) !important;
  font-size: 13px !important;
  height: 36px !important;
}
.topbar-search-input::placeholder { color: rgba(255,255,255,0.22); }

/* --- Dashboard header bar (compact editorial) --- */
.dash-header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 36px;
  margin-bottom: 24px;
  gap: 16px;
  flex-wrap: wrap;
}
.dash-header-eyebrow {
  font-size: 11px;
  color: rgba(255,255,255,0.3);
  letter-spacing: 0.15em;
  font-weight: 600;
  text-transform: uppercase;
}
.dash-header-badge {
  background: rgba(34, 197, 94, 0.08);
  border: 0.5px solid rgba(34, 197, 94, 0.25);
  color: #22C55E;
  font-size: 11px;
  font-family: DM Sans;
  font-weight: 500;
  letter-spacing: 0.08em;
  padding: 4px 12px;
  border-radius: 4px;
  text-transform: uppercase;
}

.dash-send-report-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  color: rgba(255, 255, 255, 0.4);
  font-size: 12px;
  font-family: DM Sans;
  padding: 6px 12px;
  border-radius: 6px;
  transition: color 0.2s ease;
}
.dash-send-report-btn:hover {
  color: #22C55E;
}
.dash-send-report-btn:hover .dash-send-report-icon {
  background: #22C55E !important;
}

/* --- Workouts header h1 --- */
.workouts-header h1 {
  font-family: 'Oswald', sans-serif !important;
  font-size: 32px;
  font-weight: 500;
  color: #fff;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

/* --- Custom select wrapper --- */
.select-wrapper {
  position: relative;
}
.select-wrapper::after {
  content: '▾';
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: rgba(255,255,255,0.3);
  pointer-events: none;
  font-size: 12px;
}
.select-wrapper select {
  appearance: none;
  -webkit-appearance: none;
  width: 100%;
  background: rgba(255,255,255,0.04);
  border: 0.5px solid rgba(255,255,255,0.1);
  border-radius: 6px;
  color: #fff;
  font-family: 'DM Sans', sans-serif;
  font-size: 14px;
  padding: 10px 36px 10px 14px;
  cursor: pointer;
  outline: none;
}
.select-wrapper select:focus {
  border-color: rgba(34,197,94,0.35);
  background: rgba(255,255,255,0.06);
}
.select-wrapper select option {
  background: #0F172A;
  color: #fff;
  padding: 8px;
}
.select-wrapper select option:checked,
.select-wrapper select option:hover {
  background: rgba(34,197,94,0.15);
  color: #22C55E;
}

/* --- Metric cards editorial --- */
.dash-metrics-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}
.dash-metric-card {
  background: rgba(255,255,255,0.03);
  border: 0.5px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  padding: 20px;
  transition: border-color 0.2s ease, background 0.2s ease;
}
.dash-metric-card:hover {
  border-color: rgba(34,197,94,0.35);
  background: rgba(34,197,94,0.04);
}
.dash-metric-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  color: rgba(255,255,255,0.3);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 8px;
  font-weight: 600;
}
.dash-metric-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}
.dash-metric-dot.active { background: #22C55E; }
.dash-metric-dot.inactive { background: rgba(255,255,255,0.15); }
.dash-metric-value {
  font-family: Oswald, sans-serif;
  font-size: 36px;
  color: #fff;
  font-weight: 500;
  line-height: 1;
  margin-bottom: 4px;
}
.dash-metric-context {
  font-size: 12px;
  color: rgba(255,255,255,0.3);
}

/* --- Plan limits editorial --- */
.dash-plan-section {
  margin-bottom: 24px;
}
.dash-plan-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  flex-wrap: wrap;
  gap: 8px;
}
.dash-plan-upgrade-btn {
  background: transparent;
  border: 0.5px solid rgba(34,197,94,0.4);
  color: #22C55E;
  font-size: 12px;
  padding: 6px 16px;
  border-radius: 5px;
  cursor: pointer;
  font-family: DM Sans, sans-serif;
  font-weight: 500;
  transition: background 0.2s ease;
}
.dash-plan-upgrade-btn:hover { background: rgba(34,197,94,0.08); }

.dash-plan-container {
  background: rgba(255,255,255,0.02);
  border: 0.5px solid rgba(255,255,255,0.06);
  border-radius: 10px;
  padding: 20px 24px;
}
.dash-plan-bars { display: flex; flex-direction: column; gap: 14px; }
.dash-plan-item { display: flex; flex-direction: column; gap: 4px; }
.dash-plan-item-header {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
}
.dash-plan-item-label { color: rgba(255,255,255,0.5); }
.dash-plan-item-usage {
  font-family: Oswald, sans-serif;
  color: rgba(255,255,255,0.6);
}
.dash-plan-track {
  height: 3px;
  background: rgba(255,255,255,0.08);
  border-radius: 2px;
  overflow: hidden;
}
.dash-plan-fill {
  height: 100%;
  border-radius: 2px;
  transition: width 0.4s ease;
}
.dash-plan-limit-badge {
  font-size: 10px;
  padding: 2px 8px;
  border-radius: 3px;
  background: rgba(239,68,68,0.2);
  color: #EF4444;
  margin-left: 8px;
  font-weight: 600;
  text-transform: uppercase;
}

/* --- Pending payments editorial --- */
.dash-payments-section { margin-bottom: 24px; }
.dash-payments-list { display: flex; flex-direction: column; gap: 8px; }
.dash-payment-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(255,255,255,0.02);
  border: 0.5px solid rgba(255,255,255,0.06);
  border-radius: 8px;
  padding: 14px 18px;
  gap: 12px;
  flex-wrap: wrap;
}
.dash-payment-left {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.dash-payment-name { font-size: 14px; font-weight: 500; color: #fff; }
.dash-payment-meta { font-size: 12px; color: rgba(255,255,255,0.4); }
.dash-payment-actions { display: flex; gap: 8px; flex-shrink: 0; }
.dash-btn-confirm {
  background: #22C55E;
  color: #0F172A;
  font-weight: 700;
  font-size: 12px;
  padding: 7px 16px;
  border-radius: 5px;
  border: none;
  cursor: pointer;
  font-family: DM Sans, sans-serif;
  transition: opacity 0.15s ease;
}
.dash-btn-confirm:hover { opacity: 0.85; }
.dash-btn-reject {
  background: transparent;
  color: rgba(255,255,255,0.35);
  font-size: 12px;
  padding: 7px 16px;
  border: 0.5px solid rgba(255,255,255,0.1);
  border-radius: 5px;
  cursor: pointer;
  font-family: DM Sans, sans-serif;
  transition: all 0.15s ease;
}
.dash-btn-reject:hover { color: rgba(255,255,255,0.6); border-color: rgba(255,255,255,0.2); }

/* --- Responsive --- */
@media (max-width: 1024px) {
  .dash-metrics-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
  .dash-metrics-grid { grid-template-columns: repeat(2, 1fr); }
  .dash-header-bar { flex-direction: column; align-items: flex-start; }
  .dash-header-bar > div { flex-wrap: wrap; }
  .dash-plan-header { flex-direction: column; align-items: flex-start; gap: 8px; }
  .dash-plan-container { padding: 16px; }
  .nav-item { padding: 12px 14px; }
  .nav-group-sep { padding: 20px 20px 6px; font-size: 11px; }
  .dash-btn-confirm, .dash-btn-reject { padding: 9px 18px; font-size: 13px; }
  .topbar-search-input { height: 40px !important; font-size: 15px !important; }
  .page-container { padding: 14px; }
}
@media (max-width: 480px) {
  .dash-metrics-grid { grid-template-columns: 1fr; }
  .dash-metric-value { font-size: 28px; }
  .dash-header-bar > div { flex-wrap: wrap; }
  .dash-payment-item { flex-direction: column; align-items: flex-start; }
  .dash-payment-actions { width: 100%; justify-content: flex-end; }
  .dash-payment-actions .dash-btn-confirm,
  .dash-payment-actions .dash-btn-reject { flex: 1; text-align: center; }
  .dash-plan-container { padding: 14px; }
  .page-container { padding: 12px; }
  .dash-header-bar .btn-sm { padding: 8px 12px; font-size: 0.82rem; }
  .nav-item { padding: 14px 14px; }
  .dash-btn-confirm, .dash-btn-reject { padding: 11px 0; font-size: 13px; flex: 1; }
}

/* ============================================================================
   TURBINAFIT BRAND LOGO
   ============================================================================ */
.tf-logo-link { text-decoration: none; display: inline-flex; align-items: center; }
.tf-logo { display: flex; align-items: center; gap: 10px; }
.tf-logo-icon {
  width: 36px; height: 36px;
  background: #22C55E;
  border-radius: 7px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.tf-logo-wordmark { display: flex; flex-direction: column; line-height: 1; gap: 3px; }
.tf-logo-name {
  font-family: 'Oswald', sans-serif;
  font-size: 18px; font-weight: 700;
  color: #ffffff;
  letter-spacing: 0.05em;
}
.tf-logo-accent { color: #22C55E; }
.tf-logo-sub {
  font-family: 'DM Sans', sans-serif;
  font-size: 9px;
  color: rgba(255,255,255,0.25);
  letter-spacing: 0.22em;
  text-transform: uppercase;
}
@media (max-width: 640px) {
  .tf-logo-wordmark { display: none; }
  .tf-logo-icon { width: 32px; height: 32px; border-radius: 6px; }
}

/* ============================================================================
   DRAWER MOBILE (substitui sidebar antiga em mobile)
   ============================================================================ */

.nav-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0);
  backdrop-filter: blur(0px);
  -webkit-backdrop-filter: blur(0px);
  pointer-events: none;
  transition: background 0.3s ease, backdrop-filter 0.3s ease;
  z-index: 100;
}
.nav-backdrop.open {
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  pointer-events: all;
}

.nav-drawer {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: 260px;
  background: #080F1E;
  border-right: 0.5px solid rgba(255, 255, 255, 0.08);
  transform: translateX(-100%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 101;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}
.nav-drawer.open {
  transform: translateX(0);
}

.nav-drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 16px 16px;
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.06);
  flex-shrink: 0;
}

.nav-drawer-close {
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.3);
  font-size: 16px;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 4px;
  transition: color 0.15s, background 0.15s;
}
.nav-drawer-close:hover {
  color: rgba(255, 255, 255, 0.7);
  background: rgba(255, 255, 255, 0.05);
}

.nav-drawer-nav {
  flex: 1;
  padding: 8px 0;
  overflow-y: auto;
}

.nav-drawer-section {
  font-size: 9px;
  color: rgba(255, 255, 255, 0.2);
  letter-spacing: 0.2em;
  padding: 16px 16px 6px;
  pointer-events: none;
  user-select: none;
}

.nav-drawer-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 16px;
  font-size: 13px;
  font-family: 'DM Sans', sans-serif;
  color: rgba(255, 255, 255, 0.45);
  text-decoration: none;
  cursor: pointer;
  border-left: 2px solid transparent;
  transition: color 0.15s, background 0.15s, border-color 0.15s;
}
.nav-drawer-link:hover {
  color: rgba(255, 255, 255, 0.8);
  background: rgba(255, 255, 255, 0.03);
}
.nav-drawer-link.active {
  color: #22C55E;
  border-left-color: #22C55E;
  background: rgba(34, 197, 94, 0.06);
}

.nav-drawer-icon {
  font-size: 14px;
  width: 20px;
  text-align: center;
  opacity: 0.6;
  flex-shrink: 0;
}
.nav-drawer-link.active .nav-drawer-icon {
  opacity: 1;
}

.nav-drawer-footer {
  padding: 14px 16px;
  border-top: 0.5px solid rgba(255, 255, 255, 0.06);
  font-size: 10px;
  font-family: 'DM Sans', sans-serif;
  color: rgba(255, 255, 255, 0.2);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}
.nav-drawer-logout {
  background: none;
  border: none;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #EF4444;
  padding: 4px 8px;
  border-radius: 4px;
  margin-left: auto;
  flex-shrink: 0;
}
.nav-drawer-logout:hover { background: rgba(239,68,68,0.1); }

body.drawer-open {
  overflow: hidden;
}

/* Esconde drawer e backdrop no desktop */
@media (min-width: 768px) {
  .nav-drawer,
  .nav-backdrop { display: none !important; }
}

/* Em mobile: esconde a sidebar antiga que deslizava, usa o drawer */
@media (max-width: 767px) {
  .sidebar {
    transform: translateX(-100%) !important;
    pointer-events: none !important;
  }
  .sidebar-overlay {
    display: none !important;
  }
  .sidebar-mobile-open {
    transform: translateX(-100%) !important;
  }
}

/* --- Profile header (modal) --- */
.profile-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 8px;
}
.profile-header-info { flex: 1; min-width: 0; }
.profile-header-info h3 {
  font-family: Oswald, sans-serif;
  font-size: 20px;
  font-weight: 500;
  color: #fff;
  margin: 4px 0 2px;
}
.profile-header-info p {
  font-size: 12px;
  color: rgba(255,255,255,0.35);
  margin: 0;
}
.profile-badges {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 8px;
}
.profile-notes-text {
  font-size: 13px;
  color: rgba(255,255,255,0.45);
  line-height: 1.5;
  word-wrap: break-word;
  overflow-wrap: break-word;
}
.profile-section-desc {
  font-size: 12px;
  color: rgba(255,255,255,0.25);
  margin: -8px 0 14px;
}
.profile-qr-canvas {
  display: block;
  border-radius: 8px;
}
.profile-access-header {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 16px;
}
.profile-access-header .profile-section-label {
  border-bottom: none;
  padding-bottom: 0;
  margin-bottom: 0;
  white-space: nowrap;
}
.profile-access-header .profile-section-desc {
  font-size: 11px;
  color: rgba(255,255,255,0.25);
  margin: 0;
}
.profile-access-body {
  text-align: center;
}

.profile-qr-container {
  display: inline-block;
  background: rgba(255,255,255,0.03);
  border: 0.5px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  padding: 8px;
  margin: 0 auto 16px;
}

.profile-qr-info {
  text-align: left;
  max-width: 100%;
}

.profile-link-row {
  display: flex;
  gap: 6px;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 10px;
  max-width: 100%;
}

.profile-link-row .profile-input {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.profile-qr-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  max-width: 100%;
}

.profile-qr-actions .btn {
  flex: 1;
  justify-content: center;
  text-align: center;
  min-width: 120px;
}

@media (min-width: 769px) {
  .profile-access-body {
    text-align: left;
  }
  .profile-qr-container {
    display: inline-flex;
    margin: 0;
  }
  .profile-access-body {
    display: flex;
    flex-direction: row;
    gap: 20px;
    align-items: flex-start;
  }
  .profile-qr-info {
    flex: 1;
    min-width: 0;
  }
}
.profile-password-row {
  display: flex;
  gap: 8px;
  align-items: center;
}

/* --- Mobile: profile modal --- */
@media (max-width: 768px) {
  .profile-section {
    overflow: hidden;
  }
  .profile-measurements-grid {
    grid-template-columns: 1fr;
  }
  .profile-block-name,
  .profile-header-info h3 {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  .profile-qr-container {
    align-self: center;
  }
  .profile-qr-info {
    width: 100%;
    min-width: 0;
  }
  .profile-link-row {
    flex-wrap: wrap;
    gap: 6px;
  }
  .profile-link-row .profile-input {
    width: 100%;
  }
  .profile-qr-actions {
    flex-wrap: wrap;
    gap: 6px;
  }
  .profile-qr-actions .profile-btn {
    flex: 1;
    justify-content: center;
  }
  .profile-password-row {
    flex-wrap: wrap;
    gap: 6px;
  }
  .profile-password-row .profile-input {
    width: 100%;
  }
  .profile-password-row .btn {
    width: 100%;
  }
  .profile-access-header {
    flex-direction: column;
    gap: 4px;
  }
}

/* --- Empty State Editorial --- */
.empty-state-editorial {
  text-align: center;
  padding: 60px 20px;
  border: 0.5px dashed rgba(255,255,255,0.1);
  border-radius: 12px;
  background: rgba(255,255,255,0.03);
}
.empty-state-editorial .empty-state-icon {
  color: rgba(255,255,255,0.08);
  margin-bottom: 16px;
}
.empty-state-editorial .empty-state-title {
  font-family: Oswald, sans-serif;
  font-size: 20px;
  font-weight: 500;
  color: #fff;
  margin: 0 0 8px;
}
.empty-state-editorial .empty-state-description {
  font-size: 13px;
  color: rgba(255,255,255,0.3);
  margin: 0 0 20px;
}
