/* ===== リセット・基本設定 ===== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --primary: #31302e;
    --accent: #0075de;
    --accent-hover: #005bab;
    --text: rgba(0, 0, 0, 0.95);
    --text-light: #615d59;
    --text-muted: #a39e98;
    --bg: #ffffff;
    --warm-white: #f6f5f4;
    --white: #fff;
    --border: rgba(0, 0, 0, 0.1);
    --shadow: rgba(0,0,0,0.04) 0px 4px 18px,
              rgba(0,0,0,0.027) 0px 2.025px 7.85px,
              rgba(0,0,0,0.02) 0px 0.8px 2.93px,
              rgba(0,0,0,0.01) 0px 0.175px 1.04px;
    --shadow-hover: rgba(0,0,0,0.01) 0px 1px 3px,
                    rgba(0,0,0,0.02) 0px 3px 7px,
                    rgba(0,0,0,0.02) 0px 7px 15px,
                    rgba(0,0,0,0.04) 0px 14px 28px,
                    rgba(0,0,0,0.05) 0px 23px 52px;
    --radius: 12px;
    --radius-sm: 4px;
    --radius-pill: 9999px;
    --transition: 0.3s ease;
    --max-width: 1200px;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, system-ui, 'Hiragino Kaku Gothic ProN', 'Hiragino Sans', Meiryo, sans-serif;
    color: var(--text);
    background: var(--bg);
    line-height: 1.5;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    font-kerning: normal;
}

a {
    color: var(--accent);
    text-decoration: none;
    transition: color var(--transition);
}

a:hover {
    color: var(--accent-hover);
}

a:focus-visible,
.btn:focus-visible,
.nav-list a:focus-visible {
    outline: 2px solid #097fe8;
    outline-offset: 2px;
    border-radius: 2px;
}

img {
    max-width: 100%;
    height: auto;
}

.container {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* ===== ヘッダー ===== */
.site-header {
    background: var(--white);
    color: var(--text);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid var(--border);
}

.site-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.site-logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text);
    letter-spacing: normal;
}

.site-logo:hover {
    color: var(--accent);
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text);
    font-size: 1.5rem;
    cursor: pointer;
}

.nav-list {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-list a {
    color: var(--text);
    font-size: 0.94rem;
    font-weight: 600;
    transition: color var(--transition);
}

.nav-list a:hover {
    color: var(--accent);
}

/* ===== メイン ===== */
.site-main {
    flex: 1;
    padding: 2rem 0;
}

/* ===== ヒーロー ===== */
.hero {
    text-align: center;
    padding: 5rem 0 3rem;
    margin-bottom: 2rem;
}

.hero h1 {
    font-size: 4rem;
    color: var(--text);
    margin-bottom: 0.75rem;
    font-weight: 700;
    letter-spacing: -1.5px;
    line-height: 1.0;
}

h1, h2, h3 {
    font-feature-settings: "lnum", "locl";
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-light);
    font-weight: 600;
    line-height: 1.4;
}

/* ===== セクション ===== */
.section-title {
    font-size: 1.625rem;
    color: var(--text);
    margin-bottom: 1.5rem;
    padding-bottom: 0;
    border-bottom: none;
    display: block;
    font-weight: 700;
    letter-spacing: -0.625px;
}

/* ===== サイトカード（ポートフォリオ） ===== */
.sites-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.site-card {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 1.5rem;
    transition: box-shadow var(--transition), transform var(--transition);
    border-top: none;
    border: 1px solid var(--border);
    border-left: 3px solid var(--card-color, var(--accent));
}

.site-card:hover {
    box-shadow: var(--shadow-hover);
    transform: translateY(-1px);
}

.site-card-title {
    font-size: 1.375rem;
    margin-bottom: 0.75rem;
    font-weight: 700;
    letter-spacing: -0.25px;
}

.site-card-title a {
    color: var(--text);
}

.site-card-description {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 1rem;
    line-height: 1.5;
}

.site-card-tags {
    margin-bottom: 1rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.tag {
    display: inline-block;
    background: #f2f9ff;
    color: #097fe8;
    padding: 0.25rem 0.5rem;
    border-radius: var(--radius-pill);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.125px;
}

.site-card-actions {
    display: flex;
    gap: 0.75rem;
}

/* ===== ボタン ===== */
.btn {
    display: inline-block;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    font-size: 0.94rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition);
    border: 1px solid transparent;
    text-align: center;
}

