* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    background: #f4f7fb;
    color: #1f2937;
}

/* Navigation */

nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 40px;
    background: #173b63;
    color: #ffffff;
}

.logo {
    font-size: 22px;
    font-weight: 700;
}

nav ul {
    display: flex;
    gap: 24px;
    margin: 0;
    padding: 0;
    list-style: none;
}

nav a {
    color: #ffffff;
    text-decoration: none;
    font-weight: 600;
}

nav a:hover {
    text-decoration: underline;
}

/* Header */

.home-header {
    padding: 10px 16px;
    text-align: center;
    background: linear-gradient(135deg, #173b63, #2563a8);
    color: #ffffff;
}

.eyebrow {
    margin: 0 0 10px;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    opacity: 0.85;
}

.home-header h1 {
    margin: 0;
    font-size: 42px;
}

.header-description {
    max-width: 700px;
    margin: 18px auto 0;
    line-height: 1.6;
    font-size: 18px;
}

/* Main layout */

.home-layout {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr);
    gap: 28px;
    max-width: 1200px;
    margin: 36px auto;
    padding: 0 24px;
}

/* Chat section */

.chat-box { 
  display: flex; 
  flex-direction: column; 
  height: calc(100vh - 100px); /* Reduced subtracted space to make it taller */
  min-height: 620px; 
  max-height: 900px; /* Increased from 760px for extra height */
  background: #ffffff; 
  border: 1px solid #dbe3ec; 
  border-radius: 16px; 
  overflow: hidden; 
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}


.chat-header {
    padding: 24px;
    background: #eef4fb;
    border-bottom: 1px solid #dbe3ec;
}

.chat-header h2 {
    margin: 0 0 8px;
    color: #173b63;
}

.chat-header p {
    margin: 0;
    color: #52606d;
}

.chat-messages {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 24px;
    overflow-y: auto;
}

.message {
    max-width: 78%;
    padding: 12px 16px;
    border-radius: 14px;
    line-height: 1.5;
    white-space: pre-line;
}

.bot-message {
    align-self: flex-start;
    background: #edf3f9;
    color: #243b53;
    border-bottom-left-radius: 4px;
}

.user-message {
    align-self: flex-end;
    background: #2563eb;
    color: #ffffff;
    border-bottom-right-radius: 4px;
}

.chat-input-area {
    display: flex;
    gap: 12px;
    padding: 18px;
    background: #ffffff;
    border-top: 1px solid #dbe3ec;
    flex-shrink: 0;
}

.input-wrapper {
    position: relative;
    flex: 1;
}

#userInput {
    width: 100%;
    padding: 13px 14px;
    border: 1px solid #b8c5d3;
    border-radius: 9px;
    font-size: 16px;
    outline: none;
}

#userInput:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

#sendButton {
    padding: 0 22px;
    background: #2563eb;
    color: #ffffff;
    border: none;
    border-radius: 9px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
}

#sendButton:hover {
    background: #1d4ed8;
}

/* Autocomplete suggestions */

.suggestions {
    position: absolute;
    left: 0;
    right: 0;
    bottom: calc(100% + 8px);
    display: none;
    max-height: 260px;
    overflow-y: auto;
    background: #ffffff;
    border: 1px solid #d9e2ec;
    border-radius: 10px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
    z-index: 20;
}

.suggestion-item {
    display: flex;
    flex-direction: column;
    gap: 3px;
    padding: 12px 14px;
    cursor: pointer;
    border-bottom: 1px solid #edf2f7;
}

.suggestion-item:last-child {
    border-bottom: none;
}

.suggestion-item:hover {
    background: #f0f5ff;
}

.suggestion-topic {
    color: #173b63;
    font-weight: 700;
}

.suggestion-hint {
    color: #6b7c93;
    font-size: 12px;
}

/* Sidebar */

.home-sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.sidebar-card {
    padding: 22px;
    background: #ffffff;
    border: 1px solid #dbe3ec;
    border-radius: 14px;
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.06);
}

.sidebar-card h2 {
    margin-top: 0;
    color: #173b63;
}

.sidebar-card p {
    color: #52606d;
    line-height: 1.6;
}

.primary-link,
.popular-article {
    display: block;
    margin-top: 12px;
    color: #2563eb;
    text-decoration: none;
    font-weight: 700;
}

