/* ConstructNav Takeoff Studio — additive full-screen workspace */
.cn-to-fs-control,
.cn-to-panel-button{
  align-items:center;
  display:inline-flex;
  gap:7px;
  justify-content:center;
  white-space:nowrap;
}

.cn-to-fs-button{
  background:#0b365c;
  border-color:#0b365c;
  color:#fff;
}

.cn-to-fs-button:hover{
  background:#082a48;
  border-color:#082a48;
}

.cn-to-fs-primary-button{
  background:linear-gradient(135deg,#0b365c,#174f7f);
  border:1px solid #0b365c;
  box-shadow:0 4px 12px rgba(11,54,92,.24);
  color:#fff;
  flex:0 0 auto;
  font-size:14px;
  font-weight:850;
  min-height:44px;
  order:-20;
  padding:10px 16px;
}

.cn-to-fs-primary-button:hover{
  background:linear-gradient(135deg,#082a48,#123f67);
  border-color:#082a48;
  box-shadow:0 5px 15px rgba(11,54,92,.3);
}

.cn-to-fs-primary-button:focus-visible{
  outline:3px solid rgba(43,108,176,.3);
  outline-offset:2px;
}

.cn-to-fs-control .cn-to-fs-icon{
  font-size:16px;
  line-height:1;
}

.cn-to-panel-button{
  display:none;
}

html.cn-takeoff-fullscreen,
html.cn-takeoff-fullscreen body{
  height:100%;
  overflow:hidden!important;
  overscroll-behavior:none;
}

#takeoff.cn-takeoff-is-fullscreen{
  background:#eef3f7;
  box-sizing:border-box;
  display:grid!important;
  grid-template-rows:auto auto auto minmax(0,1fr);
  height:100vh;
  height:100dvh;
  inset:0;
  margin:0!important;
  max-width:none!important;
  overflow:hidden;
  padding:10px 12px 12px!important;
  position:fixed;
  width:100vw;
  z-index:100000;
}

#takeoff.cn-takeoff-is-fullscreen > .section-head{
  align-items:center;
  background:#fff;
  border:1px solid #d6e0e8;
  border-radius:10px;
  box-shadow:0 3px 12px rgba(7,27,48,.08);
  gap:12px;
  margin:0 0 8px!important;
  min-width:0;
  padding:8px 10px;
}

#takeoff.cn-takeoff-is-fullscreen > .section-head h2{
  font-size:20px;
  line-height:1.15;
  margin:0;
}

#takeoff.cn-takeoff-is-fullscreen > .section-head p{
  font-size:12px;
  margin:2px 0 0;
}

#takeoff.cn-takeoff-is-fullscreen .to-link-controls{
  flex-wrap:nowrap;
  margin-left:auto;
  min-width:0;
}

#takeoff.cn-takeoff-is-fullscreen .to-project-select{
  min-width:150px;
  width:min(190px,16vw);
}

#takeoff.cn-takeoff-is-fullscreen .cn-to-panel-button{
  display:inline-flex;
}

#takeoff.cn-takeoff-is-fullscreen .cn-to-fs-button,
#takeoff.cn-takeoff-is-fullscreen .cn-to-fs-primary-button{
  background:#9d2f2f;
  border-color:#9d2f2f;
  box-shadow:0 2px 7px rgba(95,19,19,.2);
}

#takeoff.cn-takeoff-is-fullscreen .cn-to-fs-button:hover,
#takeoff.cn-takeoff-is-fullscreen .cn-to-fs-primary-button:hover{
  background:#822525;
  border-color:#822525;
}

#takeoff.cn-takeoff-is-fullscreen > .to-toolbar{
  align-items:center;
  background:#fff;
  border:1px solid #d6e0e8;
  border-radius:10px;
  box-shadow:0 3px 12px rgba(7,27,48,.06);
  display:flex;
  flex-wrap:nowrap;
  gap:6px;
  margin:0 0 7px!important;
  min-width:0;
  overflow-x:auto;
  overflow-y:hidden;
  padding:7px;
  scrollbar-color:#aebdca transparent;
  scrollbar-width:thin;
}

#takeoff.cn-takeoff-is-fullscreen > .to-toolbar > *{
  flex:0 0 auto;
}

#takeoff.cn-takeoff-is-fullscreen .to-file label,
#takeoff.cn-takeoff-is-fullscreen .to-tool{
  min-height:36px;
  padding:8px 10px;
}

#takeoff.cn-takeoff-is-fullscreen .to-file label{
  border-style:solid;
}

