/* Notification center surfaces and their independent Dock. */
@media (max-width:760px) {
  .onc-overview :is(.onc-overview-panel,.onc-action-cards) { display:contents; }
  .onc-overview-section-title { display:none; }
}

@media (min-width:761px) {
  html body #onc-center[data-onc-overview="true"] {
    background:var(--oa-home-background)!important;
    background-blend-mode:normal,normal,luminosity;
    border-color:#c3d8ed!important;
    box-shadow:inset 0 1px #fff,0 12px 32px #244e7414!important;
  }

  html body :is(#onc-center,.onc-module-ghost) .onc-overview {
    align-content:safe center;
    gap:clamp(18px,3.6vh,36px);
    padding:clamp(20px,4vh,46px) clamp(16px,4vw,64px) 12px!important;
  }

  html body :is(#onc-center,.onc-module-ghost) .onc-home-header {
    width:min(100%,var(--oa-home-width));
    margin-inline:auto;
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:18px;
    text-align:start;
  }

  html body :is(#onc-center,.onc-module-ghost) .onc-home-header h1 {
    font-size:var(--oa-home-title-size);
    line-height:1.15;
    letter-spacing:-.04em;
    color:var(--oa-home-title-ink);
  }

  html body :is(#onc-center,.onc-module-ghost) .onc-overview .onc-home-cluster {
    width:min(100%,var(--oa-home-width));
    margin-inline:auto;
    min-height:0;
    grid-template-columns:minmax(0,1fr);
    grid-template-areas:none;
    gap:clamp(16px,3vw,36px);
  }

  .onc-overview-panel {
    min-width:0;
    display:grid;
    grid-template-columns:minmax(0,1fr);
    grid-template-rows:auto 1fr;
    gap:12px;
  }

  .onc-overview-section-title {
    margin:0;
    padding:0 2px;
    font-size:clamp(15px,1.25vw,18px);
    color:#133650;
  }

  .onc-action-cards,
  html body :is(#onc-center,.onc-module-ghost) .onc-followup-panel .onc-home-right {
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    grid-auto-rows:1fr;
    gap:clamp(9px,1.1vw,17px);
    padding:0;
    grid-area:auto;
    border:0;
    background:none;
    box-shadow:none;
  }

  .onc-action-cards :is(.onc-home-lead,.onc-home-left) { display:contents; }

  html body :is(#onc-center,.onc-module-ghost) .onc-overview-panel .onc-preview-card:nth-child(n) {
    grid-column:auto;
    min-height:var(--oa-home-action-height)!important;
    padding:var(--oa-home-inset)!important;
    justify-content:center;
    border:1px solid var(--oa-home-tile-line)!important;
    border-radius:calc(var(--oa-home-icon-radius) + var(--oa-home-inset))!important;
    background:var(--oa-home-tile)!important;
    box-shadow:var(--oa-home-tile-shadow)!important;
  }

  html body #onc-center .onc-overview-panel .onc-preview-card {
    backdrop-filter:var(--oa-home-tile-glass)!important;
    -webkit-backdrop-filter:var(--oa-home-tile-glass)!important;
  }

  html body :is(#onc-center,.onc-module-ghost) .onc-followup-panel .onc-home-right .onc-preview-card:nth-child(n) {
    min-height:76px!important;
  }

  .onc-overview-panel .oa-home-arrow { display:none; }

  html body :is(#onc-center,.onc-module-ghost) .onc-overview-panel :is(.onc-home-lead,.onc-home-side) .onc-preview-head.oa-home-card-head {
    position:static;
    display:grid;
    grid-template-columns:auto minmax(0,1fr) auto;
    align-items:center;
    align-self:stretch;
    gap:clamp(6px,1vw,12px)!important;
    padding:0!important;
    text-align:start!important;
  }

  html body :is(#onc-center,.onc-module-ghost) .onc-action-panel .onc-action-cards .onc-preview-head.oa-home-card-head {
    grid-template-columns:minmax(0,1fr) auto;
    grid-template-areas:"icon count" "label label";
  }

  .onc-action-panel .onc-preview-icon { grid-area:icon; }
  .onc-action-panel .onc-preview-head strong { grid-area:label; }
  .onc-action-panel .onc-preview-count { grid-area:count; position:static; justify-self:end; }

  html body :is(#onc-center,.onc-module-ghost) .onc-overview-panel .onc-preview-head.oa-home-card-head strong {
    font-size:clamp(14px,1.2vw,18px)!important;
    color:#143452;
    overflow-wrap:anywhere;
  }

  html body :is(#onc-center,.onc-module-ghost) .onc-overview-panel .onc-preview-head .onc-preview-icon {
    width:36px!important;
    height:36px!important;
    border:1px solid #fff9;
    border-radius:var(--oa-home-icon-radius);
    background:linear-gradient(155deg,#ffffff85,transparent 70%),var(--nc-tint,#e5eef8);
    box-shadow:inset 0 1px #fff9,0 2px 4px #26496918;
  }

  html body :is(#onc-center,.onc-module-ghost) .onc-overview-panel :is(.onc-home-lead,.onc-home-side) .onc-preview-head .onc-preview-count {
    font-size:clamp(28px,3vw,48px)!important;
    margin:0!important;
    color:#163b67!important;
    font-variant-numeric:tabular-nums;
  }

  html body :is(#onc-center,.onc-module-ghost) .onc-followup-panel .onc-home-right .onc-preview-head .onc-preview-count {
    font-size:clamp(18px,1.7vw,25px)!important;
    font-weight:650;
  }

  html body :is(#onc-center,.onc-module-ghost) .onc-overview-panel .onc-preview-card:nth-child(n):is(:hover,:focus-visible) {
    background:linear-gradient(155deg,#f7fcffe8,color-mix(in srgb,var(--nc-tint,#e4f1fb) 78%,transparent))!important;
  }

  html body :is(#onc-center,.onc-module-ghost) .onc-overview-panel .onc-preview-card:focus-visible {
    outline:2px solid #174f8b;
    outline-offset:3px;
  }

  @media (prefers-reduced-transparency:reduce) {
    html body :is(#onc-center,.onc-module-ghost) .onc-overview-panel .onc-preview-card:nth-child(n) {
      background:#f4f9fd!important;
    }
    html body #onc-center .onc-overview-panel .onc-preview-card {
      backdrop-filter:none!important;
      -webkit-backdrop-filter:none!important;
    }
  }

  @container (min-width:990px) {
    html body :is(#onc-center,.onc-module-ghost) .onc-overview .onc-home-cluster {
      grid-template-columns:minmax(0,1fr) minmax(0,2.05fr) minmax(0,1fr);
      grid-template-rows:auto repeat(3,minmax(76px,auto));
      align-items:center;
      column-gap:clamp(24px,3.4vw,64px);
      row-gap:10px;
    }

    .onc-action-panel { grid-area:1 / 2 / span 4; }
    .onc-action-panel .onc-overview-section-title { text-align:center; }
    .onc-followup-panel,
    html body :is(#onc-center,.onc-module-ghost) .onc-followup-panel .onc-home-right { display:contents; }
    .onc-followup-panel .onc-overview-section-title {
      grid-area:1 / 1;
      text-align:center;
    }
    html body :is(#onc-center,.onc-module-ghost) .onc-followup-panel .onc-preview-card:nth-child(n) { grid-column:1; }
    html body :is(#onc-center,.onc-module-ghost) .onc-followup-panel .onc-preview-card:nth-child(n+3) { grid-column:3; }
    .onc-followup-panel .onc-preview-card:is(:nth-child(1),:nth-child(3)) { grid-row:2; }
    .onc-followup-panel .onc-preview-card:is(:nth-child(2),:nth-child(4)) { grid-row:3; }
    .onc-followup-panel .onc-preview-card:nth-child(5) { grid-row:4; }
  }
}

/* The overview scrollport ends above the fixed Dock and its raised captions. */
@media screen and (min-width:601px) {
  html body #onc-center[data-onc-overview="true"] > .onc-overview {
    margin-block-end:calc(max(12px,env(safe-area-inset-bottom)) + var(--oa-dock-height,74px) + 76px);
    padding-block-end:12px!important;
    scroll-padding-block-end:12px;
  }
}

@media screen and (max-width:600px) {
  html body #onc-center[data-onc-overview="true"] > .onc-overview {
    margin-block-end:calc(var(--oa-mobile-dock-height,90px) + max(26px,env(safe-area-inset-bottom)));
    padding-block-end:10px!important;
    scroll-padding-block-end:10px;
  }
}

/* Keep the surface on the persistent notification Dock, including its category views. */
@media screen and (min-width:761px) and (hover:hover) and (pointer:fine) {
  html body.oa-compact-center.oa-dock-standard.oa-dock-standard.oa-dock-standard #onc-dock {
    bottom:max(12px,env(safe-area-inset-bottom))!important;
    border:1px solid #eef8ffc2!important;
    border-radius:19px!important;
    background:linear-gradient(165deg,#f1f8ff5c,#7b9cba44)!important;
    backdrop-filter:blur(19px) saturate(150%)!important;
    -webkit-backdrop-filter:blur(19px) saturate(150%)!important;
    box-shadow:inset 0 1px #fff9,inset 0 -1px #183c5d24,0 7px 20px #16375534!important;
  }

  #onc-dock button[data-onc-category="all"]:has(+button)::after,
  #onc-dock button:is([data-onc-category="sign"],[data-onc-category="revise"],[data-onc-category="execute"],[data-onc-category="accept"]):has(+button:not(:is([data-onc-category="sign"],[data-onc-category="revise"],[data-onc-category="execute"],[data-onc-category="accept"])))::after {
    content:"";
    position:absolute;
    top:18%;
    bottom:18%;
    right:calc(-1 * var(--oa-dock-gap,6px) / 2);
    width:1px;
    background:#264e6b70;
    box-shadow:1px 0 #f5fbff91;
    pointer-events:none;
  }

  @media (prefers-reduced-transparency:reduce) {
    html body.oa-compact-center.oa-dock-standard.oa-dock-standard.oa-dock-standard #onc-dock {
      background:#eaf3fb!important;
      backdrop-filter:none!important;
      -webkit-backdrop-filter:none!important;
    }
  }
}

