*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
:root {
  --navy:    #00003C;
  --blue:    #0071FF;
  --accent:  #00FF87;
  --bg:      #F5F6FA;
  --white:   #FFFFFF;
  --text:    #0D1A3A;
  --muted:   #6B748A;
  --border:  #D8DBE8;
  --hover:   #EEF1FB;
  --r:       4px;
  --r2:      6px;
  --sh:      0 1px 3px rgba(0,0,60,.07), 0 1px 2px rgba(0,0,60,.04);
}
html { font-size: 15px; }
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.55;
}
a { color: inherit; }

.pre-header {
  background: #FFF8F0;
  border-bottom: 1px solid #FDDCB5;
  padding: 10px 40px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: .85rem;
  color: #7C4D1E;
}
.pre-header-icon { font-size: 1.1rem; margin-top: 1px; flex-shrink: 0; }
.pre-header-text a { color: #0071FF; }

.navbar {
  background: var(--navy);
  height: 58px;
  padding: 0 40px;
  display: flex;
  align-items: center;
  position: sticky;
  top: 0;
  z-index: 300;
  box-shadow: 0 2px 8px rgba(0,0,0,.2);
}
.brand {
  display: flex; align-items: center; gap: 0;
  cursor: pointer; text-decoration: none; margin-right: 44px; flex-shrink: 0;
}
.brand-logo { display: block; }
.brand-sep { width: 1px; height: 20px; background: rgba(255,255,255,.25); margin: 0 10px; }
.brand-name { font-size: .88rem; font-weight: 600; color: rgba(255,255,255,.8); }

.nav-items { display: flex; align-items: center; gap: 2px; flex: 1; }
.nav-btn {
  padding: 6px 13px; border-radius: var(--r);
  font-size: .88rem; font-weight: 500; color: rgba(255,255,255,.72);
  background: none; border: none; cursor: pointer;
  font-family: inherit; position: relative; transition: color .15s;
  white-space: nowrap; text-decoration: none;
}
.nav-btn:hover { color: #fff; }
.nav-btn.active { color: #fff; font-weight: 700; }

.nav-right { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.btn-usr {
  width: 32px; height: 32px; border-radius: 50%;
  background: rgba(255,255,255,.12); color: #fff;
  border: 1px solid rgba(255,255,255,.28);
  cursor: pointer; font-size: .78rem;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; transition: background .15s;
}
.btn-usr:hover { background: rgba(255,255,255,.22); }
.btn-ayuda {
  background: transparent; color: rgba(255,255,255,.85);
  border: 1px solid rgba(255,255,255,.32);
  padding: 5px 14px; border-radius: var(--r);
  font-size: .82rem; font-weight: 600; cursor: pointer; font-family: inherit;
  white-space: nowrap; transition: background .15s; text-decoration: none;
}
.btn-ayuda:hover { background: rgba(255,255,255,.1); color: #fff; }
.btn-salir {
  background: rgba(255,255,255,.12); color: #fff;
  border: 1px solid rgba(255,255,255,.28);
  padding: 5px 14px; border-radius: var(--r);
  font-size: .82rem; font-weight: 600; cursor: pointer; font-family: inherit;
  white-space: nowrap; transition: background .15s;
}
.btn-salir:hover { background: rgba(255,255,255,.22); }

.section-white { background: var(--white); padding: 56px 40px; }
.section-gray  { background: var(--bg);    padding: 56px 40px; }
.section-navy  { background: var(--navy);  padding: 56px 40px; }
.section-inner { max-width: 1080px; margin: 0 auto; }

.page-h1 {
  font-size: 2.4rem; font-weight: 900; color: var(--navy);
  margin-bottom: 40px; letter-spacing: -.5px;
}
.section-h1 {
  font-size: 1.7rem; font-weight: 900; color: var(--navy);
  margin-bottom: 28px; letter-spacing: -.3px;
}
.section-tag {
  font-size: .68rem; font-weight: 800; text-transform: uppercase;
  letter-spacing: .12em; color: var(--muted);
  margin-bottom: 8px; display: block;
}

.bienvenida { padding: 56px 40px 48px; background: var(--white); }
.bienvenida-inner { max-width: 1080px; margin: 0 auto; }
.bienvenida h1 {
  font-size: 2.6rem; font-weight: 900; color: var(--navy);
  letter-spacing: -.5px; line-height: 1.15;
}

.tbl-wrap { overflow-x: auto; border-radius: var(--r2); border: 1px solid var(--border); background: var(--white); box-shadow: var(--sh); }
table { width: 100%; border-collapse: collapse; font-size: .875rem; }
thead tr { background: var(--navy); }
thead th { padding: 10px 14px; text-align: left; color: #fff; font-size: .68rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; white-space: nowrap; }
tbody tr { border-bottom: 1px solid var(--border); transition: background .1s; }
tbody tr:last-child { border-bottom: none; }
tbody tr:hover td { background: var(--hover); }
tbody td { padding: 10px 14px; color: var(--text); background: var(--white); }
.td-link { color: var(--blue); cursor: pointer; font-weight: 600; text-decoration: none; }
.td-link:hover { text-decoration: underline; }
.tbl-footer { padding: 9px 14px; background: #FAFBFD; border-top: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; font-size: .8rem; color: var(--muted); }
.a-action { color: var(--blue); text-decoration: none; font-size: .85rem; cursor: pointer; font-weight: 500; }
.a-action:hover { text-decoration: underline; }

.search-card { background: var(--white); border: 1px solid var(--border); border-radius: var(--r2); box-shadow: var(--sh); padding: 28px 32px; }
.search-row { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; margin-bottom: 18px; }
.field-lbl { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); display: block; margin-bottom: 4px; }

.kpi-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.kpi-card { background: var(--white); border: 1px solid var(--border); border-radius: var(--r2); box-shadow: var(--sh); padding: 24px 22px 20px; border-top: 3px solid var(--navy); }
.kpi-num { font-size: 2.2rem; font-weight: 900; color: var(--navy); line-height: 1; margin-bottom: 4px; }
.kpi-lbl { font-size: .82rem; color: var(--muted); margin-bottom: 14px; }
.kpi-bar { height: 3px; background: var(--border); border-radius: 2px; overflow: hidden; margin-bottom: 12px; }
.kpi-fill { height: 100%; background: var(--accent); border-radius: 2px; }
.kpi-lnk { color: var(--blue); font-size: .8rem; cursor: pointer; text-decoration: none; }
.kpi-lnk:hover { text-decoration: underline; }

.blog-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.blog-card { background: var(--white); border: 1px solid var(--border); border-radius: var(--r2); overflow: hidden; box-shadow: var(--sh); }
.blog-img { height: 160px; background: var(--navy); display: flex; align-items: center; justify-content: center; color: rgba(255,255,255,.3); font-size: .75rem; overflow: hidden; }
.blog-img img { width: 100%; height: 100%; object-fit: cover; }
.blog-body { padding: 18px 18px 20px; }
.blog-title { font-size: 1rem; font-weight: 700; color: var(--navy); margin-bottom: 8px; line-height: 1.3; }
.blog-excerpt { font-size: .83rem; color: var(--muted); margin-bottom: 14px; line-height: 1.5; }
.blog-link { color: var(--blue); font-size: .83rem; font-weight: 600; cursor: pointer; text-decoration: none; }
.blog-link:hover { text-decoration: underline; }

.fi, .fs {
  width: 100%; padding: 9px 12px;
  border: 1px solid var(--border); border-radius: var(--r);
  font-size: .88rem; font-family: inherit; color: var(--text);
  background: var(--white); transition: border-color .15s;
}
.fi:focus, .fs:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 2px rgba(0,113,255,.14); }
.fs {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%2300003C'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 10px center;
  padding-right: 28px; cursor: pointer;
}

.sel-box {
  background: var(--white); border: 1px solid var(--border);
  border-radius: var(--r2); padding: 32px 36px;
  max-width: 600px; margin: 0 auto 32px;
  box-shadow: var(--sh);
}
.sel-box .fl { margin-bottom: 18px; }
.sel-box .fl label { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); display: block; margin-bottom: 5px; }
.sel-cta { padding-top: 20px; border-top: 1px solid var(--border); text-align: center; }
.btn-link { background: none; border: none; color: var(--navy); font-size: .9rem; font-weight: 700; cursor: pointer; font-family: inherit; }
.btn-link:hover { color: var(--blue); text-decoration: underline; }

.mini-sel { background: var(--white); border: 1px solid var(--border); border-radius: var(--r2); padding: 14px 20px; display: flex; gap: 14px; align-items: flex-end; flex-wrap: wrap; margin-bottom: 20px; box-shadow: var(--sh); }
.mini-sel .fl { margin: 0; flex: 1; min-width: 160px; }
.mini-sel .fl label { font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); display: block; margin-bottom: 4px; }

.form-card { background: var(--white); border: 1px solid var(--border); border-radius: var(--r2); padding: 28px 32px; box-shadow: var(--sh); }
.form-note { font-size: .82rem; color: var(--muted); margin-bottom: 18px; font-style: italic; }
.fg { margin-bottom: 14px; }
.fg label { font-size: .8rem; font-weight: 700; color: var(--text); display: block; margin-bottom: 4px; }
.g2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 20px; }
.g3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px 20px; }
.g4 { display: grid; grid-template-columns: 1fr 1fr 1fr 1fr; gap: 12px 16px; }
.date-rng { display: flex; align-items: center; gap: 6px; }
.date-rng input { flex: 1; padding: 9px 10px; border: 1px solid var(--border); border-radius: var(--r); font-size: .88rem; font-family: inherit; color: var(--text); background: var(--white); }
.date-rng input:focus { outline: none; border-color: var(--blue); }
.date-rng span { color: var(--muted); font-size: .85rem; }
.radio-row { display: flex; gap: 20px; flex-wrap: wrap; margin-top: 6px; }
.radio-row label { display: flex; align-items: center; gap: 6px; font-size: .85rem; cursor: pointer; font-weight: 400; }
.radio-row input[type=radio] { accent-color: var(--navy); width: 14px; height: 14px; }
.chk { display: flex; align-items: center; gap: 7px; font-size: .88rem; }
.chk input { accent-color: var(--navy); width: 14px; height: 14px; }
.form-actions { margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--border); display: flex; gap: 10px; }
.sel-otra { margin-top: 14px; }
.sel-otra a { text-decoration: none; }
.sel-otra a:hover { text-decoration: underline; }

