.tt-body {
  background: #f3f6fb;
  margin: 0;
  font-family: Inter, Segoe UI, Arial, Helvetica, sans-serif;
  color: #0f172a;
}

.tt-shell {
  width: min(98%, 1680px);
  margin: 14px auto 28px;
}

.tt-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
}

.tt-title .tt-h1 {
  font-size: 28px;
  font-weight: 700;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  letter-spacing: -0.02em;
}

.tt-title .tt-sub {
  margin-top: 6px;
  color: #64748b;
  font-size: 12px;
}

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

.tt-user-badge {
  border: 1px solid #d9e2ef;
  background: #fff;
  padding: 9px 12px;
  border-radius: 10px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.05);
}

.tt-user-name { font-weight: 700; }
.tt-user-meta { font-size: 12px; color: #64748b; }
.tt-user-meta .dot { margin: 0 6px; }

.tt-main { display: grid; gap: 16px; }

/* Section (Excel-like sheet block) */
.tt-section {
  border: 1px solid #d6dfeb;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
}

.tt-section-h {
  margin: 0;
  padding: 12px 14px;
  font-size: 15px;
  font-weight: 700;
  border-bottom: 1px solid #e2e8f0;
  background: linear-gradient(180deg, #f8fbff 0%, #f2f6fc 100%);
}

.tt-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(180px, 1fr));
  gap: 12px;
  padding: 14px;
}

.tt-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 12px 14px;
  padding: 14px;
  border-bottom: 1px solid #e8edf5;
}

.tt-toolbar .tt-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 190px;
  flex: 0 1 240px;
}

.tt-toolbar .tt-field select.tt-input,
.tt-toolbar .tt-field input.tt-input {
  min-height: 40px;
}

.tt-field .tt-label {
  font-size: 11px;
  color: #475569;
  margin-bottom: 0;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.tt-input {
  width: 100%;
  border: 1px solid #cdd7e5;
  border-radius: 8px;
  padding: 8px 10px;
  font-size: 13px;
  background: #fff;
  outline: none;
  box-sizing: border-box;
}

.tt-input:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.tt-input-num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.tt-btn {
  border: 1px solid #cbd5e1;
  background: #fff;
  border-radius: 8px;
  padding: 9px 14px;
  min-height: 40px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
}

.tt-btn-primary {
  background: #2563eb;
  border-color: #2563eb;
  color: #fff;
}

.tt-btn:hover { filter: brightness(0.99); }
.tt-btn:disabled { opacity: .6; cursor: not-allowed; }

.tt-spacer { flex: 1; }
.tt-tabs { display: inline-flex; gap: 8px; flex-wrap: wrap; }

/* Excel grid table */
.tt-table-wrap {
  overflow: auto;
  margin-top: 8px;
}

.tt-table {
  width: 100%;
  min-width: 1020px;
  border-collapse: collapse;
  table-layout: fixed;
}

.tt-table thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: #edf2f9;
  color: #374151;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .02em;
  font-weight: 700;
  border: 1px solid #dbe4ef;
  padding: 8px 9px;
  text-align: left;
}

.tt-table td {
  border: 1px solid #e7edf5;
  padding: 4px 6px;
  vertical-align: middle;
  background: #fff;
  line-height: 1.35;
}

.tt-table td .tt-input,
.tt-table td select.tt-input {
  border: 1px solid transparent;
  border-radius: 6px;
  padding: 7px 8px;
  min-height: 34px;
  box-shadow: none;
}

.tt-table td .tt-input:focus,
.tt-table td select.tt-input:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.12);
}

.tt-cell-actions { text-align: center; }

.tt-icon-btn {
  border: none;
  background: transparent;
  font-size: 14px;
  padding: 6px 8px;
  cursor: pointer;
}

.tt-total-label {
  text-align: right;
  font-weight: 700;
  padding-right: 12px;
}

.tt-total,
.tt-right {
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
}

.tt-alert {
  margin: 10px 14px 12px;
  border-radius: 8px;
  padding: 9px 12px;
  font-size: 12px;
  border: 1px solid;
}

.tt-alert-ok {
  color: #065f46;
  background: #ecfdf5;
  border-color: #a7f3d0;
}

.tt-alert-error {
  color: #7f1d1d;
  background: #fef2f2;
  border-color: #fecaca;
}

.tt-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  flex-wrap: wrap;
}

.tt-hint {
  font-size: 11px;
  color: #6b7280;
}

.tt-emp-name { font-weight: 700; }
.tt-emp-sub { font-size: 11px; color: #6b7280; }

.tt-table tbody tr:hover td {
  background: #fbfdff;
}

.tt-table tbody tr[title] td {
  cursor: pointer;
}

.tt-btn-ghost {
  background: #f8fafc;
}

/* App tab bar (single-page sections) */
.tt-app-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 10px 12px;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  margin-bottom: 14px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
}

.tt-app-tab {
  border: none;
  background: transparent;
  color: #475569;
  font-size: 13px;
  font-weight: 600;
  padding: 10px 16px;
  border-radius: 10px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: background 0.15s, color 0.15s;
}

.tt-app-tab:hover {
  background: #f1f5f9;
  color: #1e293b;
}

.tt-app-tab-active {
  background: linear-gradient(135deg, #6366f1 0%, #7c3aed 100%);
  color: #fff !important;
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.35);
}

.tt-app-tab-active:hover {
  filter: brightness(1.05);
  color: #6f62c3 !important
}

.tt-section-desc {
  margin: 0;
  padding: 0 14px 12px;
  font-size: 13px;
  color: #64748b;
  line-height: 1.45;
  border-bottom: 1px solid #eef2f7;
}

.tt-field-grow {
  flex: 1 1 280px;
  min-width: 200px;
}

.tt-day-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  padding: 8px 12px;
  background: #eef2ff;
  border: 1px solid #c7d2fe;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  color: #3730a3;
}

.tt-day-meta-label {
  text-transform: uppercase;
  font-size: 10px;
  letter-spacing: 0.04em;
  color: #6366f1;
}

.tt-day-meta-sub {
  font-weight: 500;
  color: #64748b;
}

.tt-cell-text {
  padding: 6px 8px;
  min-height: 34px;
  display: flex;
  align-items: center;
}

.tt-status-badge {
  display: inline-block;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.2;
}

.tt-status-short {
  background: #fee2e2;
  color: #991b1b;
}

.tt-status-extra {
  background: #ffedd5;
  color: #9a3412;
}

.tt-status-complete {
  background: #dcfce7;
  color: #166534;
}

@media (max-width: 900px) {
  .tt-grid-2 { grid-template-columns: 1fr; }
  .tt-top { flex-direction: column; align-items: flex-start; }
  .tt-toolbar .tt-field {
    min-width: 100%;
    flex: 1 1 100%;
  }
  .tt-table {
    min-width: 860px;
  }
}

