/* shared.css — dùng chung cho toàn bộ site Hải Linh Cái Mép */
@import url('https://fonts.googleapis.com/css2?family=Barlow+Condensed:wght@500;600;700;800&family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@400;600&display=swap');

:root{
  --deep-ocean:#0A3D62;
  --marine-navy:#062744;
  --flame-red:#E8362A;
  --flame-amber:#F5A623;
  --steel-mist:#EDF2F6;
  --ink-slate:#1C2B36;
  --line:#B9CBDA;
  --card-bg:#FFFFFF;
}
*{box-sizing:border-box; margin:0; padding:0;}
body{
  font-family:'Inter',sans-serif;
  background:var(--steel-mist);
  color:var(--ink-slate);
  min-height:100vh;
}
a{color:inherit; text-decoration:none;}
.mono{font-family:'JetBrains Mono',monospace;}

/* ---------- Thanh điều hướng ---------- */
.site-nav{
  background:var(--marine-navy);
  border-bottom:1px solid rgba(245,166,35,.25);
  position:sticky; top:0; z-index:150;
}
.nav-inner{
  max-width:1180px; margin:0 auto; padding:12px 20px;
  display:flex; align-items:center; justify-content:space-between; gap:16px; flex-wrap:wrap;
}
.nav-logo{
  display:flex; align-items:center; gap:10px;
  font-family:'Barlow Condensed',sans-serif; font-weight:800; letter-spacing:.02em;
  color:#fff; font-size:18px; text-transform:uppercase;
}
.nav-logo img{width:34px; height:34px; border-radius:6px;}
.nav-links{display:flex; align-items:center; gap:6px; flex-wrap:wrap;}
.nav-links a{
  color:#cfe0ee; font-size:14px; font-weight:600; padding:8px 14px; border-radius:8px;
  transition:background .15s, color .15s;
}
.nav-links a:hover{background:rgba(255,255,255,.08); color:#fff;}
.nav-links a.active{background:var(--flame-amber); color:var(--marine-navy);}
.nav-links a.admin-only-link{display:none;}

.nav-auth{display:flex; align-items:center; gap:8px;}
.admin-pill{
  background:rgba(255,255,255,.1); border:1px solid rgba(245,166,35,.5); color:#fff;
  font-size:13px; font-weight:600; padding:8px 14px; border-radius:999px;
  cursor:pointer; transition:filter .15s;
}
.admin-pill:hover{filter:brightness(1.2);}
.admin-badge{
  display:inline-flex; align-items:center; gap:6px; flex-wrap:wrap;
  background:rgba(245,166,35,.9); color:var(--marine-navy);
  font-size:12.5px; font-weight:700; padding:6px 12px; border-radius:999px;
}
.admin-badge button{
  background:none; border:none; color:var(--marine-navy); font-weight:700;
  cursor:pointer; font-size:12.5px; text-decoration:underline;
}

/* ---------- Modal đăng nhập / auth chung ---------- */
.auth-overlay{
  display:none; position:fixed; inset:0; z-index:300;
  background:rgba(6,20,34,.62); align-items:center; justify-content:center; padding:20px;
}
.auth-overlay.show{display:flex;}
.auth-modal{
  background:var(--card-bg); border-radius:16px; width:100%; max-width:380px;
  padding:28px 26px; box-shadow:0 30px 70px rgba(0,0,0,.35); position:relative;
}
.admin-panel-modal .auth-modal{max-width:480px;}
.auth-modal h3{font-family:'Barlow Condensed',sans-serif; font-size:22px; color:var(--marine-navy); margin-bottom:4px;}
.auth-modal .auth-sub{font-size:13px; color:#7a8a97; margin-bottom:18px;}
.auth-modal label{display:block; font-size:12px; font-weight:600; color:var(--ink-slate); margin:12px 0 6px;}
.auth-modal input, .auth-modal textarea{
  width:100%; padding:10px 12px; border:1px solid var(--line); border-radius:8px;
  font-family:inherit; font-size:14px;
}
.auth-modal input:focus, .auth-modal textarea:focus{outline:none; border-color:var(--flame-amber);}
.auth-actions{display:flex; gap:10px; margin-top:20px;}
.auth-actions button{
  flex:1; padding:10px 14px; border:none; border-radius:8px; font-weight:700; cursor:pointer; font-size:14px;
}
.auth-btn-primary{background:var(--flame-red); color:#fff;}
.auth-btn-primary:hover{filter:brightness(1.08);}
.auth-btn-primary:disabled{opacity:.5; cursor:not-allowed;}
.auth-btn-secondary{background:var(--steel-mist); color:var(--ink-slate);}
.auth-msg{font-size:13px; margin-top:12px; min-height:16px;}
.auth-msg.err{color:var(--flame-red);}
.auth-msg.ok{color:#2e8b57;}
.auth-close{position:absolute; top:14px; right:18px; font-size:22px; cursor:pointer; color:#9fb0bc;}

.admin-users-list{max-height:220px; overflow-y:auto; margin:10px 0 4px; border:1px solid var(--line); border-radius:8px;}
.admin-user-row{
  display:flex; justify-content:space-between; align-items:center;
  padding:9px 12px; border-bottom:1px solid var(--line); font-size:13.5px;
}
.admin-user-row:last-child{border-bottom:none;}
.admin-user-row .del-user{background:none; border:none; color:var(--flame-red); cursor:pointer; font-size:12px; font-weight:700;}
.admin-panel-divider{border-top:1px dashed var(--line); margin:16px 0 4px;}

/* ---------- Nút & thẻ dùng chung ---------- */
.btn{
  background:var(--card-bg); border:1px solid var(--line); color:var(--marine-navy);
  font-size:13px; font-weight:700; padding:9px 16px; border-radius:9px; cursor:pointer;
}
.btn:hover{background:var(--steel-mist);}
.btn-primary{background:var(--flame-red); color:#fff; border-color:var(--flame-red);}
.btn-primary:hover{filter:brightness(1.08);}
.btn-primary:disabled{opacity:.5; cursor:not-allowed;}

.page-wrap{max-width:1180px; margin:0 auto; padding:28px 20px 60px;}
.empty-state{
  text-align:center; padding:60px 20px; color:#7a8a97; font-size:14.5px;
  background:var(--card-bg); border-radius:16px; border:1px dashed var(--line);
}

/* ---------- Danh mục ---------- */
.cat-badge{
  display:inline-block; font-size:11px; font-weight:700; padding:3px 10px; border-radius:999px;
  background:rgba(10,61,98,.08); color:var(--deep-ocean); letter-spacing:.01em;
}
.cat-filter-bar{display:flex; gap:8px; flex-wrap:wrap; margin-bottom:22px;}
.cat-chip{
  background:var(--card-bg); border:1px solid var(--line); color:var(--marine-navy);
  font-size:13px; font-weight:600; padding:7px 15px; border-radius:999px; cursor:pointer;
  transition:background .15s, color .15s, border-color .15s;
}
.cat-chip:hover{background:var(--steel-mist);}
.cat-chip.active{background:var(--deep-ocean); color:#fff; border-color:var(--deep-ocean);}
