/*
 * TOTP設定ガイド専用の配色、レイアウト、レスポンシブ表示を定義する。
 */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');

:root {
    --ink: #1a1a1a;
    --muted: #6b7280;
    --line: #e5e7eb;
    --cyan: #0042a1;
    --cyan-dark: #00347d;
    --pink: #f0558b;
    --gradient: linear-gradient(135deg, #f0558b 0%, #0042a1 100%);
    --soft: #fdf2f8;
    --warning: #e83e73;
    --paper: #ffffff;
    --canvas: #f9fafb;
    --glass: rgba(255, 255, 255, .1);
    --glass-strong: rgba(255, 255, 255, .15);
    --shadow: 0 8px 40px rgba(0, 0, 0, .12);
    --shadow-strong: 0 16px 80px rgba(0, 0, 0, .16);
}

* { box-sizing: border-box; }
html { scroll-padding-top: 92px; }
body {
    margin: 0;
    color: var(--ink);
    background: var(--gradient);
    background-attachment: fixed;
    font-family: 'Inter', "Noto Sans JP", sans-serif;
    line-height: 1.7;
    overflow-x: hidden;
    min-height: 100vh;
}
main, footer { position: relative; z-index: 2; }
a { color: var(--cyan-dark); }
.nowrap { white-space: nowrap; }
.reading-progress { position: fixed; inset: 0 auto auto 0; z-index: 1001; width: 0; height: 3px; background: linear-gradient(90deg, var(--cyan), var(--pink)); transition: width .1s ease-out; }

.site-header {
    position: fixed;
    left: 0;
    right: 0;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, .2);
    background: rgba(255, 255, 255, .1);
    backdrop-filter: blur(20px);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; width: min(1180px, calc(100% - 48px)); height: 70px; margin: auto; }