.primary-link:hover,
.popular-article:hover {
    text-decoration: underline;
}

.coming-soon {
    display: block;
    margin-top: 12px;
    color: #6b7280;
}

/* Knowledge article response card */

.article-message {
    width: 100%;
    max-width: 560px;
    padding: 0;
    background: transparent;
}

.response-card {
    width: 100%;
    padding: 22px;
    background: #ffffff;
    border: 1px solid #d9e2ec;
    border-left: 5px solid #2563eb;
    border-radius: 12px;
    box-sizing: border-box;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
}

.response-title {
    margin: 0 0 10px;
    font-size: 20px;
    color: #172b4d;
}

.category-badge {
    display: inline-block;
    margin-bottom: 18px;
    padding: 5px 11px;
    background: #e8f0ff;
    color: #1d4ed8;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
}

.section-label {
    margin: 5px 0 6px;
    color: #52606d;
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.response-summary {
    margin: 0;
    color: #334e68;
    line-height: 1.6;
}

.response-divider {
    margin: 18px 0;
    border: 0;
    border-top: 1px solid #d9e2ec;
}

.response-answer {
    color: #243b53;
    line-height: 1.7;
    white-space: pre-line;
}

.related-articles {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

.related-button {
    padding: 8px 12px;
    background: #f0f5ff;
    color: #1d4ed8;
    border: 1px solid #b6ccfe;
    border-radius: 7px;
    font-family: inherit;
    font-size: 14px;
    cursor: pointer;
}

.related-button:hover {
    background: #dbe8ff;
    border-color: #7da2f8;
}

/* Responsive layout */

@media (max-width: 850px) {
    nav {
        flex-direction: column;
        gap: 14px;
        padding: 18px 20px;
    }

    nav ul {
        flex-wrap: wrap;
        justify-content: center;
    }

    .home-header {
        padding: 42px 20px 30px;
    }

    .home-header h1 {
        font-size: 34px;
    }

    .home-layout {
        grid-template-columns: 1fr;
        padding: 0 16px;
    }

    .chat-box {
        min-height: 560px;
    }

    .message {
        max-width: 90%;
    }
}

@media (max-width: 560px) {
    .chat-input-area {
        flex-direction: column;
    }

    #sendButton {
        min-height: 46px;
    }

    .home-header h1 {
        font-size: 30px;
    }
}
/* ChatGPT typing indicator */

.typing {
    display: flex;
    gap: 6px;
    align-items: center;
}

.typing span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #4f73c8;
    animation: bounce 1.2s infinite;
}

.typing span:nth-child(2) {
    animation-delay: .2s;
}

.typing span:nth-child(3) {
    animation-delay: .4s;
}

@keyframes bounce {

    0%,80%,100%{
        transform: translateY(0);
        opacity:.4;
    }

    40%{
        transform: translateY(-7px);
        opacity:1;
    }

}
.message {

    animation: fadeIn .35s ease;

}

@keyframes fadeIn{

from{

opacity:0;
transform:translateY(10px);

}

to{

opacity:1;
transform:translateY(0);

}

}
.response-card{

transition:.25s;

}

.response-card:hover{

transform:translateY(-4px);

box-shadow:0 12px 30px rgba(0,0,0,.15);

}
/* Category browser */

.category-browser-card {
    overflow: hidden;
}

.category-browser {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 18px 0;
}

.category-section {
    overflow: hidden;
    border: 1px solid #dbe3ec;
    border-radius: 10px;
    background: #ffffff;
}

.category-toggle {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 13px 14px;
    background: #f5f8fc;
    color: #173b63;
    border: none;
    font-family: inherit;
    font-size: 15px;
    font-weight: 700;
    text-align: left;
    cursor: pointer;
}

.category-toggle:hover {
    background: #eaf1fa;
}

.category-toggle.active {
    background: #173b63;
    color: #ffffff;
}

.category-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 26px;
    height: 26px;
    padding: 0 8px;
    background: #dce9f8;
    color: #173b63;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
}

.category-toggle.active .category-count {
    background: #ffffff;
    color: #173b63;
}

.category-article-list {
    display: none;
    flex-direction: column;
    padding: 8px;
    background: #ffffff;
    border-top: 1px solid #dbe3ec;
}

