:root {
    --primary-color: #6366f1;
    --primary-hover: #4f46e5;
    --text-main: #1f2937;
    --text-muted: #6b7280;
    --bg-color: #f3f4f6;
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(255, 255, 255, 0.5);
    --glass-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.1);
    --toolbar-height: 60px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', 'Noto Sans JP', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-main);
    overflow: hidden;
    /* 背景アニメーションのため */
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* 背景のBlobアニメーション */
.background-blobs {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.blob {
    position: absolute;
    filter: blur(80px);
    opacity: 0.6;
    animation: move 20s infinite alternate;
}

.blob-1 {
    top: -10%;
    left: -10%;
    width: 50vw;
    height: 50vw;
    background: #c084fc;
    animation-delay: 0s;
}

.blob-2 {
    bottom: -10%;
    right: -10%;
    width: 50vw;
    height: 50vw;
    background: #6366f1;
    animation-delay: -5s;
}

.blob-3 {
    bottom: 20%;
    left: 20%;
    width: 30vw;
    height: 30vw;
    background: #f472b6;
    animation-delay: -10s;
}

@keyframes move {
    from {
        transform: translate(0, 0) scale(1);
    }

    to {
        transform: translate(20px, -20px) scale(1.1);
    }
}

/* アプリケーションコンテナ */
.app-container {
    width: 90%;
    max-width: 1000px;
    height: 90vh;
    display: flex;
    flex-direction: column;
    gap: 20px;
    z-index: 1;
}

/* ヘッダー */
.editor-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 10px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-main);
}

.brand h1 {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.brand .material-icons-round {
    font-size: 2rem;
    color: var(--primary-color);
}

.status-bar {
    font-size: 0.85rem;
    color: var(--text-muted);
    font-weight: 500;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.status-bar.visible {
    opacity: 1;
}

/* メインエディタエリア */
.editor-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 16px;
    overflow: hidden;
}

/* ガラスモーフィズムパネルユーティリティ */
.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    box-shadow: var(--glass-shadow);
}

/* ツールバー */
.toolbar {
    display: flex;
    align-items: center;
    padding: 10px 20px;
    gap: 16px;
    flex-wrap: wrap;
}

.toolbar-group {
    display: flex;
    gap: 8px;
}

.separator {
    width: 1px;
    height: 24px;
    background-color: rgba(0, 0, 0, 0.1);
}

.tool-btn {
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    color: var(--text-muted);
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tool-btn:hover {
    background-color: rgba(99, 102, 241, 0.1);
    color: var(--primary-color);
}

.tool-btn.active {
    background-color: var(--primary-color);
    color: white;
}

/* エディタコンテンツエリア */
.editor-container {
    flex: 1;
    padding: 40px;
    overflow-y: auto;
    background: rgba(255, 255, 255, 0.85);
    /* 読みやすさのために少し不透明に */
    position: relative;
    cursor: text;
}

.editor-content {
    outline: none;
    min-height: 100%;
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--text-main);
}

.editor-content[placeholder]:empty:before {
    content: attr(placeholder);
    color: #9ca3af;
    cursor: text;
}

/* エディタ内のスタイル */
.editor-content ul,
.editor-content ol {
    margin-left: 20px;
}

.editor-content blockquote {
    border-left: 4px solid var(--primary-color);
    padding-left: 16px;
    color: var(--text-muted);
    font-style: italic;
}

/* フッター */
.editor-footer {
    display: flex;
    justify-content: flex-end;
    gap: 20px;
    padding: 0 10px;
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* スクロールバーのスタイル */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.1);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.2);
}