/* ============================================================
   InfoturSFX — membro.css
   ============================================================ */

:root {
  --verde:   #1e3a2f;
  --verde2:  #2e5e44;
  --terra:   #c4714a;
  --areia:   #f0e8d8;
  --creme:   #faf6ef;
  --dourado: #c8a84b;
  --pedra:   #7a7060;
  --msidebar: 230px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: 'Raleway', sans-serif; background: #f4f2ed; color: #1e2a22; }
a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }

/* ── AUTH PAGES ── */
.mauth-body { background: var(--verde); min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px; }
.mauth-wrap { background: white; border-radius: 8px; padding: 44px 40px; width: 100%; max-width: 440px; }
.mauth-wide  { max-width: 680px; }
.mauth-logo  { font-family: 'Cormorant Garamond', serif; font-size: 1.6rem; font-weight: 600; color: var(--verde); display: block; margin-bottom: 20px; }
.mauth-wrap h2 { font-family: 'Cormorant Garamond', serif; font-size: 1.8rem; font-weight: 300; color: var(--verde); }
.mauth-sub   { font-size: .82rem; color: var(--pedra); margin-top: 6px; margin-bottom: 24px; line-height: 1.6; }
.mauth-form .form-group { margin-bottom: 14px; }
.mauth-form label { display: block; font-size: .7rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--pedra); margin-bottom: 5px; }
.mauth-form input { width: 100%; border: 1px solid #ddd; border-radius: 3px; padding: 10px 14px; font-family: 'Raleway', sans-serif; font-size: .9rem; outline: none; transition: border-color .2s; }
.mauth-form input:focus { border-color: var(--verde2); }
.mform-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.mauth-info { background: #e8f5e9; border-left: 4px solid #4caf50; padding: 10px 14px; font-size: .8rem; color: #1b5e20; border-radius: 0 3px 3px 0; margin: 14px 0; }
.mauth-link { text-align: center; margin-top: 16px; font-size: .8rem; color: var(--pedra); }
.mauth-link a { color: var(--verde2); font-weight: 600; }

/* ── BUTTONS ── */
.mbtn-full    { width: 100%; background: var(--verde); color: var(--areia); border: none; padding: 12px; font-family: 'Raleway', sans-serif; font-size: .78rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; border-radius: 3px; cursor: pointer; margin-top: 8px; transition: background .2s; }
.mbtn-full:hover { background: var(--verde2); }
.mbtn-primary { background: var(--verde); color: var(--areia); border: none; padding: 9px 22px; font-family: 'Raleway', sans-serif; font-size: .72rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; border-radius: 3px; cursor: pointer; transition: background .2s; display: inline-block; }
.mbtn-primary:hover { background: var(--verde2); }
.mbtn-secondary { background: white; color: var(--pedra); border: 1px solid #ddd; padding: 9px 22px; font-family: 'Raleway', sans-serif; font-size: .72rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; border-radius: 3px; cursor: pointer; display: inline-block; transition: background .2s; }
.mbtn-secondary:hover { background: #f5f2ec; }
.mbtn-xs { font-size: .65rem; padding: 4px 10px; border: 1px solid #ddd; border-radius: 2px; background: white; cursor: pointer; display: inline-block; transition: background .15s; }
.mbtn-xs:hover { background: var(--verde); color: white; border-color: var(--verde); }
.mbtn-xs.danger { border-color: #e57373; color: #c62828; }
.mbtn-xs.danger:hover { background: #c62828; color: white; }

/* ── LAYOUT ── */
.membro-body { display: flex; min-height: 100vh; }

/* SIDEBAR */
.msidebar { width: var(--msidebar); background: var(--verde); min-height: 100vh; position: fixed; top: 0; left: 0; overflow-y: auto; display: flex; flex-direction: column; z-index: 50; }
.msidebar-logo { font-family: 'Cormorant Garamond', serif; font-size: 1.2rem; font-weight: 600; color: var(--areia); padding: 20px; display: block; border-bottom: 1px solid rgba(255,255,255,.08); }
.msidebar-user { display: flex; align-items: center; gap: 12px; padding: 16px 20px; border-bottom: 1px solid rgba(255,255,255,.08); }
.muser-foto { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; }
.muser-avatar { width: 40px; height: 40px; border-radius: 50%; background: var(--terra); display: flex; align-items: center; justify-content: center; font-size: 1.1rem; font-weight: 700; color: white; flex-shrink: 0; }
.muser-nome { font-size: .82rem; font-weight: 600; color: var(--areia); }
.muser-plano { font-size: .58rem; letter-spacing: .14em; text-transform: uppercase; padding: 2px 8px; border-radius: 20px; font-weight: 700; display: inline-block; margin-top: 3px; }
.plano-basico   { background: rgba(255,255,255,.1); color: rgba(240,232,216,.7); }
.plano-destaque { background: rgba(196,113,74,.3); color: #ffb68a; }
.plano-premium  { background: rgba(200,168,75,.3); color: var(--dourado); }
.msidebar-nav { display: flex; flex-direction: column; padding: 12px 0; flex: 1; }
.msidebar-nav a { font-size: .72rem; color: rgba(240,232,216,.65); padding: 10px 20px; transition: background .15s, color .15s; }
.msidebar-nav a:hover { background: rgba(255,255,255,.07); color: var(--areia); }
.msidebar-nav a.active { background: rgba(255,255,255,.1); color: var(--dourado); font-weight: 600; }
.msidebar-nav a.mlogout { color: rgba(196,113,74,.8); }
.nav-sep { height: 1px; background: rgba(255,255,255,.08); margin: 8px 20px; }

/* MAIN */
.membro-main { margin-left: var(--msidebar); flex: 1; display: flex; flex-direction: column; }
.membro-topbar { background: white; border-bottom: 1px solid #e8e4dc; padding: 0 28px; height: 58px; display: flex; align-items: center; position: sticky; top: 0; z-index: 40; }
.membro-topbar h1 { font-family: 'Cormorant Garamond', serif; font-size: 1.4rem; font-weight: 400; color: var(--verde); }
.membro-content { padding: 28px; flex: 1; }

/* ALERTS */
.alert { padding: 11px 18px; border-radius: 3px; font-size: .82rem; margin-bottom: 18px; border-left: 4px solid; }
.alert.mx { margin: 0 28px 0; }
.alert-success { background: #edf7ed; border-color: #4caf50; color: #1b5e20; }
.alert-warning  { background: #fff8e1; border-color: #ff9800; color: #e65100; }
.alert-danger   { background: #fce4ec; border-color: #e91e63; color: #880e4f; }

/* DASHBOARD */
.mdash-welcome { font-size: 1rem; color: var(--pedra); margin-bottom: 20px; }
.mdash-cards { display: grid; grid-template-columns: repeat(4,1fr); gap: 14px; margin-bottom: 24px; }
.mdash-card { background: white; border-radius: 4px; padding: 20px 16px; text-align: center; border: 1px solid #ede9e0; }
.mdash-card.green  { border-left: 4px solid #4caf50; }
.mdash-card.warn   { border-left: 4px solid #ff9800; }
.mdash-card.danger { border-left: 4px solid #e91e63; }
.mdash-icon { font-size: 1.5rem; display: block; margin-bottom: 8px; }
.mdash-num  { font-family: 'Cormorant Garamond', serif; font-size: 2rem; font-weight: 300; color: var(--verde); line-height: 1; }
.mdash-label { font-size: .62rem; color: var(--pedra); margin-top: 5px; letter-spacing: .06em; }
.mdash-empty { background: white; border-radius: 4px; border: 1px dashed #ddd; padding: 48px 24px; text-align: center; }
.mdash-empty h3 { font-family: 'Cormorant Garamond', serif; font-size: 1.4rem; color: var(--verde); margin-bottom: 8px; }
.mdash-empty p  { font-size: .85rem; color: var(--pedra); margin-bottom: 20px; }
.mdash-recentes { background: white; border-radius: 4px; border: 1px solid #ede9e0; margin-bottom: 20px; }
.mdash-sec-header { display: flex; justify-content: space-between; align-items: center; padding: 16px 20px; border-bottom: 1px solid #ede9e0; }
.mdash-sec-header h3 { font-family: 'Cormorant Garamond', serif; font-size: 1.1rem; font-weight: 400; color: var(--verde); }
.mdash-sec-header a { font-size: .7rem; color: var(--verde2); font-weight: 600; }
.mdash-planos { background: white; border-radius: 4px; border: 1px solid #ede9e0; padding: 20px; }
.mdash-planos h3 { font-family: 'Cormorant Garamond', serif; font-size: 1.1rem; font-weight: 400; color: var(--verde); margin-bottom: 8px; }
.mdash-planos p { font-size: .82rem; color: var(--pedra); margin-bottom: 14px; }

/* TABLES */
.mtable-wrap { overflow-x: auto; }
.mtable { width: 100%; border-collapse: collapse; font-size: .82rem; }
.mtable th { background: #f9f7f2; text-align: left; padding: 10px 16px; font-size: .62rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--pedra); border-bottom: 1px solid #ede9e0; }
.mtable td { padding: 12px 16px; border-bottom: 1px solid #f0ece3; vertical-align: middle; }
.mtable tr:last-child td { border-bottom: none; }
.mtable tr:hover td { background: #faf8f4; }
.td-actions { display: flex; gap: 6px; }

/* FORMS */
.mform-info { background: #e8f5e9; border-left: 4px solid #4caf50; padding: 12px 16px; font-size: .82rem; color: #1b5e20; border-radius: 0 3px 3px 0; margin-bottom: 20px; }
.mform-card { background: white; border-radius: 4px; border: 1px solid #ede9e0; padding: 28px; }
.adm-form .form-row { display: grid; grid-template-columns: repeat(auto-fit,minmax(180px,1fr)); gap: 14px; margin-bottom: 0; }
.adm-form .form-group { display: flex; flex-direction: column; gap: 4px; margin-bottom: 14px; }
.adm-form .form-group.flex2 { grid-column: span 2; }
.adm-form label { font-size: .7rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--pedra); }
.adm-form label small { font-weight: 400; text-transform: none; letter-spacing: 0; }
.adm-form input,.adm-form select,.adm-form textarea { border: 1px solid #ddd; border-radius: 3px; padding: 9px 12px; font-family: 'Raleway',sans-serif; font-size: .88rem; outline: none; transition: border-color .2s; width: 100%; }
.adm-form input:focus,.adm-form select:focus,.adm-form textarea:focus { border-color: var(--verde2); }
.adm-form textarea { resize: vertical; min-height: 90px; }
.form-actions { display: flex; gap: 12px; margin-top: 8px; }
.thumb-preview { max-height: 100px; max-width: 200px; border-radius: 3px; margin-bottom: 8px; object-fit: cover; }

/* PROFILE */
.mfoto-wrap { display: flex; align-items: center; gap: 20px; margin-bottom: 24px; padding-bottom: 20px; border-bottom: 1px solid #ede9e0; }
.mfoto-atual { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; }
.mfoto-placeholder { width: 72px; height: 72px; border-radius: 50%; background: var(--verde); display: flex; align-items: center; justify-content: center; font-size: 1.8rem; font-weight: 700; color: white; flex-shrink: 0; }

/* BADGES */
.badge { font-size: .6rem; padding: 3px 9px; border-radius: 20px; font-weight: 600; display: inline-block; }
.badge-on      { background: #e8f5e9; color: #2e7d32; }
.badge-off     { background: #f5f5f5; color: #666; }
.badge-warn    { background: #fff3e0; color: #e65100; }
.badge-danger  { background: #fce4ec; color: #c62828; }
.badge-plano-basico   { background: #f5f5f5; color: #555; }
.badge-plano-destaque { background: #fff3e0; color: #e65100; }
.badge-plano-premium  { background: #fffde7; color: #f57f17; }

/* ADMIN TABS */
.adm-tabs { display: flex; gap: 4px; margin-bottom: 20px; border-bottom: 2px solid #ede9e0; }
.adm-tab { padding: 10px 20px; font-size: .78rem; font-weight: 600; letter-spacing: .06em; color: var(--pedra); border-bottom: 2px solid transparent; margin-bottom: -2px; transition: color .2s, border-color .2s; display: flex; align-items: center; gap: 6px; }
.adm-tab:hover { color: var(--verde); }
.adm-tab.active { color: var(--verde); border-color: var(--verde); }
.badge-count { background: var(--terra); color: white; font-size: .6rem; padding: 1px 7px; border-radius: 20px; font-weight: 700; }
.row-pendente td { background: #fffde7 !important; }
.adm-toolbar { display: flex; justify-content: flex-end; margin-bottom: 16px; }

@media (max-width: 768px) {
  .msidebar { transform: translateX(-100%); transition: transform .3s; }
  .membro-main { margin-left: 0; }
  .mdash-cards { grid-template-columns: 1fr 1fr; }
  .mform-row { grid-template-columns: 1fr; }
  .adm-form .form-group.flex2 { grid-column: span 1; }
}

/* ── TOPBAR EXTRAS ── */
.msidebar-toggle { display: none; background: none; border: none; font-size: 1.3rem; color: var(--verde); cursor: pointer; margin-right: 12px; }
.mtopbar-stats { font-size: .7rem; color: var(--pedra); margin-left: auto; }
.mside-badge { background: var(--terra); color: white; font-size: .55rem; padding: 1px 6px; border-radius: 20px; font-weight: 700; margin-left: 4px; }
@media (max-width: 768px) {
  .msidebar-toggle { display: block; }
  .msidebar { transform: translateX(-100%); }
  .msidebar.open { transform: translateX(0); }
}
