:root {
    color-scheme: light;
    --bg: #ffffff;
    --page: #ffffff;
    --sidebar: #f8f9fb;
    --surface: #ffffff;
    --surface-hover: #f1f3f6;
    --text: #202123;
    --muted: #777b84;
    --subtle: #9ba0a9;
    --border: #e5e7eb;
    --accent: #2563eb;
    --accent-hover: #1d4ed8;
    --accent-soft: #eff6ff;
    --success: #16a34a;
    --danger: #dc2626;
    --shadow: 0 12px 36px rgba(15, 23, 42, .08);
    --radius: 16px;
}

* {
    box-sizing: border-box;
}

html {
    height: 100%;
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    min-height: 100%;
    color: var(--text);
    background: var(--bg);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system,
        BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: 14px;
    -webkit-font-smoothing: antialiased;
}

button,
textarea {
    font: inherit;
}

button {
    color: inherit;
}

button:focus-visible,
textarea:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
}

button:disabled {
    cursor: not-allowed;
    opacity: .5;
}

button:not(:disabled) {
    -webkit-tap-highlight-color: transparent;
}

[hidden] {
    display: none !important;
}

.app-shell {
    display: flex;
    width: 100%;
    height: 100dvh;
    min-height: 420px;
    overflow: hidden;
    background: var(--page);
}

/* SIDEBAR */

.sidebar {
    width: 270px;
    min-width: 270px;
    display: flex;
    flex-direction: column;
    gap: 25px;
    padding: 22px 15px 15px;
    background: var(--sidebar);
    border-right: 1px solid var(--border);
    transition: transform .25s ease;
    z-index: 50;
}

.sidebar-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 5px;
}

.brand,
.dialog-brand {
    display: inline-flex;
    align-items: center;
    gap: 11px;
    text-decoration: none;
    color: var(--text);
    min-width: 0;
}

