/* ================================================
   SportFlow - style.css
   ================================================ */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  /* ---- LIGHT (padrão) ---- */
  --bg:           #FCFAF7;
  --bg-elev:      #F5EEE7;
  --surface:      #FEFCFA;
  --border-c:     #E9E1D8;
  --text:         #211D1B;
  --text-muted:   #7D746C;

  --accent:       #E15D5D;
  --accent-dark:  #C44646;
  --accent-rgb:   225, 93, 93;

  --danger:       #C9701E;
  --danger-rgb:   201, 112, 30;

  --success:      #3D8A68;
  --success-rgb:  61, 138, 104;

  --amarelo:      #8C6318;
  --amarelo-rgb:  140, 99, 24;

  /* ---- aliases de compatibilidade (usados em app.js / pagamentos.js) ---- */
  --preto:        var(--bg);
  --cinza-escuro: var(--bg-elev);
  --cinza-card:   var(--surface);
  --cinza-borda:  var(--border-c);
  --cinza-texto:  var(--text-muted);
  --branco:       var(--text);
  --verde:        var(--accent);
  --verde-escuro: var(--accent-dark);
  --vermelho:     var(--danger);
}

[data-theme="dark"] {
  /* ---- DARK — paleta original do FlowTrain ---- */
  --bg:           #0A0A0A;
  --bg-elev:      #111111;
  --surface:      #1A1A1A;
  --border-c:     #2A2A2A;
  --text:         #F5F5F0;
  --text-muted:   #888888;

  --accent:       #00D084;
  --accent-dark:  #00A366;
  --accent-rgb:   0, 208, 132;

  --danger:       #FF4A4A;
  --danger-rgb:   255, 74, 74;

  --success:      #00D084;
  --success-rgb:  0, 208, 132;

  --amarelo:      #FFD600;
  --amarelo-rgb:  255, 214, 0;
}

body {
  font-family: 'DM Sans', sans-serif;
  background: var(--preto);
  color: var(--branco);
  min-height: 100vh;
  transition: background-color .2s ease, color .2s ease;
}

/* ---- AUTH ---- */
#auth-screen {
  position: fixed;
  inset: 0;
  z-index: 999;
  background: var(--preto);
  display: flex;
  justify-content: center;
  align-items: center;
  overflow-y: auto;
}

.auth-card {
  display: flex;
  width: 100%;
  max-width: 960px;
  margin: 2rem auto;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
  border: 1px solid var(--cinza-borda);
}

.auth-left {
  flex: 1;
  max-width: 480px;
  background: var(--cinza-escuro);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 3rem;
  position: relative;
  overflow: hidden;
}

.brand {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 5rem;
  letter-spacing: 4px;
  color: var(--verde);
  line-height: 1;
  margin-bottom: 0.5rem;
}

.brand-sub {
  font-size: 0.9rem;
  color: var(--cinza-texto);
  letter-spacing: 3px;
  text-transform: uppercase;
}

.auth-deco {
  position: absolute;
  font-family: 'Bebas Neue', sans-serif;
  font-size: 14rem;
  color: rgba(var(--accent-rgb),0.05);
  bottom: -2rem;
  right: -1rem;
  pointer-events: none;
  line-height: 1;
}

.auth-right {
  width: 480px;
  flex-shrink: 0;
  background: var(--preto);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 3rem;
  border-left: 1px solid var(--cinza-borda);
}

@media (min-width: 769px) {
  .auth-right { width: 480px; max-width: 50%; }
}

.tab-row {
  display: flex;
  border: 1px solid var(--cinza-borda);
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 2rem;
}

.tab-btn {
  flex: 1;
  padding: 0.75rem;
  background: transparent;
  border: none;
  color: var(--cinza-texto);
  font-family: 'DM Sans', sans-serif;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}
.tab-btn.active { background: var(--verde); color: var(--preto); font-weight: 700; }

.form-title    { font-family: 'Bebas Neue', sans-serif; font-size: 2.2rem; letter-spacing: 2px; margin-bottom: 0.3rem; }
.form-subtitle { font-size: 0.85rem; color: var(--cinza-texto); margin-bottom: 1.5rem; }

