/* ============================================================
   PGDT v2 — Estilo dinámico con animaciones
   Paleta: vino/tinto gubernamental
   ============================================================ */

@font-face{
  font-family: 'Clab';
  src: url('../fonts/Clab_Personal_Use-Regular.otf') format('opentype');
  font-weight: 400;
  font-style: normal;
}
@font-face{
  font-family: 'Clab';
  src: url('../fonts/Clab_Personal_Use-Italic.otf') format('opentype');
  font-weight: 400;
  font-style: italic;
}
@font-face{
  font-family: 'Clab';
  src: url('../fonts/Clab_Personal_Use-Bold.otf') format('opentype');
  font-weight: 700;
  font-style: normal;
}
@font-face{
  font-family: 'Clab';
  src: url('../fonts/Clab_Personal_Use-BoldItalic.otf') format('opentype');
  font-weight: 700;
  font-style: italic;
}

:root {
  --vino: #5D2632;
  --vino2: #3A0C17;
  --vino-light: #8a2b52;
  --accent: #882941;
  --accent-light: #d4789a;
  --gold: #B89A5E;
  --bg: #f8f6f7;
  --bg-warm: #faf7f8;
  --card: #ffffff;
  --text: #181921;
  --text-light: #444;
  --muted: #7a7278;
  --border: #e8e2e5;
  --border-light: #f0eced;
  --shadow-sm: 0 2px 8px rgba(74,15,36,.06);
  --shadow: 0 8px 30px rgba(74,15,36,.08);
  --shadow-lg: 0 20px 50px rgba(74,15,36,.12);
  --shadow-hover: 0 12px 40px rgba(74,15,36,.14);
  --radius: 16px;
  --radius-lg: 22px;
  --radius-xl: 28px;
  --transition: .3s cubic-bezier(.4,0,.2,1);
  --transition-bounce: .5s cubic-bezier(.34,1.56,.64,1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: 'DM Sans', system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ============================================================
   ANIMATIONS
   ============================================================ */

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes slideDown {
  from { opacity: 0; transform: translateY(-20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes slideUp {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes scaleIn {
  from { opacity: 0; transform: scale(.92); }
  to { opacity: 1; transform: scale(1); }
}

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.05); }
}

@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

@keyframes slideInRight {
  from { opacity: 0; transform: translateX(30px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes ripple {
  to { transform: scale(4); opacity: 0; }
}

.fade-in { animation: fadeIn .5s ease-out; }
.fade-in-up { animation: fadeInUp .6s ease-out; }
.animate-slide-down { animation: slideDown .4s var(--transition); }
.animate-slide-up { animation: slideUp .5s ease-out; }
.animate-scale { animation: scaleIn .4s ease-out; }

/* Staggered children animation */
.stagger > * { opacity: 0; animation: fadeInUp .5s ease-out forwards; }
.stagger > *:nth-child(1) { animation-delay: .05s; }
.stagger > *:nth-child(2) { animation-delay: .1s; }
.stagger > *:nth-child(3) { animation-delay: .15s; }
.stagger > *:nth-child(4) { animation-delay: .2s; }
.stagger > *:nth-child(5) { animation-delay: .25s; }
.stagger > *:nth-child(6) { animation-delay: .3s; }
.stagger > *:nth-child(7) { animation-delay: .35s; }
.stagger > *:nth-child(8) { animation-delay: .4s; }

/* ============================================================
   TOPBAR
   ============================================================ */

.topbar {
  background-image: linear-gradient(90deg, rgba(93,38,50,.92), rgba(136,41,65,.88)), url('../img/membrete.png');
  background-size: cover;
  background-position: center;

  background: linear-gradient(135deg, var(--vino2) 0%, var(--vino) 50%, var(--vino-light) 100%);
  color: #fff;
  padding: 0;
  box-shadow: 0 4px 20px rgba(74,15,36,.25);
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(10px);
}

.topbar__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: #fff;
  transition: opacity var(--transition);
}
.brand:hover { opacity: .9; }

.seal {
  width: 42px; height: 42px;
  border-radius: 12px;
  background: rgba(255,255,255,.12);
  display: flex; align-items: center; justify-content: center;
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255,255,255,.1);
  transition: transform var(--transition), background var(--transition);
}
.seal:hover { transform: rotate(-5deg) scale(1.05); background: rgba(255,255,255,.18); }
.brand__gov { font-size: 11px; opacity: .8; letter-spacing: .3px; }
.brand__title { font-size: 14px; font-weight: 700; }

.nav { display: flex; gap: 6px; align-items: center; }
.nav a {
  color: #fff; text-decoration: none; opacity: .85;
  padding: 8px 12px; border-radius: 10px;
  font-size: 14px; font-weight: 500;
  transition: all var(--transition);
  position: relative;
}
.nav a:hover { opacity: 1; background: rgba(255,255,255,.12); }

.nav__notif {
  position: relative;
  display: flex !important;
  align-items: center;
  justify-content: center;
}
.nav__badge {
  position: absolute;
  top: 2px; right: 2px;
  background: #ef4444;
  color: #fff;
  font-size: 10px;
  font-weight: 800;
  min-width: 18px; height: 18px;
  border-radius: 999px;
  display: flex; align-items: center; justify-content: center;
  padding: 0 4px;
  animation: pulse 2s infinite;
  border: 2px solid var(--vino);
}

.nav__user {
  position: relative;
  cursor: pointer;
  margin-left: 4px;
}

.avatar-sm {
  width: 36px; height: 36px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  color: #fff;
  font-weight: 700;
  font-size: 13px;
  border: 2px solid rgba(255,255,255,.2);
  transition: transform var(--transition), border-color var(--transition);
}
.avatar-sm:hover { transform: scale(1.08); border-color: rgba(255,255,255,.4); }

/* Dropdown */
.dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  min-width: 220px;
  z-index: 200;
  opacity: 0;
  transform: translateY(-8px) scale(.96);
  pointer-events: none;
  transition: all .25s ease;
}
.dropdown.show {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}
.dropdown__header {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border-light);
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.dropdown__header strong { color: var(--text); font-size: 14px; }
.dropdown__header .muted { font-size: 12px; }
.dropdown__item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  color: var(--text-light);
  text-decoration: none;
  font-size: 14px;
  transition: background var(--transition);
}
.dropdown__item:hover { background: var(--bg-warm); }
.dropdown__item--danger { color: #dc2626; }
.dropdown__item--danger:hover { background: #fef2f2; }
.dropdown__sep { margin: 4px 0; border: none; border-top: 1px solid var(--border-light); }
.badge-sm {
  background: #ef4444;
  color: #fff;
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 999px;
  font-weight: 700;
  margin-left: auto;
}

/* ============================================================
   BUTTONS
   ============================================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--accent);
  color: #fff;
  border: none;
  padding: 11px 20px;
  border-radius: 12px;
  text-decoration: none;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
}
.btn:hover { background: var(--vino); transform: translateY(-1px); box-shadow: var(--shadow); }
.btn:active { transform: translateY(0) scale(.98); }

.btn--nav {
  background: rgba(255,255,255,.14);
  border: 1px solid rgba(255,255,255,.25);
  backdrop-filter: blur(4px);
}
.btn--nav:hover { background: rgba(255,255,255,.22); }

.btn--ghost {
  background: transparent;
  color: var(--vino);
  border: 1.5px solid var(--border);
}
.btn--ghost:hover { background: var(--bg-warm); border-color: var(--accent); color: var(--accent); }

.btn--danger {
  background: #dc2626;
}
.btn--danger:hover { background: #b91c1c; }

.btn--sm {
  padding: 7px 14px;
  font-size: 13px;
  border-radius: 10px;
}

.btn--icon {
  width: 38px; height: 38px;
  padding: 0;
  border-radius: 10px;
}

/* ============================================================
   CONTAINER & LAYOUT
   ============================================================ */

.container {
  max-width: 1200px;
  margin: 24px auto;
  padding: 0 20px;
}

.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.grid2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-bottom: 16px; }
.grid4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 16px; }

@media (max-width: 900px) {
  .grid { grid-template-columns: 1fr; }
  .grid2 { grid-template-columns: 1fr; }
  .grid4 { grid-template-columns: repeat(2, 1fr); }
  .hero { grid-template-columns: 1fr !important; }
}
@media (max-width: 600px) {
  .grid4 { grid-template-columns: 1fr; }
  .topbar__inner { flex-wrap: wrap; }
}

/* ============================================================
   CARDS
   ============================================================ */

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: 22px;
  transition: all var(--transition);
}
.card:hover {
  box-shadow: var(--shadow);
}

.card--interactive {
  cursor: pointer;
}
.card--interactive:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
  border-color: var(--accent-light);
}

