/**
 * AI Assistant Page Styles
 * 
 * @description AI助手页面专用样式文件
 * @author ALYR Team  
 * @version 1.0.0
 * @since 2025-01-27
 */

/* 重置和基础样式 */
.assistant-page {
    background: #13141a;
    min-height: 100vh;
    padding-top: 80px; /* 为导航栏留出空间 */
    margin: 0;
    position: relative;
    width: 100%;
    overflow-x: hidden; /* 防止横向溢出 */
}

/* 对话区域滚动条样式 */
.chat-messages::-webkit-scrollbar {
    width: 6px;
}

.chat-messages::-webkit-scrollbar-track {
    background: #2d2d2d;
    border-radius: 3px;
}

.chat-messages::-webkit-scrollbar-thumb {
    background: #c54043;
    border-radius: 3px;
    transition: background 0.3s ease;
}

.chat-messages::-webkit-scrollbar-thumb:hover {
    background: #dd6366;
}

.chat-container {
    display: flex;
    flex-direction: column;
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
    height: calc(100vh - 50px);
    position: relative;
    padding: 0 20px; /* 添加左右内边距 */
    box-sizing: border-box; /* 确保padding不会导致溢出 */
}

.chat-messages {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden; /* 防止横向溢出 */
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    transition: background 0.5s ease;
    word-wrap: break-word; /* 强制长单词换行 */
    word-break: break-word; /* 兼容性更好的换行 */
    align-items: stretch; /* 确保子元素能正常拉伸 */
}

/* 当chat-messages只包含欢迎界面时，自动移除gap */
.chat-messages:has(.welcome-screen:only-child) {
    gap: 0;
}

/* 兼容性方案：对于不支持:has()的浏览器 */
.chat-messages .welcome-screen:only-child {
    margin: auto 0; /* 垂直居中 */
}

/* 统一的Hello视频样式 - 重新设计 */
.hello-video {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    margin: 0 auto 30px auto;
    display: block;
    background: #13141a;
    transition: all 0.3s ease;
    object-fit: cover;
    position: relative;
    z-index: 10;
    cursor: pointer;
}

/* 隐藏视频播放器控件 */
.hello-video::-webkit-media-controls {
    display: none !important;
}

.hello-video::-webkit-media-controls-enclosure {
    display: none !important;
}

.hello-video::-webkit-media-controls-panel {
    display: none !important;
}

.hello-video::-webkit-media-controls-play-button {
    display: none !important;
}

.hello-video::-webkit-media-controls-timeline {
    display: none !important;
}

.hello-video::-webkit-media-controls-current-time-display {
    display: none !important;
}

.hello-video::-webkit-media-controls-time-remaining-display {
    display: none !important;
}

.hello-video::-webkit-media-controls-mute-button {
    display: none !important;
}

.hello-video::-webkit-media-controls-volume-slider {
    display: none !important;
}

.hello-video::-webkit-media-controls-fullscreen-button {
    display: none !important;
}

/* Hello视频封面样式 - 确保封面和视频样式完全一致 */
#helloVideoCover {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    margin: 0 auto 30px auto;
    display: block;
    background: #13141a;
    object-fit: cover;
    position: relative;
    z-index: 10;
    cursor: pointer;
}

/* Hello视频响应式设计 - 统一尺寸 */
@media (max-width: 768px) {
    .hello-video,
    #helloVideoCover {
        width: 180px;
        height: 180px;
        margin: 0 auto 25px auto;
    }
}

@media (max-width: 480px) {
    .hello-video,
    #helloVideoCover {
        width: 160px;
        height: 160px;
        margin: 0 auto 20px auto;
    }
}

/* 浅色主题下的助手页面背景 */
body.theme-light .assistant-page {
    background: var(--bg-primary) !important;
    color: var(--text-primary) !important;
}

/* 浅色主题下的输入框样式 */
body.theme-light .input-wrapper {
    border: 1px solid var(--border-color) !important;
    background: var(--bg-primary) !important;
}

body.theme-light .input-wrapper:focus-within {
    border-color: #c54043 !important;
}

body.theme-light .chat-input {
    color: var(--text-primary) !important;
}

body.theme-light .chat-input::placeholder {
    color: var(--text-secondary) !important;
}

/* 浅色主题下的按钮样式 */
body.theme-light .mode-button {
    background-color: var(--bg-primary) !important;
    border: 1px solid var(--border-color) !important;
    color: var(--text-primary) !important;
}

body.theme-light .mode-button:hover {
    background: #cae4ff !important;
    border-color: #cae4ff !important;
    color: #333 !important;
}

