/* ============================================================
   LEGÁLIS PARAGUAY — Hoja de estilos principal
   Tipografías: Oswald (títulos) + Nunito (cuerpo)
   Paleta: Navy #1a1a2e | Oro #c9a84c | Blanco #ffffff
============================================================ */

:root {
  --navy:      #1a1a2e;
  --navy-mid:  #16213e;
  --navy-light:#0f3460;
  --gold:      #c9a84c;
  --gold-light:#e8c97a;
  --gold-dark: #a8872d;
  --white:     #ffffff;
  --gray-100:  #f8f9fa;
  --gray-200:  #e9ecef;
  --gray-600:  #6c757d;
  --success:   #198754;
  --danger:    #dc3545;
  --shadow-sm: 0 2px 8px rgba(0,0,0,.07);
  --shadow-md: 0 4px 20px rgba(0,0,0,.12);
  --radius:    8px;
  --radius-lg: 16px;
  --transition: .2s ease;
}

/* ── Base ─────────────────────────────────────────────────── */
* { box-sizing: border-box; }

body {
  font-family: 'Nunito', sans-serif;
  font-size: 15px;
  color: #333;
  background: #fff;
  line-height: 1.65;
}

h1, h2, h3, h4, h5, h6,
.font-oswald {
  font-family: 'Oswald', sans-serif;
}

a { color: var(--gold-dark); text-decoration: none; }
a:hover { color: var(--gold); }

/* ── NAVBAR ───────────────────────────────────────────────── */
.legalis-navbar {
  background: var(--navy) !important;
  border-bottom: 2px solid var(--gold);
  padding: .7rem 0;
  box-shadow: 0 2px 12px rgba(0,0,0,.25);
}

.legalis-brand {
  font-family: 'Oswald', sans-serif;
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: 2px;
  line-height: 1;
  display: flex;
  align-items: baseline;
  gap: 1px;
}

.brand-leg  { color: var(--white); }
.brand-alis { color: var(--gold); }
.brand-py   {
  font-size: .65rem;
  color: var(--gray-600);
  letter-spacing: .5px;
  margin-left: 3px;
  font-weight: 400;
}

.legalis-navbar .nav-link {
  color: rgba(255,255,255,.8) !important;
  font-weight: 600;
  font-size: .88rem;
  padding: .45rem .75rem !important;
  border-radius: var(--radius);
  transition: var(--transition);
}

.legalis-navbar .nav-link:hover {
  color: var(--gold) !important;
  background: rgba(201,168,76,.1);
}

/* ── Botón dorado ─────────────────────────────────────────── */
.btn-legalis-gold {
  background: var(--gold);
  color: var(--navy) !important;
  border: none;
  font-weight: 700;
  font-family: 'Oswald', sans-serif;
  letter-spacing: .5px;
  transition: var(--transition);
}

.btn-legalis-gold:hover {
  background: var(--gold-light);
  color: var(--navy) !important;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(201,168,76,.4);
}

.btn-legalis-navy {
  background: var(--navy);
  color: var(--gold) !important;
  border: 2px solid var(--gold);
  font-weight: 700;
  font-family: 'Oswald', sans-serif;
  transition: var(--transition);
}

.btn-legalis-navy:hover {
  background: var(--gold);
  color: var(--navy) !important;
}

/* ── Avatar mini ──────────────────────────────────────────── */
.user-avatar-mini {
  width: 28px; height: 28px;
  background: var(--gold);
  color: var(--navy);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: .8rem;
  font-family: 'Oswald', sans-serif;
}

/* ── Dropdown ─────────────────────────────────────────────── */
.legalis-dropdown {
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  min-width: 220px;
}

.legalis-dropdown .dropdown-item {
  font-size: .9rem;
  padding: .55rem 1rem;
  transition: var(--transition);
}

.legalis-dropdown .dropdown-item:hover {
  background: var(--gray-100);
  color: var(--navy);
}

/* ── HERO ─────────────────────────────────────────────────── */
.legalis-hero {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-mid) 50%, var(--navy-light) 100%);
  color: white;
  padding: 90px 0 70px;
  position: relative;
  overflow: hidden;
}