.category-article-list.open {
    display: flex;
}

.category-article-button {
    width: 100%;
    padding: 10px 11px;
    background: transparent;
    color: #334e68;
    border: none;
    border-radius: 7px;
    font-family: inherit;
    font-size: 14px;
    text-align: left;
    cursor: pointer;
}

.category-article-button:hover {
    background: #eef4fb;
    color: #1d4ed8;
}
/* Favorite articles */

.article-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
}

.article-heading .response-title {
    flex: 1;
}

.favorite-article-button {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    padding: 0;
    background: #f5f8fc;
    color: #6b7280;
    border: 1px solid #d9e2ec;
    border-radius: 50%;
    font-family: inherit;
    font-size: 25px;
    line-height: 1;
    cursor: pointer;
    transition: 0.2s ease;
}

.favorite-article-button:hover {
    background: #fff7d6;
    color: #d97706;
    border-color: #f4c95d;
    transform: scale(1.06);
}

.favorite-article-button.active {
    background: #fff7d6;
    color: #d97706;
    border-color: #f4c95d;
}

.favorites-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 16px;
}

.favorites-empty {
    color: #6b7280;
    font-size: 14px;
    font-style: italic;
}

.favorite-item {
    display: flex;
    align-items: stretch;
    overflow: hidden;
    border: 1px solid #dbe3ec;
    border-radius: 8px;
}

.favorite-open-button {
    flex: 1;
    padding: 10px 12px;
    background: #f5f8fc;
    color: #173b63;
    border: none;
    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
    text-align: left;
    cursor: pointer;
}

.favorite-open-button:hover {
    background: #eaf1fa;
    color: #1d4ed8;
}

.favorite-remove-button {
    width: 40px;
    background: #ffffff;
    color: #6b7280;
    border: none;
    border-left: 1px solid #dbe3ec;
    font-family: inherit;
    font-size: 22px;
    cursor: pointer;
}

.favorite-remove-button:hover {
    background: #fee2e2;
    color: #b91c1c;
}
/* Admin dashboard */

.admin-header {
    padding: 48px 40px 34px;
    text-align: center;
    background: linear-gradient(135deg, #173b63, #2563a8);
    color: #ffffff;
}

.admin-header h1 {
    margin: 0;
    font-size: 40px;
}

.admin-layout {
    max-width: 1200px;
    margin: 36px auto;
    padding: 0 24px 40px;
}

.admin-stat-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px;
    margin-bottom: 28px;
}

.admin-stat-card {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 24px;
    background: #ffffff;
    border: 1px solid #dbe3ec;
    border-radius: 14px;
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.06);
}

.admin-stat-label {
    color: #52606d;
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.admin-stat-number {
    color: #173b63;
    font-size: 38px;
}

.admin-panel {
    padding: 26px;
    background: #ffffff;
    border: 1px solid #dbe3ec;
    border-radius: 14px;
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.06);
}

.admin-panel-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 22px;
}

.admin-panel-heading h2 {
    margin: 0 0 8px;
    color: #173b63;
}

.admin-panel-heading p {
    margin: 0;
    color: #52606d;
}

.admin-danger-button {
    flex-shrink: 0;
    padding: 10px 15px;
    background: #ffffff;
    color: #b91c1c;
    border: 1px solid #f1a7a7;
    border-radius: 8px;
    font-family: inherit;
    font-weight: 700;
    cursor: pointer;
}

.admin-danger-button:hover {
    background: #fee2e2;
}

.unanswered-questions-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.unanswered-question-card {
    padding: 18px;
    background: #f8fafc;
    border: 1px solid #dbe3ec;
    border-left: 4px solid #2563eb;
    border-radius: 10px;
}

.unanswered-question-card h3 {
    margin: 0 0 12px;
    color: #243b53;
    font-size: 17px;
}

.unanswered-question-details {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    color: #6b7280;
    font-size: 13px;
}

.admin-empty-message {
    margin: 0;
    padding: 20px;
    color: #6b7280;
    text-align: center;
    background: #f8fafc;
    border: 1px dashed #cbd5e1;
    border-radius: 10px;
}

