html,
body {
  max-width: 100%;
  overflow-x: clip;
}

.server-page-title {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  left: 12px;
  top: 12px;
  z-index: 1000;
  padding: 11px 16px;
  border-radius: 8px;
  background: #10272e;
  color: #fff;
  transform: translateY(-180%);
}

.skip-link:focus { transform: none; }

button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 3px solid #f5a623;
  outline-offset: 3px;
}

.header-inner,
.workspace,
.main-panel,
.toolbar,
.search,
.search input,
.content,
.hero,
.info-page,
.contact-layout,
.contact-form-wrap {
  min-width: 0;
}

body.drawer-open { overflow: hidden; }

.drawer { overflow-y: auto; }
.drawer-head { position: sticky; top: -28px; z-index: 2; background: #fff; padding: 28px 0 12px; }
.quote-clear {
  width: 100%;
  margin-top: 10px;
  padding: 11px 14px;
  border: 1px solid #b7d3d8;
  border-radius: 9px;
  background: #fff;
  color: #8a3030;
  font-weight: 750;
}
.quote-item h4[role="link"] { cursor: pointer; color: #075c72; }
.quote-item h4[role="link"]:hover { text-decoration: underline; }
.form-honeypot { position: absolute !important; left: -10000px !important; width: 1px !important; height: 1px !important; overflow: hidden !important; }
.form-status.is-error { color: #a22d2d !important; }
.form-status.is-success { color: #167042 !important; font-weight: 700; }
.quote-empty-warning { margin: 12px 0; color: #a22d2d; font-size: 13px; }
.consent a { color: #057d9f; font-weight: 750; }
.mobile-menu-toggle { display: none; }

@media (max-width: 800px) {
  .topbar-inner,
  .header-inner,
  .workspace {
    width: 100% !important;
    max-width: 100% !important;
    padding-left: 14px;
    padding-right: 14px;
  }
  .header-inner { gap: 8px; }
  .header .logo { min-width: 0; }
  .header .site-logo { width: 118px; height: 62px; }
  .header-actions { order: 2; gap: 4px; margin-left: auto; }
  .quote-btn { display: inline-flex; align-items: center; gap: 5px; padding: 10px 11px; white-space: nowrap; }
  .quote-btn > span:not(.quote-count) { display: none; }
  .quote-btn .quote-count { margin-left: 0; }

  .mobile-menu-toggle {
    display: inline-grid;
    place-items: center;
    width: 44px;
    height: 44px;
    order: 3;
    flex: 0 0 44px;
    border: 1px solid var(--line);
    border-radius: 9px;
    background: #fff;
    color: var(--ink);
    font-size: 22px;
  }
  .main-nav { order: 4; }
  .main-nav.mobile-open {
    display: flex;
    position: absolute;
    top: 68px;
    left: 14px;
    right: 14px;
    z-index: 50;
    flex-direction: column;
    gap: 3px;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fff;
    box-shadow: var(--shadow);
  }
  .main-nav.mobile-open .nav-btn { display: block; width: 100%; min-height: 44px; text-align: left; }

  .main-panel,
  .content,
  .hero,
  .info-page { width: 100% !important; max-width: 100% !important; }
  .toolbar { display: grid; width: 100%; max-width: 100%; grid-template-columns: minmax(0, 1fr) 44px 44px; }
  .toolbar .search { grid-column: 1 / -1; width: 100%; }
  .search { overflow: hidden; }
  .search input { width: 0; min-width: 0; }
  .hero h1, .info-hero h1, .contact-hero h1 { overflow-wrap: anywhere; }
  .hero p, .info-page p { overflow-wrap: anywhere; }
  .drawer { width: min(100%, 460px); }
  .primary, .secondary, .view-btn, .tree button, .folder { min-height: 44px; }
}

@media (max-width: 370px) {
  .header .site-logo { width: 100px; }
  .header-inner { width: calc(100% - 20px); }
  .toolbar { grid-template-columns: minmax(0, 1fr) 42px 42px; }
  .hero { padding: 24px 20px; }
  .hero h1 { font-size: 29px; }
}