.field-group { margin-bottom: 1rem; }
.field-group label {
  display: block;
  font-size: 0.75rem;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--cinza-texto);
  margin-bottom: 0.4rem;
}
.field-group input {
  width: 100%;
  background: var(--cinza-card);
  border: 1px solid var(--cinza-borda);
  border-radius: 8px;
  padding: 0.8rem 1rem;
  color: var(--branco);
  font-family: 'DM Sans', sans-serif;
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.2s;
}
.field-group input:focus { border-color: var(--verde); }

.role-selector { display: flex; gap: 0.75rem; margin-bottom: 1.25rem; }
.role-card {
  flex: 1;
  border: 1px solid var(--cinza-borda);
  border-radius: 10px;
  padding: 1rem;
  cursor: pointer;
  text-align: center;
  transition: all 0.2s;
}
.role-card:hover      { border-color: var(--verde); }
.role-card.selected   { border-color: var(--verde); background: rgba(var(--accent-rgb),0.08); }
.role-icon  { font-size: 1.8rem; margin-bottom: 0.4rem; }
.role-label { font-size: 0.8rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; }
.role-desc  { font-size: 0.72rem; color: var(--cinza-texto); margin-top: 0.2rem; }

.btn-primary {
  width: 100%;
  padding: 0.9rem;
  background: var(--verde);
  border: none;
  border-radius: 8px;
  color: var(--preto);
  font-family: 'DM Sans', sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all 0.2s;
  margin-top: 0.25rem;
}
.btn-primary:hover    { background: var(--verde-escuro); transform: translateY(-1px); }
.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

.msg-erro {
  background: rgba(var(--danger-rgb),0.1);
  border: 1px solid rgba(var(--danger-rgb),0.3);
  border-radius: 8px;
  padding: 0.7rem 1rem;
  font-size: 0.85rem;
  color: var(--danger);
  margin-bottom: 1rem;
  display: none;
}
.msg-ok {
  background: rgba(var(--success-rgb),0.1);
  border: 1px solid rgba(var(--success-rgb),0.3);
  border-radius: 8px;
  padding: 0.7rem 1rem;
  font-size: 0.85rem;
  color: var(--success);
  margin-bottom: 1rem;
  display: none;
}

/* ---- TOPBAR ---- */
.topbar {
  background: var(--cinza-escuro);
  border-bottom: 1px solid var(--cinza-borda);
  padding: 0 2rem;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 100;
}
.topbar-brand { font-family: 'Bebas Neue', sans-serif; font-size: 1.8rem; letter-spacing: 3px; color: var(--verde); }
.topbar-user  { display: flex; align-items: center; gap: 1rem; }
.user-badge   {
  display: flex; align-items: center; gap: 0.5rem;
  background: var(--cinza-card); border: 1px solid var(--cinza-borda);
  border-radius: 50px; padding: 0.4rem 1rem 0.4rem 0.4rem;
}
.user-avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--verde); color: var(--preto);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 0.9rem;
}
#topbar-nome { font-size: 0.85rem; font-weight: 600; }
#topbar-role { font-size: 0.7rem; color: var(--cinza-texto); text-transform: uppercase; letter-spacing: 1px; }
.btn-sair {
  background: transparent; border: 1px solid var(--cinza-borda);
  border-radius: 8px; padding: 0.5rem 1rem;
  color: var(--cinza-texto); font-family: 'DM Sans', sans-serif;
  font-size: 0.85rem; cursor: pointer; transition: all 0.2s;
}
.btn-sair:hover { border-color: var(--vermelho); color: var(--vermelho); }

/* ---- NAV ---- */
.nav-tabs { background: var(--cinza-escuro); border-bottom: 1px solid var(--cinza-borda); display: flex; padding: 0 2rem; }
.nav-tab {
  padding: 1rem 1.5rem; background: transparent;
  border: none; border-bottom: 2px solid transparent;
  color: var(--cinza-texto); font-family: 'DM Sans', sans-serif;
  font-size: 0.9rem; font-weight: 500; cursor: pointer; transition: all 0.2s;
  display: inline-flex; align-items: center; gap: .5rem;
}
.nav-tab svg { vertical-align: middle !important; }
.nav-tab:hover  { color: var(--branco); }
.nav-tab.active { color: var(--verde); border-bottom-color: var(--verde); }

