/* =========================================================
   Two Hommès — Manager Portal (Base + UI Upgrades)
========================================================= */

:root{
  --th-bg:#050506;
  --th-panel: rgba(255,255,255,.04);
  --th-stroke: rgba(255,255,255,.12);
  --th-text: rgba(255,255,255,.92);
  --th-muted: rgba(255,255,255,.72);

  --th-red:#b80505;
  --th-red-soft: rgba(184,5,5,.18);
  --th-red-stroke: rgba(184,5,5,.55);

  --th-gold: rgba(212,175,55,.95);
}

*{ box-sizing:border-box; }
html,body{ height:100%; }
body{
  margin:0;
  background: var(--th-bg);
  color: var(--th-text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a{ color: inherit; }

.heroGlow{
  position: fixed;
  inset: -30%;
  background:
    radial-gradient(circle at 30% 25%, rgba(184,5,5,.25) 0%, rgba(0,0,0,0) 55%),
    radial-gradient(circle at 70% 40%, rgba(212,175,55,.12) 0%, rgba(0,0,0,0) 60%),
    radial-gradient(circle at 55% 80%, rgba(184,5,5,.12) 0%, rgba(0,0,0,0) 58%);
  pointer-events:none;
  z-index:0;
  filter: blur(0px);
  opacity:.95;
}

.container{
  position: relative;
  z-index: 1;
  max-width: 980px;
  margin: 0 auto;
  padding: 18px 14px 36px;
}

.topbar{
  position: sticky;
  top:0;
  z-index: 50;
  padding: 10px 12px;
  background: linear-gradient(180deg, rgba(5,5,6,.92), rgba(5,5,6,.65));
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255,255,255,.08);
}

.brand{
  max-width: 980px;
  margin: 0 auto;
  display:flex;
  align-items:center;
  gap:12px;
}

.brand img{
  height: 30px;
  width:auto;
  display:block;
}

.badge{
  font-size:12px;
  color: rgba(255,255,255,.72);
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.03);
}

.card{
  border: 1px solid rgba(255,255,255,.10);
  background: rgba(255,255,255,.03);
  border-radius: 20px;
  padding: 16px;
  box-shadow: 0 10px 40px rgba(0,0,0,.30);
}

.h1{
  font-size: 20px;
  font-weight: 800;
  margin: 0 0 8px;
  letter-spacing: .2px;
}

.small{
  color: rgba(255,255,255,.68);
  font-size: 12px;
  line-height: 1.35;
}

.row{
  display:flex;
  align-items:center;
  gap: 10px;
}

.grid.two{
  display:grid;
  gap: 12px;
  grid-template-columns: 1fr;
}
@media(min-width:820px){
  .grid.two{ grid-template-columns: 1fr 1fr; }
}

.entry{
  border: 1px solid rgba(255,255,255,.10);
  background: rgba(0,0,0,.22);
  border-radius: 18px;
  padding: 14px;
}

.entryTop{
  display:flex;
  justify-content: space-between;
  gap: 12px;
  align-items:flex-start;
}

.entryTitle{
  font-size: 15px;
  font-weight: 800;
  margin: 0 0 2px;
  color: rgba(255,255,255,.92);
}

.kv{
  margin-top: 10px;
  color: rgba(255,255,255,.78);
  font-size: 12px;
  line-height: 1.45;
}

.actions{
  display:flex;
  gap: 10px;
  margin-top: 12px;
}

.btn{
  appearance:none;
  border: none;
  cursor:pointer;
  display:inline-flex;
  justify-content:center;
  align-items:center;
  gap:8px;

  width: 100%;
  padding: 12px 14px;
  border-radius: 16px;
  font-weight: 800;
  letter-spacing: .2px;

  color: rgba(255,255,255,.95);
  background: linear-gradient(180deg, rgba(184,5,5,.98), rgba(130,0,0,.98));
  box-shadow: 0 10px 30px rgba(184,5,5,.22);
  border: 1px solid rgba(184,5,5,.55);
}

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

.btn.secondary{
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.14);
  color: rgba(255,255,255,.90);
  box-shadow: none;
}

.pill{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding: 10px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.04);
  font-size: 12px;
  text-decoration:none;
  color: rgba(255,255,255,.84);
}

.pill.active{
  border-color: rgba(184,5,5,.70);
  background: rgba(184,5,5,.14);
  box-shadow: 0 0 0 4px rgba(184,5,5,.12);
}

.formsList{
  display:flex;
  flex-wrap: wrap;
  gap: 10px;
  padding:0;
  margin:0;
  list-style:none;
}

