:root { --primary: #4f46e5; --bg-main: #f8fafc; --text-main: #1e293b; --text-muted: #64748b; --radius: 8px; }
* { box-sizing: border-box; font-family: 'Inter', sans-serif; font-size: 11.5px; }
body { margin: 0; background: var(--bg-main); color: var(--text-main); line-height: 1.4; }
.container { max-width: 1750px; margin: 0 auto; padding: 20px; }
.layout-wrapper { display: grid; grid-template-columns: 1fr 360px; gap: 24px; align-items: start; }

.card, .section { background: #fff; border-radius: var(--radius); padding: 16px; border: 1px solid #e2e8f0; margin-bottom: 15px; }

/* Selection Grid */
.selection-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.selection-group-box { background: #f1f5f9; padding: 10px; border-radius: 6px; border: 1px solid #e2e8f0; }
.group-label { font-size: 9px; font-weight: 800; text-transform: uppercase; color: var(--primary); margin-bottom: 8px; border-bottom: 1px solid #cbd5e1; padding-bottom: 4px; }
.selection-item { display: grid; grid-template-columns: 20px 1fr; align-items: center; margin-bottom: 6px; gap: 12px; }

/* Table Logic */
table { width: 100%; border-collapse: collapse; table-layout: fixed; min-width: 1100px; margin-top: 10px; }
thead th { font-size: 9px; text-transform: uppercase; color: var(--text-muted); padding: 8px; border-bottom: 2px solid #f1f5f9; text-align: left; }
th:nth-child(1) { width: 18%; } th:nth-child(2) { width: 90px; } th:nth-child(3) { width: 85px; }
th:nth-child(4), th:nth-child(5), th:nth-child(6), th:nth-child(7) { width: 95px; }
th:nth-child(8) { width: 100px; } th:nth-child(9) { width: 140px; text-align: right; padding-right: 20px; }

tbody td { padding: 4px 6px; vertical-align: middle; }
input, select, textarea { width: 100%; padding: 6px; border: 1px solid #e2e8f0; border-radius: 4px; background: #fff; }
input:disabled { background: #f1f5f9; color: #94a3b8; cursor: not-allowed; }
.area-in { background: #f1f5f9 !important; font-weight: 600; text-align: center; }

/* Category Headers */
.section-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.header-left { display: flex; align-items: center; gap: 12px; }
.sub-room-header { display: flex; align-items: center; gap: 10px; margin-top: 15px; border-top: 1px solid #f1f5f9; padding-top: 10px; }
.sub-room-title { margin: 0; color: var(--text-muted); text-transform: uppercase; font-size: 10px; }

/* Dual Notes Layout */
.category-notes-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; margin-top: 15px; border-top: 1px solid #f1f5f9; padding-top: 10px; }
.note-half { display: flex; flex-direction: column; }
.category-notes { min-height: 60px; resize: vertical; margin-top: 5px; }
.client-notes { border-left: 3px solid var(--primary); background: #fcfcfc; }
.internal-notes { border-left: 3px solid #ef4444; background: #fffafa; }

/* Sidebar */
.sidebar { position: sticky; top: 20px; }
.summary { background: #1e293b; color: #fff; padding: 20px; border-radius: var(--radius) var(--radius) 0 0; }
.summary * { color: #fff; }
.summary .row { display: flex; justify-content: space-between; margin-bottom: 12px; align-items: center; }
.summary input { width: 70px; color: #000; text-align: right; }
.summary .total { font-size: 16px; font-weight: 800; border-top: 1px solid #334155; padding-top: 12px; margin-top: 12px; }
.sidebar-notes { background: #fff; padding: 15px; border: 1px solid #e2e8f0; border-top: none; border-radius: 0 0 var(--radius) var(--radius); }

.label-tiny { font-size: 9px; font-weight: 700; text-transform: uppercase; color: var(--text-muted); display: block; margin-bottom: 2px; }
.btn { background: var(--primary); color: #fff; border: none; padding: 10px 16px; border-radius: 6px; font-weight: 600; cursor: pointer; }
.btn-outline-xs { font-size: 9px; padding: 2px 6px; border: 1px solid #d1d5db; border-radius: 4px; background: #fff; cursor: pointer; color: var(--primary); font-weight: 600; }
.icon-btn { background: none; border: none; color: #ef4444; cursor: pointer; font-size: 14px; }

/* Printing Logic */
@media print {
  .no-print, .internal-notes, .note-half:last-child { display: none !important; }
  .category-notes-grid { display: block; }
  .client-notes { border: none !important; padding: 0 !important; background: transparent !important; }
  .layout-wrapper { display: block; }
  .sidebar { position: static; width: 100%; margin-top: 20px; }
  .summary { color: #000 !important; background: #fff !important; border: 1px solid #eee; }
  .summary * { color: #000 !important; }
  input, textarea { border: none !important; padding: 0 !important; background: transparent !important; }
}

.page-title {
  text-align: center;
  font-size: 56px;
  font-weight: 800;
  margin: 20px 0 30px;
}



/* ===============================
   EXPAND / COLLAPSE TOGGLE
================================ */

.toggle{
    cursor:pointer;
    font-size:18px;          /* bigger icon */
    line-height:1;
    width:22px;              /* larger click area */
    height:22px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    border-radius:6px;
    color:#374151;
    user-select:none;
}

.toggle:hover{
    background:#e5e7eb;      /* subtle hover affordance */
    color:#111827;
}

.section.collapsed .toggle{
    font-size:18px;          /* keep consistent when collapsed */
}


.section-header-left{
    gap:10px; /* was 8px */
}