.card--accent {
  border-left: 4px solid var(--accent);
}

.card__icon {
  width: 48px; height: 48px;
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 14px;
  transition: transform var(--transition-bounce);
}
.card--interactive:hover .card__icon { transform: scale(1.1) rotate(-3deg); }

/* ============================================================
   HERO
   ============================================================ */

.hero {
  display: grid;
  grid-template-columns: 1.4fr .9fr;
  gap: 16px;
  align-items: stretch;
  margin-bottom: 22px;
}

.hero__copy {
  background: linear-gradient(135deg, var(--vino2) 0%, var(--vino) 60%, var(--vino-light) 100%);
  color: #fff;
  border-radius: var(--radius-xl);
  padding: 36px 32px;
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
  animation: fadeIn .6s ease-out;
}
.hero__copy::before {
  content: '';
  position: absolute;
  top: -60%; right: -20%;
  width: 300px; height: 300px;
  background: radial-gradient(circle, rgba(255,255,255,.06) 0%, transparent 70%);
  border-radius: 50%;
}
.hero__copy::after {
  content: '';
  position: absolute;
  bottom: -40%; left: -10%;
  width: 200px; height: 200px;
  background: radial-gradient(circle, rgba(177,70,107,.2) 0%, transparent 70%);
  border-radius: 50%;
}