@media (max-width: 900px) {
    .admin-stat-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 560px) {
    .admin-header {
        padding: 38px 20px 28px;
    }

    .admin-header h1 {
        font-size: 31px;
    }

    .admin-stat-grid {
        grid-template-columns: 1fr;
    }

    .admin-panel-heading {
        flex-direction: column;
    }

    .admin-danger-button {
        width: 100%;
    }
}
/* ======================================================
   TOP VIEWED ARTICLES
   ====================================================== */

.top-articles-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 20px;
}

.top-article-item {
    display: grid;
    grid-template-columns: 45px 1fr auto;
    align-items: center;
    gap: 16px;
    padding: 16px 18px;
    background: #f7f9fc;
    border: 1px solid #d8e1ec;
    border-radius: 12px;
}

.top-article-rank {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #1f5f9f;
    color: white;
    font-weight: 700;
}

.top-article-topic {
    font-size: 16px;
    font-weight: 600;
    color: #163b66;
}

.top-article-views {
    font-size: 14px;
    font-weight: 600;
    color: #58677a;
    white-space: nowrap;
}

@media (max-width: 600px) {
    .top-article-item {
        grid-template-columns: 40px 1fr;
    }

    .top-article-views {
        grid-column: 2;
    }
}
/* ======================================================
   DASHBOARD
====================================================== */

.knowledge-dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.knowledge-dashboard-card {
    display: flex;
    align-items: center;
    gap: 18px;

    background: #ffffff;

    border-radius: 14px;

    padding: 20px;

    border: 1px solid #e5e7eb;

    box-shadow: 0 6px 18px rgba(0,0,0,.08);

    transition: all .25s ease;
}

.knowledge-dashboard-card:hover {
    transform: translateY(-4px);

    box-shadow: 0 10px 26px rgba(0,0,0,.15);
}

.knowledge-dashboard-icon {

    width: 58px;
    height: 58px;

    border-radius: 50%;

    background: #0f4c81;

    color: white;

    display: flex;

    align-items: center;

    justify-content: center;

    font-size: 28px;

    flex-shrink: 0;
}

.knowledge-dashboard-label {

    display: block;

    color: #6b7280;

    font-size: .9rem;

    margin-bottom: 6px;
}

.knowledge-dashboard-number {

    display: block;

    font-size: 2rem;

    font-weight: 700;

    color: #111827;
}

.knowledge-dashboard-date {

    display: block;

    font-size: 1rem;

    font-weight: 600;

    color: #111827;
}
/* ======================================================
   ADMIN LAYOUT
====================================================== */

.admin-main {

    display: grid;

    grid-template-columns: 260px 1fr;

    gap: 30px;

    align-items: start;

    max-width: 1600px;

    margin: 30px auto;

    padding: 0 25px;
}

.admin-sidebar {

    background: #0f4c81;

    color: white;

    border-radius: 16px;

    padding: 24px;

    position: sticky;

    top: 20px;

    min-height: 700px;
}

.sidebar-logo {

    text-align: center;

    margin-bottom: 35px;
}

.sidebar-logo h2 {

    margin-top: 12px;

    font-size: 1.4rem;
}

.sidebar-nav {

    display: flex;

    flex-direction: column;

    gap: 12px;
}

.sidebar-link {

    color: white;

    text-decoration: none;

    padding: 14px 18px;

    border-radius: 10px;

    transition: .25s;

    font-weight: 600;
}

.sidebar-link:hover {

    background: rgba(255,255,255,.15);
}

.sidebar-link.active {

    background: white;

    color: #0f4c81;
}
/* ======================================================
   KNOWLEDGE MANAGER CONTROLS
====================================================== */

.knowledge-heading-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.knowledge-primary-button,
.knowledge-secondary-button,
.knowledge-edit-button,
.knowledge-delete-button {
    border: none;
    border-radius: 9px;
    padding: 10px 16px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease,
        background 0.2s ease;
}

.knowledge-primary-button {
    background: #0f5c9e;
    color: #ffffff;
    box-shadow: 0 4px 10px rgba(15, 92, 158, 0.25);
}

.knowledge-primary-button:hover {
    background: #0b4d87;
    transform: translateY(-2px);
    box-shadow: 0 7px 15px rgba(15, 92, 158, 0.3);
}

.knowledge-secondary-button {
    background: #eef4fa;
    color: #174a73;
    border: 1px solid #cbd9e7;
}

