:root{
  --eddi-red: #BB1821;
  --eddi-red-2: #DE6B73;
  --eddi-red-dark: #8f1017;
  --eddi-bg: #f7f8fb;
  --eddi-surface: #ffffff;
  --eddi-surface-2: #fff6f7;
  --eddi-text: #1f2937;
  --eddi-muted: #6b7280;
  --eddi-border: rgba(187, 24, 33, 0.14);
  --eddi-shadow: 0 14px 40px rgba(17, 24, 39, 0.08);
  --eddi-radius-xl: 24px;
  --eddi-radius-lg: 18px;
  --eddi-radius-md: 14px;
  --eddi-max: 1380px;

  --font-sans: "Montserrat", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

*{ box-sizing:border-box; }

html, body{
  margin:0;
  padding:0;
  background:var(--eddi-bg);
  color:var(--eddi-text);
  font-family:var(--font-sans);
}

a{
  color:inherit;
  text-decoration:none;
}

img{
  max-width:100%;
  display:block;
}

.page-shell{
  min-height:100vh;
}

.container-eddi{
  width:min(var(--eddi-max), calc(100% - 32px));
  margin:0 auto;
}

.eddi-topbar{
  position:sticky;
  top:0;
  z-index:40;
  background:linear-gradient(135deg, #7d0f16 0%, #BB1821 55%, #DE6B73 100%);
  color:#fff;
  box-shadow:0 10px 30px rgba(0,0,0,.15);
}

.eddi-topbar-inner{
  width:min(var(--eddi-max), calc(100% - 32px));
  margin:0 auto;
  min-height:76px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:18px;
  padding:12px 0;
}

.eddi-brand{
  display:flex;
  align-items:center;
  gap:14px;
  min-width:0;
}

.eddi-logo{
  height:48px;
  width:auto;
  object-fit:contain;
  flex:0 0 auto;
}

.eddi-brand-meta{
  display:flex;
  flex-direction:column;
  min-width:0;
}

.eddi-brand-title{
  font-size:1rem;
  font-weight:800;
  letter-spacing:-.02em;
}

.eddi-brand-subtitle{
  font-size:.82rem;
  opacity:.92;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.eddi-nav{
  display:flex;
  flex-wrap:wrap;
  justify-content:flex-end;
  gap:10px;
}

.eddi-nav a,
.eddi-nav button{
  border:none;
  background:rgba(255,255,255,.12);
  color:#fff;
  padding:.72rem .95rem;
  border-radius:999px;
  font-weight:700;
  cursor:pointer;
  font-family:inherit;
  font-size:.95rem;
  transition:.18s ease;
}

.eddi-nav a:hover,
.eddi-nav button:hover{
  background:rgba(255,255,255,.22);
  transform:translateY(-1px);
}

.eddi-main{
  padding:28px 0 38px;
}

.page-head{
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:18px;
  margin-bottom:22px;
}

.page-head h1{
  margin:0;
  font-size:2rem;
  line-height:1.05;
  font-weight:800;
  letter-spacing:-.03em;
}

.page-head p{
  margin:.45rem 0 0;
  color:var(--eddi-muted);
  font-size:.98rem;
}

.page-actions{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
}

.card-eddi{
  background:var(--eddi-surface);
  border:1px solid var(--eddi-border);
  border-radius:var(--eddi-radius-xl);
  box-shadow:var(--eddi-shadow);
}

.card-eddi-soft{
  background:linear-gradient(180deg, #fff 0%, var(--eddi-surface-2) 100%);
  border:1px solid var(--eddi-border);
  border-radius:var(--eddi-radius-xl);
  box-shadow:var(--eddi-shadow);
}

.badge-eddi{
  display:inline-flex;
  align-items:center;
  gap:.45rem;
  border-radius:999px;
  padding:.38rem .78rem;
  background:rgba(187,24,33,.08);
  color:var(--eddi-red);
  border:1px solid rgba(187,24,33,.12);
  font-size:.82rem;
  font-weight:800;
}

.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:.45rem;
  border-radius:14px;
  padding:.82rem 1rem;
  font-weight:800;
  font-size:.95rem;
  line-height:1;
  border:1px solid transparent;
  cursor:pointer;
  transition:.18s ease;
  font-family:inherit;
}

.btn:hover{
  transform:translateY(-1px);
}

.btn-primary{
  background:var(--eddi-red);
  color:#fff;
  border-color:var(--eddi-red);
}

.btn-primary:hover{
  background:var(--eddi-red-dark);
  border-color:var(--eddi-red-dark);
}

.btn-secondary{
  background:#fff;
  color:var(--eddi-text);
  border-color:rgba(17,24,39,.10);
}

.btn-secondary:hover{
  background:#f9fafb;
}

.btn-soft{
  background:rgba(187,24,33,.08);
  color:var(--eddi-red);
  border-color:rgba(187,24,33,.12);
}

.btn-warning{
  background:#111827;
  color:#fff;
}

.btn-warning:hover{
  background:#000;
}

.kpi-grid{
  display:grid;
  grid-template-columns:repeat(4, minmax(0, 1fr));
  gap:16px;
  margin-bottom:20px;
}

.kpi-card{
  background:linear-gradient(180deg, #fff 0%, #fff7f8 100%);
  border:1px solid var(--eddi-border);
  border-radius:20px;
  box-shadow:var(--eddi-shadow);
  padding:18px;
}

.kpi-card .kpi-label{
  color:var(--eddi-muted);
  font-size:.84rem;
  font-weight:700;
  margin-bottom:8px;
}

.kpi-card .kpi-value{
  font-size:2rem;
  line-height:1;
  font-weight:900;
  color:var(--eddi-red);
  letter-spacing:-.03em;
}

.detail-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:18px;
}

.admin-card{
  background:#fff;
  border:1px solid var(--eddi-border);
  border-radius:22px;
  box-shadow:var(--eddi-shadow);
  overflow:hidden;
}

.admin-card-head{
  padding:18px 18px 12px;
  border-bottom:1px solid rgba(17,24,39,.06);
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
}

.admin-card-head h2{
  margin:0;
  font-size:1.05rem;
  font-weight:800;
  letter-spacing:-.02em;
}

.table-wrap{
  overflow:auto;
}

.table-admin{
  width:100%;
  border-collapse:collapse;
  min-width:540px;
}

.table-admin th,
.table-admin td{
  padding:12px 16px;
  border-bottom:1px solid rgba(17,24,39,.06);
  text-align:left;
  font-size:.94rem;
}

.table-admin th{
  font-size:.8rem;
  text-transform:uppercase;
  letter-spacing:.06em;
  color:var(--eddi-muted);
  background:#fcfcfd;
}

.table-admin tbody tr:hover{
  background:#fff9fa;
}

.login-shell{
  min-height:100vh;
  display:grid;
  place-items:center;
  padding:28px 16px;
  background:
    radial-gradient(circle at top left, rgba(222,107,115,.18), transparent 32%),
    radial-gradient(circle at bottom right, rgba(187,24,33,.14), transparent 28%),
    linear-gradient(180deg, #fff 0%, #f8fafc 100%);
}

.login-card{
  width:min(480px, 100%);
  background:#fff;
  border:1px solid var(--eddi-border);
  border-radius:28px;
  box-shadow:0 22px 60px rgba(17,24,39,.12);
  padding:28px;
}

.login-brand{
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:14px;
  text-align:center;
  margin-bottom:20px;
}

.login-brand img{
  max-width:260px;
  width:100%;
  height:auto;
  object-fit:contain;
}

.login-brand h1{
  margin:0;
  font-size:1.8rem;
  line-height:1.05;
  color:var(--eddi-red);
  font-weight:900;
  letter-spacing:-.03em;
}

.login-brand p{
  margin:0;
  color:var(--eddi-muted);
}

.login-form{
  display:grid;
  gap:16px;
}

.field{
  display:grid;
  gap:8px;
}

.field label{
  font-size:.92rem;
  font-weight:700;
}

.field input{
  width:100%;
  border:1px solid rgba(17,24,39,.12);
  background:#fff;
  border-radius:14px;
  padding:.92rem 1rem;
  font:inherit;
  outline:none;
  transition:border-color .18s ease, box-shadow .18s ease;
}

.field input:focus{
  border-color:rgba(187,24,33,.45);
  box-shadow:0 0 0 4px rgba(187,24,33,.10);
}

.alert-error{
  border:1px solid rgba(187,24,33,.18);
  background:rgba(187,24,33,.08);
  color:var(--eddi-red-dark);
  border-radius:14px;
  padding:.9rem 1rem;
  font-weight:700;
}

.login-btn{
  width:100%;
  min-height:48px;
}

.admin-shell{
  width:min(var(--eddi-max), calc(100% - 32px));
  margin:0 auto;
  padding:28px 0 38px;
}

@media (max-width: 1120px){
  .kpi-grid{
    grid-template-columns:repeat(2, minmax(0, 1fr));
  }

  .detail-grid{
    grid-template-columns:1fr;
  }
}

@media (max-width: 820px){
  .eddi-topbar-inner{
    align-items:flex-start;
    flex-direction:column;
  }

  .eddi-nav{
    width:100%;
    justify-content:flex-start;
  }

  .page-head{
    flex-direction:column;
  }
}

@media (max-width: 640px){
  .container-eddi,
  .admin-shell,
  .eddi-topbar-inner{
    width:min(var(--eddi-max), calc(100% - 20px));
  }

  .kpi-grid{
    grid-template-columns:1fr;
  }

  .login-card{
    padding:22px;
    border-radius:22px;
  }

  .page-head h1{
    font-size:1.6rem;
  }
}