.hero h1 {
  margin: 0 0 12px;
  font-family: 'Clab', sans-serif;
  font-size: 34px;
  line-height: 1.1;
  position: relative;
  z-index: 1;
}
.hero p {
  margin: 0 0 18px;
  opacity: .9;
  font-size: 15px;
  position: relative;
  z-index: 1;
  max-width: 440px;
}
.hero__actions { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 16px; position: relative; z-index: 1; }
.hero__card .card { height: 100%; animation: slideInRight .6s ease-out; }

.chips { display: flex; gap: 8px; flex-wrap: wrap; position: relative; z-index: 1; }
.chip {
  background: rgba(255,255,255,.12);
  padding: 7px 14px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 500;
  border: 1px solid rgba(255,255,255,.1);
  backdrop-filter: blur(4px);
  transition: all var(--transition);
}
.chip:hover { background: rgba(255,255,255,.2); transform: translateY(-1px); }

.steps { margin: 14px 0 0; padding-left: 0; list-style: none; counter-reset: step; }
.steps li {
  counter-increment: step;
  padding: 10px 0 10px 36px;
  position: relative;
  border-left: 2px solid var(--border-light);
  margin-left: 12px;
}
.steps li::before {
  content: counter(step);
  position: absolute;
  left: -13px; top: 8px;
  width: 24px; height: 24px;
  background: var(--accent);
  color: #fff;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px;
  font-weight: 700;
}
.steps li:last-child { border-left-color: transparent; }