/* ---- HAMBÚRGUER / MENU MOBILE ---- */
.topbar-left { display: flex; align-items: center; gap: .9rem; }
.btn-hamburguer {
  display: none;
  background: transparent; border: none; cursor: pointer;
  color: var(--branco); padding: .4rem; border-radius: 8px;
  align-items: center; justify-content: center;
}
.btn-hamburguer svg { width: 22px; height: 22px; }
.btn-hamburguer:hover { background: var(--cinza-card); }

.btn-tema {
  background: transparent; border: 1px solid var(--cinza-borda);
  border-radius: 50%; width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; color: var(--cinza-texto); transition: all .2s;
  flex-shrink: 0;
}
.btn-tema:hover { border-color: var(--verde); color: var(--verde); }
.btn-tema svg { width: 18px; height: 18px; }

.menu-overlay {
  display: none;
  position: fixed; inset: 0;
  background: rgba(0,0,0,.55);
  z-index: 1300;
}
.menu-overlay.aberto { display: block; }

.menu-drawer {
  position: fixed;
  top: 0; bottom: 0; left: 0;
  width: 280px; max-width: 82vw;
  background: var(--cinza-escuro);
  border-right: 1px solid var(--cinza-borda);
  z-index: 1301;
  display: flex;
  flex-direction: column;
  transform: translateX(-100%);
  transition: transform .25s ease;
}
.menu-drawer.aberto { transform: translateX(0); }
.menu-drawer-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.1rem 1.25rem;
  border-bottom: 1px solid var(--cinza-borda);
}
.menu-drawer-nav { padding: .6rem; overflow-y: auto; flex: 1; }
.menu-drawer-nav .nav-tab {
  display: flex; width: 100%; text-align: left;
  padding: .9rem 1rem; border-radius: 8px; border-bottom: none;
}
.menu-drawer-nav .nav-tab.active { background: rgba(var(--accent-rgb),.1); }

@media (max-width: 1024px) {
  .btn-hamburguer { display: flex; }
  .nav-tabs { display: none; }
}

.content { padding: 2rem; max-width: 1100px; margin: 0 auto; }
.page       { display: none; }
.page.active{ display: block; }

.section-title { font-family: 'Bebas Neue', sans-serif; font-size: 1.8rem; letter-spacing: 2px; margin-bottom: 0.25rem; }
.section-sub   { font-size: 0.85rem; color: var(--cinza-texto); margin-bottom: 1.5rem; }

/* ---- STATS ---- */
.stats-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 1rem; margin-bottom: 2rem; }
.stat-card { background: var(--cinza-card); border: 1px solid var(--cinza-borda); border-radius: 12px; padding: 1.25rem; }
.stat-label{ font-size: 0.75rem; color: var(--cinza-texto); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 0.5rem; }
.stat-value{ font-family: 'Bebas Neue', sans-serif; font-size: 2.5rem; color: var(--verde); line-height: 1; }
.stat-sub  { font-size: 0.75rem; color: var(--cinza-texto); margin-top: 0.25rem; }