.knowledge-secondary-button:hover {
    background: #dfeaf5;
    transform: translateY(-2px);
}
.knowledge-favorite-button{
    background:#fff8dc;
    color:#9a6700;
}

.knowledge-favorite-button:hover{
    background:#ffe9a8;
    transform:translateY(-2px);
}
.knowledge-edit-button {
    background: #e8f3ff;
    color: #145b91;
}

.knowledge-edit-button:hover {
    background: #d5eaff;
    transform: translateY(-2px);
}

.knowledge-delete-button {
    background: #fff0f0;
    color: #a22c2c;
}

.knowledge-delete-button:hover {
    background: #ffdede;
    transform: translateY(-2px);
}

.knowledge-toolbar {
    margin-top: 22px;
    margin-bottom: 22px;
}

.knowledge-search-input {
    width: 100%;
    max-width: 560px;
    padding: 13px 16px;
    border: 1px solid #cdd7e2;
    border-radius: 10px;
    background: #ffffff;
    font-size: 1rem;
    outline: none;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.knowledge-search-input:focus {
    border-color: #2473b7;
    box-shadow: 0 0 0 4px rgba(36, 115, 183, 0.13);
}

.knowledge-article-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}
/* ======================================================
   RECENT ACTIVITY
====================================================== */

.recent-activity-list{
    display:flex;
    flex-direction:column;
    gap:14px;
}

.recent-activity-item{
    display:flex;
    justify-content:space-between;
    align-items:center;
    padding:16px 18px;
    border:1px solid #e5e7eb;
    border-radius:12px;
    background:#ffffff;
    transition:all .2s ease;
}

.recent-activity-item:hover{
    background:#f8fafc;
    border-color:#cbd5e1;
}

.recent-activity-details{
    display:flex;
    flex-direction:column;
    gap:4px;
}

.recent-activity-details strong{
    color:#1e3a8a;
    font-size:15px;
}

.recent-activity-details > span:not(.activity-badge){
    color:#64748b;
    font-size:14px;
}

.recent-activity-date{
    color:#94a3b8;
    font-size:13px;
    white-space:nowrap;
}
/* ======================================================
   ACTIVITY BADGES
====================================================== */

.activity-badge{
    display:inline-block;
    padding:4px 10px;
    border-radius:999px;
    font-size:12px;
    font-weight:600;
    letter-spacing:.3px;
    color:#ffffff;
    margin-bottom:4px;
}

.activity-title{
    color:#64748b;
    font-size:14px;
}

.created-article{
    background:#16a34a;
}

.updated-article{
    background:#f59e0b;
}

.deleted-article{
    background:#dc2626;
}

.imported-knowledge-base{
    background:#2563eb;
}

.exported-knowledge-base{
    background:#7c3aed;
}
/* =====================================================
   SKYCHAT v1.0 PILOT HOME-PAGE POLISH
   ===================================================== */
:root {
    --sky-navy: #12385f;
    --sky-blue: #2468ad;
    --sky-light: #eaf3fb;
    --sky-accent: #f0b429;
    --ink: #172b4d;
    --muted: #5d6b7a;
    --line: #d8e2ec;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.app-nav {
    position: sticky;
    top: 0;
    z-index: 100;
    padding: 12px 40px;
    box-shadow: 0 6px 22px rgba(14, 40, 70, .18);
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: #fff;
}

.brand img {
    width: 58px;
    height: 58px;
    object-fit: contain;
    border-radius: 12px;
    background: #fff;
    padding: 4px;
}

.brand-copy {
    display: flex;
    flex-direction: column;
    line-height: 1.15;
}

.brand-copy strong { font-size: 20px; }
.brand-copy small { margin-top: 4px; opacity: .78; }
.app-nav a.active { border-bottom: 2px solid var(--sky-accent); padding-bottom: 5px; }