#takeoff.cn-takeoff-is-fullscreen .to-page-controls,
#takeoff.cn-takeoff-is-fullscreen .to-zoom-controls{
  background:#f4f7fa;
  border:1px solid #dce4eb;
  border-radius:8px;
  padding:3px;
}

#takeoff.cn-takeoff-is-fullscreen .to-zoom-controls{
  margin-left:0;
}

#takeoff.cn-takeoff-is-fullscreen > .to-status{
  box-sizing:border-box;
  margin:0 0 7px;
  min-height:30px;
  overflow:hidden;
  padding:6px 9px;
  text-overflow:ellipsis;
  white-space:nowrap;
}

#takeoff.cn-takeoff-is-fullscreen > .to-workspace{
  gap:10px;
  grid-template-columns:minmax(0,1fr) minmax(290px,340px);
  height:100%;
  margin-top:0!important;
  min-height:0;
  overflow:hidden;
}

#takeoff.cn-takeoff-is-fullscreen .to-viewer{
  border-radius:10px;
  height:100%;
  min-height:0;
}

#takeoff.cn-takeoff-is-fullscreen .to-empty{
  min-height:100%;
}

#takeoff.cn-takeoff-is-fullscreen .to-side{
  height:100%;
  min-height:0;
  overflow-x:hidden;
  overflow-y:auto;
  padding-right:3px;
  scrollbar-color:#aebdca transparent;
  scrollbar-width:thin;
}

#takeoff.cn-takeoff-is-fullscreen .to-panel{
  border-radius:10px;
  padding:12px;
}

#takeoff.cn-takeoff-is-fullscreen .to-measure-list{
  max-height:none;
}

#takeoff.cn-takeoff-is-fullscreen.cn-takeoff-panel-collapsed > .to-workspace{
  grid-template-columns:minmax(0,1fr);
}

#takeoff.cn-takeoff-is-fullscreen.cn-takeoff-panel-collapsed .to-side{
  display:none;
}

@media (max-width:1100px){
  #takeoff.cn-takeoff-is-fullscreen{
    padding:8px!important;
  }

  #takeoff.cn-takeoff-is-fullscreen > .section-head{
    align-items:flex-start;
  }

  #takeoff.cn-takeoff-is-fullscreen > .section-head > div:first-child p{
    display:none;
  }

  #takeoff.cn-takeoff-is-fullscreen .to-link-controls{
    overflow-x:auto;
    padding-bottom:2px;
  }

  #takeoff.cn-takeoff-is-fullscreen .to-project-select{
    min-width:130px;
    width:150px;
  }

  #takeoff.cn-takeoff-is-fullscreen > .to-workspace{
    grid-template-columns:minmax(0,1fr) minmax(270px,31vw);
  }
}

@media (max-width:760px){
  .cn-to-fs-button,
  .cn-to-fs-primary-button{
    min-height:42px;
  }

  #takeoff.cn-takeoff-is-fullscreen{
    grid-template-rows:auto auto auto minmax(0,1fr);
    padding:max(6px,env(safe-area-inset-top)) 6px max(6px,env(safe-area-inset-bottom))!important;
  }

  #takeoff.cn-takeoff-is-fullscreen > .section-head{
    display:flex;
    overflow-x:auto;
  }

  #takeoff.cn-takeoff-is-fullscreen > .section-head > div:first-child{
    display:none;
  }

  #takeoff.cn-takeoff-is-fullscreen .to-link-controls{
    margin-left:0;
    width:max-content;
  }

  #takeoff.cn-takeoff-is-fullscreen .to-project-select{
    min-width:145px;
    width:145px;
  }

  #takeoff.cn-takeoff-is-fullscreen > .to-workspace{
    grid-template-columns:minmax(0,1fr);
  }

  #takeoff.cn-takeoff-is-fullscreen .to-side{
    background:#eef3f7;
    bottom:6px;
    box-shadow:-8px 0 25px rgba(7,27,48,.2);
    display:flex;
    max-width:360px;
    padding:8px;
    position:absolute;
    right:6px;
    top:132px;
    width:calc(100vw - 28px);
    z-index:4;
  }

  #takeoff.cn-takeoff-is-fullscreen.cn-takeoff-panel-collapsed .to-side{
    display:none;
  }

  #takeoff.cn-takeoff-is-fullscreen .to-status{
    max-width:100%;
  }
}

@media (prefers-reduced-motion:reduce){
  #takeoff.cn-takeoff-is-fullscreen,
  #takeoff.cn-takeoff-is-fullscreen .to-side{
    scroll-behavior:auto;
  }
}