body.theme-light .mode-button.active {
    background: #cae4ff !important;
    border-color: #cae4ff !important;
    color: #333 !important;
}

body.theme-light .clear-chat-button {
    background-color: var(--bg-primary) !important;
    border: 1px solid var(--border-color) !important;
    color: var(--text-primary) !important;
}

body.theme-light .clear-chat-button:hover {
    background: var(--bg-secondary) !important;
    border-color: #c54043 !important;
}

body.theme-light .clear-chat-button:disabled {
    background: var(--bg-secondary) !important;
    border-color: var(--border-color) !important;
    color: var(--text-secondary) !important;
}

body.theme-light .fullscreen-button {
    background-color: var(--bg-primary) !important;
    border: 1px solid var(--border-color) !important;
    color: var(--text-primary) !important;
}

body.theme-light .fullscreen-button:hover {
    background: var(--bg-secondary) !important;
    border-color: #c54043 !important;
}

body.theme-light .fullscreen-button:disabled {
    background: var(--bg-secondary) !important;
    border-color: var(--border-color) !important;
    color: var(--text-secondary) !important;
}

/* 浅色主题下的文字样式 */
body.theme-light .disclaimer {
    color: var(--text-secondary) !important;
}

/* 浅色主题下的滚动条样式 */
body.theme-light .chat-messages::-webkit-scrollbar {
    background: #f9fafb !important;
    width: 8px;
    height: 8px;
}

body.theme-light .chat-messages::-webkit-scrollbar-track {
    background: #f9fafb !important;
    border-radius: 4px;
}

body.theme-light .chat-messages::-webkit-scrollbar-thumb {
    background: #d1d5db !important;
    border-radius: 4px;
    transition: background 0.3s ease;
}

body.theme-light .chat-messages::-webkit-scrollbar-thumb:hover {
    background: #9ca3af !important;
}

body.theme-light .chat-messages::-webkit-scrollbar-corner {
    background: #f9fafb !important;
}

/* 浅色主题下的Hello视频背景 - 提高优先级 */
body.theme-light .assistant-page .hello-video,
body.theme-light .assistant-page #helloVideoCover,
body.theme-light .chat-messages .hello-video,
body.theme-light .welcome-screen .hello-video {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
}

body.theme-light .assistant-page .hello-video:hover,
body.theme-light .assistant-page #helloVideoCover:hover,
body.theme-light .chat-messages .hello-video:hover,
body.theme-light .welcome-screen .hello-video:hover {
    background: #ffffff !important;
}

/* 浅色主题下的欢迎界面样式 */
body.theme-light .welcome-screen {
    color: var(--text-primary) !important;
}

body.theme-light .welcome-screen h1 {
    color: var(--text-primary) !important;
}

body.theme-light .welcome-screen p {
    color: var(--text-secondary) !important;
}

/* 浅色主题下的消息样式 */
body.theme-light .message.bot .message-content,
body.theme-light .message.assistant .message-content {
    background: var(--bg-secondary) !important;
    color: var(--text-primary) !important;
    border: 1px solid var(--border-color) !important;
}

body.theme-light .message-content strong {
    color: var(--text-primary) !important;
}

/* 深度思考模式的科技感背景 - 应用到整个页面 */
.assistant-page.deep-thinking {
    background: repeating-linear-gradient( 0deg, transparent, transparent 39px, rgba(197, 64, 67, 0.2) 40px, rgba(197, 64, 67, 0.2) 41px ), repeating-linear-gradient( 90deg, transparent, transparent 36px, rgba(221, 152, 255, 0.2) 50px, rgba(221, 152, 255, 0.1) 50px ), linear-gradient(180deg, #1a1a1a 0%, #000420 0%, #13141a 100%);
    background-size: 
        40px 40px,
        40px 40px,
        100% 100%;
    background-position: 
        0 0,
        0 0,
        0 0;
    position: relative;
}

.assistant-page.deep-thinking::before {
    content: '';
    position: absolute;
    top: 80px; /* 跳过导航栏 */
    left: 0;
    right: 0;
    bottom: 0;
    background: transparent;
    pointer-events: none;
    z-index: 1;
    opacity: 1;
}

.assistant-page.deep-thinking .chat-container {
    position: relative;
    z-index: 2;
}

/* 儿童模式的背景 */
.assistant-page.child-mode {
    background: #13141a;
    position: relative;
}

.assistant-page.child-mode::after {
    display: none;
}

/* 保留原有的对话区域样式但移除背景 */
.chat-messages.deep-thinking {
    position: relative;
}

.chat-messages.deep-thinking .message {
    position: relative;
    z-index: 2;
}

.chat-messages.child-mode {
    position: relative;
}

.chat-messages.child-mode .message {
    position: relative;
    z-index: 2;
}

/* 欢迎界面样式 */
.welcome-screen {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #ffffff;
    height: 100%;
    width: 100%;
    padding: 40px 20px;
    box-sizing: border-box;
}

.welcome-screen h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin: 0 0 15px 0;
    color: #ffffff;
}

