:root {
      --brand: #254a4f;
      --shade: #f3f8f7;
      --white: #ffffff;
      --border: 1px solid #254a4f;
    }
    * { box-sizing: border-box; }
    html, body {
      margin: 0;
      padding: 0;
      font-family: system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
      color: var(--brand);
      background: var(--shade);
    }
    body {
      min-height: 100vh;
      display: flex;
      flex-direction: column;
    }
    header {
      background: var(--brand);
      color: var(--white);
      padding: 12px 20px;
      border-bottom: var(--border);
    }
    header .inner {
      max-width: 1200px;
      margin: 0 auto;
      display: flex;
      flex-direction: column;
      gap: 4px;
    }
    header h1 {
      margin: 0;
      font-size: 1.2rem;
      letter-spacing: 0.03em;
      text-transform: uppercase;
    }
    header .product {
      font-size: 1rem;
      font-weight: 600;
    }
    header .tagline {
      font-size: 0.9rem;
      opacity: 0.9;
    }

    main {
      flex: 1;
      max-width: 1200px;
      width: 100%;
      margin: 0 auto;
      padding: 16px;
    }
    .layout {
      display: grid;
      grid-template-columns: 260px minmax(0, 1fr) 260px;
      gap: 16px;
      align-items: flex-start;
    }
    @media (max-width: 960px) {
      .layout {
        grid-template-columns: 220px minmax(0, 1fr);
      }
      .pdf-panel {
        grid-column: span 2;
        order: 3;
      }
    }
    @media (max-width: 720px) {
      .layout {
        display: flex;
        flex-direction: column;
      }
      .sidebar {
        order: 1;
      }
      .content {
        order: 2;
      }
      .pdf-panel {
        order: 3;
      }
    }

    .sidebar, .content, .pdf-panel {
      background: var(--white);
      border: var(--border);
      border-radius: 14px;
      padding: 14px;
      box-shadow: 0 6px 18px rgba(0,0,0,0.04);
    }
    h2, h3, h4 {
      margin-top: 0;
      color: var(--brand);
    }

    .sidebar h2 {
      font-size: 1rem;
      margin-bottom: 8px;
    }
    .topic-list {
      display: flex;
      flex-direction: column;
      gap: 6px;
      max-height: 70vh;
      overflow-y: auto;
      padding-right: 4px;
    }
    .topic-btn {
      display: flex;
      flex-direction: column;
      align-items: flex-start;
      width: 100%;
      text-align: left;
      padding: 8px 10px;
      border-radius: 10px;
      border: 1px solid transparent;
      background: #f7fbfb;
      cursor: pointer;
      font: inherit;
      color: inherit;
    }
    .topic-btn span.title {
      font-size: 0.9rem;
      font-weight: 600;
    }
    .topic-btn span.meta {
      font-size: 0.75rem;
      opacity: 0.8;
    }
    .topic-btn:hover {
      border-color: #99cbd1;
      background: #f0f6f6;
    }
    .topic-btn.active {
      border-color: var(--brand);
      background: #e3f0f0;
    }

    .content {
      min-height: 320px;
    }
    .search-box {
      margin-bottom: 10px;
    }
    .search-box label {
      display: block;
      font-size: 0.8rem;
      font-weight: 600;
      margin-bottom: 4px;
    }
    .search-row {
      display: flex;
      gap: 8px;
    }
    .search-row input {
      flex: 1;
      padding: 8px 10px;
      border-radius: 999px;
      border: var(--border);
      font: inherit;
    }
    .search-row button {
      padding: 8px 14px;
      border-radius: 999px;
      border: var(--border);
      background: var(--shade);
      font: inherit;
      cursor: pointer;
      font-weight: 600;
    }
    .search-row button:hover {
      filter: brightness(0.97);
    }
    .search-hint {
      font-size: 0.75rem;
      margin-top: 4px;
      opacity: 0.8;
    }

    .search-results {
      margin: 8px 0 14px;
      border-radius: 10px;
      border: 1px dashed #b2c9cb;
      padding: 8px 10px;
      background: #f8fbfb;
      max-height: 240px;
      overflow-y: auto;
    }
    .search-results h3 {
      font-size: 0.9rem;
      margin: 0 0 4px;
    }
    .result-item {
      padding: 6px 4px;
      border-radius: 6px;
      cursor: pointer;
    }
    .result-item:hover {
      background: #e8f2f2;
    }
    .result-item-title {
      font-size: 0.85rem;
      font-weight: 600;
    }
    .result-item-snippet {
      font-size: 0.75rem;
      opacity: 0.85;
    }

    #topicContent h2 {
      font-size: 1.1rem;
      margin-bottom: 6px;
    }
    #topicContent .lede {
      font-size: 0.9rem;
      font-weight: 500;
      margin-bottom: 10px;
    }
    #topicContent p {
      font-size: 0.88rem;
      line-height: 1.6;
      margin-top: 0;
      margin-bottom: 8px;
    }
    .badge {
      display: inline-block;
      font-size: 0.7rem;
      padding: 3px 7px;
      border-radius: 999px;
      border: 1px solid #b2c9cb;
      background: #f5faf9;
      margin-bottom: 6px;
    }

    .pdf-panel h3 {
      font-size: 0.95rem;
      margin-bottom: 6px;
    }
    .pdf-panel p {
      font-size: 0.8rem;
      line-height: 1.5;
      margin-top: 0;
      margin-bottom: 8px;
    }
    .primary-btn {
      display: inline-block;
      padding: 9px 14px;
      border-radius: 999px;
      border: var(--border);
      background: var(--shade);
      color: var(--brand);
      font-size: 0.85rem;
      font-weight: 700;
      text-decoration: none;
      text-align: center;
    }
    .primary-btn:hover {
      filter: brightness(0.97);
    }

    .primary-btn.secondary {
      margin-top: 6px;
      font-weight: 600;
      opacity: 0.95;
    }

    .pdf-meta {
      font-size: 0.75rem;
      opacity: 0.9;
      margin-top: 6px;
    }

    footer {
      padding: 10px 16px 14px;
      font-size: 0.75rem;
      text-align: center;
      color: rgba(37,74,79,0.8);
    }