/* 社内ツールポータル — 明るめ / グラスモーフィズム */
:root {
    --ink:        #1a2030;
    --muted:      #5d6678;
    --glass:      rgba(255,255,255,0.62);
    --glass-strong: rgba(255,255,255,0.82);
    --glass-line: rgba(255,255,255,0.85);
    --hairline:   rgba(26,32,48,0.08);
    --accent:     #2563ff;
    --accent-2:   #00b6d4;
    --accent-deep:#1748c8;
    --accent-ink: #ffffff;
    --accent-tint:rgba(37,99,255,0.08);
    --danger:     #d63a3a;
    --grad: linear-gradient(120deg, #2563ff 0%, #2aa8e0 55%, #19c6c0 100%);
    --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", monospace;
    --sans: "IBM Plex Sans JP", system-ui, "Segoe UI", "Hiragino Kaku Gothic ProN", "Meiryo", sans-serif;
}

* { box-sizing: border-box; }
html, body { height: 100%; }

body {
    margin: 0;
    font-family: var(--sans);
    color: var(--ink);
    background-color: #eef1f8;
    background-image:
        radial-gradient(42% 38% at 12% 8%,  rgba(37,99,255,0.30),  transparent 60%),
        radial-gradient(40% 40% at 88% 6%,  rgba(0,182,212,0.26),  transparent 62%),
        radial-gradient(46% 46% at 82% 92%, rgba(120,90,255,0.18), transparent 60%),
        radial-gradient(44% 44% at 8% 96%,  rgba(56,210,180,0.18), transparent 60%);
    background-attachment: fixed;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

/* ===== ログイン / エラー ===== */
.stage {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 28px;
}

.gate {
    position: relative;
    width: min(420px, 100%);
    background: var(--glass);
    border: 1px solid var(--glass-line);
    border-radius: 20px;
    padding: 42px 38px 38px;
    box-shadow: 0 30px 60px -30px rgba(26,40,90,0.45), inset 0 1px 0 rgba(255,255,255,0.6);
    -webkit-backdrop-filter: blur(20px) saturate(1.5);
    backdrop-filter: blur(20px) saturate(1.5);
    animation: rise 0.6s cubic-bezier(0.2,0.7,0.2,1) both;
}

.gate__rule {
    position: absolute;
    top: 0; left: 26px; right: 26px;
    height: 3px;
    border-radius: 0 0 4px 4px;
    background: var(--grad);
}

.gate__eyebrow,
.masthead__eyebrow {
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.22em;
    color: var(--accent);
    font-weight: 600;
    margin: 0 0 16px;
    text-transform: uppercase;
}

.gate__title {
    font-weight: 700;
    font-size: 25px;
    line-height: 1.3;
    margin: 0 0 12px;
    letter-spacing: -0.01em;
}

.gate__note { color: var(--muted); font-size: 14px; line-height: 1.75; margin: 0 0 28px; }
.gate__error { color: var(--danger); font-weight: 600; font-size: 15px; line-height: 1.7; margin: 4px 0 28px; }

/* ===== ボタン ===== */
.action {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 13px 24px;
    background-image: var(--grad);
    color: var(--accent-ink);
    text-decoration: none;
    font-weight: 600;
    font-size: 14.5px;
    border-radius: 11px;
    transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
    box-shadow: 0 14px 26px -12px rgba(37,99,255,0.7);
}
.action:hover { transform: translateY(-2px); filter: brightness(1.05); box-shadow: 0 20px 34px -12px rgba(37,99,255,0.7); }
.action__arrow { transition: transform 0.2s ease; }
.action:hover .action__arrow { transform: translateX(4px); }
.action--ghost { background-image: none; background: var(--glass); color: var(--accent); border: 1px solid var(--glass-line); box-shadow: none; -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.action--ghost:hover { background: var(--glass-strong); transform: none; filter: none; }

/* ===== ポータル ヘッダー ===== */
.masthead {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 16px clamp(20px, 5vw, 52px);
    background: rgba(255,255,255,0.55);
    border-bottom: 1px solid var(--glass-line);
    -webkit-backdrop-filter: blur(16px) saturate(1.5);
    backdrop-filter: blur(16px) saturate(1.5);
    position: sticky;
    top: 0;
    z-index: 5;
}
.masthead__brand { display: flex; flex-direction: column; gap: 4px; }
.masthead__eyebrow { margin: 0; font-size: 10px; }
.masthead__title { font-weight: 700; font-size: 18px; letter-spacing: -0.01em; }
.masthead__user { display: flex; align-items: center; gap: 14px; }
.masthead__mail { color: var(--muted); font-size: 13px; }
.masthead__logout { color: var(--accent); font-size: 13px; font-weight: 500; text-decoration: none; padding: 6px 13px; border-radius: 9px; transition: background 0.2s ease; }
.masthead__logout:hover { background: var(--accent-tint); }

/* ===== ボード ===== */
.board { max-width: 1140px; margin: 0 auto; padding: clamp(30px, 5vw, 52px) clamp(20px, 5vw, 52px) 70px; }
.board__lead { font-size: 14px; color: var(--muted); margin: 0 0 24px; font-weight: 500; }

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(284px, 1fr));
    gap: 18px;
}

/* ===== カード ===== */
.card {
    position: relative;
    display: flex;
    flex-direction: column;
    background: var(--glass);
    border: 1px solid var(--glass-line);
    border-radius: 18px;
    padding: 24px 24px 22px;
    text-decoration: none;
    color: inherit;
    overflow: hidden;
    -webkit-backdrop-filter: blur(16px) saturate(1.4);
    backdrop-filter: blur(16px) saturate(1.4);
    box-shadow: 0 18px 40px -28px rgba(26,40,90,0.4), inset 0 1px 0 rgba(255,255,255,0.55);
    transition: transform 0.26s cubic-bezier(0.2,0.7,0.2,1), box-shadow 0.26s ease, background 0.26s ease;
    animation: rise 0.55s cubic-bezier(0.2,0.7,0.2,1) both;
}
.card::after {
    content: "";
    position: absolute;
    left: 0; right: 0; top: 0;
    height: 3px;
    background: var(--grad);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}
.card:hover { transform: translateY(-5px); background: var(--glass-strong); box-shadow: 0 30px 54px -26px rgba(26,40,90,0.5), inset 0 1px 0 rgba(255,255,255,0.7); }
.card:hover::after { transform: scaleX(1); }

.card__idx {
    font-family: var(--mono);
    font-size: 12px; font-weight: 600;
    letter-spacing: 0.1em;
    margin-bottom: 16px;
    background: var(--grad);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent; color: var(--accent);
    width: max-content;
}
.card__name { font-weight: 600; font-size: 17px; line-height: 1.45; margin-bottom: 8px; letter-spacing: -0.005em; }
.card__desc { color: var(--muted); font-size: 13px; line-height: 1.8; flex: 1 1 auto; margin-bottom: 18px; }
.card__open { display: inline-flex; align-items: center; gap: 7px; color: var(--accent); font-size: 13px; font-weight: 600; }
.card__arrow { transition: transform 0.24s ease; }
.card:hover .card__arrow { transform: translateX(5px); }

/* ===== motion ===== */
@keyframes rise {
    from { opacity: 0; transform: translateY(13px); }
    to   { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
    .gate, .card { animation: none; }
    .action, .card, .card__arrow, .action__arrow, .card::after, .masthead__logout { transition: none; }
}
