
:root {
    --sakura:        #c8536e;
    --sakura-dark:   #9e2f4a;
    --sakura-deeper: #7a1f38;
    --sakura-light:  #fce8ee;
    --sakura-pale:   #fff5f7;
    --accent:        #c8a84b;
    --white:         #ffffff;
    --border:        #f0d0da;
    --text-dark:     #2a1520;
    --text-mid:      #6b3a4a;
    --shadow:        0 4px 20px rgba(200,83,110,0.10);
    --shadow-lg:     0 8px 32px rgba(200,83,110,0.18);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: 'Hiragino Kaku Gothic ProN', 'Hiragino Sans', 'Meiryo', sans-serif;
    background: var(--sakura-pale);
    color: var(--text-dark);
    line-height: 1.7;
}

a { color: inherit; text-decoration: none; }

/* ヘッダー */
header {
    background: linear-gradient(135deg, var(--sakura-dark) 0%, var(--sakura) 100%);
    color: #fff;
    padding: 0 1rem;
    box-shadow: 0 2px 12px rgba(158,47,74,0.35);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 3px solid var(--accent);
}

.header-inner {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.65rem 0;
    gap: 1rem;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 1rem;
    min-width: 0;
}

.header-sakura-brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border-right: 1px solid rgba(255,255,255,0.3);
    padding-right: 1rem;
    flex-shrink: 0;
}

.header-sakura-brand img {
    height: 32px;
    width: auto;
    filter: brightness(0) invert(1);
}

.header-sakura-brand-text {
    font-size: 0.7rem;
    line-height: 1.3;
    color: rgba(255,255,255,0.9);
    font-weight: 700;
}

.header-sakura-brand-text span {
    display: block;
    font-size: 0.62rem;
    font-weight: 400;
    opacity: 0.8;
}

