/*
Theme Name: FinSight Home
Theme URI: https://example.com/
Author: FinSight AI Lab
Description: 投資ニュースと市場データを中心にしたFinSightのホームテーマ。
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
Text Domain: finsight-home
*/

:root {
    --ink: #172126;
    --muted: #607078;
    --paper: #f4f7f8;
    --surface: #ffffff;
    --line: #d9e2e5;
    --teal: #006d77;
    --teal-dark: #004f57;
    --orange: #e07a45;
    --green: #198754;
    --red: #c94c4c;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    color: var(--ink);
    background: var(--paper);
    font-family: "Yu Gothic", "Hiragino Kaku Gothic ProN", Meiryo, sans-serif;
    line-height: 1.7;
}
a { color: var(--teal); text-decoration: none; }
a:hover { color: var(--teal-dark); }
.site-shell { overflow: hidden; }
.site-header {
    background: rgba(255,255,255,.94);
    border-bottom: 1px solid var(--line);
    position: sticky;
    top: 0;
    z-index: 10;
    backdrop-filter: blur(12px);
}
.header-inner, .content-width { width: min(1160px, calc(100% - 40px)); margin: 0 auto; }
.header-inner { min-height: 72px; display: flex; align-items: center; justify-content: space-between; gap: 28px; }
.brand { color: var(--ink); display: inline-flex; align-items: baseline; gap: 10px; }
.brand strong { font-family: Georgia, serif; font-size: 1.55rem; letter-spacing: .02em; }
.brand span { color: var(--muted); font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; }
.main-nav { display: flex; align-items: center; gap: 24px; font-size: .88rem; font-weight: 700; }
.main-nav a { color: var(--ink); }
.main-nav a:hover { color: var(--teal); }
.hero { position: relative; padding: 88px 0 76px; background: #e8f0ef; }
.hero:after { content: ""; position: absolute; right: -7%; top: -42px; width: 52%; height: 340px; opacity: .35; background: repeating-linear-gradient(165deg, transparent 0 34px, var(--teal) 35px 36px, transparent 37px 70px); transform: rotate(-4deg); pointer-events: none; }
.hero-grid { position: relative; z-index: 1; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(280px, .85fr); gap: 60px; align-items: center; }
.eyebrow { margin: 0 0 16px; color: var(--orange); font-size: .77rem; font-weight: 800; letter-spacing: .18em; text-transform: uppercase; }
.hero h1 { max-width: 640px; margin: 0; font-family: Georgia, "Yu Mincho", serif; font-size: clamp(2.4rem, 5vw, 4.65rem); line-height: 1.12; letter-spacing: 0; }
.hero-copy { max-width: 570px; margin: 24px 0 30px; color: #405158; font-size: 1.05rem; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 46px; padding: 0 20px; border: 1px solid var(--teal); border-radius: 3px; font-weight: 800; }
.button-primary { color: #fff; background: var(--teal); }
.button-secondary { color: var(--teal); background: transparent; }
.hero-panel { padding: 22px; background: rgba(255,255,255,.72); border: 1px solid rgba(0,109,119,.2); box-shadow: 12px 12px 0 rgba(0,109,119,.1); }
.panel-label { margin: 0 0 16px; color: var(--muted); font-size: .73rem; font-weight: 800; letter-spacing: .16em; }
.signal-row { display: flex; align-items: end; justify-content: space-between; gap: 18px; padding: 15px 0; border-top: 1px solid var(--line); }
.signal-row { color: inherit; }
.signal-row:hover { color: var(--teal); }
.signal-row strong { display: block; font-size: 1.25rem; }
.signal-row span { color: var(--muted); font-size: .78rem; }
.status { color: var(--orange); font-size: .78rem; font-weight: 700; }
.nav-arrow { color: var(--teal); font-size: 1.25rem; font-weight: 400; }
.section { padding: 48px 0; }
#economic-events { padding-top: 48px; }
#economic-schedule { padding-bottom: 48px; }
.section-white { background: var(--surface); }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 24px; }
.section-heading h2 { margin: 0; font-family: Georgia, "Yu Mincho", serif; font-size: 2rem; line-height: 1.2; }
.section-heading p { margin: 0; color: var(--muted); font-size: .88rem; }
.finsight-card { background: var(--surface); border: 1px solid var(--line); }
.finsight-market-card { overflow: hidden; }
.market-grid { display: grid; grid-template-columns: repeat(5, 1fr); }
.market-item { padding: 20px; border-right: 1px solid var(--line); }
.market-item:last-child { border-right: 0; }
.market-item small { color: var(--muted); font-weight: 700; }
.market-value { display: block; margin: 5px 0; font-size: 1.3rem; font-weight: 800; }
.market-note { color: var(--orange); font-size: .76rem; }
.market-up { color: var(--green); }
.market-down { color: var(--red); }
.news-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 36px; align-items: start; }
.news-feed { padding: 0; background: transparent; border: 0; }
.news-feed h3 { margin: 0 0 20px; font-size: 1.05rem; }
.news-content { color: #314047; }
.finsight-news-empty { margin: 0; padding: 28px; background: var(--surface); border: 1px solid var(--line); color: var(--muted); }
.news-content h1, .news-content h2 { font-family: Georgia, "Yu Mincho", serif; line-height: 1.3; }
.news-content img { max-width: 100%; height: auto; }
.news-content a { text-decoration: underline; text-underline-offset: 3px; }
.news-content ul { padding-left: 1.3em; }
.finsight-briefing-meta { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: -4px 0 22px; color: var(--muted); font-size: .73rem; font-weight: 800; letter-spacing: .12em; }
.finsight-briefing-meta span { color: var(--orange); }
.finsight-briefing-meta time { letter-spacing: 0; font-weight: 600; }
.finsight-briefing-summary { padding: 22px 26px; background: #f8fafc; border: 1px solid var(--line); border-radius: 4px; }
.finsight-briefing-summary .briefing-summary-title { margin: 0 0 10px; font-size: 1.1rem; font-weight: 800; color: var(--ink); }
.finsight-briefing-summary p { margin: 10px 0; color: #1e293b; font-size: .96rem; line-height: 1.8; font-weight: 500; }
.finsight-briefing-summary p:last-child { margin-bottom: 0; }
.finsight-source-list { margin-bottom: 0; }
.finsight-news-cards { display: grid; gap: 12px; margin-top: 22px; }
.finsight-news-card { padding: 18px; border: 1px solid var(--line); background: var(--surface); }
.finsight-news-card-meta { display: flex; justify-content: space-between; gap: 12px; color: var(--muted); font-size: .7rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.finsight-news-card-meta span:last-child { letter-spacing: 0; text-transform: none; }
.finsight-news-card-meta .importance-high { color: var(--red); }
.finsight-news-card-meta .importance-medium { color: var(--orange); }
.finsight-news-card h3 { margin: 10px 0 6px; font-size: 1.05rem; line-height: 1.45; }
.finsight-news-card p { margin: 7px 0; color: #405158; font-size: .88rem; }
.finsight-news-card .finsight-news-card-impact { color: var(--teal-dark); font-weight: 700; }
.finsight-news-card-source { margin: 0 0 10px; color: var(--muted); font-size: .76rem; }
.finsight-news-card-link { font-size: .82rem; font-weight: 800; }
.economic-events-card { padding: 0 24px 24px; background: var(--surface); border: 1px solid var(--line); }
.next-week-schedule { border: 1px solid var(--line); background: var(--surface); }
.schedule-day { display: grid; grid-template-columns: 130px minmax(0, 1fr); border-bottom: 1px solid var(--line); }
.schedule-day:last-child { border-bottom: 0; }
.schedule-day > time { display: flex; align-items: flex-start; padding: 18px 20px; color: #fff; background: var(--teal); font-size: 1.1rem; font-weight: 800; }
.schedule-events { display: grid; }
.schedule-event { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 15px 20px; border-bottom: 1px solid #edf1f2; }
.schedule-event:last-child { border-bottom: 0; }
.schedule-country { color: var(--teal-dark); font-size: .78rem; font-weight: 800; }
.schedule-event strong { font-size: 1rem; }
.schedule-event small { color: var(--muted); font-variant-numeric: tabular-nums; }
.event-history { border: 1px solid var(--line); background: var(--surface); }
.event-history-month { border-top: 1px solid var(--line); }
.event-history-month h3 { margin: 0; padding: 15px 20px; color: var(--teal-dark); font-size: 1.15rem; background: #f7faf9; }
.event-history-month .schedule-event { border-top: 1px solid #edf1f2; }
.economic-results-card { margin-top: 46px; padding-top: 28px; border-top: 1px solid var(--line); }
.economic-events-header { display: flex; align-items: end; justify-content: space-between; gap: 20px; padding: 0 0 22px; }
.economic-events-header h2 { margin: 0; font-family: Georgia, "Yu Mincho", serif; font-size: 2rem; }
.economic-events-header > span { color: var(--muted); font-size: .82rem; }
.economic-events-empty { margin: 0; padding: 24px 0; color: var(--muted); border-bottom: 1px solid var(--line); }
.economic-results-list { border-top: 1px solid var(--line); }
.economic-result-item { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px; align-items: center; padding: 16px 0; border-bottom: 1px solid var(--line); }
.economic-result-title > span { color: var(--muted); font-size: .72rem; font-weight: 800; }
.economic-result-title h3 { margin: 3px 0; font-size: 1rem; }
.economic-result-title small { color: var(--muted); font-size: .76rem; }
.economic-result-values { display: flex; align-items: stretch; gap: 8px; font-variant-numeric: tabular-nums; }
.economic-result-values > span { display: inline-flex; min-width: 78px; flex-direction: column; justify-content: center; gap: 2px; padding: 7px 10px; color: var(--muted); background: var(--paper); }
.economic-result-values small { font-size: .68rem; line-height: 1.2; }
.economic-result-values b { color: var(--ink); font-size: .9rem; line-height: 1.2; }
.economic-result-values .economic-result-actual { background: #e8f0ef; border-left: 3px solid var(--teal); }
.economic-result-values .economic-result-difference { background: transparent; }
.economic-result-values .economic-result-difference b { font-weight: 800; }
.economic-result-values .is-positive b { color: var(--green); }
.economic-result-values .is-negative b { color: var(--red); }
.economic-results-link { display: inline-block; margin-top: 18px; font-size: .82rem; font-weight: 800; }
.economic-events-history-label { margin: 0 0 14px; color: var(--muted); font-size: .82rem; }
.economic-events-filters { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 18px; }
.economic-events-filters button { padding: 7px 13px; color: var(--muted); background: var(--paper); border: 1px solid var(--line); border-radius: 3px; cursor: pointer; font: inherit; font-size: .78rem; font-weight: 700; }
.economic-events-filters button.is-active { color: #fff; background: var(--teal); border-color: var(--teal); }
.economic-events-list { border-top: 1px solid var(--line); }
.economic-event-day { border-bottom: 1px solid var(--line); }
.economic-event-day-heading { display: flex; align-items: baseline; gap: 10px; margin: 0; padding: 14px 0 8px; font-size: .86rem; }
.economic-event-day-heading strong { font-size: 1rem; }
.economic-event-day-heading span { color: var(--muted); font-weight: 600; }
.economic-event-item { display: grid; grid-template-columns: 90px minmax(0, 1fr); gap: 8px 22px; padding: 14px 0; border-top: 1px solid #edf1f2; }
.economic-event-country strong { display: block; font-size: 1.05rem; }
.economic-event-values { grid-column: 2; display: flex; flex-wrap: wrap; align-items: stretch; gap: 8px; color: var(--muted); font-variant-numeric: tabular-nums; }
.economic-event-value { display: inline-flex; min-width: 76px; flex-direction: column; justify-content: center; gap: 2px; padding: 6px 10px; background: #f4f7f8; }
.economic-event-value small { color: var(--muted); font-size: .68rem; line-height: 1.2; }
.economic-event-value b { color: var(--ink); font-size: .88rem; font-weight: 700; line-height: 1.2; }
.economic-event-actual { background: #e8f0ef; border-left: 3px solid var(--teal); }
.economic-event-difference { background: transparent; }
.economic-event-difference b { font-weight: 800; }
.economic-event-difference.is-positive { color: var(--green); }
.economic-event-difference.is-negative { color: var(--red); }
.economic-event-meta { display: flex; gap: 12px; color: var(--muted); font-size: .72rem; font-weight: 800; letter-spacing: .08em; }
.economic-event-meta .importance-high { color: var(--red); }
.economic-event-meta .importance-medium { color: var(--orange); }
.economic-event-item h4 { margin: 5px 0; font-size: 1.08rem; }
.economic-event-item p { margin: 0; color: #405158; font-size: .86rem; }
.content-page { padding: 64px 0; background: var(--paper); min-height: 60vh; }
.content-page h1 { margin: 0; font-family: Georgia, "Yu Mincho", serif; font-size: 2.4rem; line-height: 1.2; }
.content-page-body, .finsight-news-single { padding: 28px; background: var(--surface); border: 1px solid var(--line); }
.finsight-contact-form { display: grid; gap: 18px; max-width: 720px; }
.finsight-contact-form label { display: grid; gap: 6px; color: var(--muted); font-size: .85rem; font-weight: 700; }
.finsight-contact-form input, .finsight-contact-form textarea { width: 100%; padding: 10px 12px; color: var(--ink); background: #fff; border: 1px solid var(--line); font: inherit; }
.finsight-contact-form button { width: fit-content; min-height: 44px; padding: 0 20px; color: #fff; background: var(--teal); border: 1px solid var(--teal); cursor: pointer; font: inherit; font-weight: 800; }
.contact-form-honeypot { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; }
.contact-form-notice { padding: 14px; border-left: 3px solid var(--teal); background: #f7faf9; }
.contact-form-error { border-left-color: var(--red); }
.finsight-news-filters { display: flex; flex-wrap: wrap; align-items: end; gap: 12px; margin-bottom: 28px; padding: 18px; background: #f7faf9; border: 1px solid var(--line); }
.finsight-news-filters label { display: grid; gap: 5px; color: var(--muted); font-size: .78rem; font-weight: 700; }
.finsight-news-filters input, .finsight-news-filters select { min-height: 40px; padding: 7px 10px; color: var(--ink); background: #fff; border: 1px solid var(--line); font: inherit; }
.finsight-news-filters button { min-height: 40px; padding: 7px 16px; color: #fff; background: var(--teal); border: 1px solid var(--teal); cursor: pointer; font: inherit; font-weight: 800; }
.finsight-news-archive-list { display: grid; gap: 12px; }
.finsight-news-archive-item { padding: 20px; border: 1px solid var(--line); background: var(--surface); }
.finsight-news-archive-meta { display: flex; flex-wrap: wrap; gap: 12px; color: var(--muted); font-size: .76rem; font-weight: 700; }
.finsight-news-archive-meta span:first-child { color: var(--orange); }
.finsight-news-archive-item h2 { margin: 8px 0 5px; font-size: 1.15rem; line-height: 1.45; }
.finsight-news-archive-item h2 a { color: var(--ink); }
.finsight-news-archive-item p { margin: 0 0 10px; color: #405158; font-size: .9rem; }
.finsight-news-archive-link, .finsight-news-source { font-size: .82rem; font-weight: 800; }
.finsight-news-archive .page-numbers { display: flex; gap: 8px; margin: 24px 0 0; padding: 0; list-style: none; }
.finsight-news-archive .page-numbers a, .finsight-news-archive .page-numbers span { display: inline-flex; min-width: 36px; min-height: 36px; align-items: center; justify-content: center; border: 1px solid var(--line); }
.finsight-news-archive .page-numbers .current { color: #fff; background: var(--teal); border-color: var(--teal); }
.finsight-news-archive-empty { padding: 24px 0; color: var(--muted); }
.finsight-news-single h1 { margin: 0 0 10px; font-family: Georgia, "Yu Mincho", serif; font-size: 2.3rem; line-height: 1.3; }
.finsight-news-single-date { color: var(--muted); font-size: .82rem; }
.finsight-news-single-content { margin: 28px 0; color: #314047; }
.finsight-news-disclaimer { padding: 14px; color: var(--muted); background: #f7faf9; border-left: 3px solid var(--teal); font-size: .82rem; }
.finsight-news-source { padding-top: 18px; border-top: 1px solid var(--line); }
.site-footer { padding: 28px 0; color: #c0ced0; background: #102024; font-size: .82rem; }
.footer-inner { display: flex; justify-content: space-between; gap: 20px; }
.footer-inner a { color: #d8e7e8; }
.screen-reader-text { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
@media (max-width: 800px) {
    .header-inner { min-height: 64px; flex-wrap: wrap; padding: 10px 0; }
    .main-nav { width: 100%; gap: 12px; overflow-x: auto; font-size: .76rem; white-space: nowrap; scrollbar-width: none; }
    .main-nav::-webkit-scrollbar { display: none; }
    .hero { padding: 62px 0 56px; }
    .hero-grid, .news-layout { grid-template-columns: 1fr; gap: 34px; }
    #economic-events { padding-top: 24px; }
    .economic-events-header { display: block; }
    .schedule-header { display: block; }
    .schedule-header time { display: block; margin-top: 8px; }
    .economic-events-header > span { display: block; margin-top: 10px; }
    .economic-event-item { grid-template-columns: 64px minmax(0, 1fr); gap: 14px; }
    .economic-event-values { grid-column: 2; }
    .economic-result-item { display: block; }
    .economic-result-item .economic-result-values { margin-top: 12px; flex-wrap: wrap; }
    .hero:after { width: 90%; opacity: .2; }
    .market-grid { grid-template-columns: repeat(2, 1fr); }
    .market-item:nth-child(2) { border-right: 0; }
    .market-item:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
}
@media (max-width: 520px) {
    .header-inner, .content-width { width: min(100% - 28px, 1160px); }
    .brand span { display: none; }
    .main-nav { gap: 8px; }
    .hero h1 { font-size: 2.65rem; }
    .section { padding: 46px 0; }
    .news-feed { padding: 20px; }
    .content-page { padding: 46px 0; }
    .content-page-body, .finsight-news-single { padding: 20px; }
    .content-page h1, .finsight-news-single h1 { font-size: 1.85rem; }
    .schedule-day { display: block; }
    .schedule-day > time { display: block; padding: 10px 14px; }
    .schedule-event { grid-template-columns: 44px minmax(0, 1fr); gap: 8px; padding: 13px 14px; }
    .schedule-event small { grid-column: 2; }
    .finsight-news-filters { display: grid; }
    .finsight-news-filters input, .finsight-news-filters select, .finsight-news-filters button { width: 100%; }
    .footer-inner { display: block; }
}
