/* /www/wwwroot/minio.vpsttt.com/layout.css */
:root{
  --bg:#f6f7fb;
  --card:#ffffff;
  --text:#0f172a;
  --muted:#64748b;
  --line:#e5e7eb;
  --primary:#2563eb;
  --primary2:#1d4ed8;
  --danger:#b91c1c;

  /* dashboard feel */
  --shadow: 0 8px 24px rgba(2, 6, 23, .06);
  --radius: 16px;

  /* MAX content width on very wide screens (still "full page") */
  --w: 1600px;

  --font: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji","Segoe UI Emoji";
}

*{box-sizing:border-box}
html,body{height:100%}

body{
  margin:0;
  font-family:var(--font);
  color:var(--text);
  background:
    radial-gradient(1200px 600px at 20% -10%, #dbeafe 0%, transparent 50%),
    radial-gradient(1000px 600px at 80% 0%, #e0e7ff 0%, transparent 45%),
    var(--bg);
}

/* links */
a{color:var(--primary); text-decoration:none}
a:hover{color:var(--primary2); text-decoration:underline}

/* ===== Layout container: full-width but capped ===== */
.container{
  width: min(100%, var(--w));
  margin: 0 auto;
  padding: 18px 18px;
}
@media (min-width: 1200px){
  .container{ padding: 20px 24px; }
}

/* ===== Card ===== */
.card{
  background:var(--card);
  border:1px solid var(--line);
  border-radius:var(--radius);
  box-shadow:var(--shadow);
  overflow: hidden; /* giúp topbar sticky + radius đẹp */
}

/* ===== Topbar (dashboard style) ===== */
.topbar{
  position: sticky;
  top: 0;
  z-index: 50;

  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 12px;

  padding: 12px 16px;

  /* glassy header */
  background: rgba(255,255,255,.78);
  backdrop-filter: blur(10px);
  border-bottom:1px solid var(--line);
}

/* Brand */
.brand{display:flex; align-items:center; gap:12px; min-width: 0;}
.brand img{height:52px; width:auto; flex: 0 0 auto;}
@media (max-width: 520px){
  .brand img{height:40px;}
}
.brand .title{
  font-weight:900;
  letter-spacing:.2px;
  line-height: 1.1;
  white-space: nowrap;
}
.brand .sub{
  font-size:12px;
  color:var(--muted);
  margin-top:2px;
  line-height: 1.2;
  white-space: nowrap;
}

/* Responsive brand text wrap if needed */
@media (max-width: 720px){
  .brand .title, .brand .sub{white-space: normal;}
}

/* Nav area */
.nav{
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap:wrap;
  justify-content:flex-end;
}
@media (max-width: 720px){
  .topbar{flex-direction:column; align-items:flex-start;}
  .nav{width:100%; justify-content:flex-start;}
}

/* Pills */
.pill{
  display:inline-flex; align-items:center; gap:8px;
  padding:8px 10px;
  border:1px solid var(--line);
  border-radius:999px;
  background:#fff;
  color:var(--text);
}
.pill small{color:var(--muted)}

/* Buttons */
.btn{
  display:inline-flex; align-items:center; justify-content:center;
  padding:10px 12px;
  border-radius:12px;
  border:1px solid var(--line);
  background:#fff;
  cursor:pointer;
  font-weight:800;
  user-select:none;
}
.btn:hover{border-color:#cbd5e1}
.btn.primary{background:var(--primary); color:#fff; border-color:var(--primary)}
.btn.primary:hover{background:var(--primary2); border-color:var(--primary2)}
.btn.danger{background:var(--danger); color:#fff; border-color:var(--danger)}
.btn.danger:hover{filter:brightness(.95)}
.btn:disabled{opacity:.6; cursor:not-allowed}

/* Main content */
.main{padding:16px}
@media (min-width: 1200px){
  .main{padding:20px}
}

.h1{font-size:22px; font-weight:900; margin:0 0 8px}
.muted{color:var(--muted)}
.hr{height:1px; background:var(--line); margin:14px 0}

/* Forms */
.form{
  display:grid;
  gap:12px;
  max-width:520px; /* rộng hơn chút cho desktop */
}
.label{font-weight:900; font-size:13px}
.input{
  width:100%;
  padding:11px 12px;
  border:1px solid var(--line);
  border-radius:12px;
  outline:none;
  background:#fff;
}
.input:focus{
  border-color:#93c5fd;
  box-shadow:0 0 0 4px rgba(59,130,246,.15)
}

/* Flash messages */
.flash{
  padding:10px 12px;
  border-radius:12px;
  border:1px solid var(--line);
  background:#fff;
}
.flash.ok{border-color:#86efac; background:#f0fdf4}
.flash.err{border-color:#fecaca; background:#fef2f2}

/* Footer */
.footer{
  padding:14px 16px;
  display:flex;
  justify-content:space-between;
  align-items:center;
  color:var(--muted);
  font-size:12px;
  border-top:1px solid var(--line);
}
@media (max-width: 520px){
  .footer{flex-direction:column; align-items:flex-start; gap:6px;}
}

/* ===== Optional helpers for dashboard tiles/grids (if you use them) ===== */
.grid-actions{
  display:grid;
  gap:14px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
@media (max-width: 980px){
  .grid-actions{grid-template-columns: repeat(2, minmax(0, 1fr));}
}
@media (max-width: 640px){
  .grid-actions{grid-template-columns: 1fr;}
}

.tile{
  background:#fff;
  border:1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 6px 18px rgba(2,6,23,.05);
  padding:14px;
}
.tile .t{font-weight:900; margin:0 0 6px}
.tile .d{margin:0 0 12px; color:var(--muted); line-height:1.35}