.legalis-hero::before {
  content: '§';
  position: absolute;
  font-size: 400px;
  font-family: 'Oswald', sans-serif;
  color: rgba(255,255,255,.03);
  right: -50px;
  top: -80px;
  line-height: 1;
}

.hero-badge {
  display: inline-block;
  background: rgba(201,168,76,.15);
  border: 1px solid var(--gold);
  color: var(--gold);
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: 2px;
  padding: .35rem .9rem;
  border-radius: 20px;
  margin-bottom: 1rem;
  font-family: 'Oswald', sans-serif;
}

.legalis-hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: 1px;
}

.legalis-hero h1 .text-gold { color: var(--gold); }

/* ── Tarjetas de categoría ────────────────────────────────── */
.cat-card {
  background: white;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  transition: var(--transition);
  cursor: pointer;
  height: 100%;
}

.cat-card:hover {
  border-color: var(--gold);
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}

.cat-card:hover .cat-icon { background: var(--gold); color: var(--navy); }

.cat-icon {
  width: 52px; height: 52px;
  background: var(--gray-100);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  color: var(--gold-dark);
  transition: var(--transition);
  margin-bottom: 1rem;
}

/* ── Tarjetas de avisos ───────────────────────────────────── */
.aviso-card {
  background: white;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 1.25rem;
  transition: var(--transition);
  height: 100%;
}

.aviso-card:hover {
  border-color: var(--gold);
  box-shadow: var(--shadow-sm);
}

.aviso-card .aviso-cat-badge {
  display: inline-block;
  background: rgba(201,168,76,.12);
  color: var(--gold-dark);
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .5px;
  padding: .2rem .6rem;
  border-radius: 4px;
  margin-bottom: .5rem;
  font-family: 'Oswald', sans-serif;
  text-transform: uppercase;
}

.aviso-card h6 {
  font-family: 'Oswald', sans-serif;
  font-size: 1rem;
  color: var(--navy);
  line-height: 1.3;
}

.aviso-card .aviso-meta {
  font-size: .78rem;
  color: var(--gray-600);
}

/* ── Badge destacado ──────────────────────────────────────── */
.badge-destacado {
  background: var(--gold);
  color: var(--navy);
  font-size: .65rem;
  font-weight: 700;
  font-family: 'Oswald', sans-serif;
  padding: .2rem .5rem;
  border-radius: 3px;
  letter-spacing: .5px;
}

/* ── Secciones ────────────────────────────────────────────── */
.section-title {
  font-family: 'Oswald', sans-serif;
  font-size: 1.7rem;
  font-weight: 600;
  color: var(--navy);
  letter-spacing: .5px;
}

.section-title .accent { color: var(--gold); }

.section-divider {
  width: 50px;
  height: 3px;
  background: var(--gold);
  margin: .5rem 0 1.5rem;
  border-radius: 2px;
}

/* ── CTA Banner ───────────────────────────────────────────── */
.cta-banner {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-light) 100%);
  border-radius: var(--radius-lg);
  padding: 3rem 2rem;
  color: white;
  position: relative;
  overflow: hidden;
}

.cta-banner::after {
  content: '';
  position: absolute;
  width: 300px; height: 300px;
  background: var(--gold);
  opacity: .05;
  border-radius: 50%;
  right: -80px;
  top: -80px;
}

/* ── Formularios ──────────────────────────────────────────── */
.legalis-form-card {
  background: white;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  padding: 2.5rem;
  border-top: 4px solid var(--gold);
}

.form-label {
  font-weight: 600;
  color: #444;
  font-size: .9rem;
  margin-bottom: .35rem;
}

.form-control, .form-select {
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius);
  padding: .6rem .9rem;
  font-family: 'Nunito', sans-serif;
  font-size: .92rem;
  transition: var(--transition);
}

.form-control:focus, .form-select:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(201,168,76,.15);
}