/* ---- TREINOS ---- */
.pills-categoria { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1rem; }
.pill-categoria {
  background: var(--preto); border: 1px solid var(--cinza-borda); color: var(--cinza-texto);
  border-radius: 20px; padding: .5rem 1rem; font-family: 'DM Sans', sans-serif;
  font-size: .8rem; font-weight: 600; cursor: pointer; transition: all .15s; white-space: nowrap;
}
.pill-categoria:hover  { border-color: var(--verde); color: var(--branco); }
.pill-categoria.active { background: var(--verde); border-color: var(--verde); color: var(--preto); }
.pill-categoria-count  { opacity: .7; font-weight: 400; }
.cards-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px,1fr)); gap: 1rem; }
.sport-card {
  background: var(--cinza-card); border: 1px solid var(--cinza-borda);
  border-radius: 12px; padding: 1.25rem; cursor: pointer; transition: all 0.2s;
}
.sport-card:hover   { border-color: var(--verde); transform: translateY(-2px); }
.sport-card.open    { border-color: var(--verde); background: rgba(var(--accent-rgb),0.05); }
.sport-header       { display: flex; align-items: center; gap: 0.75rem; }
.sport-emoji        { font-size: 2rem; }
.sport-name         { font-weight: 700; font-size: 1rem; }
.sport-count        { font-size: 0.75rem; color: var(--cinza-texto); }
.treino-list        { display: none; }
.sport-card.open .treino-list { display: block; margin-top: 1rem; border-top: 1px solid var(--cinza-borda); padding-top: 1rem; }
.treino-item        { background: var(--preto); border: 1px solid var(--cinza-borda); border-radius: 8px; padding: 0.75rem 1rem; margin-bottom: 0.5rem; }
.treino-item-name   { font-weight: 600; font-size: 0.9rem; }
.treino-item-desc   { font-size: 0.8rem; color: var(--cinza-texto); margin-top: 0.2rem; }
.treino-item-tag    {
  display: inline-block; background: rgba(var(--accent-rgb),0.15); color: var(--verde);
  border-radius: 4px; padding: 0.15rem 0.5rem; font-size: 0.7rem; font-weight: 700; margin-top: 0.4rem;
}

/* ---- FREQUÊNCIA ---- */
.freq-box { background: var(--cinza-card); border: 1px solid var(--cinza-borda); border-radius: 12px; padding: 1.5rem; margin-bottom: 1.5rem; }
.freq-box-title { font-weight: 600; font-size: 1rem; margin-bottom: 1rem; }
.freq-row { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; margin-bottom: 1rem; }
.freq-row select,
.freq-row input[type="date"] {
  background: var(--preto); border: 1px solid var(--cinza-borda);
  border-radius: 8px; padding: 0.6rem 1rem;
  color: var(--branco); font-family: 'DM Sans', sans-serif;
  font-size: 0.9rem; outline: none; flex: 1; min-width: 150px;
}
.freq-row select option { background: var(--cinza-card); }
.btn-marcar {
  background: var(--verde); border: none; border-radius: 8px;
  padding: 0.6rem 1.5rem; color: var(--preto);
  font-family: 'DM Sans', sans-serif; font-weight: 700;
  font-size: 0.9rem; cursor: pointer; white-space: nowrap; transition: all 0.2s;
}
.btn-marcar:hover { background: var(--verde-escuro); }

/* ---- TABELA ---- */
.freq-table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 0.85rem; }
th {
  text-align: left; padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--cinza-borda);
  color: var(--cinza-texto); font-size: 0.75rem;
  letter-spacing: 1px; text-transform: uppercase; font-weight: 500;
}
td { padding: 0.75rem 1rem; border-bottom: 1px solid var(--cinza-borda); }
tr:hover td { background: rgba(255,255,255,0.02); }
.badge-presente { background: rgba(var(--success-rgb),0.15); color: var(--success); border-radius: 4px; padding: 0.2rem 0.6rem; font-size: 0.75rem; font-weight: 700; }

/* ---- SPINNER ---- */
.spinner {
  display: inline-block; width: 14px; height: 14px;
  border: 2px solid rgba(0,0,0,0.2); border-top-color: var(--preto);
  border-radius: 50%; animation: spin 0.6s linear infinite;
  vertical-align: middle; margin-right: 6px;
}
@keyframes spin { to { transform: rotate(360deg); } }

@media (max-width: 768px) {
  #auth-screen { align-items: flex-start; }
  .auth-card {
    margin: 0;
    max-width: 100%;
    border-radius: 0;
    border: none;
    box-shadow: none;
    min-height: 100vh;
  }
  .auth-left  { display: none; }
  .auth-right {
    width: 100%;
    min-height: 100vh;
    padding: 2rem 1.5rem;
    justify-content: flex-start;
    padding-top: 3rem;
    border-left: none;
  }
  .cards-grid { grid-template-columns: 1fr; }
}