.brand-logo {
    width: 39px;
    height: 39px;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 13px;
    background: linear-gradient(145deg, #3977f6, #2053d6);
    color: #fff;
    font-size: 17px;
    box-shadow: 0 4px 10px rgba(37, 99, 235, .2);
}

.brand-copy {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.brand-copy strong {
    font-size: 15px;
    letter-spacing: .4px;
}

.brand-copy small {
    color: var(--muted);
    font-size: 11px;
}

.icon-button {
    width: 38px;
    height: 38px;
    display: inline-flex;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: var(--muted);
    cursor: pointer;
    transition: background .18s, color .18s, transform .18s;
}

.icon-button:hover {
    background: var(--surface-hover);
    color: var(--text);
}

.icon-button:active {
    transform: scale(.95);
}

.sidebar-close,
.menu-toggle,
.mobile-brand {
    display: none;
}

.new-chat-button {
    width: 100%;
    min-height: 45px;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 12px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--surface);
    font-size: 13px;
    font-weight: 600;
    text-align: left;
    cursor: pointer;
    transition: background .2s, border-color .2s;
}

.new-chat-button:hover {
    background: var(--surface-hover);
    border-color: #d2d6de;
}

.new-chat-button > i {
    font-size: 14px;
}

.shortcut {
    margin-left: auto;
    color: var(--subtle);
    font-size: 10px;
    font-weight: 500;
}

.sidebar-section {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.section-label {
    padding: 0 10px 9px;
    color: var(--subtle);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1px;
}

.sidebar-prompt {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 10px;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: var(--muted);
    text-align: left;
    font-size: 12px;
    cursor: pointer;
    transition: background .18s, color .18s;
}

.sidebar-prompt i {
    width: 17px;
    text-align: center;
    color: var(--subtle);
}

.sidebar-prompt:hover {
    background: var(--surface-hover);
    color: var(--text);
}

.sidebar-prompt:hover i {
    color: var(--accent);
}

.sidebar-spacer {
    flex: 1;
    min-height: 20px;
}

.sidebar-status {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 8px 5px;
    border-top: 1px solid var(--border);
}

.status-indicator,
.tiny-status {
    width: 8px;
    height: 8px;
    display: inline-block;
    flex-shrink: 0;
    border-radius: 50%;
    background: var(--success);
}

.status-indicator.is-busy {
    background: #f59e0b;
}

.status-indicator.is-error {
    background: var(--danger);
}

.status-copy {
    min-width: 0;
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 4px;
}

.status-copy strong {
    font-size: 11px;
    font-weight: 600;
}

.status-copy small {
    color: var(--muted);
    font-size: 10px;
}

/* MAIN AND TOPBAR */

.main-panel {
    display: flex;
    flex: 1;
    flex-direction: column;
    min-width: 0;
    min-height: 0;
    background: var(--page);
}

.topbar {
    min-height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    padding: 0 27px;
    border-bottom: 1px solid var(--border);
    background: var(--page);
    z-index: 5;
}

.topbar-left,
.topbar-right,
.desktop-page-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.desktop-page-title {
    gap: 10px;
    font-size: 13px;
    font-weight: 650;
}

.model-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 8px;
    border: 1px solid var(--border);
    border-radius: 7px;
    color: var(--muted);
    font-size: 10px;
    font-weight: 500;
}

.model-tag i {
    color: #7c3aed;
}

.topbar-right {
    gap: 4px;
}

/* CHAT VIEWPORT */

.chat-viewport {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
    scroll-behavior: smooth;
    scrollbar-width: thin;
    scrollbar-color: #d1d5db transparent;
}

.chat-content {
    width: 100%;
    max-width: 850px;
    min-height: 100%;
    margin: 0 auto;
    padding: 35px 28px 25px;
}

.welcome-screen {
    width: 100%;
    max-width: 700px;
    margin: 5vh auto 25px;
    text-align: center;
    animation: welcome-in .5s ease both;
}

@keyframes welcome-in {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.welcome-mark {
    width: 80px;
    height: 80px;
    position: relative;
    margin: 0 auto 24px;
}

.welcome-mark-inner {
    width: 68px;
    height: 68px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 6px;
    border: 1px solid #dbeafe;
    border-radius: 23px;
    background: linear-gradient(145deg, #eff6ff, #dbeafe);
    color: #2563eb;
    font-size: 28px;
    box-shadow: 0 10px 30px rgba(37, 99, 235, .1);
}

.welcome-spark {
    position: absolute;
    color: #7c3aed;
    font-size: 20px;
}

.spark-one {
    top: -4px;
    right: 0;
}

.spark-two {
    bottom: 0;
    left: -3px;
    color: #f59e0b;
}

.welcome-eyebrow {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: var(--muted);
    font-size: 10px;
    font-weight: 750;
    letter-spacing: 1.5px;
}

.welcome-eyebrow .tiny-status {
    width: 6px;
    height: 6px;
}

.welcome-screen h1 {
    margin: 17px 0 13px;
    color: var(--text);
    font-size: clamp(31px, 4vw, 43px);
    font-weight: 720;
    letter-spacing: -1.8px;
    line-height: 1.16;
}

.mobile-break {
    display: none;
}

.welcome-description {
    max-width: 450px;
    margin: 0 auto;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.8;
}

.suggestion-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-top: 35px;
    text-align: left;
}

.suggestion-card {
    min-width: 0;
    min-height: 83px;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px;
    border: 1px solid var(--border);
    border-radius: 15px;
    background: var(--surface);
    cursor: pointer;
    text-align: left;
    transition: transform .2s, box-shadow .2s, border-color .2s, background .2s;
}

.suggestion-card:hover {
    transform: translateY(-2px);
    border-color: #c7d7fa;
    box-shadow: var(--shadow);
    background: var(--surface);
}

.suggestion-icon {
    width: 39px;
    height: 39px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    border-radius: 12px;
    font-size: 15px;
}

.icon-blue {
    color: #2563eb;
    background: #eff6ff;
}

.icon-purple {
    color: #7c3aed;
    background: #f5f3ff;
}

.icon-orange {
    color: #c2410c;
    background: #fff7ed;
}

.icon-green {
    color: #15803d;
    background: #f0fdf4;
}

.suggestion-text {
    min-width: 0;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.suggestion-text strong {
    font-size: 12px;
    font-weight: 650;
    line-height: 1.4;
}

.suggestion-text small {
    color: var(--muted);
    font-size: 10px;
    line-height: 1.4;
}

.suggestion-arrow {
    color: var(--subtle);
    font-size: 10px;
    align-self: flex-start;
}

.welcome-note {
    margin: 24px auto 0;
    color: var(--subtle);
    font-size: 10px;
    line-height: 1.6;
}

.welcome-note i {
    margin-right: 4px;
}

/* =====================================================
   TOMBOL MODE PENGEMBANG
   Mengikuti gaya icon-button lainnya
   ===================================================== */

.developer-mode-button {
    width: 38px;
    height: 38px;
    display: inline-flex;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: var(--muted);
    text-decoration: none;
    cursor: pointer;
    transition:
        background .18s,
        color .18s,
        transform .18s;
}

.developer-mode-button i {
    color: inherit;
    font-size: 14px;
}

.developer-mode-button:hover {
    background: var(--surface-hover);
    color: var(--text);
}

.developer-mode-button:active {
    transform: scale(.95);
}

.developer-mode-button:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
}

/* Penyesuaian tablet dan mobile */
@media (max-width: 700px) {
    .topbar-right .developer-mode-button {
        width: 35px;
        height: 35px;
    }
}

/* Layar mobile kecil */
@media (max-width: 360px) {
    .topbar-right .developer-mode-button {
        width: 31px;
        height: 34px;
    }
}

/* MESSAGE LIST */

.messages-list {
    display: flex;
    flex-direction: column;
    gap: 29px;
    padding: 12px 0 28px;
}

.message-row {
    display: flex;
    align-items: flex-start;
    gap: 13px;
    animation: message-in .22s ease both;
}

@keyframes message-in {
    from {
        opacity: 0;
        transform: translateY(7px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.message-row.user-message {
    justify-content: flex-end;
}

.message-avatar {
    width: 31px;
    height: 31px;
    display: flex;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    border-radius: 11px;
    background: #eff6ff;
    color: #2563eb;
    font-size: 13px;
}

.user-message .message-avatar {
    background: #e9eaf0;
    color: #555b68;
}

.message-body {
    min-width: 0;
    max-width: min(82%, 680px);
}

.message-heading {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 2px 0 8px;
    color: var(--muted);
    font-size: 11px;
}

.user-message .message-heading {
    justify-content: flex-end;
}

.message-time {
    color: var(--subtle);
    font-size: 10px;
}

.message-bubble {
    color: var(--text);
    font-size: 14px;
    line-height: 1.85;
    overflow-wrap: anywhere;
    white-space: pre-wrap;
}

.user-message .message-bubble {
    display: inline-block;
    padding: 12px 16px;
    border: 1px solid #dbeafe;
    border-radius: 18px 18px 5px 18px;
    background: #eff6ff;
}

.user-message .message-body {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.assistant-message .message-bubble {
    padding: 0;
}

.message-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px;
    margin-top: 9px;
}

.message-action {
    min-width: 30px;
    height: 29px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 0 8px;
    border: 1px solid transparent;
    border-radius: 8px;
    background: transparent;
    color: var(--muted);
    font-size: 10px;
    cursor: pointer;
    transition: background .18s, color .18s;
}

.message-action:hover {
    background: var(--surface-hover);
    color: var(--text);
}

.message-action.feedback-active {
    background: var(--accent-soft);
    color: var(--accent);
}

.message-action-label {
    font-size: 10px;
}

.typing-indicator {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    min-height: 36px;
    color: var(--muted);
    font-size: 12px;
}

.typing-dots {
    display: inline-flex;
    gap: 4px;
    margin-left: 4px;
}

.typing-dots span {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: #9ca3af;
    animation: dot-bounce 1.1s infinite ease-in-out;
}

.typing-dots span:nth-child(2) {
    animation-delay: .15s;
}

.typing-dots span:nth-child(3) {
    animation-delay: .3s;
}

@keyframes dot-bounce {
    0%, 60%, 100% { transform: translateY(0); opacity: .55; }
    30% { transform: translateY(-4px); opacity: 1; }
}

/* COMPOSER */

.composer-area {
    flex-shrink: 0;
    padding: 12px 25px 16px;
    background: var(--page);
}

.composer-inner {
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
}

.composer-box {
    padding: 12px 13px 10px;
    border: 1px solid #d8dbe2;
    border-radius: 21px;
    background: var(--surface);
    box-shadow: 0 3px 15px rgba(15, 23, 42, .035);
    transition: border-color .2s, box-shadow .2s;
}

.composer-box:focus-within {
    border-color: #9ab8fa;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, .07);
}

#messageInput {
    width: 100%;
    min-height: 33px;
    max-height: 160px;
    display: block;
    resize: none;
    overflow-y: auto;
    padding: 2px 3px 9px;
    border: 0;
    outline: none;
    background: transparent;
    color: var(--text);
    font-size: 14px;
    line-height: 1.6;
}

#messageInput::placeholder {
    color: var(--subtle);
}

#messageInput:focus-visible {
    outline: none;
}

.composer-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.composer-tools,
.composer-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.composer-hint {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--subtle);
    font-size: 10px;
}

.composer-hint i {
    color: #6b8ddf;
}

.char-counter {
    color: var(--subtle);
    font-size: 10px;
    font-variant-numeric: tabular-nums;
}

.send-button {
    width: 34px;
    height: 34px;
    display: inline-flex;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 12px;
    background: #202123;
    color: #fff;
    font-size: 14px;
    cursor: pointer;
    transition: transform .15s, background .15s;
}

.send-button:not(:disabled):hover {
    background: #34363a;
    transform: translateY(-1px);
}

.send-button:disabled {
    opacity: 1;
    background: #e5e7eb;
    color: #9ca3af;
}

.composer-disclaimer {
    margin: 10px 0 0;
    color: var(--subtle);
    text-align: center;
    font-size: 10px;
    line-height: 1.5;
}

.error-banner {
    display: flex;
    align-items: center;
    gap: 9px;
    margin-bottom: 10px;
    padding: 10px 12px;
    border: 1px solid #fecaca;
    border-radius: 12px;
    background: #fef2f2;
    color: #991b1b;
    font-size: 12px;
}

.error-banner > span {
    flex: 1;
    overflow-wrap: anywhere;
}

.retry-button {
    padding: 6px 9px;
    border: 1px solid #fecaca;
    border-radius: 8px;
    background: #fff;
    color: #991b1b;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
}

.small-icon {
    width: 28px;
    height: 28px;
}

/* DIALOG */

.about-dialog {
    width: min(420px, calc(100% - 30px));
    padding: 22px;
    border: 1px solid var(--border);
    border-radius: 20px;
    background: var(--surface);
    color: var(--text);
    box-shadow: 0 25px 90px rgba(0, 0, 0, .18);
}

.about-dialog::backdrop {
    background: rgba(15, 23, 42, .38);
    backdrop-filter: blur(3px);
}

.dialog-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.dialog-brand {
    font-size: 14px;
}

.about-dialog p {
    color: var(--muted);
    font-size: 13px;
    line-height: 1.8;
}

.dialog-note {
    padding: 11px 12px;
    border-radius: 10px;
    background: var(--sidebar);
}

.primary-button {
    width: 100%;
    margin-top: 8px;
    padding: 11px;
    border: 0;
    border-radius: 11px;
    background: var(--accent);
    color: #fff;
    font-weight: 600;
    cursor: pointer;
}

.primary-button:hover {
    background: var(--accent-hover);
}

/* DARK MODE */

body.dark-mode {
    color-scheme: dark;
    --bg: #17181c;
    --page: #212226;
    --sidebar: #191a1e;
    --surface: #26272c;
    --surface-hover: #303137;
    --text: #ececf1;
    --muted: #a4a6af;
    --subtle: #777b86;
    --border: #373940;
    --accent: #6894ff;
    --accent-hover: #4f7de9;
    --accent-soft: #252f48;
    --shadow: 0 12px 36px rgba(0, 0, 0, .18);
}

.dark-mode .brand-logo {
    background: linear-gradient(145deg, #3977f6, #2053d6);
}

.dark-mode .welcome-mark-inner {
    border-color: #343e57;
    background: linear-gradient(145deg, #28364e, #232d41);
    color: #8bb2ff;
}

.dark-mode .suggestion-card:hover {
    border-color: #475a7d;
}

.dark-mode .icon-blue {
    color: #8bb2ff;
    background: #25334d;
}

.dark-mode .icon-purple {
    color: #c4a7ff;
    background: #352b4b;
}

.dark-mode .icon-orange {
    color: #fdba74;
    background: #433024;
}

.dark-mode .icon-green {
    color: #86efac;
    background: #20392c;
}

.dark-mode .user-message .message-bubble {
    border-color: #34496f;
    background: #293750;
}

.dark-mode .message-avatar {
    background: #28354c;
    color: #8bb2ff;
}

.dark-mode .user-message .message-avatar {
    background: #393a41;
    color: #e5e7eb;
}

.dark-mode .send-button {
    background: #e5e7eb;
    color: #202123;
}

.dark-mode .send-button:not(:disabled):hover {
    background: #fff;
}

.dark-mode .send-button:disabled {
    background: #3a3b42;
    color: #777b86;
}

.dark-mode .error-banner {
    border-color: #713737;
    background: #3a2426;
    color: #fecaca;
}

.dark-mode .retry-button {
    border-color: #713737;
    background: #42292b;
    color: #fecaca;
}

/* TABLET */

@media (max-width: 1000px) {
    .sidebar {
        width: 240px;
        min-width: 240px;
    }

    .topbar {
        padding: 0 20px;
    }

    .chat-content {
        padding-right: 22px;
        padding-left: 22px;
    }

    .composer-area {
        padding-right: 20px;
        padding-left: 20px;
    }
}

/* MOBILE */

@media (max-width: 700px) {
    .app-shell {
        height: 100dvh;
        min-height: 0;
        position: relative;
    }

    .sidebar {
        position: fixed;
        inset: 0 auto 0 0;
        width: min(300px, 86vw);
        min-width: 0;
        height: 100dvh;
        padding-top: max(18px, env(safe-area-inset-top));
        padding-bottom: max(15px, env(safe-area-inset-bottom));
        transform: translateX(-105%);
        box-shadow: none;
        z-index: 101;
    }

    .sidebar.sidebar-open {
        transform: translateX(0);
        box-shadow: 20px 0 60px rgba(0, 0, 0, .14);
    }

    .sidebar-close,
    .menu-toggle,
    .mobile-brand {
        display: inline-flex;
    }

    .sidebar-overlay {
        position: fixed;
        inset: 0;
        z-index: 100;
        background: rgba(15, 23, 42, .4);
        opacity: 0;
        visibility: hidden;
        transition: opacity .2s, visibility .2s;
    }

    .sidebar-overlay.overlay-visible {
        opacity: 1;
        visibility: visible;
    }

    .main-panel {
        width: 100%;
        min-height: 0;
    }

    .topbar {
        min-height: 58px;
        padding: 0 12px;
        gap: 7px;
    }

    .topbar-left {
        gap: 7px;
        min-width: 0;
    }

    .menu-toggle,
    .topbar-right .icon-button {
        width: 35px;
        height: 35px;
    }

    .mobile-brand {
        align-items: center;
        gap: 9px;
        min-width: 0;
    }

    .mobile-brand .brand-logo {
        width: 34px;
        height: 34px;
        border-radius: 11px;
        font-size: 15px;
    }

    .mobile-brand > span:last-child {
        min-width: 0;
        display: flex;
        flex-direction: column;
        gap: 3px;
    }

    .mobile-brand strong {
        overflow: hidden;
        font-size: 12px;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .mobile-brand small {
        display: flex;
        align-items: center;
        gap: 5px;
        color: var(--muted);
        font-size: 10px;
    }

    .mobile-brand .tiny-status {
        width: 6px;
        height: 6px;
    }

    .desktop-page-title {
        display: none;
    }

    .topbar-right {
        gap: 1px;
    }

    .chat-viewport {
        flex: 1;
        min-height: 0;
    }

    .chat-content {
        padding: 18px 16px 20px;
    }

    .welcome-screen {
        margin: 5vh auto 20px;
        max-width: 440px;
    }

    .welcome-mark {
        width: 66px;
        height: 66px;
        margin-bottom: 21px;
    }

    .welcome-mark-inner {
        width: 58px;
        height: 58px;
        margin: 4px;
        border-radius: 19px;
        font-size: 24px;
    }

    .welcome-eyebrow {
        font-size: 9px;
        letter-spacing: 1.1px;
    }

    .welcome-screen h1 {
        margin-top: 15px;
        font-size: clamp(29px, 8vw, 37px);
        letter-spacing: -1.3px;
    }

    .mobile-break {
        display: initial;
    }

    .welcome-description {
        max-width: 330px;
        padding: 0 6px;
        font-size: 12px;
        line-height: 1.75;
    }

    .suggestion-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 9px;
        margin-top: 25px;
    }

    .suggestion-card {
        min-height: 65px;
        gap: 11px;
        padding: 11px;
        border-radius: 13px;
    }

    .suggestion-icon {
        width: 36px;
        height: 36px;
        border-radius: 11px;
    }

    .suggestion-text strong {
        font-size: 12px;
    }

    .suggestion-text small {
        font-size: 10px;
    }

    .welcome-note {
        max-width: 330px;
        margin-top: 19px;
        font-size: 9px;
    }

    .messages-list {
        gap: 25px;
        padding-top: 7px;
    }

    .message-row {
        gap: 9px;
    }

    .message-avatar {
        width: 29px;
        height: 29px;
        border-radius: 10px;
        font-size: 12px;
    }

    .message-body {
        max-width: calc(100% - 39px);
    }

    .message-bubble {
        font-size: 13px;
        line-height: 1.8;
    }

    .user-message .message-bubble {
        padding: 10px 13px;
        border-radius: 16px 16px 4px 16px;
    }

    .message-heading {
        margin-bottom: 6px;
        font-size: 10px;
    }

    .message-actions {
        margin-top: 7px;
    }

    .message-action {
        min-height: 31px;
        padding: 0 7px;
    }

    .composer-area {
        padding: 8px 10px max(10px, env(safe-area-inset-bottom));
        border-top: 1px solid var(--border);
    }

    .composer-box {
        padding: 10px 10px 8px;
        border-radius: 18px;
    }

    #messageInput {
        min-height: 36px;
        max-height: 120px;
        padding: 1px 2px 8px;
        font-size: 16px;
    }

    .composer-toolbar {
        gap: 5px;
    }

    .composer-tools,
    .composer-actions {
        gap: 6px;
    }

    .composer-hint {
        font-size: 9px;
    }

    .char-counter {
        font-size: 9px;
    }

    .send-button {
        width: 34px;
        height: 34px;
        border-radius: 11px;
    }

    .composer-disclaimer {
        margin-top: 7px;
        padding: 0 5px;
        font-size: 9px;
    }

    .error-banner {
        gap: 7px;
        padding: 9px;
        font-size: 11px;
    }

    .retry-button {
        padding: 6px;
        font-size: 10px;
    }
}

/* SMALL MOBILE */

@media (max-width: 360px) {
    .topbar {
        padding: 0 7px;
    }

    .mobile-brand {
        gap: 6px;
    }

    .mobile-brand .brand-logo {
        width: 30px;
        height: 30px;
    }

    .topbar-right .icon-button {
        width: 31px;
        height: 34px;
    }

    .chat-content {
        padding-right: 12px;
        padding-left: 12px;
    }

    .composer-area {
        padding-right: 7px;
        padding-left: 7px;
    }

    .composer-hint {
        max-width: 160px;
    }
}

/* REDUCE MOTION */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
    }
}