.home-header {
    position: relative;
    overflow: hidden;
    padding-top: 48px;
    background:
        radial-gradient(circle at 15% 20%, rgba(255,255,255,.13), transparent 28%),
        radial-gradient(circle at 85% 10%, rgba(255,255,255,.10), transparent 24%),
        linear-gradient(135deg, #12385f, #2468ad);
}

.pilot-badge {
    display: inline-flex;
    margin-bottom: 14px;
    padding: 7px 12px;
    border: 1px solid rgba(255,255,255,.4);
    border-radius: 999px;
    background: rgba(255,255,255,.12);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .6px;
    text-transform: uppercase;
}

.stat-strip {
    display: grid;
    grid-template-columns: repeat(4, minmax(110px, 1fr));
    max-width: 720px;
    margin: 30px auto 0;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,.2);
    border-radius: 14px;
    background: rgba(8, 34, 62, .24);
    backdrop-filter: blur(6px);
}

.stat-strip div { padding: 14px 12px; border-right: 1px solid rgba(255,255,255,.15); }
.stat-strip div:last-child { border-right: 0; }
.stat-strip strong, .stat-strip span { display: block; }
.stat-strip strong { font-size: 20px; }
.stat-strip span { margin-top: 3px; font-size: 12px; opacity: .78; }

.chat-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

.online-indicator {
    display: inline-block;
    margin-bottom: 7px;
    color: #27864b;
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .5px;
}

.secondary-button {
    flex-shrink: 0;
    padding: 9px 12px;
    border: 1px solid #b9c9d9;
    border-radius: 8px;
    background: #fff;
    color: var(--sky-navy);
    font-weight: 700;
    cursor: pointer;
}

.secondary-button:hover { background: #f4f8fc; }

.quick-topics {
    display: flex;
    gap: 8px;
    padding: 14px 18px;
    overflow-x: auto;
    border-bottom: 1px solid var(--line);
    background: #fbfdff;
}

.quick-topics button {
    flex: 0 0 auto;
    padding: 8px 12px;
    border: 1px solid #bfd2e5;
    border-radius: 999px;
    background: #fff;
    color: var(--sky-navy);
    font-family: inherit;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
}

.quick-topics button:hover { background: var(--sky-light); border-color: #7fa9d2; }

.welcome-message {
    display: flex;
    flex-direction: column;
    gap: 7px;
    padding: 17px 18px;
}

.welcome-message strong { color: var(--sky-navy); font-size: 16px; }
.welcome-message span { color: #43576c; }

#sendButton { min-width: 154px; }

.pilot-notice {
    margin: 0;
    padding: 9px 18px 13px;
    background: #fff;
    color: #68798a;
    font-size: 12px;
    text-align: center;
}

.card-kicker {
    display: block;
    margin-bottom: 6px;
    color: var(--sky-blue);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .8px;
    text-transform: uppercase;
}

.app-footer {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    padding: 24px 40px;
    background: #0d2c4b;
    color: rgba(255,255,255,.78);
    font-size: 13px;
}

@media (max-width: 850px) {
    .app-nav { position: static; }
    .brand-copy { align-items: center; }
    .stat-strip { grid-template-columns: repeat(2, 1fr); }
    .stat-strip div:nth-child(2) { border-right: 0; }
    .stat-strip div:nth-child(-n+2) { border-bottom: 1px solid rgba(255,255,255,.15); }
}

@media (max-width: 560px) {
    .brand img { width: 52px; height: 52px; }
    .chat-header { align-items: flex-start; }
    .secondary-button { font-size: 12px; }
    #sendButton { min-width: 0; }
    .app-footer { flex-direction: column; padding: 20px; text-align: center; }
}
.article-source {
    margin-top: 8px;
}

.source-manual {
    margin: 0 0 4px;
    font-weight: 600;
    line-height: 1.5;
}

.source-page {
    margin: 0;
    font-size: 0.9rem;
    color: #52627a;
}
/* ==========================================
   Structured Knowledge Article Sections
========================================== */

.article-purpose {
    margin: 8px 0 12px;
    line-height: 1.6;
    color: #2f3b52;
}

.article-navigation {
    margin: 8px 0 12px;
    font-weight: 600;
    color: #0b5cab;
    line-height: 1.6;
}

.article-procedure,
.article-notes {
    margin: 8px 0 12px;
    padding-left: 24px;
}

.article-procedure li,
.article-notes li {
    margin-bottom: 8px;
    line-height: 1.6;
}

.article-source {
    margin-top: 10px;
}

.source-manual {
    margin: 0 0 4px;
    font-weight: 600;
    color: #1f2937;
}

.source-page {
    margin: 0;
    color: #6b7280;
    font-size: 0.9rem;
}