/* ========== EXTRAS V2 ========== */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.85);
  z-index: 999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.modal-box {
  background: var(--cinza-card);
  border: 1px solid var(--cinza-borda);
  border-radius: 16px;
  padding: 2rem;
  width: 100%;
  max-width: 500px;
  max-height: 90vh;
  overflow-y: auto;
}
.modal-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.5rem;
  letter-spacing: 2px;
  margin-bottom: 1.5rem;
}
.textarea-field {
  width: 100%;
  background: var(--cinza-card);
  border: 1px solid var(--cinza-borda);
  border-radius: 8px;
  padding: .8rem 1rem;
  color: var(--branco);
  font-family: 'DM Sans', sans-serif;
  font-size: .9rem;
  outline: none;
  resize: vertical;
  min-height: 80px;
  transition: border-color .2s;
}
.textarea-field:focus { border-color: var(--verde); }
.select-field {
  width: 100%;
  background: var(--cinza-card);
  border: 1px solid var(--cinza-borda);
  border-radius: 8px;
  padding: .8rem 1rem;
  color: var(--branco);
  font-family: 'DM Sans', sans-serif;
  font-size: .9rem;
  outline: none;
}
.select-field option { background: var(--cinza-card); }
.btn-cancelar {
  flex: 1;
  padding: .9rem;
  background: transparent;
  border: 1px solid var(--cinza-borda);
  border-radius: 8px;
  color: var(--cinza-texto);
  font-family: 'DM Sans', sans-serif;
  cursor: pointer;
  transition: all .2s;
}
.btn-cancelar:hover { border-color: var(--vermelho); color: var(--vermelho); }
.ex-card {
  background: var(--preto);
  border: 1px solid var(--cinza-borda);
  border-radius: 8px;
  padding: .75rem 1rem;
  margin-bottom: .5rem;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: .5rem;
}
.ex-card-info { flex: 1; }
.ex-card-nome { font-weight: 600; font-size: .9rem; margin-bottom: .3rem; }
.ex-card-tags { display: flex; flex-wrap: wrap; gap: .35rem; margin-top: .35rem; }
.ex-card-obs  { font-size: .78rem; color: var(--verde); margin-top: .3rem; }
.chat-msg-minha {
  max-width: 70%; align-self: flex-end;
  background: var(--verde); color: var(--preto);
  padding: .6rem 1rem;
  border-radius: 12px 12px 2px 12px;
  font-size: .9rem; line-height: 1.4;
  word-break: break-word;
}
.chat-msg-outro {
  max-width: 70%; align-self: flex-start;
  background: var(--cinza-escuro); color: var(--branco);
  padding: .6rem 1rem;
  border-radius: 12px 12px 12px 2px;
  font-size: .9rem; line-height: 1.4;
  word-break: break-word;
}
.chat-msg-hora {
  font-size: .65rem;
  color: var(--cinza-texto);
  margin-top: .2rem;
  text-align: right;
}
.contato-item {
  padding: .75rem 1rem;
  cursor: pointer;
  border-bottom: 1px solid var(--cinza-borda);
  display: flex;
  align-items: center;
  gap: .75rem;
  transition: background .15s;
}
.contato-item:hover { background: rgba(255,255,255,.04); }
.contato-item.ativo { background: rgba(var(--accent-rgb),.08); border-left: 3px solid var(--verde); }
.contato-avatar {
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--verde); color: var(--preto);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: .9rem; flex-shrink: 0;
}
.conexao-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: .75rem 0;
  border-bottom: 1px solid var(--cinza-borda);
}
.treino-recebido {
  background: var(--cinza-card);
  border: 1px solid var(--cinza-borda);
  border-radius: 12px;
  padding: 1.25rem;
  margin-bottom: 1rem;
}
.treino-recebido-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 1rem;
}


/* ========== SUPORTE (WIDGET FLUTUANTE) ========== */
#suporte-fab {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--verde);
  border: none;
  box-shadow: 0 6px 20px rgba(var(--accent-rgb),0.35);
  cursor: pointer;
  z-index: 1200;
  display: none;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  transition: transform 0.2s, box-shadow .2s;
}
#suporte-fab svg { color: var(--preto); width: 24px; height: 24px; }
#suporte-fab:hover { transform: scale(1.08); box-shadow: 0 8px 26px rgba(var(--accent-rgb),0.45); }