.welcome-screen p {
    font-size: 1.1rem;
    color: #ccc;
    margin: 0;
    line-height: 1.6;
}

/* 消息样式 */
.message {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    max-width: 100%;
    position: relative;
}

.message.user {
    flex-direction: row-reverse;
}

.message.bot,
.message.assistant {
    flex-direction: row;
}

.message-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, #c54043, #dd98ff);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    flex-shrink: 0;
    font-size: 14px;
}

.message.user .message-avatar {
    display: none;
}

.message.bot .message-avatar,
.message.assistant .message-avatar {
    display: flex;
}

.message-wrapper {
    display: flex;
    flex-direction: column;
    max-width: 70%;
    min-width: 0;
}

.message-content {
    background: #2a2a2a;
    padding: 12px 16px;
    border-radius: 12px;
    color: #ffffff;
    line-height: 1.6;
    position: relative;
    word-wrap: break-word;
    word-break: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
    width: fit-content;
    max-width: 100%;
    display: block;
    min-height: 20px;
    white-space: pre-wrap;
}

.message.user .message-content {
    background: #e5e5e5;
    color: #333;
}

.message.bot .message-content,
.message.assistant .message-content {
    background: #2a2a2a;
    color: #ffffff;
    display: block;
    opacity: 1;
    visibility: visible;
}

.message-content strong {
    color: #fff;
    font-weight: 600;
}

.message-content br {
    line-height: 1.8;
}

