:root {
    --bg: #0f172a;
    --bg-soft: #111827;
    --card: #ffffff;
    --card-soft: #f9fafb;
    --border: #e5e7eb;
    --border-strong: #cbd5f5;
    --accent: #2563eb;
    --accent-soft: rgba(37,99,235,0.08);
    --accent-strong: #1d4ed8;
    --text-main: #111827;
    --text-sub: #6b7280;
    --danger: #dc2626;
    --success: #16a34a;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 24px;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
                 "Noto Sans JP", sans-serif;
    background:
        radial-gradient(circle at top left, rgba(37,99,235,0.18) 0, transparent 50%),
        radial-gradient(circle at bottom right, rgba(15,23,42,0.9) 0, #020617 55%);
    color: var(--text-main);
}

.app {
    max-width: 1120px;
    margin: 0 auto;
}

header {
    margin-bottom: 20px;
    position: relative;
}

.product-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    padding: 3px 9px;
    border-radius: 999px;
    background: rgba(15,23,42,0.85);
    color: #e5e7eb;
    border: 1px solid rgba(148,163,184,0.4);
}

.product-badge-dot {
    width: 6px;
    height: 6px;
    border-radius: 999px;
    background: #22c55e;
}

/* ロゴ */
.app-logo {
    position: absolute;
    top: 20px;
    right: 32px;
    height: 60px;
    opacity: 0.92;
    user-select: none;
}

@media (max-width: 600px) {
    .app-logo {
        position: relative;
        top: 0;
        right: 0;
        height: 38px;
        margin: 0 auto 12px;
        display: block;
    }

    header {
        text-align: center;
        padding-top: 20px;
    }
}

h1 {
    margin: 8px 0 4px;
    font-size: 24px;
    font-weight: 650;
    letter-spacing: .04em;
    color: #e5e7eb;
}

.subtitle {
    color: #9ca3af;
    font-size: 13px;
}

.shell {
    border-radius: 18px;
    background: linear-gradient(135deg, rgba(148,163,184,0.3), rgba(15,23,42,0.9));
    padding: 1px;
    box-shadow: 0 24px 60px rgba(15,23,42,0.75);
}

.main {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr);
    gap: 18px;
    padding: 18px;
    border-radius: 17px;
    background: linear-gradient(135deg, #f9fafb, #eef2ff);
}

@media (max-width: 900px) {
    body {
        padding: 16px;
    }
    .main {
        grid-template-columns: minmax(0, 1fr);
    }
}

.column {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.card {
    border-radius: 14px;
    background: var(--card);
    border: 1px solid var(--border);
    padding: 16px 18px;
}

.card-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.step {
    width: 26px;
    height: 26px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
    color: var(--accent-strong);
    border: 1px solid var(--accent-soft);
    background: #eff6ff;
}

.card-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-main);
}

.card-sub {
    font-size: 12px;
    color: var(--text-sub);
}

/* フィールド系（社員番号用も含む） */
.field {
    margin-top: 10px;
}

.text-input {
    width: 100%;
    font-size: 13px;
    border-radius: 9px;
    border: 1px solid var(--border);
    padding: 8px 10px;
    background: #ffffff;
    color: var(--text-main);
}

.field-note {
    margin: 4px 0 0;
    font-size: 11px;
    color: var(--text-sub);
}

label {
    display: block;
    font-size: 12px;
    margin: 10px 0 4px;
    color: var(--text-sub);
}

input[type="file"],
select,
textarea {
    width: 100%;
    font-size: 13px;
    border-radius: 9px;
    border: 1px solid var(--border);
    padding: 8px 10px;
    background: #ffffff;
    color: var(--text-main);
}

input[type="file"] {
    padding: 6px 10px;
}

textarea {
    resize: vertical;
    min-height: 90px;
}

.button-row {
    margin-top: 14px;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
}

button {
    border-radius: 999px;
    border: none;
    padding: 9px 18px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: background .14s ease, transform .08s ease, box-shadow .14s ease;
}

button.primary {
    background: var(--accent);
    color: #f9fafb;
    box-shadow: 0 8px 18px rgba(37,99,235,0.35);
}

button.primary:hover:not(:disabled) {
    background: var(--accent-strong);
    transform: translateY(-1px);
    box-shadow: 0 10px 26px rgba(37,99,235,0.4);
}

button.ghost {
    background: #ffffff;
    border: 1px solid var(--border);
    color: var(--text-main);
}

button.ghost:hover:not(:disabled) {
    background: #f3f4f6;
}

button:disabled {
    opacity: .6;
    cursor: default;
    box-shadow: none;
    transform: none;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    padding: 4px 9px;
    border-radius: 999px;
    background: var(--accent-soft);
    color: var(--text-sub);
    border: 1px dashed var(--border-strong);
}

.badge-dot {
    width: 6px;
    height: 6px;
    border-radius: 999px;
    background: var(--accent-strong);
}

.status {
    margin-top: 8px;
    font-size: 12px;
    color: var(--text-sub);
    min-height: 1.4em;
}

.status.error {
    color: var(--danger);
}

.status.success {
    color: var(--success);
}

.analysis-summary {
    font-size: 13px;
    line-height: 1.6;
}

.analysis-summary h3 {
    font-size: 13px;
    margin: 10px 0 4px;
}

.slides-list {
    max-height: 210px;
    margin-top: 10px;
    padding: 10px 12px;
    border-radius: 10px;
    background: var(--card-soft);
    border: 1px solid #e0e7ff;
    overflow-y: auto;
    font-size: 12px;
}

.slide-item {
    padding: 6px 0;
    border-bottom: 1px solid #e5e7eb;
}

.slide-item:last-child {
    border-bottom: none;
}

.slide-title {
    font-weight: 500;
}

.slide-meta {
    font-size: 11px;
    color: var(--text-sub);
}

.chip {
    display: inline-flex;
    align-items: center;
    padding: 2px 6px;
    border-radius: 999px;
    font-size: 10px;
    margin-right: 4px;
    margin-top: 2px;
    border: 1px solid rgba(239,68,68,0.35);
    color: #b91c1c;
    background: #fef2f2;
}

.qa-question {
    font-size: 13px;
    background: #f9fafb;
    border-radius: 10px;
    padding: 10px 12px;
    border: 1px solid #e5e7eb;
    min-height: 46px;
}

.evaluation {
    font-size: 13px;
    margin-top: 10px;
    padding: 10px 12px;
    border-radius: 10px;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    white-space: pre-wrap;
}

.score-tag {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 11px;
    margin-right: 6px;
}

.score-A {
    background: rgba(22,163,74,0.08);
    color: #15803d;
    border: 1px solid rgba(22,163,74,0.3);
}

.score-B {
    background: rgba(234,179,8,0.08);
    color: #b45309;
    border: 1px solid rgba(234,179,8,0.3);
}

.score-C {
    background: rgba(239,68,68,0.08);
    color: #b91c1c;
    border: 1px solid rgba(239,68,68,0.3);
}

/* ダッシュボードへのナビリンク */
.nav-links {
    font-size: 12px;
    margin-top: 10px;
    margin-bottom: 4px;
}

.nav-links a {
    display: inline-block;
    margin-right: 8px;
    padding: 6px 12px;
    border-radius: 999px;
    border: 1px solid #4b5563;
    background: #020617;
    color: #93c5fd;
    text-decoration: none;
}

.nav-links a:hover {
    background: #111827;
}