/* RONVO Team Center 11.0.7 – einheitliche Desktop-Arbeitsbreite */
:root{
  --content-max:1760px;
  --workspace-gap:22px;
  --form-column:430px;
  --surface-radius:22px;
  --surface-border:rgba(115,132,157,.22);
  --surface-shadow:0 10px 32px rgba(30,48,78,.075)
}

/* Jede Anwendungseite nutzt exakt dieselbe zentrierte Arbeitsfläche wie die Übersicht. */
.content{
  width:100%;
  max-width:var(--content-max);
  margin-inline:auto;
  padding:30px 38px 64px
}
.content>*:not(.flash){max-width:none;width:100%}

/* Statusmeldungen bleiben kompakte, schwebende Toasts und beeinflussen das Seitenraster nicht. */
.content>.flash{
  width:auto;
  max-width:min(440px,calc(100vw - 32px));
  margin:0;
  white-space:normal;
  overflow-wrap:anywhere
}

.panel{border-color:var(--surface-border);border-radius:var(--surface-radius);box-shadow:var(--surface-shadow)}

/* Gemeinsames Verwaltungsraster: feste Formularspalte, flexibler Inhaltsbereich. */
.two-col{
  display:grid;
  grid-template-columns:minmax(340px,var(--form-column)) minmax(0,1fr);
  gap:var(--workspace-gap);
  align-items:start;
  width:100%;
  max-width:none;
  margin-inline:0
}
.two-col>.panel:first-child{position:sticky;top:112px}
.two-col>.panel:last-child,.two-col>.feed{min-width:0;width:100%}

/* Alte seitenbezogene Breitenbegrenzungen vollständig aufheben. */
.page-tasks .two-col,
.page-checklists .two-col,
.page-calendar .two-col,
.page-absences .two-col,
.page-knowledge .two-col,
.page-news .two-col,
.page-employees .two-col,
.page-settings .two-col,
.page-audit .two-col,
.page-profile .profile-layout,
.page-notifications .narrow-wide,
.page-notifications .notification-list,
.page-documents .documents-v850,
.page-messages .chat-layout,
.page-messages .chat-shell{
  width:100%;
  max-width:none;
  margin-inline:0
}

.page-tasks .two-col>.panel:last-child,
.page-checklists .two-col>.panel:last-child,
.page-calendar .two-col>.panel:last-child,
.page-absences .two-col>.panel:last-child,
.page-knowledge .two-col>.panel:last-child,
.page-employees .two-col>.panel:last-child{min-height:420px}

.page-news .feed{min-height:420px;border:1px solid var(--surface-border);border-radius:var(--surface-radius);background:var(--panel);box-shadow:var(--surface-shadow);padding:22px}
.page-news .feed>.empty{min-height:190px;display:grid;place-content:center}
.page-notifications .narrow-wide{min-height:420px}
.page-notifications .notification-list>.empty{min-height:260px;display:grid;place-content:center}

.panel-head{min-height:38px}
.empty{min-height:190px;display:grid;place-content:center}
.form-grid{gap:16px}
.form-grid>.btn.primary{width:100%;min-height:46px}
input,textarea,select{min-height:44px}
textarea{min-height:112px}

.employee-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:18px;align-items:stretch}.employee-card{min-width:0}.employee-card h4,.employee-card p{word-break:break-word;overflow-wrap:anywhere}@media (max-width:1600px){.employee-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}@media (max-width:1200px){.employee-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}@media (max-width:768px){.employee-grid{grid-template-columns:1fr}}
.employee-card{height:100%;padding:24px 20px;border-radius:18px}
.employee-card-head{display:flex;flex-direction:column;align-items:center;text-align:center;gap:14px}
.employee-card-head>div:last-child{width:100%;min-width:0}
.employee-card h4{font-size:17px;margin:0 0 7px}
.employee-card p{overflow-wrap:anywhere}
.employee-badges{justify-content:center}
.employee-meta{text-align:center;padding:16px 0;margin-top:15px;border-top:1px solid var(--line)}
.employee-card-actions{margin-top:auto;display:grid;gap:9px}
.employee-card-actions>*,.employee-card-actions .btn,.employee-edit>summary{width:100%}
.team-panel{min-height:460px}
.page-employees .two-col>.panel:first-child{align-self:start}

