:root {
    --bg-base: #0a0e1a;
    --glass-bg: rgba(255, 255, 255, 0.04);
    --glass-heavy: rgba(255, 255, 255, 0.12);
    --glass-panel: rgba(255, 255, 255, 0.02);
    --border: rgba(255, 255, 255, 0.12);
    --liquid-blue: #60a5fa;
    --liquid-purple: #c084fc;
    --danger: #f87171;
    --text: #f8fafc;
    --text-muted: #94a3b8;
}

*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; background: var(--bg-base); color: var(--text); font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; overflow: hidden; height: 100vh; }

.glass-bg { position: fixed; inset: 0; z-index: -1; background: #080c16; overflow: hidden; }
.fluid-aurora { position: absolute; inset: 0; background: radial-gradient(circle at 50% 50%, #1e293b 0%, transparent 70%); }
.orb { position: absolute; border-radius: 50%; filter: blur(120px); opacity: 0.15; width: 600px; height: 600px; }
.orb1 { top: -10%; left: -10%; background: var(--liquid-blue); }
.orb2 { bottom: -10%; right: -10%; background: var(--liquid-purple); }

.glass-panel { background: var(--glass-panel); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); border: 1px solid var(--border); border-radius: 16px; box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4); }

.glass-btn { background: rgba(255, 255, 255, 0.03); border: 1px solid var(--border); color: var(--text); padding: 10px 18px; border-radius: 10px; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; font-size: 13px; transition: all 0.2s; font-family: inherit; }
.glass-btn:hover { background: rgba(255, 255, 255, 0.08); border-color: rgba(255, 255, 255, 0.25); color: #fff; }
.btn-icon { background: transparent; border: none; color: var(--text-muted); font-size: 20px; cursor: pointer; width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.btn-icon:hover { background: rgba(255, 255, 255, 0.06); color: #fff; }

/* 認証画面専用 */
.auth-page { display: flex; align-items: center; justify-content: center; min-height: 100vh; padding: 20px; position: relative; z-index: 10; }
.auth-card { width: 100%; max-width: 450px; padding: 40px; text-align: center; }
.input-group { position: relative; margin-bottom: 20px; }
.input-group i { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); color: var(--text-muted); }
.input-group input { width: 100%; background: rgba(0,0,0,0.2); border: 1px solid var(--border); border-radius: 12px; padding: 14px 16px 14px 46px; color: #fff; font-size: 15px; outline: none; }
.input-group input:focus { border-color: var(--liquid-purple); }

/* ランチャーレイアウト */
.launcher-wrap { display: flex; flex-direction: column; align-items: center; justify-content: center; height: 100vh; padding: 40px; position: relative; z-index: 10; }
.launcher-title-area { text-align: center; margin-bottom: 40px; }
.launcher-title-area h1 { font-size: 2.5rem; margin: 0 0 10px 0; letter-spacing: 2px; }
.badge { background: var(--liquid-purple); padding: 4px 10px; border-radius: 8px; font-size: 11px; margin-left: 6px; }
.badge.admin { background: #f59e0b; }
.app-matrix { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 20px; width: 100%; max-width: 800px; }
.app-node { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 25px; cursor: pointer; transition: all 0.25s ease; text-decoration: none; color: var(--text); }
.app-node:hover { background: var(--glass-heavy); border-color: var(--liquid-blue); transform: translateY(-4px); }
.app-node-icon { font-size: 2.6rem; color: var(--liquid-blue); margin-bottom: 12px; }

/* RipDrive アプリレイアウト */
.layout-app { display: grid; grid-template-columns: 260px 1fr; gap: 20px; padding: 20px; height: 100vh; }
.sidebar { display: flex; flex-direction: column; padding: 20px; height: 100%; }
.brand { display: flex; align-items: center; gap: 10px; margin-bottom: 25px; font-size: 15px; cursor: pointer; color: var(--liquid-blue); font-weight: bold; transition: 0.2s; }
.brand:hover { color: #fff; }
.tree-container { flex: 1; overflow-y: auto; }
.tree-view, .tree-view ul { list-style: none; padding-left: 0; margin: 0; }
.tree-view ul { padding-left: 16px; }
.tree-item { cursor: pointer; padding: 8px; border-radius: 6px; font-size: 13px; display: flex; align-items: center; gap: 8px; color: var(--text-muted); }
.tree-item:hover { background: rgba(255,255,255,0.04); color: #fff; }
.main-area { display: flex; flex-direction: column; gap: 20px; height: 100%; }
.breadcrumbs { display: flex; align-items: center; gap: 15px; padding: 15px 20px; }
.list-section { flex: 1; padding: 20px; overflow-y: auto; }
.file-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 16px; }
.file-card { background: rgba(255,255,255,0.01); border: 1px solid rgba(255,255,255,0.03); border-radius: 12px; padding: 20px 10px; text-align: center; position: relative; cursor: pointer; transition: 0.2s; }
.file-card:hover { background: rgba(255,255,255,0.06); border-color: rgba(255,255,255,0.15); transform: translateY(-2px); }
.file-icon { font-size: 2.5rem; margin-bottom: 8px; color: var(--liquid-blue); }
.file-name { font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* モーダル */
.modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.6); backdrop-filter: blur(8px); display: none; justify-content: center; align-items: center; z-index: 1000; }
.modal-content { width: 90%; max-width: 500px; padding: 25px; }
.modal-content.large { max-width: 850px; height: 80vh; display: flex; flex-direction: column; }
.modal-header { display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--border); padding-bottom: 10px; margin-bottom: 15px; }
.modal-body { flex: 1; overflow-y: auto; }