/* 打字效果 */
.typing-cursor::after {
    content: '|';
    animation: blink 1s infinite;
    color: #c54043;
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

/* 消息操作按钮 */
.message-actions {
    display: flex;
    gap: 8px;
    margin-top: 8px;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.message:hover .message-actions {
    opacity: 1;
}

.message-action {
    background: none;
    border: none;
    color: #888;
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: all 0.2s ease;
    font-size: 12px;
}

.message-action:hover {
    color: #c54043;
    background: rgba(197, 64, 67, 0.1);
}

/* 打字指示器 */
.typing-indicator {
    display: none;
    padding: 12px 20px;
    color: #888;
    font-style: italic;
    font-size: 14px;
    animation: pulse 1.5s infinite;
}

.typing-indicator.show {
    display: block;
}

@keyframes pulse {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}

/* 模式选择器样式 */
.mode-selector {
    padding: 0 0px 16px 0px;
}

.mode-container {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    gap: 12px;
    align-items: center;
    justify-content: space-between;
}

.mode-buttons {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.action-buttons {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.mode-button {
    padding: 8px 16px;
    background-color:transparent;
    border: 1px solid #404040;
    border-radius: 10px;
    color: #ffffff;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.mode-button:hover {
    background: #df272d;
    border-color: #df272d;
    color: #ffffff;
}

.mode-button.active {
    background: #da272d;
    border-color: #da272d;
    color: #ffffff;
}

.clear-chat-button {
    padding: 8px 16px;
    background-color: transparent;
    border: 1px solid #777777;
    border-radius: 10px;
    color: #ffffff;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    display: none;
}

.clear-chat-button.show {
    display: inline-block;
}

.clear-chat-button:hover {
    background: #222326;
    border-color: #da272d;
}

.clear-chat-button:disabled {
    background: #555555;
    border-color: #666666;
    color: #888888;
    cursor: not-allowed;
    opacity: 0.5;
}

.fullscreen-button {
    padding: 8px 16px;
    background-color: transparent;
    border: 1px solid #555555;
    border-radius: 10px;
    color: #ffffff;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    display: inline-block;
}

.fullscreen-button:hover {
    background: #222326;
    border-color: #da272d;
}

.fullscreen-button:disabled {
    background: #555555;
    border-color: #666666;
    color: #888888;
    cursor: not-allowed;
    opacity: 0.5;
}

/* 输入区域 */

.input-container {
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
    width: 100%;
    box-sizing: border-box;
}

.input-wrapper {
    border: 1px solid #404040;
    border-radius: 10px;
    padding: 20px 60px 20px 20px;
    display: flex;
    align-items: flex-end;
    gap: 12px;
    transition: border-color 0.2s ease;
    min-height: 64px;
    position: relative;
    width: 100%;
    box-sizing: border-box;
    max-width: 100%;
}

.input-wrapper:focus-within {
    border-color: #c54043;
}

.chat-input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    color: #ffffff;
    font-size: 15px;
    line-height: 1.5;
    resize: none;
    min-height: 28px;
    max-height: 120px;
    font-family: inherit;
    padding: 0;
}

.chat-input::placeholder {
    color: #888888;
}

.send-button {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    width: 36px;
    height: 36px;
    background: #c54043;
    border: none;
    border-radius: 10px;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease;
}

.send-button:hover:not(:disabled) {
    background: linear-gradient(133deg, #c54043 17.88%, #dd98ff 98.36%);
}

.send-button:disabled {
    background: #666666;
    cursor: not-allowed;
}

.disclaimer {
    color: #888888;
    font-size: 12px;
    text-align: center;
    margin-top: 10px;
}

/* 动画效果 */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* 平板模式适配 - 769px到1024px */
@media (min-width: 769px) and (max-width: 1024px) {
    
    .assistant-container {
        max-width: 100%;
        margin: 0 24px;
    }
    
    .chat-container {
        max-width: 100%;
        height: calc(100vh - 120px);
    }
    
    .chat-messages {
        padding: 20px 24px;
    }
    
    .message {
        max-width: 85%;
    }
    
    .chat-input-container {
        padding: 16px 24px;
    }
    
    .chat-input {
        font-size: 16px;
        padding: 12px 50px 12px 16px;
    }
    
    .send-button {
        width: 40px;
        height: 40px;
    }
    
    /* 控制按钮适配 */
    .chat-controls {
        gap: 12px;
        padding: 0 24px;
    }
    
    .mode-button,
    .clear-chat-button,
    .fullscreen-button {
        padding: 8px 16px;
        font-size: 14px;
    }
    
    /* 欢迎屏幕适配 */
    .welcome-screen {
        padding: 40px 24px;
    }
    
    .welcome-title {
        font-size: 2.5rem;
    }
    
    .example-questions {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
}

/* 移动端适配 */
@media (max-width: 768px) {
    .chat-container {
        padding: 0 16px;
    }
    
    .mode-container {
        justify-content: center;
        flex-wrap: wrap; /* 允许换行以防按钮过多 */
        gap: 8px; /* 统一所有按钮之间的间距 */
    }
    
    .mode-buttons {
        justify-content: center;
        gap: 6px; /* 减小模式按钮之间的间距以节省空间 */
    }
    
    .action-buttons {
        gap: 6px; /* 减小操作按钮之间的间距 */
    }
    
    .welcome-screen {
        padding: 30px 16px;
    }
    
    .welcome-screen h1 {
        font-size: clamp(1.5rem, 4vw, 2rem);
        margin: 0 auto 12px auto;
    }
    
    .welcome-screen p {
        font-size: clamp(0.9rem, 2.5vw, 1.1rem);
        margin: 0 auto;
    }
    
    .clear-chat-button {
        padding: 6px 10px; /* 减小内边距以节省空间 */
        font-size: 12px;
        white-space: nowrap;
    }
    
    .fullscreen-button {
        display: none; /* 移动端隐藏全屏按钮 */
    }
    
    /* 移动端输入框高度调整 */
    .chat-input {
        min-height: 35px;
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    .chat-container {
        padding: 0 12px;
    }
    
    .mode-container {
        gap: 6px; /* 进一步减小间距 */
    }
    
    .mode-buttons {
        gap: 4px; /* 小屏幕上进一步减小间距 */
    }
    
    .action-buttons {
        gap: 4px;
    }
    
    .mode-button {
        padding: 6px 10px; /* 减小按钮大小以适应小屏幕 */
        font-size: 11px; /* 减小字体以节省空间 */
    }
    
    .clear-chat-button {
        padding: 6px 8px; /* 进一步减小清除按钮的大小 */
        font-size: 11px;
    }
    
    .input-wrapper {
        padding: 8px 12px;
    }
    
    .chat-input {
        font-size: 14px;
    }
    
    .send-button {
        width: 36px;
        height: 36px;
    }
    
    .welcome-screen {
        padding: 25px 12px;
    }
    
    .welcome-screen h1 {
        font-size: clamp(1.2rem, 4vw, 1.6rem);
        margin: 0 auto 10px auto;
        line-height: 1.3;
    }
    
    .welcome-screen p {
        font-size: clamp(0.85rem, 3vw, 1rem);
        margin: 0 auto;
        line-height: 1.6;
    }
}

/* Toast消息样式 */
.toast-message {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: #2a2a2a;
    color: #fff;
    padding: 12px 16px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    z-index: 10000;
    opacity: 0;
    transform: translateX(100px);
    transition: all 0.3s ease;
    border-left: 4px solid #c54043;
    max-width: 300px;
    word-wrap: break-word;
}

.toast-message.show {
    opacity: 1;
    transform: translateX(0);
}

.toast-message.success {
    border-left-color: #4CAF50;
}

.toast-message.error {
    border-left-color: #f44336;
}

.toast-message.info {
    border-left-color: #2196F3;
}

/* 全屏模式样式 */
.fullscreen-mode {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 9999 !important;
    background: #13141a !important;
    padding-top: 20px !important;
}

.fullscreen-mode .chat-container {
    height: calc(100vh - 20px) !important;
    max-width: none !important;
    padding: 0 20px !important;
}

/* 隐藏头部和尾部 */
body.fullscreen-active header,
body.fullscreen-active footer,
body.fullscreen-active .header,
body.fullscreen-active .footer {
    display: none !important;
}

body.fullscreen-active {
    overflow: hidden;
}

/* 儿童模式消息操作按钮 */
.assistant-page.child-mode .message-actions {
    margin-left: 10px;
}

/* 示例卡片样式 */
.example-cards {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    max-width: 1000px;
    width: 100%;
    margin-top: 1rem;
    overflow: hidden;
}

.example-card {
    border: 1px solid #404040;
    border-radius: 10px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: left;
}

.example-card:hover {
    background: #222326;
}

.example-card h4 {
    margin: 0 0 8px 0;
    font-size: 16px;
    font-weight: 600;
    color: #ffffff;
    line-height: 1.4;
}

.example-card p {
    margin: 0;
    font-size: 14px;
    color: #b3b3b3;
    line-height: 1.5;
}

/* 输入区域高级样式 */
.chat-input-area {
    padding-bottom: 6rem;
}

/* 儿童模式的星空背景 - 应用到整个页面 */
.assistant-page.child-mode {
    background: linear-gradient(180deg, #0a0a23 0%, #1a1a3e 50%, #0a0a23 100%);
    position: relative;
    overflow: hidden;
}

.assistant-page.child-mode::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
        radial-gradient(2px 2px at 20px 30px, #ffd700, transparent),
        radial-gradient(2px 2px at 40px 70px, #87ceeb, transparent),
        radial-gradient(1px 1px at 90px 40px, #ffb6c1, transparent),
        radial-gradient(1px 1px at 130px 80px, #98fb98, transparent),
        radial-gradient(2px 2px at 160px 30px, #dda0dd, transparent),
        radial-gradient(1px 1px at 200px 90px, #ffd700, transparent),
        radial-gradient(2px 2px at 240px 50px, #87ceeb, transparent),
        radial-gradient(1px 1px at 280px 20px, #ffb6c1, transparent),
        radial-gradient(1px 1px at 320px 60px, #98fb98, transparent),
        radial-gradient(2px 2px at 360px 40px, #dda0dd, transparent);
    background-repeat: repeat;
    background-size: 400px 400px;
    pointer-events: none;
    z-index: 1;
}

.assistant-page.child-mode::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
        radial-gradient(1px 1px at 50px 100px, #fff, transparent),
        radial-gradient(2px 2px at 150px 200px, #fff, transparent),
        radial-gradient(1px 1px at 250px 50px, #fff, transparent),
        radial-gradient(1px 1px at 350px 150px, #fff, transparent),
        radial-gradient(2px 2px at 100px 300px, #fff, transparent);
    background-repeat: repeat;
    background-size: 500px 500px;
    pointer-events: none;
    z-index: 1;
}

/* 响应式示例卡片 */
@media (max-width: 768px) {
    .example-cards {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
        margin-top: 0.8rem;
    }
    
    .example-card {
        padding: 16px;
    }
    
    .example-card h4 {
        font-size: 15px;
    }
    
    .example-card p {
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .example-cards {
        grid-template-columns: 1fr;
        gap: 10px;
        margin-top: 0.6rem;
    }
    
    .example-card {
        padding: 14px;
    }
    
    .example-card h4 {
        font-size: 14px;
        margin-bottom: 6px;
    }
    
    .example-card p {
        font-size: 12px;
    }
}

.assistant-page.child-mode .chat-container {
    position: relative;
    z-index: 2;
}