/* =========================================================
   Chepics コーポレートサイト 共有スタイル
   ブランドカラーはプロダクトLP(/chepics)と統一
   ========================================================= */

:root {
    --primary-color: #F65B0A;
    --primary-light: #FF7A33;
    --primary-dark: #D94E06;
    --text-color: #141414;
    --text-secondary: #444444;
    --text-light: #777777;
    --bg-color: #FFFFFF;
    --bg-secondary: #F7F7F8;
    --dark-bg: #141414;
    --border-color: #ECECEC;
    --gradient-primary: linear-gradient(135deg, #F65B0A 0%, #FF8C42 100%);
    --gradient-warm: linear-gradient(135deg, #FFF3ED 0%, #FFE8DA 100%);
    --max-width: 1080px;
    --radius: 14px;
    --shadow: 0 10px 30px rgba(20, 20, 20, 0.06);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: Arial, 'Helvetica Neue', Helvetica, 'Hiragino Kaku Gothic ProN', 'Hiragino Sans', Meiryo, sans-serif;
    color: var(--text-color);
    background-color: var(--bg-color);
    font-size: 17px;
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    display: block;
}

.container {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 24px;
}

.section {
    padding: 88px 0;
}

.section-secondary {
    background: var(--bg-secondary);
}

.eyebrow {
    display: block;
    font-size: clamp(2.8rem, 7.5vw, 5rem);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.02em;
    color: var(--text-color);
    margin-bottom: 16px;
}

.section-title {
    font-size: clamp(1.7rem, 3.4vw, 2.6rem);
    font-weight: 800;
    line-height: 1.4;
    letter-spacing: -0.01em;
    color: var(--text-color);
}

.section-lead {
    margin-top: 24px;
    color: var(--text-secondary);
    font-size: clamp(1.05rem, 2vw, 1.25rem);
    line-height: 1.9;
    max-width: 760px;
}

.text-center { text-align: center; }
.mx-auto { margin-left: auto; margin-right: auto; }

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    font-size: 1.02rem;
    padding: 16px 32px;
    border-radius: 999px;
    transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: var(--text-color);
    color: #fff;
    box-shadow: 0 8px 20px rgba(20, 20, 20, 0.16);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 26px rgba(20, 20, 20, 0.24);
}

.btn-outline {
    background: transparent;
    color: var(--text-color);
    border: 1.5px solid var(--text-color);
}

.btn-outline:hover {
    background: var(--text-color);
    color: #fff;
}

/* ---------- Header ---------- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: saturate(180%) blur(12px);
    border-bottom: 1px solid var(--border-color);
}

.site-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
    width: 100%;
    padding: 0 20px;
}

.site-logo img {
    height: 26px;
    width: auto;
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 28px;
}

.site-nav a {
    font-size: 0.92rem;
    font-weight: 600;
    color: var(--text-secondary);
    transition: color 0.15s ease;
}

.site-nav a:hover { color: var(--primary-color); }

.site-nav .nav-cta {
    padding: 9px 18px;
    border-radius: 999px;
    background: var(--gradient-primary);
    color: #fff;
}

.site-nav .nav-cta:hover { color: #fff; }

/* Language switcher */
.lang-switch {
    position: relative;
    font-size: 0.85rem;
}

.lang-switch select {
    appearance: none;
    -webkit-appearance: none;
    border: 1px solid var(--border-color);
    background: #fff;
    border-radius: 999px;
    padding: 7px 30px 7px 14px;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23777' stroke-width='3'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
}

/* Mobile nav */
.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
}

.nav-toggle span {
    width: 24px;
    height: 2px;
    background: var(--text-color);
    border-radius: 2px;
}

@media (max-width: 820px) {
    .nav-toggle { display: flex; }
    .site-nav {
        position: fixed;
        inset: 64px 0 auto 0;
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
        background: #fff;
        padding: 16px 24px 28px;
        border-bottom: 1px solid var(--border-color);
        box-shadow: var(--shadow);
        transform: translateY(-12px);
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.18s ease, transform 0.18s ease;
    }
    .site-nav.open {
        opacity: 1;
        transform: translateY(0);
        pointer-events: auto;
    }
    .site-nav a { width: 100%; padding: 10px 0; }
    .lang-switch { margin-top: 8px; }
}

/* ---------- Hero ---------- */
.hero {
    position: relative;
    display: flex;
    align-items: center;
    min-height: clamp(440px, 70vh, 720px);
    padding: clamp(72px, 12vw, 132px) 0;
    border-bottom: 1px solid var(--border-color);
    /* 背景画像。暗いオーバーレイを重ねて白文字の可読性を確保する */
    background-color: var(--dark-bg);
    background-image:
        linear-gradient(180deg, rgba(20, 20, 20, 0.45) 0%, rgba(20, 20, 20, 0.65) 100%),
        url("../images/hero-bg.jpg");
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.hero-inner {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 24px;
}

.hero h1 {
    font-size: clamp(2.6rem, 8vw, 5.2rem);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.02em;
    color: #FFFFFF;
    text-shadow: 0 2px 24px rgba(0, 0, 0, 0.35);
}

.hero h1 .accent {
    color: var(--primary-light);
}

.hero p {
    margin-top: 22px;
    font-size: clamp(1rem, 2.4vw, 1.18rem);
    color: rgba(255, 255, 255, 0.88);
    max-width: 640px;
}

.hero-actions {
    margin-top: 36px;
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
}

/* 暗いヒーロー背景の上で使うボタン配色 */
.btn-hero-primary {
    background: var(--gradient-primary);
    color: #fff;
    box-shadow: 0 10px 26px rgba(246, 91, 10, 0.38);
}

.btn-hero-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 32px rgba(246, 91, 10, 0.48);
}

