html,
body {
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    overflow: hidden;
}

body {
    display: flex;
    flex-direction: column;
    background: #faf9fd;
    color: #25232b;
    font-family: system-ui, -apple-system, sans-serif;
}

.demo-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-shrink: 0;
    gap: 16px;
    padding: 16px 24px;
    border-bottom: 1px solid #e6e1ec;
}

.brand {
    font-size: 20px;
    font-weight: 700;
}

.subtitle {
    margin-left: 12px;
    color: #65616f;
    font-size: 14px;
    font-weight: 400;
}

a {
    color: #65558f;
    text-underline-offset: 4px;
}

#compose-root {
    display: block;
    position: relative;
    flex: 1;
    min-height: 0;
}

.loading {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 24px;
    text-align: center;
}

.loading h1 {
    font-size: clamp(24px, 4vw, 36px);
    font-weight: 600;
}

.loading p {
    max-width: 480px;
    margin: 8px 0;
    line-height: 1.6;
}

.hint {
    color: #65616f;
    font-size: 14px;
}

.spinner {
    width: 32px;
    height: 32px;
    border: 3px solid #e6e1ec;
    border-top-color: #65558f;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.loading.failed .spinner {
    display: none;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

@media (max-width: 480px) {
    .demo-header { padding: 12px 16px; }
    .subtitle { display: none; }
}

@media (prefers-reduced-motion: reduce) {
    .spinner { animation: none; }
}
