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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Helvetica Neue', Arial, 'Hiragino Sans', 'Hiragino Kaku Gothic ProN', Meiryo, sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #e8ebe8 100%);
    color: #3a3a3a;
    line-height: 1.8;
    min-height: 100vh;
    padding: 20px;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 20px;
}

header {
    text-align: center;
    margin-bottom: 60px;
    position: relative;
}

h1 {
    font-size: 2.5em;
    font-weight: 400;
    color: #4a5568;
    letter-spacing: 0.1em;
    margin-bottom: 8px;
}

.subtitle {
    font-size: 0.9em;
    color: #a0aec0;
    font-weight: 300;
    margin-bottom: 10px;
}

.admin-btn {
    position: absolute;
    top: 0;
    right: 0;
    background: transparent;
    border: 1px solid #cbd5e0;
    color: #718096;
    padding: 8px 20px;
    cursor: pointer;
    font-size: 0.9em;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.admin-btn:hover {
    background: #f7fafc;
    border-color: #a0aec0;
}

/* 投稿カード */
.post {
    background: white;
    padding: 40px;
    margin-bottom: 30px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    transition: box-shadow 0.3s ease;
}

.post:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.post-date {
    font-size: 0.85em;
    color: #a0aec0;
    margin-bottom: 15px;
    font-family: 'Helvetica Neue', sans-serif;
}

.post-title {
    font-size: 1.8em;
    color: #2d3748;
    margin-bottom: 20px;
    font-weight: 400;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 15px;
}

.post-body {
    color: #4a5568;
    white-space: pre-wrap;
    word-wrap: break-word;
}

/* モーダル */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background-color: white;
    margin: 5% auto;
    padding: 40px;
    border-radius: 4px;
    width: 90%;
    max-width: 600px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.close {
    color: #a0aec0;
    float: right;
    font-size: 28px;
    font-weight: 300;
    cursor: pointer;
    line-height: 20px;
}

.close:hover {
    color: #4a5568;
}

.modal-content h2 {
    color: #2d3748;
    margin-bottom: 30px;
    font-weight: 400;
    font-size: 1.5em;
}

.auth-input,
#postTitle,
#postBody {
    width: 100%;
    padding: 12px;
    margin-bottom: 20px;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    font-family: inherit;
    font-size: 1em;
    transition: border-color 0.3s ease;
}

.auth-input:focus,
#postTitle:focus,
#postBody:focus {
    outline: none;
    border-color: #a0aec0;
}

#postBody {
    resize: vertical;
    min-height: 200px;
    line-height: 1.8;
}

#submitPost {
    width: 100%;
    padding: 14px;
    background: #4a5568;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1em;
    transition: background 0.3s ease;
}

#submitPost:hover {
    background: #2d3748;
}

/* 管理画面用スタイル */
.admin-form {
    background: white;
    padding: 40px;
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    margin-bottom: 40px;
}

.admin-posts {
    margin-top: 40px;
}

.delete-btn:hover {
    background: #c53030 !important;
}

/* レスポンシブ */
@media (max-width: 768px) {
    h1 {
        font-size: 2em;
    }

    .post {
        padding: 25px;
    }

    .post-title {
        font-size: 1.5em;
    }

    .modal-content {
        margin: 10% auto;
        padding: 25px;
        width: 95%;
    }

    .admin-btn {
        position: static;
        margin-top: 20px;
    }
}