.btn-hero-outline {
    background: #fff;
    color: var(--text-color);
    border: 1.5px solid #fff;
    box-shadow: 0 10px 26px rgba(20, 20, 20, 0.18);
}

.btn-hero-outline:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 32px rgba(20, 20, 20, 0.26);
}

/* 狭い画面ではボタンを縦並び・全幅にし、中央寄せで折り返す */
@media (max-width: 640px) {
    .hero-actions {
        flex-direction: column;
        align-items: stretch;
    }
    .hero-actions .btn {
        width: 100%;
        justify-content: center;
        text-align: center;
        padding-left: 20px;
        padding-right: 20px;
        /* 日本語が語中で改行されるのを防ぎ、<wbr> の位置だけで折り返す */
        word-break: keep-all;
    }
}

/* ---------- Cards / grid ---------- */
.grid {
    display: grid;
    gap: 24px;
    margin-top: 48px;
}

.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }

@media (max-width: 820px) {
    .grid-2, .grid-3 { grid-template-columns: 1fr; }
}

.card {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 32px;
    box-shadow: var(--shadow);
}

.card h3 {
    font-size: 1.4rem;
    font-weight: 800;
    margin-bottom: 14px;
}

.card p {
    color: var(--text-secondary);
    font-size: 1.05rem;
    line-height: 1.85;
}

/* Product highlight card */
.product-card {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: 40px;
    align-items: center;
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 44px;
    box-shadow: var(--shadow);
    margin-top: 48px;
}

.product-card .product-visual img {
    width: 100%;
    border-radius: 12px;
}

.product-card h3 {
    font-size: clamp(1.8rem, 3vw, 2.2rem);
    font-weight: 800;
    margin-bottom: 16px;
}

.product-card p {
    color: var(--text-secondary);
    font-size: 1.08rem;
    line-height: 1.85;
}

.product-card .product-actions {
    margin-top: 26px;
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
}

@media (max-width: 820px) {
    .product-card { grid-template-columns: 1fr; padding: 28px; }
}

/* ---------- Company profile table ---------- */
.profile-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 40px;
    border-top: 1px solid var(--border-color);
}

.profile-table th,
.profile-table td {
    text-align: left;
    padding: 20px 8px;
    border-bottom: 1px solid var(--border-color);
    vertical-align: top;
    font-size: 0.98rem;
}

.profile-table th {
    width: 220px;
    font-weight: 700;
    color: var(--text-color);
}

.profile-table td { color: var(--text-secondary); }

@media (max-width: 640px) {
    .profile-table th, .profile-table td { display: block; width: 100%; }
    .profile-table th { padding-bottom: 4px; border-bottom: none; }
    .profile-table td { padding-top: 4px; }
}

/* ---------- News list ---------- */
.news-list {
    margin-top: 40px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.news-item {
    display: block;
    padding: 22px 8px;
    border-bottom: 1px solid var(--border-color);
    transition: background 0.15s ease;
}

.news-item:hover { background: var(--bg-secondary); }

.news-meta {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 8px;
}

.news-date { font-size: 0.85rem; color: var(--text-light); }

.news-tag {
    font-size: 0.74rem;
    font-weight: 700;
    color: var(--primary-color);
    background: var(--bg-secondary);
    padding: 3px 10px;
    border-radius: 999px;
}

.news-title { font-size: 1.05rem; font-weight: 700; }

.news-summary { margin-top: 6px; color: var(--text-secondary); font-size: 0.94rem; }

.news-state {
    text-align: center;
    color: var(--text-light);
    padding: 48px 0;
}

/* ---------- CTA band ---------- */
.cta-band {
    background: var(--dark-bg);
    color: #fff;
    text-align: center;
    padding: 80px 0;
}

.cta-band h2 {
    font-size: clamp(1.9rem, 5vw, 3rem);
    font-weight: 800;
    line-height: 1.3;
    letter-spacing: -0.01em;
}

.cta-band p { margin-top: 18px; font-size: 1.1rem; opacity: 0.9; }

.cta-band .btn {
    margin-top: 30px;
    background: var(--primary-color);
    color: #fff;
}

.cta-band .btn:hover { transform: translateY(-2px); }

/* ---------- Footer ---------- */
.site-footer {
    background: var(--dark-bg);
    color: #cfcfcf;
    padding: 64px 0 36px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr;
    gap: 40px;
}

@media (max-width: 820px) {
    .footer-grid { grid-template-columns: 1fr; gap: 28px; }
}

.footer-brand img { height: 28px; margin-bottom: 16px; }
.footer-brand p { font-size: 0.9rem; color: #9a9a9a; max-width: 320px; }

.footer-col h4 {
    font-size: 0.82rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #fff;
    margin-bottom: 16px;
}

.footer-col a {
    display: block;
    font-size: 0.92rem;
    color: #cfcfcf;
    padding: 6px 0;
    transition: color 0.15s ease;
}

.footer-col a:hover { color: var(--primary-light); }

.footer-bottom {
    margin-top: 48px;
    padding-top: 24px;
    border-top: 1px solid #2a2a2a;
    font-size: 0.82rem;
    color: #8a8a8a;
}

/* ---------- Reveal animation ---------- */
.fade-in {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}