.site-title {
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.site-title a { color: #fff; }

.site-subtitle {
    font-size: 0.72rem;
    opacity: 0.78;
    margin-top: 0.1rem;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-shrink: 0;
}

.header-meta {
    font-size: 0.74rem;
    color: rgba(255,255,255,0.75);
    white-space: nowrap;
}

.header-cta {
    display: inline-block;
    background: var(--accent);
    color: var(--sakura-deeper) !important;
    font-size: 0.8rem;
    font-weight: 700;
    padding: 0.42rem 1.1rem;
    border-radius: 20px;
    white-space: nowrap;
    box-shadow: 0 2px 8px rgba(200,168,75,0.4);
    transition: opacity 0.2s, transform 0.15s;
    letter-spacing: 0.02em;
}

.header-cta:hover { opacity: 0.88; transform: translateY(-1px); }

/* カテゴリナビ */
.category-nav {
    background: var(--sakura-dark);
    overflow-x: auto;
    white-space: nowrap;
    border-bottom: 3px solid var(--accent);
}

.category-nav-inner {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    padding: 0 1rem;
}

.cat-tab {
    display: inline-block;
    padding: 0.65rem 1.25rem;
    font-size: 0.86rem;
    font-weight: 600;
    border-bottom: 3px solid transparent;
    cursor: pointer;
    transition: border-color 0.2s, color 0.2s, background 0.2s;
    color: rgba(255,255,255,0.7);
    margin-bottom: -3px;
}

.cat-tab:hover { color: #fff; background: rgba(255,255,255,0.08); }
.cat-tab[data-cat="all"] { border-bottom-color: var(--accent); color: #fff; font-weight: 700; }

/* さくら研修機構バナー */
.sakura-banner {
    background: var(--sakura-light);
    border-bottom: 1px solid var(--border);
    padding: 0.5rem 1rem;
}

.sakura-banner-inner {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.sakura-banner-text {
    font-size: 0.8rem;
    color: var(--text-mid);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.sakura-banner-text strong { font-weight: 700; color: var(--sakura-dark); }

.sakura-banner-link {
    font-size: 0.76rem;
    font-weight: 700;
    color: var(--white);
    background: var(--sakura-dark);
    padding: 0.25rem 0.8rem;
    border-radius: 12px;
    transition: opacity 0.2s;
    flex-shrink: 0;
}

.sakura-banner-link:hover { opacity: 0.82; }

/* メインレイアウト */
main {
    max-width: 1100px;
    margin: 1.5rem auto;
    padding: 0 1rem;
}

/* カテゴリセクション */
.category-section { margin-bottom: 2.5rem; }

.section-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--border);
}

.section-label {
    display: inline-block;
    padding: 0.25rem 0.8rem;
    border-radius: 4px;
    font-size: 0.82rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: 0.04em;
}

.section-label.gino    { background: #c0392b; }
.section-label.ikusei  { background: #1e7e5a; }
.section-label.tokutei { background: var(--sakura-dark); }
.section-label.general { background: #7a5230; }

.section-count {
    font-size: 0.82rem;
    color: var(--text-mid);
}

/* 記事カードグリッド */
.article-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1rem;
}

.article-card {
    background: var(--white);
    border-radius: 10px;
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: box-shadow 0.2s, transform 0.2s;
    display: flex;
    flex-direction: column;
}

.article-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-3px);
}

.card-color-bar {
    height: 4px;
    flex-shrink: 0;
}

.card-color-bar.gino    { background: #c0392b; }
.card-color-bar.ikusei  { background: #1e7e5a; }
.card-color-bar.tokutei { background: var(--sakura-dark); }
.card-color-bar.general { background: #7a5230; }

.card-body {
    padding: 1rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.card-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.card-category {
    font-size: 0.72rem;
    font-weight: 700;
    padding: 0.15rem 0.5rem;
    border-radius: 3px;
    color: #fff;
}

.card-category.gino    { background: #c0392b; }
.card-category.ikusei  { background: #1e7e5a; }
.card-category.tokutei { background: var(--sakura-dark); }
.card-category.general { background: #7a5230; }

.card-date {
    font-size: 0.75rem;
    color: #aaa;
}

.card-title {
    font-size: 0.95rem;
    font-weight: 700;
    line-height: 1.45;
    margin-bottom: 0.6rem;
    color: var(--sakura-dark);
}

.card-title a:hover { text-decoration: underline; }

.card-summary {
    font-size: 0.82rem;
    color: #555;
    line-height: 1.6;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-footer {
    padding: 0.6rem 1rem;
    border-top: 1px solid var(--sakura-light);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.card-source {
    font-size: 0.72rem;
    color: #aaa;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 70%;
}

.card-read-more {
    font-size: 0.75rem;
    color: var(--sakura-dark);
    font-weight: 600;
    flex-shrink: 0;
}

.card-read-more:hover { text-decoration: underline; }

/* 記事詳細ページ */
.article-page {
    max-width: 780px;
    margin: 1.5rem auto;
    padding: 0 1rem;
}

.breadcrumb {
    font-size: 0.8rem;
    color: #888;
    margin-bottom: 1.25rem;
}

.breadcrumb a { color: var(--sakura-dark); }
.breadcrumb a:hover { text-decoration: underline; }

.article-header {
    background: var(--white);
    border-radius: 10px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    box-shadow: var(--shadow);
    border-top: 5px solid var(--sakura-dark);
}

.article-header.gino    { border-top-color: #c0392b; }
.article-header.ikusei  { border-top-color: #1e7e5a; }
.article-header.tokutei { border-top-color: var(--sakura-dark); }
.article-header.general { border-top-color: #7a5230; }

.article-category-badge {
    display: inline-block;
    padding: 0.2rem 0.65rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 0.75rem;
}

.article-category-badge.gino    { background: #c0392b; }
.article-category-badge.ikusei  { background: #1e7e5a; }
.article-category-badge.tokutei { background: var(--sakura-dark); }
.article-category-badge.general { background: #7a5230; }

.article-title {
    font-size: 1.4rem;
    font-weight: 700;
    line-height: 1.4;
    margin-bottom: 0.75rem;
    color: var(--sakura-dark);
}

.article-info {
    display: flex;
    gap: 1.25rem;
    font-size: 0.78rem;
    color: #999;
    flex-wrap: wrap;
}

.key-points {
    background: var(--sakura-light);
    border-left: 4px solid var(--sakura-dark);
    border-radius: 0 8px 8px 0;
    padding: 1rem 1.25rem;
    margin-bottom: 1rem;
}

.key-points.gino    { background: #ffebee; border-left-color: #c0392b; }
.key-points.ikusei  { background: #e8f5e9; border-left-color: #1e7e5a; }
.key-points.tokutei { background: var(--sakura-light); border-left-color: var(--sakura-dark); }
.key-points.general { background: #efebe9; border-left-color: #7a5230; }

.key-points h3 {
    font-size: 0.88rem;
    font-weight: 700;
    margin-bottom: 0.6rem;
    color: #333;
}

.key-points ul {
    list-style: none;
    padding: 0;
}

.key-points li {
    font-size: 0.85rem;
    padding: 0.2rem 0;
    padding-left: 1.25rem;
    position: relative;
    color: #333;
}

.key-points li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--sakura-dark);
    font-weight: 700;
}

.key-points.gino li::before    { color: #c0392b; }
.key-points.ikusei li::before  { color: #1e7e5a; }
.key-points.general li::before { color: #7a5230; }

.article-content {
    background: var(--white);
    border-radius: 10px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    box-shadow: var(--shadow);
    line-height: 1.85;
}

.article-content h2 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--sakura-dark);
    margin: 1.5rem 0 0.6rem;
    padding-bottom: 0.3rem;
    border-bottom: 1px solid var(--border);
}

.article-content h2:first-child { margin-top: 0; }

.article-content p {
    font-size: 0.92rem;
    color: #333;
    margin-bottom: 0.9rem;
}

.article-source {
    background: var(--white);
    border-radius: 10px;
    padding: 1rem 1.25rem;
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.article-source-label {
    font-size: 0.78rem;
    color: #888;
    flex-shrink: 0;
}

.article-source a {
    font-size: 0.82rem;
    color: var(--sakura-dark);
    word-break: break-all;
}

.article-source a:hover { text-decoration: underline; }

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--sakura-dark);
    font-size: 0.88rem;
    font-weight: 600;
}

.back-link:hover { text-decoration: underline; }

/* フッター */
footer {
    background: var(--sakura-deeper);
    color: rgba(255,255,255,0.7);
    text-align: center;
    padding: 2rem 1rem;
    font-size: 0.8rem;
    margin-top: 3rem;
}

footer a { color: rgba(255,255,255,0.85); }

.footer-brand {
    margin-bottom: 0.6rem;
    font-size: 0.88rem;
    font-weight: 700;
    color: rgba(255,255,255,0.9);
}

.footer-brand a {
    color: var(--accent);
}

/* 空状態 */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: #aaa;
    font-size: 0.9rem;
}

/* レスポンシブ */
@media (max-width: 700px) {
    .article-grid { grid-template-columns: 1fr; }
    .article-title { font-size: 1.15rem; }
    .header-inner { flex-wrap: wrap; }
    .header-sakura-brand { display: none; }
    .header-meta { display: none; }
    .sakura-banner-inner { flex-direction: column; align-items: flex-start; }
}