.btn-p { background: var(--navy); color: #fff; border: none; padding: 9px 22px; border-radius: var(--r); font-size: .88rem; font-weight: 600; cursor: pointer; font-family: inherit; display: inline-flex; align-items: center; gap: 6px; transition: background .15s; }
.btn-p:hover { background: var(--blue); }
.btn-s { background: var(--white); color: var(--navy); border: 1.5px solid var(--navy); padding: 9px 22px; border-radius: var(--r); font-size: .88rem; font-weight: 600; cursor: pointer; font-family: inherit; transition: background .15s; }
.btn-s:hover { background: var(--hover); }

.blog-banner { background: var(--navy); color: rgba(255,255,255,.85); padding: 40px; margin-top: 0; }
.blog-banner-inner { max-width: 1080px; margin: 0 auto; }
.blog-banner-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 20px; }
.bb-card { background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.12); border-radius: var(--r2); padding: 22px; }
.bb-title { font-size: .95rem; font-weight: 700; color: #fff; margin-bottom: 8px; line-height: 1.3; }
.bb-text { font-size: .82rem; color: rgba(255,255,255,.7); margin-bottom: 14px; line-height: 1.5; }
.bb-link { color: var(--accent); font-size: .82rem; font-weight: 600; cursor: pointer; text-decoration: none; }
.bb-link:hover { text-decoration: underline; }

footer { background: var(--navy); color: rgba(255,255,255,.6); padding: 40px 40px 22px; }
.footer-logo { margin-bottom: 28px; }
.footer-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 32px; margin-bottom: 28px; }
.footer-col-h { font-size: .68rem; font-weight: 800; text-transform: uppercase; letter-spacing: .1em; color: rgba(255,255,255,.35); margin-bottom: 12px; }
.footer-links { list-style: none; }
.footer-links li { margin-bottom: 8px; }
.footer-links a { color: rgba(255,255,255,.6); font-size: .85rem; text-decoration: none; cursor: pointer; transition: color .15s; }
.footer-links a:hover { color: var(--accent); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); padding-top: 16px; font-size: .74rem; color: rgba(255,255,255,.3); max-width: 1080px; }

@media(max-width:700px){
  .navbar,.section-white,.section-gray,.section-navy,.bienvenida,.pre-header { padding-left: 18px; padding-right: 18px; }
  .g2,.g3,.g4,.search-row,.kpi-grid,.blog-grid,.blog-banner-grid,.footer-grid { grid-template-columns: 1fr; }
  .sel-box { padding: 20px 16px; }
  .page-h1,.bienvenida h1 { font-size: 1.7rem; }
  .mini-sel { flex-direction: column; }
  .brand-name { display: none; }
  footer { padding: 28px 18px 16px; }
}