/* Keep the same palette through category lists, their transitions and details. */
html body :is(#onc-center,.onc-module-ghost)[data-onc-overview="false"] {
  background:linear-gradient(150deg,#eaf4fe,#d9e8f6)!important;
  border-color:#c3d8ed!important;
  box-shadow:inset 0 1px #fff,0 12px 32px #244e7414!important;
}

html body :is(#onc-center,.onc-module-ghost)[data-onc-overview="false"] .onc-listbar {
  gap:12px;
  padding:12px 16px;
  margin-bottom:10px;
  border:1px solid #fff;
  border-radius:16px;
  background:linear-gradient(145deg,#f9fcffdc,#edf6fed1);
  box-shadow:0 5px 14px #244e7412,inset 0 1px #fff;
}

.onc-list-heading {
  min-width:0;
  display:flex;
  align-items:baseline;
  flex-wrap:wrap;
  gap:4px 12px;
}

.onc-list-title {
  margin:0;
  font-size:clamp(19px,2vw,26px);
  line-height:1.25;
  color:#102d51;
  overflow-wrap:anywhere;
}

html body :is(#onc-center,.onc-module-ghost)[data-onc-overview="false"] .onc-listbar select {
  border-radius:9px!important;
  border-color:#bbd1e5!important;
  background:#f8fcff!important;
}

html body :is(#onc-center,.onc-module-ghost)[data-onc-overview="false"] .onc-scroll {
  border:1px solid #ffffffc7;
  border-radius:16px;
  background:#f4f9ff80;
}

html body :is(#onc-center,.onc-module-ghost)[data-onc-overview="false"] .onc-columns {
  background:#e0edf9;
  border-color:#d0e0ef;
}

html body :is(#onc-center,.onc-module-ghost)[data-onc-overview="false"] .onc-group {
  background:#e7f1fa;
  border-color:#d6e6f3;
}

html body :is(#onc-center,.onc-module-ghost)[data-onc-overview="false"] .onc-record {
  background:linear-gradient(150deg,#ffffffed,#eff7ffde)!important;
  border-color:#cedeed;
}

html body :is(#onc-center,.onc-module-ghost)[data-onc-overview="false"] .onc-record:is(.onc-selected,:hover,:focus-visible) {
  background:#e0effe!important;
  border-color:#a1bdd7;
}

html body :is(#onc-center,.onc-module-ghost)[data-onc-overview="false"] .onc-record.onc-selected {
  box-shadow:inset 3px 0 #2a7ab4,inset 0 1px #fff!important;
}

html body.oa-compact-center .onc-drawer {
  background:linear-gradient(160deg,#fcfdfff5,#eaf4fdf0)!important;
  border-color:#c3d8ed!important;
  border-radius:22px 0 0 22px!important;
  box-shadow:-14px 0 40px #173d6130!important;
}

html body.oa-compact-center .onc-drawer:not([data-onc-motion]) {
  backdrop-filter:blur(16px) saturate(130%)!important;
}

html body.oa-compact-center .onc-drawer .onc-detail-tabs {
  flex-wrap:wrap;
  gap:4px;
}

html body.oa-ui.oa-compact-center .onc-drawer[role="dialog"][aria-modal="false"] .onc-detail-tabs button[data-tab] {
  border:1px solid #cfdfed!important;
  border-radius:9px!important;
  background:#f6faff!important;
  box-shadow:none!important;
}

html body.oa-ui.oa-compact-center .onc-drawer[role="dialog"][aria-modal="false"] .onc-detail-tabs button[data-tab][aria-pressed="true"] {
  color:#fff!important;
  border-color:#235981!important;
  background:#235981!important;
}

@media screen and (min-width:761px) {
  html body :is(#onc-center,.onc-module-ghost)[data-onc-overview="false"] {
    background:
      linear-gradient(145deg,#edf6fef7,#e4effaf0 53%,#d9e9f7df),
      url('/assets/oa-notification-mountain-lake.webp') left 47% / max(150%,180vh) auto no-repeat,
      #8daccb!important;
    background-blend-mode:normal,luminosity;
  }
}

@media (max-width:760px) {
  html body :is(#onc-center,.onc-module-ghost)[data-onc-overview="false"] .onc-listbar { padding:10px; }
  html body.oa-compact-center .onc-drawer { border-radius:0!important; }
}

@media (prefers-reduced-transparency:reduce) {
  html body.oa-compact-center .onc-drawer:not([data-onc-motion]) {
    background:#f4f9fd!important;
    backdrop-filter:none!important;
  }
}

@media screen and (max-width:760px) {
  html body :is(#onc-center,.onc-module-ghost):is([data-onc-overview="true"],[data-onc-overview="false"]) {
    background:
      linear-gradient(165deg,#dcebf9e6,#e8f3fceb 360px,#eef6fc 700px),
      url('/assets/oa-notification-mountain-lake.webp') center top / auto 380px no-repeat,
      #eaf3fb!important;
    background-blend-mode:normal,luminosity;
  }

  html body :is(#onc-center,.onc-module-ghost) .onc-overview .onc-preview-card:nth-child(n) {
    background:linear-gradient(150deg,#fbfdff,#dfedf9)!important;
    border-color:#bcd4ea!important;
  }
}

/* Fit the clocks and every category on the notification home screen. */
@media screen and (max-height:950px), screen and (max-width:760px) {
  html body #onc-center[data-onc-overview="true"] > .onc-overview {
    grid-template-rows:max-content max-content;
    align-content:start;
    gap:clamp(8px,1.6dvh,14px);
    padding-block:clamp(8px,1.8dvh,16px) 8px!important;
  }

  html body #onc-center .onc-home-header {
    row-gap:8px;
  }

  html body #onc-center .onc-home-cluster {
    row-gap:8px;
  }

  html body #onc-center .onc-overview-panel .onc-preview-card:nth-child(n),
  html body #onc-center .onc-followup-panel .onc-home-right .onc-preview-card:nth-child(n) {
    min-height:56px!important;
    padding:6px!important;
  }
}

@media screen and (min-width:761px) and (max-height:950px) {
  html body #onc-center .onc-home-header h1 {
    font-size:clamp(24px,4.6dvh,34px);
  }

  html body #onc-center .onc-action-panel .onc-action-cards .onc-preview-head.oa-home-card-head {
    grid-template-columns:auto minmax(0,1fr) auto;
    grid-template-areas:"icon label count";
  }

  html body #onc-center .onc-overview-panel .onc-preview-head .onc-preview-count {
    position:static;
    font-size:clamp(20px,2.7vw,36px)!important;
  }

  #onc-center .onc-overview-panel,
  #onc-center .onc-action-cards {
    gap:8px;
  }

  @container (max-width:989px) {
    html body #onc-center .onc-overview .onc-home-cluster {
      grid-template-columns:repeat(2,minmax(0,1fr));
      column-gap:10px;
    }

    html body #onc-center :is(.onc-action-cards,.onc-followup-panel .onc-home-right) {
      gap:6px;
    }
  }

  @container (min-width:990px) {
    html body #onc-center .onc-overview .onc-home-cluster {
      grid-template-rows:auto repeat(3,minmax(56px,auto));
    }
  }
}