/* Große Desktopmonitore: dieselben Außenkanten in jedem Modul. */
@media (min-width:1101px){
  .page-dashboard .content,
  .page-tasks .content,
  .page-checklists .content,
  .page-calendar .content,
  .page-absences .content,
  .page-knowledge .content,
  .page-news .content,
  .page-notifications .content,
  .page-messages .content,
  .page-documents .content,
  .page-employees .content,
  .page-audit .content,
  .page-settings .content,
  .page-profile .content{max-width:var(--content-max)}
}

@media (max-width:1100px){
  .content{padding:24px 24px 52px}
  .two-col{grid-template-columns:1fr}
  .two-col>.panel:first-child{position:static}
  .page-tasks .two-col>.panel:last-child,
  .page-checklists .two-col>.panel:last-child,
  .page-calendar .two-col>.panel:last-child,
  .page-absences .two-col>.panel:last-child,
  .page-knowledge .two-col>.panel:last-child,
  .page-employees .two-col>.panel:last-child{min-height:0}
}
@media (max-width:720px){
  .content{padding:18px 14px 100px}
  .panel{padding:18px;border-radius:18px}
  .employee-grid{grid-template-columns:1fr}
  .empty{min-height:150px}
  .page-news .feed{padding:16px}
}

/* Team-Chat nutzt auf Desktop exakt dieselbe zentrale Arbeitsbreite wie die Übersicht. */
@media (min-width:901px){
  body.page-messages .content{
    flex:1 1 auto;
    width:100%;
    max-width:var(--content-max);
    min-height:0;
    height:auto;
    margin-inline:auto;
    padding:30px 38px 32px;
    overflow:hidden;
  }
  body.page-messages .chat-v8-shell,
  body.page-messages .chat-layout,
  body.page-messages .chat-shell{
    width:100%;
    max-width:none;
    height:100%;
    min-height:0;
    margin-inline:0;
  }
}

/* 11.0.6: Eine verbindliche Breitenlogik für jedes angemeldete Modul. */
@media (min-width:1101px){
  body.app-shell .main > .content{
    width:100%;
    max-width:var(--content-max);
    margin-left:auto;
    margin-right:auto;
    padding-left:38px;
    padding-right:38px;
  }

  /* Direkte Modulwurzeln dürfen die gemeinsame Arbeitsfläche nicht verkleinern. */
  body.app-shell .main > .content > :is(
    .hero-dashboard,
    .stats,
    .quick-actions,
    .dashboard-grid,
    .two-col,
    .documents-v850,
    .chat-v8-shell,
    .chat-layout,
    .chat-shell,
    .profile-layout,
    .narrow,
    .narrow-wide,
    .page-head,
    .panel,
    .card,
    .feed
  ){
    width:100%;
    max-width:none;
    margin-left:0;
    margin-right:0;
  }

  /* Module behalten nur ihre innere Funktionsaufteilung. */
  body.page-messages .chat-v8-shell,
  body.page-documents .documents-v850,
  body.page-profile .profile-layout{
    min-width:0;
  }
}



/* 11.0.7: Desktop-Sidebar verbindlich 280 px, ohne Navigations-Scrollbalken. */
@media (min-width:1101px){
  :root{--rtc-sidebar:280px;}

  body.app-shell:not(.sidebar-collapsed){
    grid-template-columns:280px minmax(0,1fr);
  }

  body.app-shell:not(.sidebar-collapsed) > .sidebar,
  body.app-shell:not(.sidebar-collapsed) .sidebar{
    width:280px;
    min-width:280px;
    max-width:280px;
    overflow:visible;
  }

  body.app-shell .sidebar nav{
    overflow:visible;
    overflow-x:visible;
    overflow-y:visible;
    scrollbar-width:none;
  }

  body.app-shell .sidebar nav::-webkit-scrollbar{
    display:none;
    width:0;
    height:0;
  }
}