.toast{
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: 24px;
  z-index: 200;
  background: rgba(0,0,0,.72);
  border: 1px solid rgba(255,255,255,.12);
  color: rgba(255,255,255,.92);
  padding: 10px 14px;
  border-radius: 999px;
  opacity: 0;
  pointer-events:none;
  transition: opacity .25s ease;
}
.toast.show{ opacity: 1; }

/* =========================================================
   UI Upgrade Pack — Summary + Status + Sticky Actions
========================================================= */

.sectionTitle{
  font-weight:800;
  margin:0 0 10px;
  font-size:13px;
  letter-spacing:.25px;
  color: rgba(255,255,255,.88);
  text-transform: uppercase;
}

.metaGrid{
  display:grid;
  grid-template-columns: 1fr;
  gap:10px;
}
@media(min-width:720px){
  .metaGrid{ grid-template-columns: 1fr 1fr; }
}

.metaItem{
  padding:12px;
  border-radius:16px;
  border:1px solid rgba(255,255,255,.12);
  background: linear-gradient(180deg, rgba(255,255,255,.04), rgba(0,0,0,.18));
}

.metaLabel{
  font-size:11px;
  color: rgba(255,255,255,.62);
  letter-spacing:.25px;
  text-transform:uppercase;
  margin-bottom:6px;
}

.metaValue{
  font-size:14px;
  color: rgba(255,255,255,.92);
  font-weight:800;
  line-height:1.25;
  word-break: break-word;
}
.metaValue a{
  color: rgba(255,255,255,.92);
  text-decoration:none;
  border-bottom: 1px dashed rgba(255,255,255,.22);
}

.pillStatus{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:8px 12px;
  border-radius:999px;
  border:1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.05);
  font-size:12px;
  color: rgba(255,255,255,.86);
}

.dot{
  width:8px;height:8px;border-radius:99px;
  background: rgba(255,255,255,.45);
}
.dot.new{
  background: rgba(184,5,5,.95);
  box-shadow:0 0 0 4px rgba(184,5,5,.18);
}
.dot.done{
  background: rgba(255,255,255,.55);
}

/* =========================================================
   Clean AF Details — show all fields, still readable
========================================================= */

.kvList{
  display:flex;
  flex-direction:column;
  gap:10px;
}

/* each field row becomes a clean "card" */
.kvRow{
  display:block;
  padding:12px;
  border-radius:16px;
  border:1px solid rgba(255,255,255,.10);
  background: linear-gradient(180deg, rgba(255,255,255,.04), rgba(0,0,0,.18));
}

/* field key label */
.kvKey{
  font-size:11px;
  letter-spacing:.25px;
  text-transform:uppercase;
  color: rgba(255,255,255,.62);
  margin-bottom:6px;
}

/* field value */
.kvVal{
  font-size:13px;
  color: rgba(255,255,255,.92);
  font-weight:700;
  line-height:1.35;
  text-align:left;
  word-break: break-word;
  white-space:pre-wrap;
}

/* compact "tap to expand" for long content */
.fieldExpand{
  margin-top:10px;
  border-top:1px solid rgba(255,255,255,.10);
  padding-top:10px;
}
.fieldExpand summary{
  cursor:pointer;
  font-weight:800;
  font-size:12px;
  color: rgba(255,255,255,.85);
  outline:none;
}
.fieldExpand summary::-webkit-details-marker{ display:none; }
.fieldExpand .detailsBody{
  margin-top:10px;
  font-size:12px;
  color: rgba(255,255,255,.78);
  white-space:pre-wrap;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

/* little inline badge for value type */
.typeTag{
  display:inline-flex;
  align-items:center;
  gap:6px;
  font-size:11px;
  padding:6px 10px;
  border-radius:999px;
  border:1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.04);
  color: rgba(255,255,255,.75);
  margin-left:8px;
}

/* Sticky bottom action bar (thumb friendly) */
.stickyBar{
  position:fixed;
  left:0; right:0; bottom:0;
  z-index:99;
  padding:12px;
  background: linear-gradient(180deg, rgba(5,5,6,.10), rgba(5,5,6,.92));
  backdrop-filter: blur(10px);
  border-top:1px solid rgba(255,255,255,.10);
}
.stickyBarInner{
  max-width:980px;
  margin:0 auto;
  display:flex;
  gap:10px;
}
.stickyBar .btn{ border-radius:16px; }
.stickyPad{ height:92px; } /* prevents overlap behind sticky bar */
