/* ============================================================
   COC CONNECT — Global Styles
   ============================================================ */

*, *::before, *::after{
  box-sizing: border-box;
}

html, body{
  margin: 0;
  padding: 0;
}

body{
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  color: #111b21;
  background: #efeae2;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img{ max-width: 100%; height: auto; display: block; }
a{ color: #128c7e; text-decoration: none; }
a:hover{ text-decoration: underline; }

button, input, select, textarea{ font-family: inherit; font-size: inherit; }
button{ cursor: pointer; }

/* ---------- Card ---------- */
.card{
  background: #fff;
  border-radius: 14px;
  border: 1px solid #e9edef;
  padding: 16px;
  box-shadow: 0 1px 3px rgba(0,0,0,.04);
  margin-bottom: 14px;
}
.card h1, .card h2, .card h3{
  margin: 0 0 10px;
  color: #111b21;
}
.card h1{ font-size: 20px; }
.card h2{ font-size: 17px; }
.card h3{ font-size: 15px; }
.card.narrow{ max-width: 420px; margin-left: auto; margin-right: auto; }
.card .muted{ color: #667781; font-size: 13px; }

/* ---------- Grid ---------- */
.grid{
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 14px;
  margin-bottom: 14px;
}

/* ---------- Forms ---------- */
label{
  display: block;
  font-size: 12.5px;
  font-weight: 600;
  color: #667781;
  margin: 10px 0 5px;
  text-transform: uppercase;
  letter-spacing: .03em;
}
input[type=text],
input[type=tel],
input[type=email],
input[type=password],
input[type=number],
input[type=date],
input[type=datetime-local],
input[type=file],
select,
textarea{
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #e9edef;
  border-radius: 10px;
  font-size: 14px;
  background: #f7f8fa;
  color: #111b21;
  outline: none;
  transition: border .15s, background .15s, box-shadow .15s;
}
input:focus,
select:focus,
textarea:focus{
  border-color: #25d366;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(37,211,102,.12);
}
input:disabled{ background: #eef0f2; color: #98a2a8; cursor: not-allowed; }
textarea{ resize: vertical; min-height: 80px; }

button:not(.nav-avatar):not(.coc-composer__btn):not(.nm-close){
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 18px;
  background: #25d366;
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  margin-top: 10px;
  transition: background .15s, transform .1s;
}
button:not(.nav-avatar):not(.coc-composer__btn):not(.nm-close):hover{
  background: #128c7e;
}
button:not(.nav-avatar):not(.coc-composer__btn):not(.nm-close):active{
  transform: scale(.98);
}

/* ---------- Alerts ---------- */
.alert{
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 13.5px;
  margin-bottom: 14px;
}
.alert.error,
.alert.danger{ background: #fde8e8; color: #b42318; border-left: 4px solid #f04438; }
.alert.success{ background: #e7f8ee; color: #128c7e; border-left: 4px solid #25d366; }
.alert.info{ background: #e0f2fe; color: #0369a1; border-left: 4px solid #3b82f6; }
.alert.warning{ background: #fff4d6; color: #8a6d00; border-left: 4px solid #f59e0b; }

/* ---------- Buttons (link-styled) ---------- */
.btn{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 16px;
  background: #25d366;
  color: #fff !important;
  border-radius: 10px;
  font-weight: 600;
  font-size: 14px;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: background .15s;
}
.btn:hover{ background: #128c7e; text-decoration: none; }
.btn.ghost{ background: #f0f2f5; color: #111b21 !important; }
.btn.ghost:hover{ background: #e4e6eb; }
.btn.danger{ background: #f04438; }
.btn.danger:hover{ background: #b42318; }
.btn.small{ padding: 6px 12px; font-size: 12.5px; }

/* ---------- Pills ---------- */
.pill{
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  text-transform: capitalize;
  letter-spacing: .02em;
}
.pill.pending{ background: #fff4d6; color: #8a6d00; }
.pill.done{ background: #e7f8ee; color: #128c7e; }
.pill.active{ background: #e7f8ee; color: #128c7e; }
.pill.inactive{ background: #f0f2f5; color: #667781; }
.pill.blocked{ background: #fde8e8; color: #b42318; }

/* ---------- Tables ---------- */
table.data{
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0,0,0,.04);
}
table.data th{
  background: #128c7e;
  color: #fff;
  padding: 10px 12px;
  text-align: left;
  font-size: 12.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .03em;
}
table.data td{
  padding: 10px 12px;
  border-bottom: 1px solid #e9edef;
  font-size: 13.5px;
}
table.data tr:last-child td{ border-bottom: none; }
table.data tr:hover td{ background: #f5f6f6; }

/* ---------- Utilities ---------- */
.muted{ color: #667781; }
.small{ font-size: 12.5px; }
.center{ text-align: center; }
.right{ text-align: right; }
.mt-0{ margin-top: 0 !important; }
.mt-1{ margin-top: 8px; }
.mt-2{ margin-top: 16px; }
.mb-0{ margin-bottom: 0 !important; }
.mb-1{ margin-bottom: 8px; }
.mb-2{ margin-bottom: 16px; }
.flex{ display: flex; }
.flex-between{ display: flex; justify-content: space-between; align-items: center; }
.gap-1{ gap: 8px; }
.gap-2{ gap: 16px; }
.hidden{ display: none !important; }

/* ---------- Divider ---------- */
hr{
  border: none;
  height: 1px;
  background: #e9edef;
  margin: 18px 0;
}

/* ---------- Scrollbar (webkit) ---------- */
::-webkit-scrollbar{ width: 8px; height: 8px; }
::-webkit-scrollbar-track{ background: transparent; }
::-webkit-scrollbar-thumb{ background: #ced4d8; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover{ background: #a8b0b5; }

/* ---------- Print ---------- */
@media print{
  .topbar, .coc-footer, .nav-dropdown, .nm-overlay{ display: none !important; }
  body{ background: #fff; }
}