@media screen and (max-width:760px) {
  html body #onc-center[data-onc-overview="true"] > .onc-overview {
    gap:8px;
    padding-block:6px!important;
  }

  html body #onc-center .onc-overview .onc-home-cluster {
    grid-template-columns:repeat(2,minmax(0,1fr));
    grid-template-areas:none;
    min-height:0;
    gap:8px;
  }

  #onc-center .onc-overview :is(.onc-home-lead,.onc-home-side) {
    display:contents;
  }

  html body #onc-center .onc-overview .onc-home-cluster .onc-preview-card:nth-child(n) {
    min-height:48px!important;
    padding:5px 6px!important;
    justify-content:center;
  }

  html body #onc-center .onc-overview .onc-home-cluster :is(.onc-home-lead,.onc-home-side) .onc-preview-head.oa-home-card-head {
    position:static;
    display:grid;
    grid-template-columns:26px minmax(0,1fr) auto;
    align-self:stretch;
    padding:0!important;
    gap:5px!important;
    text-align:start!important;
  }

  html body #onc-center .onc-home-cluster .onc-preview-head strong {
    font-size:13px!important;
  }

  html body #onc-center .onc-home-cluster .onc-preview-icon {
    grid-row:auto;
    width:26px!important;
    height:26px!important;
  }

  html body #onc-center .onc-home-cluster .onc-preview-count {
    font-size:16px!important;
  }
}