#suporte-box {
  position: fixed;
  bottom: 5.5rem;
  right: 1.5rem;
  width: 340px;
  max-width: calc(100vw - 2rem);
  height: 460px;
  max-height: calc(100vh - 8rem);
  background: var(--cinza-card);
  border: 1px solid var(--cinza-borda);
  border-radius: 18px;
  box-shadow: 0 16px 48px rgba(0,0,0,0.22);
  z-index: 1200;
  display: none;
  flex-direction: column;
  overflow: hidden;
}
#suporte-box.aberto { display: flex; }

.suporte-header {
  background: var(--cinza-escuro);
  border-bottom: 1px solid var(--cinza-borda);
  padding: 1rem 1.1rem;
  display: flex;
  align-items: center;
  gap: .7rem;
}
.suporte-header-avatar {
  width: 34px; height: 34px; border-radius: 50%;
  background: var(--verde); flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
}
.suporte-header-avatar svg { width: 18px; height: 18px; color: var(--preto); }
.suporte-header-info { flex: 1; }
.suporte-header-title { font-weight: 700; font-size: .95rem; display: flex; align-items: center; gap: .4rem; }
.suporte-status-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--success); display: inline-block; }
.suporte-header-sub   { font-size: .72rem; color: var(--cinza-texto); margin-top: .1rem; }
.suporte-fechar {
  background: transparent;
  border: none;
  color: var(--cinza-texto);
  font-size: 1.1rem;
  cursor: pointer;
  line-height: 1;
  padding: .3rem;
  border-radius: 6px;
  transition: background .15s, color .15s;
}
.suporte-fechar:hover { color: var(--branco); background: rgba(var(--accent-rgb),.1); }

#suporte-msgs {
  flex: 1;
  overflow-y: auto;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: .5rem;
  background: var(--preto);
}

/* ---- BOLHAS DO BOT DE SUPORTE ---- */
.bot-msg {
  align-self: flex-start;
  max-width: 85%;
  background: var(--cinza-card);
  border: 1px solid var(--cinza-borda);
  color: var(--branco);
  padding: .65rem .9rem;
  border-radius: 4px 14px 14px 14px;
  font-size: .85rem;
  line-height: 1.45;
}
.user-msg {
  align-self: flex-end;
  max-width: 85%;
  background: var(--verde);
  color: var(--preto);
  padding: .6rem .9rem;
  border-radius: 14px 4px 14px 14px;
  font-size: .85rem;
  font-weight: 600;
  line-height: 1.4;
}
.bot-opcoes {
  align-self: flex-start;
  display: flex;
  flex-direction: column;
  gap: .4rem;
  max-width: 92%;
  margin-top: .1rem;
}
.bot-opcao-btn {
  text-align: left;
  background: var(--cinza-card);
  border: 1px solid var(--cinza-borda);
  color: var(--branco);
  padding: .6rem .85rem;
  border-radius: 10px;
  font-family: 'DM Sans', sans-serif;
  font-size: .82rem;
  cursor: pointer;
  transition: border-color .15s, background .15s, transform .1s;
}
.bot-opcao-btn:hover { border-color: var(--verde); background: rgba(var(--accent-rgb),.08); }
.bot-opcao-btn:active { transform: scale(.98); }
.bot-opcao-btn.destaque {
  background: var(--verde);
  border-color: var(--verde);
  color: var(--preto);
  font-weight: 700;
}
.bot-opcao-btn.destaque:hover { background: var(--verde-escuro); border-color: var(--verde-escuro); }

.suporte-input-row {
  padding: .75rem;
  border-top: 1px solid var(--cinza-borda);
  display: flex;
  gap: .5rem;
}
.suporte-input-row input {
  flex: 1;
  background: var(--preto);
  border: 1px solid var(--cinza-borda);
  border-radius: 8px;
  padding: .6rem .8rem;
  color: var(--branco);
  font-family: 'DM Sans', sans-serif;
  font-size: .85rem;
  outline: none;
}
.suporte-input-row .btn-marcar { padding: .6rem 1rem; }

@media (max-width: 480px) {
  #suporte-box {
    right: 1rem;
    left: 1rem;
    width: auto;
  }
  #suporte-fab { right: 1.25rem; bottom: 1.25rem; }
}
/* ================================================
   COOKIES E PRIVACIDADE - ESTILOS
   ================================================ */

#cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(135deg, var(--cinza-escuro) 0%, var(--preto) 100%);
  border-top: 2px solid var(--verde);
  padding: 1.5rem 2rem;
  display: none;
  flex-direction: column;
  gap: 1rem;
  z-index: 9999;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.4);
}

#cookie-banner.visivel {
  display: flex;
  animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
  from { transform: translateY(100%); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

.cookie-conteudo {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 2rem;
}

.cookie-texto h3 {
  margin: 0 0 0.5rem 0;
  font-size: 1.1rem;
  color: var(--branco);
  font-family: 'Bebas Neue', sans-serif;
}

.cookie-texto p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--cinza-texto);
  line-height: 1.6;
}

.cookie-texto a {
  color: var(--verde);
  font-weight: 600;
  cursor: pointer;
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s;
}

.cookie-texto a:hover {
  border-bottom-color: var(--verde);
}

.cookie-botoes {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.btn-cookie {
  padding: 0.7rem 1.5rem;
  border-radius: 8px;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.btn-cookie-aceitar {
  background: var(--verde);
  color: var(--preto);
}

.btn-cookie-aceitar:hover {
  background: var(--verde-escuro);
  transform: translateY(-2px);
}

.btn-cookie-essencial {
  background: transparent;
  color: var(--verde);
  border: 1px solid var(--verde);
}

.btn-cookie-essencial:hover {
  background: rgba(0, 208, 132, 0.1);
}

.btn-cookie-config {
  background: transparent;
  color: var(--cinza-texto);
  border: 1px solid var(--cinza-borda);
}

.btn-cookie-config:hover {
  border-color: var(--verde);
  color: var(--verde);
}

/* MODAIS */
#modal-cookies,
#modal-privacidade {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.8);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  padding: 2rem;
}

.modal-conteudo {
  background: var(--cinza-card);
  border: 1px solid var(--cinza-borda);
  border-radius: 16px;
  padding: 2rem;
  max-width: 600px;
  width: 100%;
  max-height: 80vh;
  overflow-y: auto;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
}

.modal-header h2 {
  margin: 0;
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.8rem;
  color: var(--branco);
}

.modal-fechar {
  background: transparent;
  border: none;
  color: var(--cinza-texto);
  font-size: 1.5rem;
  cursor: pointer;
}

.modal-fechar:hover {
  color: var(--branco);
}

.cookie-opcao {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem;
  background: var(--preto);
  border: 1px solid var(--cinza-borda);
  border-radius: 8px;
  margin-bottom: 1rem;
}

.cookie-opcao-info h4 {
  margin: 0 0 0.3rem 0;
  color: var(--branco);
  font-size: 0.95rem;
}

.cookie-opcao-info p {
  margin: 0;
  font-size: 0.8rem;
  color: var(--cinza-texto);
}

.switch {
  position: relative;
  width: 50px;
  height: 24px;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--cinza-borda);
  transition: 0.3s;
  border-radius: 24px;
}

.slider:before {
  position: absolute;
  content: '';
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background: white;
  transition: 0.3s;
  border-radius: 50%;
}

input:checked + .slider {
  background: var(--verde);
}

input:checked + .slider:before {
  transform: translateX(26px);
}

.privacidade-texto {
  font-size: 0.9rem;
  line-height: 1.8;
  color: var(--cinza-texto);
}

.privacidade-texto h3 {
  color: var(--branco);
  font-size: 1.1rem;
  margin-top: 0;
}

.privacidade-texto h4 {
  color: var(--verde);
  margin-top: 1rem;
  margin-bottom: 0.5rem;
}

.privacidade-texto ul {
  margin: 0.5rem 0;
  padding-left: 1.5rem;
}

.privacidade-texto li {
  margin: 0.3rem 0;
}

@media (max-width: 768px) {
  #cookie-banner {
    padding: 1rem;
  }

  .cookie-conteudo {
    flex-direction: column;
  }

  .cookie-botoes {
    flex-direction: column;
    width: 100%;
  }

  .btn-cookie {
    width: 100%;
  }

  .modal-conteudo {
    padding: 1.5rem;
  }
}