.btn-primary {
    background: var(--accent);
    color: var(--white);
    border-color: var(--accent);
}

.btn-primary:hover {
    background: var(--accent-hover);
    border-color: var(--accent-hover);
    color: var(--white);
}

.btn-outline {
    background: transparent;
    color: var(--text);
    border-color: var(--border);
}

.btn-outline:hover {
    background: rgba(0, 0, 0, 0.05);
    color: var(--text);
    border-color: var(--border);
    transform: scale(1.02);
}

.btn:active {
    transform: scale(0.95);
}

.btn-sm {
    padding: 0.3rem 0.8rem;
    font-size: 0.85rem;
}

.btn-block {
    display: block;
    width: 100%;
}

/* ===== サイト詳細 ===== */
.site-detail-header {
    text-align: center;
    padding: 2rem 0;
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--border);
}

.site-detail-header h1 {
    font-size: 2rem;
    color: var(--text);
    margin-bottom: 0.5rem;
}

.site-detail-url a {
    font-size: 1rem;
    color: var(--accent);
}

.site-detail-body {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 2rem;
    margin-bottom: 2rem;
}

.site-detail-main h2 {
    font-size: 1.25rem;
    color: var(--text);
    margin: 1.5rem 0 0.75rem;
}

.site-detail-main h2:first-child {
    margin-top: 0;
}

.feature-list {
    list-style: none;
    padding: 0;
}

.feature-list li {
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
}

.feature-list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: #2a9d99;
    font-weight: 700;
}



.site-info-card {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 1.5rem;
    border: 1px solid var(--border);
}

.site-info-card h3 {
    font-size: 1.1rem;
    color: var(--text);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border);
}

.site-info-card dl {
    display: grid;
    gap: 0.75rem;
}

.site-info-card dt {
    font-weight: 600;
    font-size: 0.85rem;
    color: var(--text-light);
}

.site-info-card dd {
    margin-bottom: 0.5rem;
}

.site-detail-footer {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
}

/* ===== プロフィール ===== */
.profile-section h1 {
    font-size: 2rem;
    color: var(--text);
    margin-bottom: 1.5rem;
}

.profile-main h2 {
    font-size: 1.25rem;
    color: var(--text);
    margin: 1.5rem 0 0.75rem;
}

.profile-main h2:first-child {
    margin-top: 0;
}

.profile-main p {
    margin-bottom: 1rem;
    line-height: 1.8;
}

.profile-sites {
    list-style: none;
    padding: 0;
}

.profile-sites li {
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border);
}

.profile-sites li:last-child {
    border-bottom: none;
}

/* ===== ブログ ===== */
.blog-section h1 {
    font-size: 2rem;
    color: var(--text);
    margin-bottom: 1.5rem;
}

.blog-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.blog-card {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 1.5rem;
    border: 1px solid var(--border);
}

.blog-card-title {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.blog-card-title a {
    color: var(--text);
}

.blog-card-date {
    display: block;
    font-size: 0.85rem;
    color: var(--text-light);
    margin-bottom: 0.75rem;
}

.blog-card-excerpt {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.empty-message {
    text-align: center;
    color: var(--text-light);
    padding: 3rem 0;
    font-size: 1.1rem;
}

/* ===== ブログ記事 ===== */
.blog-post-header {
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}

.blog-post-header h1 {
    font-size: 2rem;
    color: var(--text);
    margin-bottom: 0.5rem;
}

.blog-post-date {
    font-size: 0.9rem;
    color: var(--text-light);
}

.blog-post-content {
    line-height: 1.9;
    font-size: 1rem;
}

.blog-post-content h2 {
    font-size: 1.4rem;
    margin: 2rem 0 1rem;
    color: var(--text);
}

.blog-post-content h3 {
    font-size: 1.15rem;
    margin: 1.5rem 0 0.75rem;
    color: var(--text);
}

.blog-post-content p {
    margin-bottom: 1rem;
}

.blog-post-content ul, .blog-post-content ol {
    margin: 1rem 0;
    padding-left: 2rem;
}

.blog-post-footer {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
}

/* ===== ページネーション ===== */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin-top: 2rem;
}

.pagination-info {
    color: var(--text-light);
    font-size: 0.9rem;
}

/* ===== お問い合わせ ===== */
.contact-section h1 {
    font-size: 2rem;
    color: var(--text);
    margin-bottom: 0.5rem;
}

.contact-section > p {
    color: var(--text-light);
    margin-bottom: 2rem;
}

.contact-form {
    max-width: 600px;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.4rem;
    font-size: 0.95rem;
}

.required {
    color: #dd5b00;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.7rem 1rem;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-family: inherit;
    transition: border-color var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 2px rgba(0, 117, 222, 0.2);
}

.form-group-checkbox label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 400;
    cursor: pointer;
}