/* The clock group belongs to the notice dashboard grid. */
#onc-center { container-name:onc-dashboard; }
html body #onc-center[data-onc-overview="true"] > .onc-overview {
  grid-template-rows:max-content max-content;
  align-content:safe center;
  gap:clamp(8px,2dvh,20px);
  padding-block:10px!important;
}

#onc-center .onc-clock-feature {
  grid-column:1 / -1;
  min-width:0;
  width:100%;
  display:grid;
  justify-items:center;
}

#onc-center .onc-clock-feature .oa-home-clock-row {
  inset:auto;
  width:min(100%,460px);
  margin:0 auto;
}

@media screen and (min-width:761px) {
  html body #onc-center .onc-overview .onc-home-cluster {
    grid-template-columns:repeat(2,minmax(0,1fr));
    grid-template-rows:auto auto;
    align-items:start;
    min-height:0;
    gap:12px;
  }

  html body #onc-center .onc-overview :is(.onc-action-panel,.onc-followup-panel) {
    display:grid;
    grid-area:auto;
    align-content:start;
    gap:7px;
  }

  html body #onc-center .onc-overview :is(.onc-action-cards,.onc-followup-panel .onc-home-right) {
    display:grid;
    grid-auto-rows:auto;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:8px;
  }

  #onc-center .onc-overview-section-title {
    grid-area:auto;
    text-align:start;
    font-size:14px;
  }

  html body #onc-center .onc-overview .onc-overview-panel .onc-preview-card:nth-child(n) {
    grid-area:auto;
    min-height:46px!important;
    padding:6px 8px!important;
  }

  html body #onc-center .onc-overview .onc-overview-panel .onc-preview-head.oa-home-card-head {
    grid-template-columns:auto minmax(0,1fr) auto;
    grid-template-areas:"icon label count";
    gap:6px!important;
  }

  html body #onc-center .onc-overview .onc-overview-panel .onc-preview-head strong {
    font-size:clamp(12px,1.1vw,16px)!important;
  }

  html body #onc-center .onc-overview .onc-overview-panel .onc-preview-head .onc-preview-icon {
    width:26px!important;
    height:26px!important;
  }

  html body #onc-center .onc-overview .onc-overview-panel .onc-preview-head .onc-preview-count {
    position:static;
    font-size:clamp(15px,1.5vw,22px)!important;
    margin:0!important;
  }

  @container onc-dashboard (min-width:850px) {
    html body #onc-center .onc-overview .onc-home-cluster {
      grid-template-columns:minmax(0,1fr) minmax(0,2.3fr) minmax(0,1fr);
      grid-template-rows:auto;
      align-items:center;
      column-gap:clamp(14px,2.6vw,38px);
    }

    #onc-center .onc-clock-feature {
      grid-area:1 / 2;
    }

    html body #onc-center .onc-overview .onc-action-panel { grid-area:1 / 1; }
    html body #onc-center .onc-overview .onc-followup-panel { grid-area:1 / 3; }

    html body #onc-center .onc-overview :is(.onc-action-cards,.onc-followup-panel .onc-home-right) {
      grid-template-columns:minmax(0,1fr);
    }

    #onc-center .onc-clock-feature .oa-home-clock-row {
      grid-template-columns:repeat(3,minmax(0,1fr));
      gap:clamp(8px,1.6dvh,14px);
    }

    #onc-center .onc-clock-feature .oa-home-clock-primary {
      grid-area:1 / 1 / 2 / -1;
      justify-self:center;
      width:min(80%,320px);
      block-size:clamp(116px,21dvh,172px);
      background:linear-gradient(150deg,#f0f9fff0,#c7e3f7dc);
      box-shadow:inset 0 1px #fff,0 12px 30px #244e7426;
      font-size:clamp(12px,1.9cqi,16px);
    }

    #onc-center .onc-clock-feature .oa-home-clock-primary time {
      font-size:clamp(46px,17cqi,80px);
    }
  }
}

@media screen and (max-width:760px) {
  html body #onc-center .onc-overview .onc-home-cluster {
    row-gap:6px;
  }

  #onc-center .onc-clock-feature .oa-home-clock-primary time {
    font-size:clamp(24px,9cqi,42px);
  }
}