.brand { color: var(--ink); font-size: 28px; font-weight: 900; letter-spacing: -.04em; text-decoration: none; background: linear-gradient(45deg, var(--cyan), var(--pink)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
nav { display: flex; gap: 30px; }
nav a { padding: 7px 13px; border-radius: 50px; color: rgba(255,255,255,.92); font-size: 13px; font-weight: 600; text-decoration: none; }
nav a:hover, nav a.is-active { color: #fff; background: linear-gradient(45deg, rgba(0,66,161,.8), rgba(240,85,139,.8)); }

.section-kicker { margin: 0 0 15px; color: var(--cyan); font-size: 12px; font-weight: 850; letter-spacing: .16em; text-transform: uppercase; }

.deadline-section { display: grid; grid-template-columns: 270px 1fr; width: min(1040px, calc(100% - 48px)); margin: 118px auto 48px; overflow: hidden; border: 1px solid #dfe3e8; border-radius: 14px; background: var(--paper); }
.deadline-date { display: flex; flex-direction: column; justify-content: center; padding: 34px; color: #fff; background: linear-gradient(135deg, var(--pink), var(--cyan)); }
.deadline-date span { font-size: 12px; font-weight: 800; letter-spacing: .15em; }
.deadline-date strong { margin-top: 8px; font-size: 30px; letter-spacing: -.03em; }
.deadline-date b { font-size: 18px; }
.deadline-message { padding: 36px 44px; }
.deadline-message .updated { display: block; margin-bottom: 10px; color: var(--muted); font-size: 12px; }
.deadline-message h1 { margin: 0; font-size: clamp(24px, 3vw, 34px); line-height: 1.4; letter-spacing: -.025em; }
.deadline-message p { margin: 14px 0 0; color: var(--muted); }
.deadline-message .countdown { color: var(--warning); font-weight: 850; }

.article-layout { display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: 52px; width: min(1040px, calc(100% - 48px)); margin: 0 auto 32px; padding: 54px 58px; border: 1px solid #dfe3e8; border-radius: 14px; background: var(--paper); }
.toc { position: sticky; top: 105px; align-self: start; padding-left: 18px; border-left: 1px solid var(--line); }
.toc > p { margin: 0 0 15px; font-size: 12px; font-weight: 850; letter-spacing: .16em; }
.toc ol { margin: 0; padding: 0; list-style: none; }
.toc li + li { margin-top: 9px; }
.toc a { color: #71868e; font-size: 13px; font-weight: 650; text-decoration: none; }
.toc a:hover, .toc a.is-active { color: var(--cyan-dark); }

.article-section { position: relative; padding: 15px 0 78px; border-bottom: 1px solid var(--line); }
.has-reveal .article-section { opacity: 0; transform: translateY(36px); }
.has-reveal .article-section.is-visible, .has-reveal .closing-card.is-visible { opacity: 1; transform: none; }
.section-number { position: absolute; top: -6px; right: 0; margin: 0; color: #fce7f3; font-size: 74px; font-weight: 900; line-height: 1; letter-spacing: -.08em; }
.article-section .section-kicker { color: var(--cyan-dark); }
.article-section h2 { max-width: 650px; margin: 0 0 23px; font-size: clamp(29px, 4vw, 44px); line-height: 1.28; letter-spacing: -.045em; }
.article-section > p:not(.section-number):not(.section-kicker) { color: var(--muted); font-size: 16px; }
.note { padding: 18px 20px; border-left: 5px solid var(--pink); border-radius: 0 14px 14px 0; background: var(--soft); }
.notice { margin-top: 28px; padding-top: 18px; border-top: 1px dashed #d1d5db; font-size: 14px !important; }

.operation-change { margin: 30px 0; border-top: 1px solid var(--line); }
.operation-change section { padding: 24px 0; border-bottom: 1px solid var(--line); }
.operation-change h3 { margin: 0 0 8px; font-size: 19px; }
.operation-change p { margin: 0; color: var(--muted); }
.operation-change ul { margin: 18px 0 0; padding-left: 1.4em; color: var(--muted); }
.operation-change li + li { margin-top: 14px; }

.timeline { display: grid; grid-template-columns: 1fr 1fr; margin: 35px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.timeline > div { padding: 25px 26px 27px 0; }
.timeline > div + div { padding-left: 27px; border-left: 1px solid var(--line); }
.timeline time { color: var(--cyan-dark); font-size: 13px; font-weight: 850; }
.timeline h3 { margin: 5px 0; font-size: 21px; }
.timeline p { margin: 0; color: var(--muted); font-size: 14px; }
.timeline .critical time { color: var(--warning); }

.app-list, .security-list { margin: 30px 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.app-list li { display: flex; justify-content: space-between; gap: 30px; padding: 17px 0; border-bottom: 1px solid var(--line); }
.app-list span { color: var(--muted); font-size: 14px; text-align: right; }

.steps { margin: 34px 0; padding: 0; list-style: none; }
.steps li { display: grid; grid-template-columns: 52px 1fr; gap: 22px; padding: 0 0 35px; }
.steps li > span { display: grid; place-items: center; width: 46px; height: 46px; border: 0; border-radius: 50%; color: #fff; background: linear-gradient(45deg, var(--cyan), var(--pink)); box-shadow: 0 4px 18px rgba(0,66,161,.18); font-weight: 900; }
.steps h3 { margin: 2px 0 7px; font-size: 20px; }
.steps p { margin: 0; color: var(--muted); }
.steps.compact li { padding-bottom: 25px; }
.setup-flow li { position: relative; --step-color: var(--cyan); --next-step-color: var(--cyan); }
.setup-flow li:nth-child(1) { --step-color: #0042a1; --next-step-color: #1b449f; }
.setup-flow li:nth-child(2) { --step-color: #1b449f; --next-step-color: #35469c; }
.setup-flow li:nth-child(3) { --step-color: #35469c; --next-step-color: #50489a; }
.setup-flow li:nth-child(4) { --step-color: #50489a; --next-step-color: #6b4a97; }
.setup-flow li:nth-child(5) { --step-color: #6b4a97; --next-step-color: #854d95; }
.setup-flow li:nth-child(6) { --step-color: #854d95; --next-step-color: #a04f92; }
.setup-flow li:nth-child(7) { --step-color: #a04f92; --next-step-color: #bb5190; }
.setup-flow li:nth-child(8) { --step-color: #bb5190; --next-step-color: #d5538d; }
.setup-flow li:nth-child(9) { --step-color: #d5538d; --next-step-color: #f0558b; }
.setup-flow li:nth-child(10) { --step-color: #f0558b; --next-step-color: #f0558b; }
.setup-flow li:not(:last-child)::after { position: absolute; top: 46px; bottom: 0; left: 22px; width: 1px; background: linear-gradient(var(--step-color), var(--next-step-color)); content: ''; }
.setup-flow li > span { position: relative; z-index: 1; background: var(--step-color); }
.setup-flow .import-demo { margin: 24px 0 4px; }
#klpf, #register { scroll-margin-top: 100px; }
code { padding: 2px 6px; border-radius: 4px; background: #e7f3f6; font-family: ui-monospace, SFMono-Regular, Consolas, monospace; }
.official-manual { margin: 28px 0 36px; padding: 22px 24px; border-left: 4px solid var(--cyan); background: #f5f7fa; }
.official-manual h3 { margin: 0 0 8px; font-size: 17px; }
.official-manual a { overflow-wrap: anywhere; }
.official-manual p { margin: 8px 0 0; color: var(--muted); font-size: 14px; }

.klpf-section { padding-top: 45px; }
.import-demo { width: min(430px, 100%); margin: 34px 0 40px auto; padding: 24px; border-top: 4px solid var(--pink); border-radius: 20px; background: #fff; box-shadow: var(--shadow); }
.import-demo p { margin: 0 0 7px; color: var(--cyan-dark); font-size: 10px; font-weight: 900; letter-spacing: .13em; }
.import-demo strong { display: block; font-size: 20px; line-height: 1.4; }
.import-demo div { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 18px; text-align: center; }
.import-demo b, .import-demo i { padding: 9px; border-radius: 8px; font-size: 12px; font-style: normal; }
.import-demo b { color: #fff; background: linear-gradient(45deg, var(--cyan), var(--pink)); }
.import-demo i { color: var(--muted); background: #f2f6f7; }

.security-list li { padding: 14px 5px; border-bottom: 1px solid var(--line); }
.support-section dl { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; margin: 30px 0; background: var(--line); }
.support-section dl div { padding: 20px; background: #fff; }
.support-section dt { color: var(--muted); font-size: 12px; font-weight: 800; }
.support-section dd { margin: 3px 0 0; font-size: 20px; font-weight: 850; }
.fine-print { font-size: 13px !important; }

.closing-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; width: min(1040px, calc(100% - 48px)); margin: 0 auto 80px; }
.closing-card { padding: 36px 38px; border: 1px solid #dfe3e8; border-radius: 14px; background: #fff; }
.has-reveal .closing-card { opacity: 0; transform: translateY(36px); }
.has-reveal.reveal-ready .article-section,
.has-reveal.reveal-ready .closing-card { transition: opacity .7s ease-out, transform .7s cubic-bezier(.2,.8,.2,1); }
.closing-card h2 { margin: 0 0 16px; font-size: 25px; line-height: 1.4; }
.closing-card > p:not(.section-kicker) { color: var(--muted); }
.closing-card .security-list { margin-bottom: 0; }

footer { display: flex; align-items: center; gap: 25px; padding: 40px max(24px, calc((100vw - 1040px) / 2)); border-top: 1px solid var(--line); background: #fff; }
footer p { margin-right: auto; color: var(--muted); font-size: 13px; }
footer .footer-links { display: flex; align-items: center; gap: 24px; }
footer .footer-links a { color: var(--muted); font-size: 13px; white-space: nowrap; }

.bg-effects { position: fixed; inset: 0; z-index: 1; overflow: hidden; pointer-events: none; }
.floating-shapes { position: absolute; inset: 0; }
.shape { position: absolute; top: 0; border-radius: 50%; background: rgba(255,255,255,.065); animation: float 20s infinite linear; }
.shape:nth-child(1) { left: 10%; width: 80px; height: 80px; animation-delay: 0s; }
.shape:nth-child(2) { left: 20%; width: 120px; height: 120px; animation-delay: -5s; }
.shape:nth-child(3) { left: 60%; width: 60px; height: 60px; animation-delay: -10s; }
.shape:nth-child(4) { left: 80%; width: 100px; height: 100px; animation-delay: -15s; }

@keyframes float {
    0% { transform: translateY(100vh) rotate(0deg); opacity: 0; }
    10%, 90% { opacity: .6; }
    100% { transform: translateY(-10vh) rotate(360deg); opacity: 0; }
}

@media (max-width: 900px) {
    .deadline-section { grid-template-columns: 1fr; margin-top: 102px; }
    .article-layout { grid-template-columns: 1fr; padding: 44px; }
    .closing-cards { grid-template-columns: 1fr; }
    .toc { display: none; }
}
@media (max-width: 620px) {
    .header-inner { width: calc(100% - 30px); }
    nav { gap: 14px; }
    nav a:nth-child(2) { display: none; }
    .deadline-section, .article-layout, .closing-cards { width: calc(100% - 30px); }
    .article-layout { padding: 34px 24px; border-radius: 12px; }
    .deadline-message { padding: 28px 24px; }
    .timeline { grid-template-columns: 1fr; }
    .timeline > div + div { padding-left: 0; border-top: 1px solid var(--line); border-left: 0; }
    .app-list li { display: block; }
    .app-list span { display: block; margin-top: 3px; text-align: left; }
    .section-number { font-size: 56px; }
    .steps li { grid-template-columns: 42px 1fr; gap: 14px; }
    .steps li > span { width: 38px; height: 38px; }
    .setup-flow li:not(:last-child)::after { top: 38px; left: 18px; }
    footer { align-items: flex-start; flex-direction: column; gap: 7px; }
    footer p { margin: 0; }
    footer .footer-links { gap: 18px; }
}