/* ── Auth pages ───────────────────────────────────────────── */
.auth-wrapper {
  min-height: calc(100vh - 80px);
  background: var(--gray-100);
  display: flex;
  align-items: center;
  padding: 2rem 0;
}

.auth-card {
  background: white;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
}

.auth-card-header {
  background: var(--navy);
  padding: 2rem;
  text-align: center;
  border-bottom: 3px solid var(--gold);
}

.auth-card-body { padding: 2rem; }

.divider-text {
  text-align: center;
  position: relative;
  color: var(--gray-600);
  font-size: .85rem;
}

.divider-text::before,
.divider-text::after {
  content: '';
  position: absolute;
  top: 50%;
  width: 42%;
  height: 1px;
  background: var(--gray-200);
}

.divider-text::before { left: 0; }
.divider-text::after  { right: 0; }

/* ── FOOTER ───────────────────────────────────────────────── */
.legalis-footer {
  background: var(--navy);
  color: rgba(255,255,255,.7);
  border-top: 3px solid var(--gold);
}

.legalis-brand-footer {
  font-family: 'Oswald', sans-serif;
  font-size: 1.8rem;
  font-weight: 700;
  letter-spacing: 2px;
}

.footer-links { margin: 0; }
.footer-links li { margin-bottom: .5rem; }
.footer-links a {
  color: rgba(255,255,255,.6);
  font-size: .88rem;
  transition: var(--transition);
}
.footer-links a:hover { color: var(--gold); }
.footer-link-small {
  color: rgba(255,255,255,.5);
  font-size: .8rem;
}
.footer-link-small:hover { color: var(--gold); }

.badge-partner {
  background: rgba(201,168,76,.15);
  border: 1px solid rgba(201,168,76,.4);
  color: var(--gold);
  font-size: .75rem;
  padding: .25rem .7rem;
  border-radius: 20px;
  font-family: 'Oswald', sans-serif;
  letter-spacing: .5px;
}

/* ── Panel / Dashboard ────────────────────────────────────── */
.panel-sidebar {
  background: var(--navy);
  min-height: calc(100vh - 80px);
  width: 250px;
  position: fixed;
  top: 68px;
  left: 0;
  overflow-y: auto;
  z-index: 100;
  border-right: 2px solid var(--gold);
}

.panel-content {
  margin-left: 250px;
  padding: 2rem;
  min-height: calc(100vh - 80px);
}

.sidebar-link {
  display: flex;
  align-items: center;
  gap: .75rem;
  padding: .75rem 1.25rem;
  color: rgba(255,255,255,.7);
  font-weight: 600;
  font-size: .9rem;
  border-left: 3px solid transparent;
  transition: var(--transition);
}

.sidebar-link:hover,
.sidebar-link.active {
  color: var(--gold);
  background: rgba(201,168,76,.08);
  border-left-color: var(--gold);
}

.stat-card {
  background: white;
  border-radius: var(--radius);
  padding: 1.5rem;
  border-left: 4px solid var(--gold);
  box-shadow: var(--shadow-sm);
}

.stat-card .stat-num {
  font-family: 'Oswald', sans-serif;
  font-size: 2rem;
  font-weight: 700;
  color: var(--navy);
  line-height: 1;
}

.stat-card .stat-label {
  font-size: .82rem;
  color: var(--gray-600);
  margin-top: .3rem;
}

/* ── Alertas personalizadas ────────────────────────────────── */
.alert--success { background:#d1e7dd;border-color:#a3cfbb;color:#0a3622; }
.alert--danger  { background:#f8d7da;border-color:#f1aeb5;color:#58151c; }
.alert--warning { background:#fff3cd;border-color:#ffe69c;color:#664d03; }
.alert--info    { background:#cff4fc;border-color:#9eeaf9;color:#055160; }

/* ── Responsive ───────────────────────────────────────────── */
@media (max-width: 768px) {
  .legalis-hero { padding: 60px 0 40px; }
  .panel-sidebar { display: none; }
  .panel-content { margin-left: 0; }
  .legalis-form-card { padding: 1.5rem; }
}
