/* SuperTicket – Sistema de Reembolsos */
:root {
  --st-primary:       #003087;
  --st-primary-dark:  #001F5A;
  --st-primary-hover: #0044BB;
  --st-accent:        #FF6600;
  --st-accent-hover:  #E55A00;
  --st-bg:            #F4F6FB;
  --st-white:         #FFFFFF;
  --st-text:          #1A1A2E;
  --st-muted:         #6B7280;
  --st-border:        #E5E7EB;
  --st-shadow:        0 4px 20px rgba(0,48,135,.10);
  --st-shadow-sm:     0 2px 8px  rgba(0,48,135,.07);
  --st-radius:        12px;
  --st-radius-sm:     8px;
  --header-h:         68px;
  --sidebar-w:        255px;
}

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

body {
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  background: var(--st-bg);
  color: var(--st-text);
  margin: 0;
}

/* ── HEADER (public) ───────────────────────────────── */
.st-header {
  background: var(--st-primary);
  height: var(--header-h);
  display: flex;
  align-items: center;
  padding: 0 2rem;
  box-shadow: 0 2px 8px rgba(0,0,0,.25);
}
.st-header .logo-area {
  display: flex; align-items: center; gap: 12px; text-decoration: none;
}
.st-header .logo-img  { height: 40px; object-fit: contain; }
.st-header .logo-text {
  color: #fff; font-size: 1.05rem; font-weight: 700; letter-spacing: .4px;
}
.st-header .logo-text span { color: #FFB347; font-weight: 400; }

/* ── FOOTER ────────────────────────────────────────── */
.st-footer {
  background: var(--st-primary-dark);
  color: rgba(255,255,255,.55);
  text-align: center;
  padding: .9rem 1rem;
  font-size: .8rem;
}

/* ── PUBLIC MAIN ───────────────────────────────────── */
.st-public-main {
  min-height: calc(100vh - var(--header-h) - 52px);
  padding: 3rem 1rem;
}

/* ── LANDING ───────────────────────────────────────── */
.landing-hero { text-align: center; margin-bottom: 2rem; }
.landing-hero h1 {
  color: var(--st-primary); font-size: 1.75rem; font-weight: 700; margin-bottom: .4rem;
}
.landing-hero p { color: var(--st-muted); font-size: .95rem; margin: 0; }


.choice-card {
  background: var(--st-white);
  border-radius: var(--st-radius);
  box-shadow: var(--st-shadow);
  padding: 2rem 1.25rem;
  text-align: center;
  text-decoration: none;
  color: var(--st-text);
  display: block;
  transition: transform .2s, box-shadow .2s, border-color .2s;
  border: 2px solid transparent;
}
.choice-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 36px rgba(0,48,135,.18);
  border-color: var(--st-primary);
  color: var(--st-text);
}
.choice-card .icon-wrap {
  width: 64px; height: 64px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto .85rem; font-size: 1.75rem;
}
.choice-card.solicitar   .icon-wrap { background: rgba(0,48,135,.10); color: var(--st-primary); }
.choice-card.seguimiento .icon-wrap { background: rgba(255,102,0,.10); color: var(--st-accent); }
.choice-card h2 { font-size: 1.05rem; font-weight: 700; margin-bottom: .35rem; }
.choice-card p  { font-size: .85rem; color: var(--st-muted); margin: 0; }

/* ── SECTION CARDS (forms) ─────────────────────────── */
.section-card {
  background: var(--st-white);
  border-radius: var(--st-radius);
  box-shadow: var(--st-shadow-sm);
  margin-bottom: 1.5rem;
  overflow: hidden;
}
.section-card-header {
  background: var(--st-primary);
  color: #fff;
  padding: .85rem 1.5rem;
  font-weight: 600;
  font-size: .92rem;
  display: flex; align-items: center; gap: 8px;
}
.section-card-body { padding: 1.5rem; }

.page-title    { color: var(--st-primary); font-weight: 700; font-size: 1.35rem; margin-bottom: .25rem; }
.page-subtitle { color: var(--st-muted); font-size: .88rem; margin-bottom: 1.5rem; }

