/* =====================================================================
   PANTALLAS DE ENTRADA — licencia, login, configuración (hero + tarjeta)
   ===================================================================== */
.gc-stage, .gc-stage * { box-sizing:border-box; }
.gc-stage { position:relative; z-index:2; width:100%; height:100%; display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1fr); align-items:center; gap:56px; padding:48px clamp(24px,6vw,120px); overflow-y:auto; animation:panelEntrance .9s cubic-bezier(.16,1,.3,1) both; }
.gc-bg { position:absolute; inset:0; background:#060e1c url('../assets/img/hero-bg.svg') center bottom/cover no-repeat; }
.gc-bg::after { content:''; position:absolute; inset:0; background:linear-gradient(90deg, rgba(5,11,24,.86) 0%, rgba(5,11,24,.62) 42%, rgba(5,11,24,.2) 62%, rgba(5,11,24,.5) 100%); }

/* ---- Hero (izquierda) ---- */
.gc-hero { max-width:520px; }
.gc-wordmark { display:flex; align-items:center; gap:16px; margin-bottom:6px; }
.gc-wordmark img { width:56px; height:auto; filter:drop-shadow(0 6px 22px rgba(201,168,76,.28)); }
.gc-wordmark .gc-name { font-family:'DM Serif Display',Georgia,serif; font-size:clamp(2.6rem,4.4vw,3.6rem); line-height:1; color:#fff; letter-spacing:-.02em; font-weight:700; }
.gc-wordmark .gc-name em { color:var(--gold); font-style:italic; }
.gc-tag { font-size:.78rem; letter-spacing:.14em; text-transform:uppercase; color:rgba(255,255,255,.55); margin:0 0 40px; }
.gc-hero h2 { font-family:'DM Sans',sans-serif; font-size:clamp(1.4rem,2.2vw,1.75rem); font-weight:700; color:#fff; line-height:1.3; margin:0 0 12px; }
.gc-hero h2 span { color:var(--gold); display:block; }
.gc-hero > p { color:rgba(255,255,255,.62); font-size:.95rem; line-height:1.6; margin:0 0 30px; max-width:420px; }
.gc-feat { display:flex; gap:16px; align-items:flex-start; margin-bottom:18px; }
.gc-feat .ic { flex:0 0 50px; height:50px; border-radius:12px; background:rgba(255,255,255,.04); border:1px solid rgba(255,255,255,.08); display:flex; align-items:center; justify-content:center; color:var(--gold); font-size:1.15rem; }
.gc-feat b { display:block; color:#fff; font-size:.92rem; margin-bottom:3px; }
.gc-feat span { color:rgba(255,255,255,.55); font-size:.8rem; line-height:1.5; display:block; max-width:300px; }

/* ---- Tarjeta (derecha) ---- */
.gc-card { justify-self:center; width:100%; max-width:560px; background:linear-gradient(160deg, rgba(17,30,52,.92), rgba(9,18,34,.94)); border:1px solid rgba(201,168,76,.38); border-radius:26px; padding:36px 40px 30px; box-shadow:0 30px 80px rgba(0,0,0,.55), inset 0 1px 0 rgba(255,255,255,.04); backdrop-filter:blur(8px); }
.gc-card-logo { width:84px; height:84px; margin:0 auto 14px; border-radius:50%; background:radial-gradient(circle, rgba(201,168,76,.18), rgba(10,22,40,.9) 70%); border:1px solid rgba(201,168,76,.45); box-shadow:0 0 28px rgba(201,168,76,.22); display:flex; align-items:center; justify-content:center; }
.gc-card-logo img { width:46px; height:auto; display:block; }
.gc-card h3 { text-align:center; font-family:'DM Sans',sans-serif; font-size:1.45rem; font-weight:700; color:#fff; margin:0 0 6px; }
.gc-card .gc-sub { text-align:center; color:rgba(255,255,255,.6); font-size:.88rem; margin:0 0 22px; }
.gc-tabs { display:flex; border-bottom:1px solid rgba(255,255,255,.08); margin-bottom:22px; }
.gc-tabs div { flex:1; text-align:center; padding:11px 0; font-size:.88rem; color:rgba(255,255,255,.55); border-bottom:2px solid transparent; margin-bottom:-1px; }
.gc-tabs div.on { color:var(--gold-light); font-weight:600; border-color:var(--gold); }

.gc-field { margin-bottom:16px; }
.gc-field > label { display:block; font-size:.82rem; color:rgba(255,255,255,.8); margin-bottom:7px; font-weight:500; }
.gc-input { position:relative; }
.gc-input > i.lead { position:absolute; left:15px; top:50%; transform:translateY(-50%); color:rgba(255,255,255,.4); font-size:.9rem; pointer-events:none; }
.gc-input input, .gc-input select { width:100%; background:rgba(255,255,255,.045); border:1px solid rgba(255,255,255,.1); color:#fff; border-radius:10px; padding:14px 42px 14px 44px; font-family:'DM Sans',sans-serif; font-size:.92rem; outline:none; transition:border-color .2s, box-shadow .2s; text-transform:none; letter-spacing:normal; appearance:none; -webkit-appearance:none; }
.gc-input select { cursor:pointer; background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none' stroke='%23c9a84c' stroke-width='2'%3E%3Cpath d='M1 1l5 5 5-5'/%3E%3C/svg%3E"); background-repeat:no-repeat; background-position:right 16px center; }
.gc-input select option { background:#0d1b33; color:#fff; }
.gc-input input::placeholder { color:rgba(255,255,255,.38); }
.gc-input input:focus, .gc-input select:focus { border-color:var(--gold); box-shadow:0 0 0 3px rgba(201,168,76,.14); }
.gc-input .eye { position:absolute; right:6px; top:50%; transform:translateY(-50%); background:none; border:none; color:rgba(255,255,255,.45); cursor:pointer; padding:10px; font-size:.9rem; }
.gc-input .eye:hover { color:var(--gold-light); }
.gc-input.mono input { font-family:'DM Mono',monospace; letter-spacing:1px; text-transform:uppercase; }
.gc-row { display:flex; align-items:center; justify-content:space-between; margin:4px 0 20px; font-size:.82rem; color:rgba(255,255,255,.7); }
.gc-row label { display:flex; align-items:center; gap:9px; cursor:pointer; }
.gc-row input[type=checkbox] { width:16px; height:16px; accent-color:var(--gold); padding:0; }
.gc-btn { width:100%; border:none; cursor:pointer; padding:15px; border-radius:10px; font-family:'DM Sans',sans-serif; font-size:.98rem; font-weight:700; color:#0a1628; background:linear-gradient(135deg,#e8c96a 0%,#c9a84c 100%); display:flex; align-items:center; justify-content:center; gap:10px; transition:transform .2s, box-shadow .2s; }
.gc-btn:hover { transform:translateY(-2px); box-shadow:0 10px 30px rgba(201,168,76,.38); }
.gc-btn:disabled { opacity:.6; cursor:not-allowed; transform:none; }
.gc-btn.ghost { background:rgba(255,255,255,.05); color:#fff; border:1px solid rgba(255,255,255,.12); font-weight:600; }
.gc-btn.ghost:hover { box-shadow:none; border-color:rgba(201,168,76,.5); }
.gc-note { display:flex; align-items:center; justify-content:center; gap:8px; color:rgba(255,255,255,.5); font-size:.78rem; margin-top:16px; }
.gc-hint { font-size:.75rem; color:rgba(255,255,255,.55); line-height:1.5; margin:-4px 0 16px; }
.gc-hint strong { color:var(--gold); }
.gc-foot { text-align:center; font-size:.74rem; color:rgba(255,255,255,.4); margin-top:22px; }
.gc-foot strong { color:rgba(255,255,255,.85); font-weight:500; }
.gc-foot a { color:var(--gold); text-decoration:none; }
.gc-card .license-message { margin-top:12px; }
.gc-card .license-loading { margin-top:14px; }

/* licencia: bloque ID de dispositivo + features */
.gc-device { display:flex; align-items:center; gap:12px; background:rgba(201,168,76,.06); border:1px solid rgba(201,168,76,.2); border-radius:12px; padding:11px 14px; margin-top:18px; }
.gc-device i { color:var(--gold); }
.gc-device small { display:block; font-size:.62rem; text-transform:uppercase; letter-spacing:.08em; color:rgba(255,255,255,.5); margin-bottom:2px; }
.gc-device #license-device-id-display { font-family:'DM Mono',monospace; font-size:.72rem; color:rgba(255,255,255,.8); word-break:break-all; letter-spacing:1px; }
.gc-device button { margin-left:auto; flex-shrink:0; background:rgba(201,168,76,.12); border:1px solid rgba(201,168,76,.3); color:var(--gold-light); border-radius:8px; font-size:.72rem; padding:6px 11px; cursor:pointer; font-family:'DM Sans',sans-serif; }
.gc-chips { display:flex; flex-wrap:wrap; gap:8px; margin-top:16px; }
.gc-chips span { font-size:.72rem; color:rgba(255,255,255,.7); background:rgba(255,255,255,.05); border:1px solid rgba(255,255,255,.09); border-radius:20px; padding:6px 12px; }
.gc-chips i { color:var(--gold); margin-right:6px; }

/* ---- Pantalla de configuración (stepper) ---- */
#screen-inicio { background:#060e1c; }
#screen-inicio::before, #screen-inicio::after, #screen-inicio .inicio-orb { display:none; }
#screen-inicio { position:fixed; inset:0; z-index:15000; align-items:stretch; justify-content:stretch; overflow:hidden; }
.gc-stage.setup .gc-card { max-width:760px; padding:30px 40px 28px; }
.gc-steps { display:flex; align-items:flex-start; margin-bottom:26px; }
.gc-step { display:flex; flex-direction:column; align-items:center; gap:8px; font-size:.82rem; color:rgba(255,255,255,.5); }
.gc-step .n { width:38px; height:38px; border-radius:50%; border:1.5px solid rgba(255,255,255,.3); display:flex; align-items:center; justify-content:center; font-weight:600; color:rgba(255,255,255,.7); }
.gc-step.on { color:var(--gold-light); } .gc-step.on .n { border-color:var(--gold); color:var(--gold-light); box-shadow:0 0 14px rgba(201,168,76,.3); }
.gc-step.done .n { background:var(--gold); color:#0a1628; border-color:var(--gold); }
.gc-steps .bar { flex:1; height:2px; background:rgba(255,255,255,.14); margin:19px 14px 0; position:relative; border-radius:2px; }
.gc-steps .bar i { position:absolute; left:0; top:0; bottom:0; width:0; background:var(--gold); border-radius:2px; transition:width .4s; }
.gc-card h4 { font-family:'DM Sans',sans-serif; font-size:1.05rem; color:#fff; margin:0 0 4px; font-weight:700; }
.gc-card h4 + p { color:rgba(255,255,255,.55); font-size:.82rem; margin:0 0 14px; }
.gc-card .tipo-cards { gap:14px; margin:0 0 24px; justify-content:flex-start; flex-wrap:nowrap; }
.gc-card .tipo-card { flex:1; min-width:0; padding:18px 12px; border-radius:12px; background:rgba(255,255,255,.035); border:1px solid rgba(255,255,255,.1); }
.gc-card .tipo-card.selected { border-color:var(--gold); background:rgba(201,168,76,.07); transform:none; box-shadow:0 0 0 1px rgba(201,168,76,.25), 0 10px 28px rgba(201,168,76,.12); }
.gc-card .tipo-card:hover { transform:none; }
.gc-card .tipo-card .tc-name { font-size:.95rem; } .gc-card .tipo-card.selected .tc-name { color:var(--gold-light); }
.gc-card .tipo-card .tc-desc { font-size:.72rem; }
.gc-card .escala-cards { margin:0 0 6px; }
.gc-card .escala-card { background:rgba(255,255,255,.035); border:1px solid rgba(255,255,255,.1); border-radius:12px; }
.gc-card .escala-card.selected { border-color:var(--gold); background:rgba(201,168,76,.07); }
.gc-two { display:grid; grid-template-columns:1fr 1fr; gap:14px; }
.gc-pane { display:none; } .gc-pane.on { display:block; animation:fadeUp .5s cubic-bezier(.22,1,.36,1) both; }
.gc-btns { display:flex; gap:12px; margin-top:6px; } .gc-btns .gc-btn.ghost { width:auto; padding:15px 24px; }

/* ---- Sidebar con el escudo (sin que el botón se monte sobre el logo) ---- */
.sb-logo { padding:16px 48px 14px 14px; min-height:72px; gap:12px; }
.sb-logo-mark.has-img { background:transparent !important; box-shadow:none !important; border-radius:0; padding:0; width:36px; height:42px; flex-shrink:0; display:flex; align-items:center; justify-content:center; transition:transform .2s; }
.sb-logo-mark.has-img:hover { transform:scale(1.06); }
.sb-logo-mark.has-img img { width:100%; height:100%; object-fit:contain; display:block; }
.sb-app-name em { color:var(--gold-light); font-style:italic; }
.sb-logo-text { min-width:0; flex:1; }
#sb-negocio-nombre { max-width:100%; }
/* colapsado: solo el escudo, centrado; el botón se oculta (el escudo expande el menú al hacer clic) */
.sidebar.collapsed .sb-logo { padding:16px 0 14px; justify-content:center; gap:0; }
.sidebar.collapsed .sb-toggle { display:none; }
.sidebar.collapsed .sb-logo-text { flex:0 0 0; }

@media (max-width:960px) {
  .gc-stage { grid-template-columns:1fr; gap:28px; padding:28px 18px; align-content:start; }
  .gc-hero { max-width:none; text-align:center; } .gc-wordmark { justify-content:center; }
  .gc-tag { margin-bottom:0; } .gc-hero h2, .gc-hero > p, .gc-feat { display:none; }
  .gc-card, .gc-stage.setup .gc-card { padding:26px 22px; }
}
@media (max-width:560px) { .gc-two { grid-template-columns:1fr; } .gc-card .tipo-cards { flex-direction:column; } .gc-card .tipo-card { width:100%; max-width:none; } }

/* en móvil el menú siempre va expandido: el botón vuelve a mostrarse */
@media (max-width:900px) {
  .sidebar.collapsed .sb-toggle { display:flex; right:10px; transform:translateY(-50%); }
  .sidebar.collapsed .sb-logo { padding:16px 48px 14px 14px; justify-content:flex-start; gap:12px; }
  .sidebar.collapsed .sb-logo-text { flex:1; }
}

/* ---- Roles: lo que el vendedor no debe ver ni tocar ---- */
body.sin-totales .req-totales { display:none !important; }
body.sin-borrar .txn-del { display:none !important; }

/* Panel de usuarios: casillas de permisos */
.usr-grupo { grid-column:1/-1; font-size:.68rem; font-weight:700; letter-spacing:.07em; text-transform:uppercase; color:var(--text-muted); margin-top:6px; }
#usr-secciones { display:grid; grid-template-columns:repeat(auto-fill,minmax(210px,1fr)); gap:6px 14px; }
.usr-check { display:flex; align-items:center; gap:8px; font-size:.85rem; cursor:pointer; padding:5px 0; }
.usr-check input { accent-color:var(--gold); width:16px; height:16px; cursor:pointer; }
.usr-plantillas { display:flex; gap:8px; flex-wrap:wrap; margin-bottom:12px; }