/* ============================================================
   TOAST (replace old alerts)
   ============================================================ */

.toast {
  display: flex;
  align-items: center;
  gap: 10px;
  border-radius: 14px;
  padding: 14px 18px;
  margin-bottom: 16px;
  border: 1px solid var(--border);
  background: var(--card);
  box-shadow: var(--shadow);
  font-size: 14px;
  font-weight: 500;
  transition: all .4s ease;
  position: relative;
}
.toast--error {
  border-color: rgba(220,38,38,.3);
  background: linear-gradient(135deg, #fef2f2, #fff);
  color: #991b1b;
}
.toast--ok {
  border-color: rgba(22,163,74,.3);
  background: linear-gradient(135deg, #f0fdf4, #fff);
  color: #166534;
}
.toast__close {
  margin-left: auto;
  background: none;
  border: none;
  font-size: 20px;
  cursor: pointer;
  opacity: .5;
  color: inherit;
  transition: opacity var(--transition);
}
.toast__close:hover { opacity: 1; }

/* ============================================================
   MODAL SYSTEM
   ============================================================ */

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(30, 10, 18, .55);
  backdrop-filter: blur(6px);
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s ease;
}
.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal {
  background: var(--card);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  width: 90%;
  max-width: 800px;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  transform: translateY(20px) scale(.96);
  transition: transform .35s cubic-bezier(.34,1.56,.64,1);
  overflow: hidden;
}
.modal-overlay.active .modal {
  transform: translateY(0) scale(1);
}

.modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border);
}
.modal__header h3 { margin: 0; font-size: 17px; }
.modal__close {
  background: var(--bg);
  border: 1px solid var(--border);
  width: 34px; height: 34px;
  border-radius: 10px;
  font-size: 18px;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all var(--transition);
  color: var(--muted);
}
.modal__close:hover { background: #fee2e2; color: #dc2626; border-color: #fca5a5; }

.modal__body {
  padding: 24px;
  overflow-y: auto;
  flex: 1;
}

.modal__body iframe {
  width: 100%;
  height: 60vh;
  border: none;
  border-radius: var(--radius);
}

/* ============================================================
   TABLES
   ============================================================ */

.table-wrap { overflow-x: auto; margin-top: 10px; }
.table {
  width: 100%;
  border-collapse: collapse;
}
.table th, .table td {
  border-bottom: 1px solid var(--border-light);
  text-align: left;
  padding: 12px 10px;
  vertical-align: top;
  font-size: 14px;
}
.table th {
  font-size: 11px;
  color: var(--muted);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .5px;
  background: var(--bg-warm);
}
.table tbody tr {
  transition: background var(--transition);
}
.table tbody tr:hover {
  background: var(--bg-warm);
}

/* ============================================================
   BADGES
   ============================================================ */

.badge {
  display: inline-flex;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .3px;
  text-transform: uppercase;
}
.badge--revision { background: #fef3c7; color: #92400e; border: 1px solid #fde68a; }
.badge--correccion { background: #fed7aa; color: #9a3412; border: 1px solid #fdba74; }
.badge--aprobado { background: #d1fae5; color: #065f46; border: 1px solid #a7f3d0; }
.badge--rechazado { background: #fee2e2; color: #991b1b; border: 1px solid #fca5a5; }
.badge--default { background: rgba(106,27,58,.08); color: var(--vino); border: 1px solid rgba(106,27,58,.18); }
.badge--urgente { background: #fee2e2; color: #dc2626; border: 1px solid #fca5a5; animation: pulse 2s infinite; }

/* ============================================================
   FORMS
   ============================================================ */

.form { display: grid; gap: 14px; }
.form label { display: grid; gap: 6px; font-weight: 600; font-size: 14px; color: var(--text-light); }
input, select, textarea {
  padding: 11px 14px;
  border-radius: 12px;
  border: 1.5px solid var(--border);
  outline: none;
  font-size: 14px;
  font-family: inherit;
  background: var(--bg-warm);
  transition: all var(--transition);
}
input:focus, select:focus, textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(177,70,107,.12);
  background: #fff;
}
input[type="file"] {
  padding: 10px;
  cursor: pointer;
}

/* ============================================================
   LINKS
   ============================================================ */

.link { color: var(--vino); font-weight: 700; text-decoration: none; transition: color var(--transition); }
.link:hover { color: var(--accent); text-decoration: underline; }
.muted { color: var(--muted); }
hr.sep { border: none; border-top: 1px solid var(--border-light); margin: 16px 0; }

/* ============================================================
   STAT CARDS
   ============================================================ */

.stat-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  text-align: center;
  transition: all var(--transition);
}
.stat-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.stat-card__number {
  font-family: 'Clab', sans-serif;
  font-size: 32px;
  font-weight: 700;
  color: var(--vino);
  line-height: 1;
}
.stat-card__label {
  font-size: 12px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .5px;
  margin-top: 4px;
  font-weight: 600;
}

/* ============================================================
   TRAMITES CATALOG
   ============================================================ */

.tramite-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  transition: all var(--transition);
  cursor: pointer;
  position: relative;
  overflow: hidden;
}
.tramite-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: var(--card-color, var(--accent));
  transition: height var(--transition);
}
.tramite-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
}
.tramite-card:hover::before { height: 6px; }

.tramite-card__clave {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .8px;
  color: var(--muted);
  margin-bottom: 6px;
}
.tramite-card__nombre {
  font-weight: 700;
  font-size: 16px;
  margin-bottom: 8px;
  color: var(--text);
}
.tramite-card__desc {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.tramite-card__meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 14px;
  font-size: 12px;
  color: var(--muted);
}

/* ============================================================
   NOTIFICATIONS
   ============================================================ */

.notif-item {
  display: flex;
  gap: 14px;
  padding: 16px;
  border-radius: var(--radius);
  transition: all var(--transition);
  border: 1px solid transparent;
  cursor: pointer;
}
.notif-item:hover { background: var(--bg-warm); }
.notif-item--unread {
  background: rgba(177,70,107,.04);
  border-color: rgba(177,70,107,.1);
}
.notif-item__dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  margin-top: 5px;
  flex-shrink: 0;
}
.notif-item__dot--info { background: #3b82f6; }
.notif-item__dot--exito { background: #22c55e; }
.notif-item__dot--alerta { background: #f59e0b; }
.notif-item__dot--documento { background: var(--accent); }
.notif-item__dot--revision { background: #8b5cf6; }

/* ============================================================
   TIMELINE / SEGUIMIENTO
   ============================================================ */

.timeline { padding-left: 0; list-style: none; }
.timeline__item {
  position: relative;
  padding: 0 0 24px 40px;
}
.timeline__item::before {
  content: '';
  position: absolute;
  left: 14px; top: 28px; bottom: 0;
  width: 2px;
  background: var(--border);
}
.timeline__item:last-child::before { display: none; }
.timeline__dot {
  position: absolute;
  left: 4px; top: 4px;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--accent);
  border: 3px solid var(--card);
  box-shadow: 0 0 0 2px var(--accent);
}
.timeline__dot--muted { background: var(--border); box-shadow: 0 0 0 2px var(--border); }

/* ============================================================
   PAGEHEAD
   ============================================================ */

.pagehead {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 18px;
  align-items: flex-start;
}

/* ============================================================
   AUTH
   ============================================================ */

.auth { max-width: 480px; margin: 0 auto; }
.hint {
  margin-top: 14px;
  padding: 14px;
  border-radius: var(--radius);
  border: 1px dashed var(--border);
  background: var(--bg-warm);
  font-size: 13px;
}

/* ============================================================
   FILTERS
   ============================================================ */

.filters { display: flex; gap: 8px; flex-wrap: wrap; margin: 14px 0; }
.chiplink {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: 999px;
  text-decoration: none;
  border: 1.5px solid var(--border);
  background: var(--card);
  color: var(--text-light);
  font-weight: 600;
  font-size: 13px;
  transition: all var(--transition);
}
.chiplink:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-1px); }
.chiplink--active {
  background: var(--vino);
  color: #fff;
  border-color: var(--vino);
}
.chiplink--active:hover { background: var(--vino-light); color: #fff; }

/* ============================================================
   LIST
   ============================================================ */

.list { margin: 10px 0 0; padding-left: 0; list-style: none; }
.list li {
  padding: 10px 0;
  border-bottom: 1px solid var(--border-light);
}
.list li:last-child { border-bottom: none; }

/* ============================================================
   DOCUMENT LIST
   ============================================================ */

.doc-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  margin-bottom: 10px;
  transition: all var(--transition);
  background: var(--bg-warm);
}
.doc-item:hover { background: #fff; border-color: var(--accent-light); box-shadow: var(--shadow-sm); }

.doc-item__icon {
  width: 42px; height: 42px;
  border-radius: 10px;
  background: rgba(220,38,38,.08);
  color: #dc2626;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}

.doc-item__info { flex: 1; min-width: 0; }
.doc-item__name { font-weight: 600; font-size: 14px; }
.doc-item__meta { font-size: 12px; color: var(--muted); }
.doc-item__actions { display: flex; gap: 6px; }

/* ============================================================
   PROFILE
   ============================================================ */

.profile-header {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 20px;
}
.avatar-lg {
  width: 72px; height: 72px;
  border-radius: 18px;
  display: flex; align-items: center; justify-content: center;
  color: #fff;
  font-weight: 700;
  font-size: 26px;
  flex-shrink: 0;
}

/* ============================================================
   FOOTER
   ============================================================ */

.footer {
  margin-top: 40px;
  padding: 24px 0;
  background: linear-gradient(135deg, var(--vino2), #2a0a15);
  color: #fff;
}
.footer__inner { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; align-items: center; }
.footer .muted { color: rgba(255,255,255,.5); }
.footer__links { display: flex; gap: 16px; }
.footer__links a { color: rgba(255,255,255,.7); text-decoration: none; font-size: 14px; transition: color var(--transition); }
.footer__links a:hover { color: #fff; }

/* ============================================================
   EMPTY STATE
   ============================================================ */

.empty {
  text-align: center;
  padding: 40px 20px;
  color: var(--muted);
}
.empty svg { opacity: .3; margin-bottom: 12px; }
.empty__title { font-weight: 700; font-size: 16px; color: var(--text-light); margin-bottom: 6px; }

/* ============================================================
   UTILITY
   ============================================================ */

.flex-between { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.flex-gap { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.mb-0 { margin-bottom: 0; }
.mt-16 { margin-top: 16px; }
.text-center { text-align: center; }

/* Scroll progress on page load */
.progress-bar {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--accent-light));
  z-index: 999;
  transition: width .3s ease;
}


/* Fix: dropdown inside .nav inherits white text */
.nav .dropdown .dropdown__item{ color: var(--text-light); }
.nav .dropdown .dropdown__item--danger{ color: #dc2626; }
.nav .dropdown .dropdown__header strong{ color: var(--text); }
.nav .dropdown .muted{ color: var(--muted); }

.hero__media{
  flex: 1;
  display:flex;
  align-items:center;
  justify-content:center;
}
@media (max-width: 900px){
  .hero__media img{ max-height: 280px; }
}

.card--hover{
  text-decoration:none;
  color: inherit;
  transition: transform var(--transition-bounce), box-shadow var(--transition);
}
.card--hover:hover{
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
}
.link-back{ color: var(--vino); text-decoration:none; font-weight:600; }
.page-head{ margin-top: 8px; }