/* ── FORM CONTROLS ─────────────────────────────────── */
.form-label { font-weight: 500; font-size: .88rem; margin-bottom: .3rem; }
.form-control, .form-select {
  border-radius: var(--st-radius-sm);
  border-color: var(--st-border);
  font-size: .9rem;
  transition: border-color .15s, box-shadow .15s;
}
.form-control:focus, .form-select:focus {
  border-color: var(--st-primary);
  box-shadow: 0 0 0 3px rgba(0,48,135,.12);
}

/* ── BUTTONS ───────────────────────────────────────── */
.btn-st-primary {
  background: var(--st-primary); border: none; color: #fff;
  padding: .65rem 2rem; border-radius: var(--st-radius-sm);
  font-weight: 600; font-size: .92rem;
  transition: background .15s, transform .1s;
  cursor: pointer; display: inline-block; text-decoration: none;
}
.btn-st-primary:hover { background: var(--st-primary-hover); color: #fff; transform: translateY(-1px); }


.btn-st-outline {
  background: transparent; border: 2px solid var(--st-primary); color: var(--st-primary);
  padding: .6rem 1.5rem; border-radius: var(--st-radius-sm);
  font-weight: 600; font-size: .9rem; cursor: pointer;
  display: inline-block; text-decoration: none;
  transition: background .15s, color .15s;
}
.btn-st-outline:hover { background: var(--st-primary); color: #fff; }

/* ── SUCCESS BOX ───────────────────────────────────── */
.success-box {
  background: var(--st-white);
  border-radius: var(--st-radius);
  box-shadow: var(--st-shadow);
  padding: 2.5rem;
  text-align: center;
}
.success-icon {
  width: 80px; height: 80px;
  background: rgba(16,185,129,.12); color: #10B981;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 2.5rem; margin: 0 auto 1rem;
}
.tracking-number-display {
  background: var(--st-bg);
  border: 2px dashed var(--st-primary);
  border-radius: var(--st-radius-sm);
  padding: .9rem 2rem;
  display: inline-block;
  font-size: 1.6rem; font-weight: 700;
  color: var(--st-primary); letter-spacing: 3px;
  margin: 1rem 0;
}

/* ── TRACKING TIMELINE ─────────────────────────────── */
.tracking-box {
  background: var(--st-white);
  border-radius: var(--st-radius);
  box-shadow: var(--st-shadow);
  padding: 2rem;
}
.tracking-info {
  border-left: 4px solid var(--st-primary);
  padding-left: 1rem;
  margin-bottom: 2.5rem;
}
.tracking-info .tracking-num {
  font-size: 1.25rem; font-weight: 700; color: var(--st-primary);
}
.tracking-info .tracking-meta { font-size: .85rem; color: var(--st-muted); margin-top: .2rem; }


/* ── ADMIN LAYOUT ──────────────────────────────────── */
.admin-wrapper { display: flex; min-height: 100vh; }

.admin-sidebar {
  width: var(--sidebar-w);
  background: var(--st-primary-dark);
  display: flex; flex-direction: column;
  position: fixed; top: 0; left: 0; height: 100vh;
  overflow-y: auto; z-index: 100;
}
.sidebar-logo {
  padding: 1.1rem 1.5rem;
  border-bottom: 1px solid rgba(255,255,255,.1);
  display: flex; align-items: center; gap: 10px;
}
.sidebar-logo img { height: 34px; object-fit: contain; }
.sidebar-logo-text { color: #fff; font-size: .9rem; font-weight: 700; line-height: 1.25; }
.sidebar-logo-text small { display: block; color: rgba(255,255,255,.45); font-size: .7rem; font-weight: 400; }

.sidebar-nav { padding: .75rem 0; flex: 1; }
.sidebar-nav a {
  display: flex; align-items: center; gap: 10px;
  padding: .7rem 1.5rem;
  color: rgba(255,255,255,.65);
  text-decoration: none; font-size: .88rem;
  border-left: 3px solid transparent;
  transition: background .15s, color .15s;
}
.sidebar-nav a:hover { background: rgba(255,255,255,.08); color: #fff; }
.sidebar-nav a.active {
  background: rgba(255,255,255,.12); color: #fff;
  border-left-color: var(--st-accent); font-weight: 600;
}
.sidebar-nav a i { font-size: .95rem; width: 18px; text-align: center; }
.sidebar-nav .nav-sep {
  height: 1px; background: rgba(255,255,255,.1); margin: .4rem 1rem;
}
.sidebar-nav .nav-section-label {
  padding: .55rem 1.5rem .2rem;
  font-size: .68rem; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; color: rgba(255,255,255,.35);
}
.sidebar-footer {
  padding: 1rem 1.5rem;
  border-top: 1px solid rgba(255,255,255,.1);
}
.sidebar-footer .admin-nm { color: rgba(255,255,255,.75); font-size: .82rem; margin-bottom: .4rem; }
.sidebar-footer a { color: rgba(255,255,255,.45); font-size: .78rem; text-decoration: none; }
.sidebar-footer a:hover { color: #fff; }

.admin-main { margin-left: var(--sidebar-w); flex: 1; min-width: 0; display: flex; flex-direction: column; }

.admin-topbar {
  background: #fff;
  padding: .9rem 2rem;
  display: flex; align-items: center; justify-content: space-between;
  box-shadow: var(--st-shadow-sm);
  position: sticky; top: 0; z-index: 50;
}
.admin-topbar .page-nm { font-weight: 600; font-size: 1.05rem; }

.admin-content { padding: 2rem; flex: 1; }

/* ── STAT CARDS ────────────────────────────────────── */
.stat-card {
  background: var(--st-white);
  border-radius: var(--st-radius);
  box-shadow: var(--st-shadow-sm);
  padding: 1.4rem 1.5rem;
  display: flex; align-items: center; gap: 1rem;
}
.stat-icon {
  width: 54px; height: 54px; border-radius: var(--st-radius-sm);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem; flex-shrink: 0;
}
.stat-value { font-size: 1.75rem; font-weight: 700; line-height: 1; margin-bottom: .15rem; }
.stat-label { font-size: .78rem; color: var(--st-muted); }

/* ── ADMIN TABLE CARD ──────────────────────────────── */
.admin-table-card {
  background: var(--st-white);
  border-radius: var(--st-radius);
  box-shadow: var(--st-shadow-sm);
  overflow: hidden;
}
.table-card-header {
  padding: 1.1rem 1.5rem;
  border-bottom: 1px solid var(--st-border);
  display: flex; align-items: center; justify-content: space-between;
}
.table-card-header h5 { font-weight: 600; font-size: .92rem; margin: 0; }

.table > thead > tr > th {
  font-size: .76rem; text-transform: uppercase; letter-spacing: .5px;
  color: var(--st-muted); font-weight: 600;
  background: var(--st-bg);
  border-bottom: 2px solid var(--st-border);
  padding: .7rem 1rem; white-space: nowrap;
}
.table > tbody > tr > td {
  padding: .75rem 1rem; font-size: .87rem;
  vertical-align: middle; border-bottom: 1px solid var(--st-bg);
}
.table > tbody > tr:hover > td { background: rgba(0,48,135,.02); }

/* ── BADGES ────────────────────────────────────────── */
.badge.bg-primary { background: var(--st-primary) !important; }
.badge.bg-warning { background: #F59E0B !important; color: #fff !important; }
.badge.bg-info    { background: #0EA5E9 !important; }
.badge.bg-success { background: #10B981 !important; }

/* ── ALERTS ────────────────────────────────────────── */
.st-alert {
  border-radius: var(--st-radius-sm);
  padding: .9rem 1.2rem;
  margin-bottom: 1rem;
  font-size: .88rem;
  display: flex; align-items: flex-start; gap: .5rem;
}

/* ── MISC ──────────────────────────────────────────── */
.back-link {
  color: var(--st-primary); text-decoration: none; font-size: .88rem;
  display: inline-flex; align-items: center; gap: 4px; margin-bottom: 1rem;
}
.back-link:hover { text-decoration: underline; }

.filter-card {
  background: var(--st-white);
  border-radius: var(--st-radius);
  box-shadow: var(--st-shadow-sm);
  padding: 1.25rem 1.5rem;
  margin-bottom: 1.5rem;
}

/* ── VERIFICATION BOX ─────────────────────────────── */
.verif-box {
  border-radius: var(--st-radius-sm);
  padding: .8rem 1rem; font-size: .88rem;
  display: flex; align-items: flex-start; gap: .6rem;
}
.verif-box.found    { background: #ECFDF5; border: 1px solid #A7F3D0; color: #065F46; }
.verif-box.notfound { background: #FEF3C7; border: 1px solid #FDE68A; color: #92400E; }
.verif-box.checking { background: var(--st-bg); border: 1px solid var(--st-border); color: var(--st-muted); }

/* ── TICKET LIST (verification result) ────────────── */
.ticket-list { margin-top: .65rem; border-top: 1px solid rgba(6,95,70,.18); padding-top: .35rem; }
.ticket-row {
  display: flex; justify-content: space-between; align-items: baseline;
  padding: .32rem 0; font-size: .82rem; gap: .75rem;
  border-bottom: 1px solid rgba(6,95,70,.1);
}
.ticket-row span:first-child { flex: 1; }
.ticket-row span:last-child { flex-shrink: 0; font-variant-numeric: tabular-nums; }
.ticket-row.total {
  border-bottom: none; border-top: 2px solid rgba(6,95,70,.2);
  font-weight: 700; font-size: .88rem; padding-top: .5rem; margin-top: .2rem;
}

/* ── WIZARD STEPS ──────────────────────────────────── */
.wizard-steps {
  display: flex; align-items: flex-start;
  margin-bottom: 2rem; padding: 0 .25rem;
}
.wz-step { display: flex; flex-direction: column; align-items: center; gap: 5px; min-width: 70px; }
.wz-conn { flex: 1; height: 2px; background: var(--st-border); margin-top: 18px; transition: background .3s; }
.wz-conn.done { background: #10B981; }
.wz-num {
  width: 36px; height: 36px; border-radius: 50%;
  border: 2px solid var(--st-border); background: var(--st-bg);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: .85rem; color: var(--st-muted);
  transition: all .25s;
}
.wz-label { font-size: .72rem; color: var(--st-muted); font-weight: 500; white-space: nowrap; text-align: center; }
.wz-step.active .wz-num {
  background: var(--st-primary); border-color: var(--st-primary); color: #fff;
  box-shadow: 0 0 0 4px rgba(0,48,135,.12);
}
.wz-step.active .wz-label { color: var(--st-primary); font-weight: 700; }
.wz-step.done .wz-num { background: #10B981; border-color: #10B981; color: #fff; }
.wz-step.done .wz-label { color: #10B981; }

/* ── STEP PANEL ANIMATION ──────────────────────────── */
.step-panel:not(.d-none) { animation: panel-in .22s ease; }
@keyframes panel-in {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── REQUESTER CHIP (step 3) ───────────────────────── */
.requester-chip {
  background: var(--st-bg); border-radius: var(--st-radius-sm);
  padding: .8rem 1rem; margin-bottom: 1.5rem;
  display: flex; align-items: center; gap: .75rem;
  border-left: 4px solid #10B981; font-size: .88rem;
}
.rc-icon {
  width: 36px; height: 36px; border-radius: 50%;
  background: rgba(16,185,129,.12); color: #10B981;
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem; flex-shrink: 0;
}

/* ── BUTTON DISABLED STATE ─────────────────────────── */
.btn-st-primary:disabled { opacity: .45; cursor: not-allowed; transform: none !important; }

/* ── RESPONSIVE ────────────────────────────────────── */
@media (max-width: 768px) {
  .admin-sidebar { transform: translateX(-100%); transition: transform .3s; }
  .admin-sidebar.open { transform: translateX(0); }
  .admin-main { margin-left: 0; }
}

@media (max-width: 575px) {
  .st-public-main { padding: 1.5rem 1rem 1rem; }
  .landing-hero { margin-bottom: 1.25rem; }
  .landing-hero h1 { font-size: 1.3rem; }
  .landing-hero p { font-size: .85rem; }
  .choice-card { padding: 1.25rem .85rem; }
  .choice-card .icon-wrap { width: 50px; height: 50px; font-size: 1.4rem; margin-bottom: .6rem; }
  .choice-card h2 { font-size: .9rem; }
  .choice-card p { font-size: .78rem; }
}