.form-group-checkbox input[type="checkbox"] {
    width: auto;
    margin: 0;
}

/* ===== アラート ===== */
.alert {
    padding: 1rem 1.5rem;
    border-radius: var(--radius);
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
}

.alert-success {
    background: #dbeddb;
    color: #2a6b3d;
    border: 1px solid #c3dbc3;
}

.alert-error {
    background: #ffe2dd;
    color: #93342a;
    border: 1px solid #f5c6c0;
}

/* ===== 404エラーページ ===== */
.error-section {
    text-align: center;
    padding: 5rem 0;
}

.error-section h1 {
    font-size: 2.5rem;
    color: var(--text);
    margin-bottom: 1rem;
    font-weight: 700;
}

.error-section p {
    color: var(--text-light);
    font-size: 1.1rem;
    margin-bottom: 2rem;
}

.error-actions {
    display: flex;
    justify-content: center;
    gap: 1rem;
}

/* ===== フッター ===== */
.site-footer {
    background: var(--primary);
    color: rgba(255, 255, 255, 0.7);
    padding: 2rem 0;
    margin-top: auto;
}


.footer-content {
    text-align: center;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 1rem;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
}

.footer-links a:hover {
    color: var(--white);
}

.footer-copyright {
    font-size: 0.85rem;
}

/* ===== ポリシー・規約ページ ===== */
.privacy-section h1,
.terms-section h1 {
    font-size: 2rem;
    color: var(--text);
    margin-bottom: 0.5rem;
}

.policy-updated {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 2rem;
}

.policy-content h2 {
    font-size: 1.25rem;
    color: var(--text);
    margin: 2rem 0 0.75rem;
    padding-bottom: 0.4rem;
    border-bottom: 1px solid var(--border);
}

.policy-content p {
    margin-bottom: 1rem;
    line-height: 1.8;
}

.policy-content ul {
    margin: 0.5rem 0 1rem;
    padding-left: 1.5rem;
}

.policy-content li {
    margin-bottom: 0.4rem;
    line-height: 1.7;
}

.footer-legal {
    margin-top: 0.5rem;
    font-size: 0.85rem;
}

.footer-sites-menu {
    margin: 1.5rem 0;
    padding-top: 1.25rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: left;
}

.footer-sites-title {
    font-size: 0.8rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.65);
    letter-spacing: 0.08em;
    margin-bottom: 0.75rem;
}

.footer-sites-list {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem 2rem;
}

.footer-sites-list a {
    display: flex;
    flex-direction: column;
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius-sm);
    text-decoration: none;
    transition: background 0.2s ease;
}

.footer-sites-list a:hover {
    background: rgba(255, 255, 255, 0.08);
}

.footer-sites-list a:hover .footer-site-name {
    color: #fff;
}

.footer-site-name {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.9rem;
    font-weight: 500;
}

.footer-site-desc {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.78rem;
    line-height: 1.4;
    margin-top: 0.15rem;
}

/* ===== レスポンシブ ===== */
@media (max-width: 1024px) {
    .site-detail-body {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .nav-toggle {
        display: block;
    }

    .nav-list {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--white);
        padding: 1rem 1.5rem;
        gap: 1rem;
        border-bottom: 1px solid var(--border);
    }

    .nav-list.open {
        display: flex;
    }

    .hero h1 {
        font-size: 2.5rem;
        letter-spacing: -0.625px;
    }

    .sites-grid {
        grid-template-columns: 1fr;
    }

    .site-detail-body {
        grid-template-columns: 1fr;
    }

    .footer-links {
        flex-direction: column;
        gap: 0.75rem;
    }

    .footer-sites-list {
        grid-template-columns: 1fr;
    }

    .site-card-actions {
        flex-direction: column;
    }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
    }
    .site-card:hover,
    .btn:active,
    .btn-outline:hover {
        transform: none;
    }
}
