@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&family=Roboto:wght@400;500;700&family=Noto+Sans+Hebrew:wght@400;500;700&family=Noto+Kufi+Arabic:wght@400;500;700&family=Noto+Sans+JP:wght@400;500;700&display=swap');

:root{
  --bg:#f6f8fb;
  --panel:#ffffff;
  --line:#e8edf5;
  --text:#1e293b;
  --muted:#64748b;
  --blue:#2c7df0;
  --blue-dark:#1f6ad7;
  --green:#14b86a;
  --green-soft:#e9fbf1;
  --orange:#f59e0b;
  --red:#ef4444;
  --purple:#7c3aed;
  --teal:#0ea5a8;
  --shadow:0 12px 32px rgba(15,23,42,.07);
  --radius:18px;
}
*{box-sizing:border-box}
html,body{margin:0;padding:0;font-family:Poppins,Roboto,'Noto Sans Hebrew','Noto Kufi Arabic','Noto Sans JP',sans-serif;background:var(--bg);color:var(--text);font-size:14px}
a{text-decoration:none;color:inherit}
button,input,select,textarea{font:inherit}
.auth-body{min-height:100vh;background:
linear-gradient(135deg,#edf5ff 0%,#f9fbff 35%,#f5fff9 100%);
display:flex;align-items:center;justify-content:center;padding:24px}
.auth-shell{width:min(1120px,100%)}
.auth-brand{display:flex;align-items:center;gap:16px;margin-bottom:18px}
.brand-mark{width:42px;height:42px;border-radius:14px;background:linear-gradient(135deg,#2c7df0,#7c3aed);color:#fff;display:grid;place-items:center;font-weight:800;box-shadow:var(--shadow)}
.brand-title{font-size:22px;font-weight:800}
.brand-subtitle{color:var(--muted);font-size:13px}
.auth-card{display:grid;grid-template-columns:1.15fr .85fr;background:rgba(255,255,255,.84);backdrop-filter:blur(10px);border:1px solid rgba(255,255,255,.65);border-radius:28px;box-shadow:0 30px 60px rgba(15,23,42,.09);overflow:hidden}
.auth-card-side{padding:42px;background:linear-gradient(145deg,#f7fbff,#eef7ff)}
.auth-card-side h1{font-size:40px;line-height:1.08;margin:14px 0}
.auth-card-side p{color:var(--muted);font-size:15px;max-width:540px}
.auth-card-form{padding:42px;background:#fff}
.auth-card-form h2{margin:0 0 6px}
.auth-points{padding-left:18px;color:#334155;line-height:1.9}
.mini-chip{display:inline-flex;padding:8px 12px;border-radius:999px;background:#fff;border:1px solid #dbeafe;color:#2563eb;font-size:12px;font-weight:700}
.helper-text{font-size:12px;color:var(--muted);margin-top:14px}
.app-shell{display:grid;grid-template-columns:290px 1fr;min-height:100vh;align-items:start}
.sidebar{background:#f7faf8;border-right:1px solid var(--line);padding:18px;display:flex;flex-direction:column;gap:20px;position:sticky;top:0;height:100vh;height:100dvh;align-self:start;overflow-y:auto;overflow-x:hidden;scrollbar-width:thin}

.sidebar::-webkit-scrollbar{width:8px}
.sidebar::-webkit-scrollbar-thumb{background:#d7e0eb;border-radius:999px}
.sidebar::-webkit-scrollbar-track{background:transparent}
.sidebar-top{display:flex;align-items:center;justify-content:space-between}
.brand{display:flex;align-items:center;gap:12px}
.sidebar-section-label{font-size:12px;text-transform:uppercase;letter-spacing:.08em;color:#94a3b8;font-weight:700;padding:0 8px}
.sidebar-nav{display:flex;flex-direction:column;gap:6px}
.nav-item{padding:13px 14px;border-radius:14px;color:#334155;font-weight:600}
.nav-item:hover{background:#edf4ff}
.nav-item.active{background:#dff1e7;color:#0f5132}
.sidebar-user{margin-top:auto;background:#fff;border:1px solid var(--line);border-radius:18px;padding:14px;display:flex;align-items:center;gap:12px;box-shadow:var(--shadow)}
.sidebar-user .avatar{width:42px;height:42px;border-radius:14px;background:#e8f0ff;color:#2563eb;display:grid;place-items:center;font-weight:800}
.sidebar-user-name{font-weight:700}
.sidebar-user-role{font-size:12px;color:var(--muted);text-transform:capitalize}
.main-wrap{display:flex;flex-direction:column;min-width:0}
.topbar{display:flex;align-items:center;justify-content:space-between;padding:18px 24px;border-bottom:1px solid var(--line);background:rgba(246,248,251,.84);backdrop-filter:blur(10px);position:sticky;top:0;z-index:10}
.topbar-left{display:flex;align-items:center;gap:14px}
.topbar h1{font-size:18px;margin:0 0 2px;font-weight:600;letter-spacing:-.01em}
.topbar-right{display:flex;gap:12px;align-items:center}
.content-area{padding:24px}
.grid{display:grid;gap:18px}
.grid-2{grid-template-columns:repeat(2,minmax(0,1fr))}
.grid-3{grid-template-columns:repeat(3,minmax(0,1fr))}
.grid-4{grid-template-columns:repeat(4,minmax(0,1fr))}
.card,.panel{background:var(--panel);border:1px solid var(--line);border-radius:22px;box-shadow:var(--shadow)}
.card{padding:20px}
.kpi-card .kpi-label{font-size:13px;color:var(--muted);font-weight:600}
.kpi-card .kpi-value{font-size:34px;font-weight:800;margin-top:8px}
.kpi-card .kpi-sub{font-size:12px;color:var(--muted);margin-top:6px}
.section-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:16px}
.section-head h3,.section-head h2{margin:0}
.table-wrap{overflow-x:auto;overflow-y:visible}
.table{width:100%;border-collapse:separate;border-spacing:0}
.table th,.table td{padding:14px 14px;border-bottom:1px solid var(--line);text-align:left;vertical-align:top;white-space:nowrap}
.table th{font-size:12px;text-transform:uppercase;letter-spacing:.04em;color:#64748b;background:#fbfcfe}
.table tr:hover td{background:#fcfdff}
.table td.wrap{white-space:normal}
.list-stack{display:flex;flex-direction:column;gap:12px}
.list-item{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px;border:1px solid var(--line);border-radius:16px;background:#fff}
.progress{height:10px;background:#eef2f7;border-radius:999px;overflow:hidden}
.progress>span{display:block;height:100%;background:linear-gradient(90deg,#2c7df0,#31c48d);border-radius:999px}
.badge{display:inline-flex;align-items:center;padding:7px 11px;border-radius:999px;font-size:12px;font-weight:700}
.badge-success{background:#eafbf2;color:#157347}
.badge-info{background:#eaf2ff;color:#1d4ed8}
.badge-warning{background:#fff5e7;color:#b45309}
.badge-danger{background:#fff1f2;color:#be123c}
.badge-muted{background:#f1f5f9;color:#475569}
.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  border:1px solid #cfd8e3;
  border-radius:8px;
  padding:9px 14px;
  font-weight:500;
  font-size:13px;
  line-height:1.2;
  cursor:pointer;
  background:#fff;
  color:#334155;
  box-shadow:none;
}
.btn-primary{
  background:#0f6fff;
  border-color:#0f6fff;
  color:#fff;
}
.btn-primary:hover{background:#0b63e7;border-color:#0b63e7}
.btn-secondary{
  background:#fff;
  border-color:#cfd8e3;
  color:#334155;
}
.btn-ghost{
  background:#f4f8ff;
  border-color:#d7e5fb;
  color:#334155;
}
.btn-danger{
  background:#fff;
  border-color:#f1c9cf;
  color:#b91c1c;
}
.btn-xs{
  padding:7px 10px;
  font-size:11px;
  border-radius:8px;
}
.btn-block{width:100%}
.icon-btn{width:38px;height:38px;border-radius:10px;border:1px solid var(--line);background:#fff;cursor:pointer}
.mobile-only{display:none}
.search-box{display:flex;align-items:center;gap:8px;border:1px solid var(--line);background:#fff;padding:10px 12px;border-radius:10px;min-width:280px}
.search-box input{border:none;outline:none;background:transparent;width:100%}
.input,.textarea,.select{width:100%;padding:13px 14px;border-radius:10px;border:1px solid #d7e0eb;background:#fff;outline:none}
.input:focus,.textarea:focus,.select:focus{border-color:#9ac1ff;box-shadow:0 0 0 4px rgba(44,125,240,.09)}
.textarea{min-height:120px;resize:vertical}
.field-label{display:block;font-weight:700;font-size:13px;margin:12px 0 8px}
.form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}
.form-grid-3{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px}
.form-actions{display:flex;gap:10px;flex-wrap:wrap;margin-top:18px}
.alert{padding:14px 16px;border-radius:16px;margin-bottom:14px;font-weight:600;border:1px solid transparent}
.alert-success{background:#eafbf2;color:#157347;border-color:#c8efd7}
.alert-error{background:#fff1f2;color:#be123c;border-color:#fecdd3}
.alert-info{background:#edf5ff;color:#1d4ed8;border-color:#dbeafe}
.muted{color:var(--muted)}
.metric-chip{padding:8px 12px;border-radius:999px;background:#f8fafc;color:#334155;border:1px solid var(--line);font-size:12px;font-weight:700}
.toolbar{display:flex;gap:12px;align-items:center;justify-content:space-between;margin-bottom:16px;flex-wrap:wrap}
.toolbar .left,.toolbar .right{display:flex;gap:10px;align-items:center;flex-wrap:wrap}
.split{display:grid;grid-template-columns:1.6fr 1fr;gap:18px}
.calendar-list{display:flex;flex-direction:column;gap:12px}
.calendar-day{padding:16px;border:1px solid var(--line);border-radius:18px;background:#fff}
.calendar-day h4{margin:0 0 10px;font-size:16px}
.empty-state{padding:38px 20px;text-align:center;color:var(--muted)}
.link-row{display:flex;gap:10px;flex-wrap:wrap}
.quick-notes{min-height:120px}

input[type="color"].color-input{
  width:100%;
  height:54px;
  padding:6px;
  border-radius:10px;
  border:1px solid #d7e0eb;
  background:#fff;
  cursor:pointer;
  appearance:none;
  -webkit-appearance:none;
}
input[type="color"].color-input::-webkit-color-swatch-wrapper{
  padding:0;
}
input[type="color"].color-input::-webkit-color-swatch{
  border:none;
  border-radius:8px;
}
input[type="color"].color-input::-moz-color-swatch{
  border:none;
  border-radius:8px;
}
input[type="color"].color-input:focus{
  border-color:#9ac1ff;
  box-shadow:0 0 0 4px rgba(44,125,240,.09);
}

.projects-inline-toolbar{
  display:flex;
  align-items:center;
  gap:12px;
  margin-bottom:12px;
  flex-wrap:wrap;
}
.projects-inline-toolbar > .btn{
  flex:0 0 auto;
}
.projects-search-toolbar{
  display:flex;
  align-items:center;
  gap:8px;
  margin:0;
  flex:1 1 520px;
  flex-wrap:nowrap;
}
.projects-search-wrap{
  min-width:0;
  max-width:520px;
  flex:1 1 auto;
  display:flex;
  align-items:center;
  gap:10px;
  background:#fff;
  border:1px solid #d7e0eb;
  border-radius:10px;
  padding:0 12px;
  height:40px;
}
.projects-search-wrap input{
  border:none;
  outline:none;
  background:transparent;
  width:100%;
  font-size:13px;
  color:#1f2937;
}
.projects-search-icon{
  color:#748196;
  font-size:14px;
  line-height:1;
}
.projects-search-actions{
  display:flex;
  align-items:center;
  gap:8px;
  flex:0 0 auto;
}

.project-grid-card{
  padding:12px 12px 14px;
  border-radius:18px;
  overflow:visible;
}
.project-grid-wrap{
  overflow-x:auto;
  overflow-y:visible;
  padding-bottom:2px;
  position:relative;
}
.project-grid-table{min-width:980px;border-collapse:separate;border-spacing:0;font-size:12px}
.project-grid-table thead th{padding:10px 14px;background:#fbfcff;color:#5b677a;font-size:10.5px;font-weight:600;letter-spacing:.01em;text-transform:none;border-top:1px solid var(--line);border-bottom:1px solid var(--line);border-right:1px solid var(--line)}
.project-grid-table thead th:first-child{border-left:1px solid var(--line);border-top-left-radius:12px}
.project-grid-table thead th:last-child{border-top-right-radius:12px}
.project-grid-table tbody td{padding:0;border-bottom:1px solid var(--line);border-right:1px solid var(--line);vertical-align:middle;background:#fff;font-size:12px}
.project-grid-table tbody tr td:first-child{border-left:5px solid var(--project-accent,#2c7df0)}
.project-grid-table tbody tr:last-child td:first-child{border-bottom-left-radius:12px}
.project-grid-table tbody tr:last-child td:last-child{border-bottom-right-radius:12px}
.project-grid-table tbody tr:hover td{background:#fcfdff}
.project-grid-table .project-col-check,.project-grid-table .project-cell-check{width:44px;min-width:44px;text-align:center}
.project-grid-table .project-col-actions,.project-grid-table .project-cell-actions{width:64px;min-width:64px;text-align:center}
.project-grid-table .project-col-owner{width:140px;min-width:140px}
.project-grid-table .project-col-status,.project-grid-table .project-col-priority{width:170px;min-width:170px}
.project-grid-table .project-col-progress{width:170px;min-width:170px}
.project-grid-table .project-col-target{width:120px;min-width:120px}
.project-grid-table .project-col-tasks{width:72px;min-width:72px;text-align:center}
.project-grid-table .project-cell-name,.project-grid-table .project-cell-owner,.project-grid-table .project-cell-status,.project-grid-table .project-cell-priority,.project-grid-table .project-cell-progress,.project-grid-table .project-cell-target,.project-grid-table .project-cell-tasks,.project-grid-table .project-cell-actions{padding:10px 14px}
.project-grid-table .project-cell-tasks{text-align:center;font-weight:600;color:#334155}
.project-name-stack{display:flex;flex-direction:column;gap:3px;min-width:0}
.project-name-link{font-size:12px;font-weight:600;color:#1f2937;display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.project-name-link:hover{color:#1d4ed8}
.project-meta-line{font-size:10.5px;color:#7b8796;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.project-check{display:inline-block;width:20px;height:20px;border-radius:4px;border:1px solid #cfd7e3;background:#fff;vertical-align:middle}
.project-check.ghost{background:#f8fafc}
.project-solid-badge{display:flex;align-items:center;justify-content:center;min-height:34px;padding:7px 10px;border-radius:0;font-size:11px;font-weight:700;color:#fff;line-height:1.2}
.project-solid-badge.badge-success{background:#10c56f}
.project-solid-badge.badge-info{background:#2f6fda}
.project-solid-badge.badge-warning{background:#f4a63a}
.project-solid-badge.badge-danger{background:#d45457}
.project-solid-badge.badge-muted{background:#8b6c63}
.project-progress-inline{display:flex;align-items:center;gap:10px}
.project-progress-bar{flex:1;height:8px;background:#eef2f7}
.project-progress-bar>span{background:linear-gradient(90deg,var(--project-accent,#2c7df0),#31c48d)}
.project-progress-text{font-size:10.5px;font-weight:700;color:#64748b;min-width:34px;text-align:right}

.project-cell-actions{
  position:relative;
  overflow:visible !important;
}
.row-actions-menu{
  position:relative;
  display:inline-block;
}
.row-actions-menu summary{list-style:none}
.row-actions-menu summary::-webkit-details-marker{display:none}
.row-actions-toggle{width:34px;height:34px;border:1px solid var(--line);border-radius:8px;background:#fff;display:inline-flex;align-items:center;justify-content:center;cursor:pointer;color:#64748b;font-weight:800;line-height:1}
.row-actions-menu[open] .row-actions-toggle{background:#f8fbff;border-color:#cfe0ff;color:#1d4ed8}
.row-actions-dropdown{
  position:absolute;
  right:0;
  top:40px;
  min-width:132px;
  background:#fff;
  border:1px solid var(--line);
  border-radius:12px;
  box-shadow:0 16px 32px rgba(15,23,42,.12);
  padding:8px;
  z-index:9999;
  display:flex;
  flex-direction:column;
  gap:4px;
}
.row-actions-dropdown a,.row-actions-dropdown button{display:flex;width:100%;align-items:center;justify-content:flex-start;padding:9px 10px;border-radius:8px;border:none;background:#fff;color:#334155;font:inherit;font-size:12px;font-weight:500;cursor:pointer;text-align:left}
.row-actions-dropdown a:hover,.row-actions-dropdown button:hover{background:#f8fafc}
.project-detail-table tbody tr:nth-last-child(-n+2) .row-actions-dropdown{
  top:auto;
  bottom:40px;
}

.project-view-hero{padding:18px 18px 20px}
.project-view-topline{display:flex;align-items:center;gap:8px;margin-bottom:10px;font-size:11px;color:#7b8796}
.project-view-dot{width:9px;height:9px;border-radius:999px;background:var(--project-accent,#2c7df0);display:inline-block}
.project-view-code{font-weight:700;color:#475569}
.project-view-sep{opacity:.7}
.project-view-title{font-size:22px;line-height:1.15}
.project-view-owner{font-size:12px}
.project-view-desc{font-size:12px;line-height:1.65;color:#475569;margin-bottom:14px}
.project-summary-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}
.project-summary-card{border:1px solid var(--line);border-radius:16px;padding:12px;background:#fff}
.project-summary-label{font-size:10.5px;font-weight:700;color:#7b8796;margin-bottom:8px;text-transform:uppercase;letter-spacing:.04em}
.project-health-value{font-size:28px;font-weight:800;line-height:1;color:#0f172a}
.project-view-split{grid-template-columns:1.35fr .95fr}
.project-detail-card{padding:12px 12px 14px}
.project-detail-head{margin-bottom:10px}
.project-detail-head h3{font-size:15px}
.project-detail-table{
  min-width:100%;
  border-collapse:separate;
  border-spacing:0;
  font-size:12px;
  overflow:visible;
}
.project-detail-table thead th{padding:10px 12px;background:#fbfcff;color:#5b677a;font-size:10.5px;font-weight:600;letter-spacing:.01em;text-transform:none;border-top:1px solid var(--line);border-bottom:1px solid var(--line);border-right:1px solid var(--line)}
.project-detail-table thead th:first-child{border-left:1px solid var(--line);border-top-left-radius:14px}
.project-detail-table thead th:last-child{border-top-right-radius:14px}
.project-detail-table tbody,
.project-detail-table tr,
.project-detail-table td{
  overflow:visible;
}
.project-detail-table tbody td{padding:10px 12px;border-bottom:1px solid var(--line);border-right:1px solid var(--line);vertical-align:middle;background:#fff;font-size:12px}
.project-detail-table tbody td:first-child{border-left:1px solid var(--line)}
.project-detail-table tbody tr:last-child td:first-child{border-bottom-left-radius:14px}
.project-detail-table tbody tr:last-child td:last-child{border-bottom-right-radius:14px}
.project-detail-table tbody tr:hover td{background:#fcfdff}
.project-cell-title{font-size:12px;font-weight:600;color:#1f2937;line-height:1.4}
.project-assign-toolbar{margin-bottom:12px}

/* CALENDAR TIMELINE */
.calendar-timeline-card{
  padding:16px 16px 18px;
}
.calendar-timeline-head{
  margin-bottom:12px;
}
.calendar-legend{
  display:flex;
  align-items:center;
  gap:8px;
  flex-wrap:wrap;
}
.calendar-legend-chip{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:30px;
  padding:6px 12px;
  border-radius:999px;
  font-size:11px;
  font-weight:700;
  border:1px solid var(--line);
  background:#fff;
  color:#334155;
}
.calendar-legend-chip.is-task{
  background:#eef4ff;
  color:#295ec9;
  border-color:#dbe7ff;
}
.calendar-legend-chip.is-milestone{
  background:#fff3f6;
  color:#c04367;
  border-color:#ffd9e3;
}

.calendar-timeline-list{
  display:flex;
  flex-direction:column;
  gap:18px;
}

.calendar-day-block{
  display:grid;
  grid-template-columns:92px minmax(0,1fr);
  gap:14px;
  align-items:start;
}

.calendar-day-rail{
  position:relative;
  min-height:100%;
}
.calendar-day-rail::after{
  content:"";
  position:absolute;
  top:0;
  bottom:0;
  left:45px;
  width:2px;
  background:#f1d7df;
  border-radius:999px;
}
.calendar-day-block:last-child .calendar-day-rail::after{
  bottom:0;
}

.calendar-day-sticky{
  position:sticky;
  top:92px;
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:2px;
  text-align:center;
  position:relative;
  z-index:2;
}
.calendar-day-dow{
  font-size:11px;
  font-weight:700;
  color:#94a3b8;
  text-transform:uppercase;
}
.calendar-day-number{
  width:42px;
  height:42px;
  display:grid;
  place-items:center;
  border-radius:999px;
  background:#fff;
  border:1px solid #f4bfd0;
  color:#cf4f74;
  font-size:15px;
  font-weight:700;
  box-shadow:0 10px 24px rgba(15,23,42,.06);
}
.calendar-day-month{
  font-size:11px;
  color:#94a3b8;
  font-weight:600;
}
.calendar-day-today{
  margin-top:4px;
  font-size:10px;
  font-weight:700;
  color:#1d4ed8;
  background:#edf5ff;
  border:1px solid #dbeafe;
  border-radius:999px;
  padding:4px 8px;
}

.calendar-day-content{
  min-width:0;
}
.calendar-day-title-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  margin-bottom:12px;
}
.calendar-day-title-row h3{
  margin:0;
  font-size:18px;
  letter-spacing:-.01em;
}

.calendar-events{
  display:flex;
  flex-direction:column;
  gap:12px;
}
.calendar-event-row{
  display:grid;
  grid-template-columns:22px minmax(0,1fr);
  gap:12px;
  align-items:stretch;
}
.calendar-event-line{
  position:relative;
}
.calendar-event-line::before{
  content:"";
  position:absolute;
  left:10px;
  top:0;
  bottom:0;
  width:2px;
  background:#f1d7df;
  border-radius:999px;
}
.calendar-event-dot{
  position:absolute;
  left:4px;
  top:22px;
  z-index:2;
  display:block;
  width:12px;
  height:12px;
  border-radius:999px;
  border:2px solid #fff;
  box-shadow:0 0 0 2px #f5d3dc;
  background:#f48aa8;
}
.calendar-event-dot.is-todo,
.calendar-event-dot.is-planning{background:#f06292}
.calendar-event-dot.is-progress,
.calendar-event-dot.is-active{background:#6366f1}
.calendar-event-dot.is-review{background:#8b5cf6}
.calendar-event-dot.is-waiting,
.calendar-event-dot.is-onhold{background:#f59e0b}
.calendar-event-dot.is-done,
.calendar-event-dot.is-completed{background:#10b981}
.calendar-event-dot.is-cancel{background:#ef4444}
.calendar-event-dot.is-backlog{background:#94a3b8}

.calendar-event-card{
  display:block;
  width:100%;
  border-radius:22px;
  padding:16px 18px;
  border:1px solid transparent;
  box-shadow:0 10px 28px rgba(15,23,42,.05);
  transition:transform .15s ease, box-shadow .15s ease;
}
.calendar-event-card:hover{
  transform:translateY(-1px);
  box-shadow:0 14px 30px rgba(15,23,42,.08);
}

.calendar-event-card.is-task.is-todo{
  background:#fde2ea;
  border-color:#f7cad7;
}
.calendar-event-card.is-task.is-progress{
  background:#e8e2fb;
  border-color:#d8cdfa;
}
.calendar-event-card.is-task.is-review{
  background:#ebe4f7;
  border-color:#ddd0f0;
}
.calendar-event-card.is-task.is-waiting{
  background:#fff0cf;
  border-color:#ffe1a3;
}
.calendar-event-card.is-task.is-done{
  background:#dff1e7;
  border-color:#b9e5cb;
}
.calendar-event-card.is-task.is-cancel{
  background:#ffe4e7;
  border-color:#fecdd3;
}
.calendar-event-card.is-task.is-backlog{
  background:#eef3f8;
  border-color:#dce5ee;
}

.calendar-event-card.is-milestone.is-planning{
  background:#ffe0ea;
  border-color:#ffd2df;
}
.calendar-event-card.is-milestone.is-active{
  background:#dfeaff;
  border-color:#d6e4ff;
}
.calendar-event-card.is-milestone.is-completed{
  background:#d9f7e7;
  border-color:#bfeecf;
}
.calendar-event-card.is-milestone.is-onhold{
  background:#ffefd1;
  border-color:#ffe1a3;
}

.calendar-event-top{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:10px;
  margin-bottom:10px;
}
.calendar-mini-badge{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:24px;
  padding:4px 10px;
  border-radius:999px;
  font-size:10px;
  font-weight:700;
  letter-spacing:.02em;
  text-transform:uppercase;
  border:1px solid rgba(255,255,255,.65);
  background:rgba(255,255,255,.65);
}
.calendar-mini-badge.is-task{
  color:#305fd0;
}
.calendar-mini-badge.is-milestone{
  color:#c04367;
}

.calendar-event-status .project-solid-badge{
  min-height:28px;
  padding:5px 9px;
  border-radius:999px;
  font-size:10px;
  min-width:auto;
}

.calendar-event-main{
  min-width:0;
}
.calendar-event-title{
  font-size:18px;
  line-height:1.2;
  font-weight:700;
  color:#243047;
  margin-bottom:6px;
  letter-spacing:-.01em;
}
.calendar-event-project{
  font-size:12px;
  color:#556277;
  font-weight:600;
  margin-bottom:6px;
}
.calendar-event-desc{
  font-size:12px;
  color:#6b7280;
  line-height:1.55;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
}

/* override khusus calendar module: hilangkan satu kolom kiri tanpa mengganggu modul lain */
.calendar-timeline-card .calendar-day-block{
  display:block;
}
.calendar-timeline-card .calendar-day-rail,
.calendar-timeline-card .calendar-event-line{
  display:none;
}
.calendar-timeline-card .calendar-day-content{
  width:100%;
  min-width:0;
}
.calendar-timeline-card .calendar-event-row{
  display:block;
}
.calendar-timeline-card .calendar-event-card{
  display:block;
  width:100%;
}

@media (max-width: 1080px){
  .grid-4{grid-template-columns:repeat(2,minmax(0,1fr))}
  .grid-3,.grid-2,.split,.form-grid,.form-grid-3,.auth-card,.project-summary-grid,.project-view-split{grid-template-columns:1fr}
}
@media (max-width: 820px){
  .mobile-only{display:inline-flex}
  .app-shell{grid-template-columns:1fr}
  .sidebar{position:fixed;left:0;top:0;transform:translateX(-102%);transition:.25s ease;z-index:30;width:min(88vw,320px)}
  .sidebar.open{transform:translateX(0)}
  .topbar{padding:16px 18px}
  .topbar h1{font-size:17px}
  .content-area{padding:18px}
  .search-box{min-width:0;width:100%}
  .topbar-right{flex:1;justify-content:flex-end}
}
@media (max-width: 640px){
  .grid-4,.grid-3,.grid-2{grid-template-columns:1fr}
  .table th,.table td{padding:12px 10px;font-size:13px}
  .auth-card-side,.auth-card-form{padding:24px}
  .auth-card-side h1{font-size:30px}
  .topbar-right{width:100%;display:grid;grid-template-columns:1fr auto}
  .toolbar .left,.toolbar .right{width:100%}
  .projects-inline-toolbar{
    align-items:stretch;
    flex-direction:column;
  }
  .projects-search-toolbar{
    width:100%;
    flex-direction:column;
    align-items:stretch;
    flex-wrap:wrap;
  }
  .projects-search-wrap{
    min-width:100%;
    max-width:none;
  }
  .projects-search-actions{
    width:100%;
  }
  .project-grid-card,.project-detail-card{padding:10px}
  .project-grid-table{min-width:920px;font-size:12px}
  .project-grid-table thead th{font-size:10px;padding:10px 12px}
  .project-grid-table .project-cell-name,.project-grid-table .project-cell-owner,.project-grid-table .project-cell-status,.project-grid-table .project-cell-priority,.project-grid-table .project-cell-progress,.project-grid-table .project-cell-target,.project-grid-table .project-cell-tasks,.project-grid-table .project-cell-actions{padding:10px 12px}
  .project-name-link{font-size:12px}
  .project-meta-line,.project-progress-text,.row-actions-dropdown a,.row-actions-dropdown button{font-size:11px}
  .project-view-title{font-size:20px}
  .project-detail-table{min-width:760px}

  .calendar-timeline-card{
    padding:12px;
  }
  .calendar-day-block{
    grid-template-columns:56px minmax(0,1fr);
    gap:10px;
  }
  .calendar-day-rail::after{
    left:27px;
  }
  .calendar-day-number{
    width:34px;
    height:34px;
    font-size:13px;
  }
  .calendar-day-dow,
  .calendar-day-month{
    font-size:10px;
  }
  .calendar-day-title-row{
    align-items:flex-start;
    flex-direction:column;
    margin-bottom:10px;
  }
  .calendar-event-row{
    grid-template-columns:18px minmax(0,1fr);
    gap:10px;
  }
  .calendar-event-line::before{
    left:8px;
  }
  .calendar-event-dot{
    left:3px;
    width:10px;
    height:10px;
    top:20px;
  }
  .calendar-event-card{
    padding:14px 14px 15px;
    border-radius:18px;
  }
  .calendar-event-top{
    flex-direction:column;
    align-items:flex-start;
    margin-bottom:8px;
  }
  .calendar-event-title{
    font-size:16px;
  }
  .calendar-event-project,
  .calendar-event-desc{
    font-size:11px;
  }

  .calendar-timeline-card .calendar-day-block,
  .calendar-timeline-card .calendar-event-row{
    display:block;
  }
}

/* FILES MODULE */
.files-form-card{
  padding:18px 18px 20px;
}
.files-form-span-2{
  grid-column:span 2;
}
.files-upload-group{
  grid-column:span 2;
}
.files-upload-box{
  display:flex;
  flex-direction:column;
  gap:6px;
  align-items:flex-start;
  justify-content:center;
  min-height:124px;
  width:100%;
  padding:18px;
  border:1px dashed #c8d6ea;
  border-radius:16px;
  background:#f8fbff;
  cursor:pointer;
}
.files-upload-box:hover{
  border-color:#9ac1ff;
  background:#f3f8ff;
}
.files-upload-input{
  display:none;
}
.files-upload-title{
  font-size:14px;
  font-weight:700;
  color:#1f2937;
}
.files-upload-hint,
.files-current-note{
  font-size:12px;
  color:#64748b;
  line-height:1.55;
}
.files-link-cell a,
.files-open-link{
  color:#1d4ed8;
  text-decoration:none;
  word-break:break-word;
}
.files-link-cell a:hover,
.files-open-link:hover{
  text-decoration:underline;
}
@media (max-width: 1080px){
  .files-form-span-2,
  .files-upload-group{
    grid-column:auto;
  }
}


/* FILES MODULE: beri ruang dropdown action di baris atas agar tidak kepotong */
.files-grid-card{
  overflow:visible;
}
.files-grid-wrap{
  overflow-x:auto;
  overflow-y:visible;
  padding-top:96px;
  margin-top:-96px;
}
.files-grid-table{
  position:relative;
}
.files-grid-table .project-cell-actions,
.files-grid-table .row-actions-menu,
.files-grid-table .row-actions-dropdown{
  overflow:visible;
}


/* REPORTS MODULE */
.reports-hero{
  background:linear-gradient(180deg,#ffffff 0%, #fbfdff 100%);
}
.reports-hero-side{
  display:flex;
  align-items:center;
  justify-content:flex-end;
}
.reports-hero-chip{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:10px 14px;
  border-radius:999px;
  border:1px solid #dbe7ff;
  background:#f4f8ff;
  color:#334155;
  font-size:12px;
  font-weight:600;
}
.reports-hero-chip strong{
  color:#1d4ed8;
  font-size:13px;
}
.reports-summary-grid .reports-summary-card{
  min-height:112px;
}
.reports-grid-two{
  align-items:start;
}
.report-spotlight-card{
  padding:14px 14px 16px;
}
.reports-list-item{
  border-radius:16px;
}
.reports-inline-badge{
  min-height:30px;
  min-width:84px;
  border-radius:999px;
  padding:6px 12px;
}
.reports-progress-inline{
  min-width:180px;
}
.reports-health-chip{
  min-width:56px;
  justify-content:center;
}
.reports-health-chip.is-good{
  background:#eafbf2;
  color:#157347;
  border-color:#c8efd7;
}
.reports-health-chip.is-mid{
  background:#fff5e7;
  color:#b45309;
  border-color:#fde6b3;
}
.reports-health-chip.is-low{
  background:#fff1f2;
  color:#be123c;
  border-color:#fecdd3;
}
@media (max-width: 1080px){
  .reports-hero-side{
    justify-content:flex-start;
  }
}
@media (max-width: 640px){
  .reports-progress-inline{
    min-width:140px;
  }
  .reports-inline-badge{
    min-width:72px;
  }
}


/* CALENDAR MODULE: senada dengan milestone */
.calendar-theme-hero{
  background:linear-gradient(180deg,#ffffff 0%, #fbfdff 100%);
}
.calendar-theme-legend{
  display:flex;
  align-items:center;
  gap:8px;
  flex-wrap:wrap;
}
.calendar-theme-legend-chip{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:30px;
  padding:6px 12px;
  border-radius:999px;
  font-size:11px;
  font-weight:700;
  border:1px solid var(--line);
  background:#fff;
  color:#334155;
}
.calendar-theme-legend-chip.is-task{
  background:#eef4ff;
  color:#295ec9;
  border-color:#dbe7ff;
}
.calendar-theme-legend-chip.is-milestone{
  background:#fff3f6;
  color:#c04367;
  border-color:#ffd9e3;
}
.calendar-theme-list-card{
  padding:16px;
}
.calendar-theme-day-list{
  display:flex;
  flex-direction:column;
  gap:14px;
}
.calendar-theme-day-block{
  border:1px solid var(--line);
  border-radius:18px;
  background:#fff;
  overflow:hidden;
}
.calendar-theme-day-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:16px 18px;
  border-bottom:1px solid var(--line);
  background:#fbfcff;
}
.calendar-theme-day-head h3{
  margin:0;
  font-size:17px;
  letter-spacing:-.01em;
}
.calendar-theme-items{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:12px;
  padding:14px;
}
.calendar-theme-card{
  display:block;
  width:100%;
  border-radius:18px;
  padding:15px 16px;
  border:1px solid transparent;
  box-shadow:0 10px 28px rgba(15,23,42,.05);
  transition:transform .15s ease, box-shadow .15s ease;
}
.calendar-theme-card:hover{
  transform:translateY(-1px);
  box-shadow:0 14px 30px rgba(15,23,42,.08);
}
.calendar-theme-card-top{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:10px;
  margin-bottom:10px;
}
.calendar-theme-card-left{
  display:flex;
  align-items:center;
  gap:8px;
  flex-wrap:wrap;
}
.calendar-theme-mini-badge{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:24px;
  padding:4px 10px;
  border-radius:999px;
  font-size:10px;
  font-weight:700;
  letter-spacing:.02em;
  text-transform:uppercase;
  border:1px solid rgba(255,255,255,.65);
  background:rgba(255,255,255,.65);
}
.calendar-theme-mini-badge.is-task{
  color:#305fd0;
}
.calendar-theme-mini-badge.is-milestone{
  color:#c04367;
}
.calendar-theme-project-code{
  font-size:10.5px;
  font-weight:700;
  color:#64748b;
}
.calendar-theme-card-title{
  font-size:17px;
  line-height:1.25;
  font-weight:700;
  color:#243047;
  margin-bottom:6px;
  letter-spacing:-.01em;
}
.calendar-theme-card-project{
  font-size:12px;
  color:#556277;
  font-weight:600;
  margin-bottom:6px;
}
.calendar-theme-card-desc{
  font-size:12px;
  color:#6b7280;
  line-height:1.55;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
}
.calendar-theme-card.is-task.is-todo{
  background:#fde2ea;
  border-color:#f7cad7;
}
.calendar-theme-card.is-task.is-progress{
  background:#e8e2fb;
  border-color:#d8cdfa;
}
.calendar-theme-card.is-task.is-review{
  background:#ebe4f7;
  border-color:#ddd0f0;
}
.calendar-theme-card.is-task.is-waiting{
  background:#fff0cf;
  border-color:#ffe1a3;
}
.calendar-theme-card.is-task.is-done{
  background:#dff1e7;
  border-color:#b9e5cb;
}
.calendar-theme-card.is-task.is-cancel{
  background:#ffe4e7;
  border-color:#fecdd3;
}
.calendar-theme-card.is-task.is-backlog{
  background:#eef3f8;
  border-color:#dce5ee;
}
.calendar-theme-card.is-milestone.is-planning{
  background:#ffe0ea;
  border-color:#ffd2df;
}
.calendar-theme-card.is-milestone.is-active{
  background:#dfeaff;
  border-color:#d6e4ff;
}
.calendar-theme-card.is-milestone.is-completed{
  background:#d9f7e7;
  border-color:#bfeecf;
}
.calendar-theme-card.is-milestone.is-onhold{
  background:#ffefd1;
  border-color:#ffe1a3;
}

@media (max-width: 1080px){
  .calendar-theme-items{
    grid-template-columns:1fr;
  }
}
@media (max-width: 640px){
  .calendar-theme-list-card{
    padding:10px;
  }
  .calendar-theme-day-head{
    padding:14px;
    align-items:flex-start;
    flex-direction:column;
  }
  .calendar-theme-items{
    padding:10px;
    gap:10px;
  }
  .calendar-theme-card{
    padding:14px;
    border-radius:16px;
  }
  .calendar-theme-card-top{
    flex-direction:column;
    align-items:flex-start;
    margin-bottom:8px;
  }
  .calendar-theme-card-title{
    font-size:16px;
  }
  .calendar-theme-card-project,
  .calendar-theme-card-desc{
    font-size:11px;
  }
}
/* USERS MODULE */
.users-view-split{
  grid-template-columns:1.35fr .95fr;
}
.users-view-hero{
  background:linear-gradient(180deg,#ffffff 0%, #fbfdff 100%);
}
.users-metric-value{
  font-size:28px;
  font-weight:800;
  line-height:1;
  color:#0f172a;
}
.users-form-card{
  padding:18px 18px 20px;
}
.users-grid-card{
  overflow:visible;
  position:relative;
  z-index:1;
}
.users-grid-wrap{
  overflow-x:auto;
  overflow-y:visible;
  padding-top:0;
  margin-top:0;
  position:relative;
  z-index:1;
}
.users-detail-table{
  position:relative;
}
.users-detail-table .project-cell-actions,
.users-detail-table .row-actions-menu,
.users-detail-table .row-actions-dropdown{
  overflow:visible;
}
@media (max-width:1080px){
  .users-view-split{
    grid-template-columns:1fr;
  }
}


.auth-card-wide{grid-template-columns:1.15fr .85fr}.company-switch-form{margin:0}.select-compact{padding:10px 12px;min-width:220px}.hero-card{background:linear-gradient(135deg,#f6fbff 0%,#ffffff 60%,#f5fff8 100%);border:1px solid var(--line);border-radius:24px;padding:24px;box-shadow:var(--shadow)}.hero-card h2{margin:0 0 8px;font-size:28px;line-height:1.15}.hero-card p{margin:0;color:var(--muted);max-width:760px}.stat-grid{display:grid;gap:18px;grid-template-columns:repeat(4,minmax(0,1fr))}.toolbar-tabs{display:flex;gap:8px;flex-wrap:wrap}.toolbar-tabs .btn.active{background:#0f6fff;border-color:#0f6fff;color:#fff}.inline-meta{display:flex;gap:10px;flex-wrap:wrap;align-items:center}.detail-grid{display:grid;gap:18px;grid-template-columns:1.3fr .7fr}.detail-section{padding:18px;border:1px solid var(--line);border-radius:18px;background:#fff}.profile-head{display:flex;gap:16px;align-items:flex-start}.profile-photo{width:72px;height:72px;border-radius:20px;display:grid;place-items:center;background:#eef5ff;color:#0f6fff;font-size:28px;font-weight:800}.kv{display:grid;grid-template-columns:180px 1fr;gap:8px 16px;font-size:14px}.kv .key{color:#64748b;font-weight:600}.small-note{font-size:12px;color:var(--muted)}.stack{display:flex;flex-direction:column;gap:14px}.badge-soft{display:inline-flex;padding:7px 10px;border-radius:999px;font-size:12px;font-weight:700;background:#f8fafc;border:1px solid var(--line)}.dual-grid{display:grid;grid-template-columns:1fr 1fr;gap:18px}.report-kpi{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px}.report-bar{height:12px;background:#edf2f7;border-radius:999px;overflow:hidden}.report-bar>span{display:block;height:100%;background:#0f6fff;border-radius:999px}.table-actions{display:flex;gap:6px;flex-wrap:wrap}.subtle-box{padding:14px;border:1px dashed #cdd7e3;border-radius:16px;background:#fafcff}.empty-hint{padding:18px;border:1px dashed #cbd5e1;border-radius:18px;background:#fff;color:#64748b;text-align:center}.mini-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}@media (max-width: 1100px){.stat-grid,.report-kpi,.grid-4,.grid-3,.dual-grid,.detail-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}@media (max-width: 780px){.app-shell{grid-template-columns:1fr}.sidebar{position:fixed;left:-320px;top:0;bottom:0;z-index:40;width:290px;transition:.25s ease}.sidebar.open{left:0}.mobile-only{display:inline-grid;place-items:center}.content-area,.topbar{padding:16px}.stat-grid,.report-kpi,.grid-4,.grid-3,.grid-2,.dual-grid,.detail-grid,.mini-grid,.auth-card,.auth-card-wide{grid-template-columns:1fr}.topbar{align-items:flex-start;gap:12px}.topbar-right{width:100%;flex-wrap:wrap}.select-compact{min-width:0;width:100%}.toolbar,.projects-inline-toolbar{align-items:stretch}.kv{grid-template-columns:1fr}}

.section-head-tight{margin-bottom:16px}
.stack-lg{display:flex;flex-direction:column;gap:18px}
.form-span-2{grid-column:span 2}
.organization-hero{margin-bottom:18px}
.organization-hero-head{display:flex;justify-content:space-between;gap:18px;align-items:flex-start;flex-wrap:wrap}
.organization-hero-stats{display:flex;gap:12px;flex-wrap:wrap}
.hero-kpi{min-width:160px;padding:14px 16px;border:1px solid var(--line);border-radius:18px;background:#fff}
.hero-kpi span{display:block;font-size:12px;color:#64748b;margin-bottom:6px}
.hero-kpi strong{font-size:24px;line-height:1.1}
.toolbar-gapless{margin-bottom:18px}
.organization-master-table th:last-child,.organization-master-table td:last-child{text-align:left}
.inline-toggle-form{margin:0}
.usage-summary-item{align-items:center;justify-content:space-between;gap:14px}
.usage-summary-progress{min-width:180px;display:flex;flex-direction:column;gap:8px}
@media (max-width:780px){.form-span-2{grid-column:span 1}.hero-kpi,.usage-summary-progress{min-width:0;width:100%}}

.access-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}
.access-grid.compact{grid-template-columns:repeat(2,minmax(0,1fr))}
.access-pill{display:flex;align-items:center;gap:10px;padding:12px 14px;border:1px solid var(--line);border-radius:14px;background:#fff;cursor:pointer;font-weight:500}
.access-pill.small{padding:10px 12px;font-size:13px}
.access-pill input{margin:0;accent-color:#0f6fff}
.access-pill.is-primary{border-color:#bfd6ff;background:#f6faff}
.company-access-sections{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;margin-top:6px}
.company-access-card{border:1px solid var(--line);border-radius:18px;padding:14px;background:#fbfdff}
.company-access-title{font-weight:700;margin-bottom:10px}
@media (max-width: 980px){.access-grid,.access-grid.compact,.company-access-sections{grid-template-columns:1fr}}
