/* ============================================
   BLOG DETAIL PAGE - CONSOLIDATED STYLES
   ============================================ */

/* ============================================
   1. BLOG DETAIL CONTENT
   ============================================ */

/* Blog Detail Container */
.blog-detail-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 40px 20px;
}

.blog-detail-inner {
    width: 100%;
}

/* Header - Title */
.blog-detail-header {
    margin-bottom: 20px;
}

.blog-detail-title {
    font-size: 52px;
    font-weight: 600;
    color: #00214e;
    line-height: 1.3;
    margin: 0;
    text-align: left;
}

/* Meta Info */
.blog-detail-meta {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    align-items: center;
    gap: 20px;
    margin-bottom: 30px;
    padding-bottom: 20px;
}

.blog-meta-item {
    font-size: 0.9rem;
    color: #666;
}

.blog-categories a {
    color: #00214e;
    text-decoration: none;
    font-weight: 500;
}

.blog-categories a:hover {
    text-decoration: underline;
}

.blog-categories .separator {
    color: #999;
    margin: 0 2px;
}

.blog-date,
.blog-author {
    color: #666;
}

/* Featured Image */
.blog-detail-image {
    margin-bottom: 40px;
    width: 100%;
}

.blog-detail-image figure {
    margin: 0;
    width: 100%;
}

.blog-detail-image img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

/* Blog Content (Dynamic Content dari Admin) */
.blog-detail-content {
    font-size: 1.05rem;
    line-height: 1.8;
    color: #333;
}

.blog-detail-content p {
    margin-bottom: 1.5em;
    text-align: justify;
}

.blog-detail-content h2,
.blog-detail-content h3,
.blog-detail-content h4 {
    color: #1a1a1a;
    margin-top: 2em;
    margin-bottom: 0.8em;
    font-weight: 600;
}

.blog-detail-content h2 {
    font-size: 1.8rem;
    border-bottom: 2px solid #e0e0e0;
    padding-bottom: 0.5em;
}

.blog-detail-content h3 {
    font-size: 1.5rem;
}

.blog-detail-content h4 {
    font-size: 1.25rem;
}

.blog-detail-content ul,
.blog-detail-content ol {
    margin-bottom: 1.5em;
    padding-left: 2em;
}

.blog-detail-content li {
    margin-bottom: 0.5em;
}

.blog-detail-content a {
    color: #00214e;
    text-decoration: underline;
}

.blog-detail-content a:hover {
    color: #003d82;
}

.blog-detail-content img {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 2em auto;
    border-radius: 4px;
}

.blog-detail-content blockquote {
    border-left: 4px solid #00214e;
    padding-left: 1.5em;
    margin: 2em 0;
    font-style: italic;
    color: #555;
}

.blog-detail-content code {
    background: #f5f5f5;
    padding: 2px 6px;
    border-radius: 3px;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
}

.blog-detail-content pre {
    background: #f5f5f5;
    padding: 1.5em;
    border-radius: 4px;
    overflow-x: auto;
    margin-bottom: 1.5em;
}

.blog-detail-content pre code {
    background: none;
    padding: 0;
}

.blog-detail-content table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1.5em;
}

.blog-detail-content table th,
.blog-detail-content table td {
    border: 1px solid #ddd;
    padding: 12px;
    text-align: left;
}

.blog-detail-content table th {
    background: #f5f5f5;
    font-weight: 600;
}

/* ============================================
   2. COMMENTS LIST SECTION
   ============================================ */

.comments-list-section {
    margin: 3rem 0;
    padding: 2rem 0;
    border-top: 2px solid #e5e7eb;
}

.comments-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 2rem;
}

.comments-wrapper {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* Comment Item */
.comments-wrapper .comment-item {
    display: flex;
    gap: 1rem;
    padding: 1.5rem;
    background: #f9fafb;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
    transition: all 0.3s ease;
}

.comments-wrapper .comment-item:hover {
    background: #ffffff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* Avatar */
.comments-wrapper .comment-avatar {
    flex-shrink: 0;
}

.comments-wrapper .avatar-circle {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.25rem;
}

/* Comment Content */
.comment-content-wrapper {
    flex: 1;
    min-width: 0;
}

.comments-wrapper .comment-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
    gap: 1rem;
}

.comments-wrapper .comment-author {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.comments-wrapper .comment-author strong {
    color: #1f2937;
    font-size: 1rem;
    font-weight: 600;
}

.comment-website-link {
    color: #3b82f6;
    display: inline-flex;
    align-items: center;
    transition: color 0.3s ease;
}

.comment-website-link:hover {
    color: #2563eb;
}

.comments-wrapper .comment-date {
    color: #6b7280;
    font-size: 0.875rem;
    white-space: nowrap;
}

.comments-wrapper .comment-body {
    color: #374151;
    line-height: 1.7;
    font-size: 0.9375rem;
    word-wrap: break-word;
}

/* ============================================
   3. COMMENT FORM SECTION
   ============================================ */

.comments-area {
    margin: 3rem 0;
    padding: 2rem 0;
    border-top: 2px solid #e5e7eb;
}

.comment-respond {
    max-width: 100%;
}

.comment-reply-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 1rem;
}

.comment-notes {
    font-size: 0.875rem;
    color: #6b7280;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.comment-notes .required {
    color: #ef4444;
    font-weight: 600;
}

/* Alerts */
.alert {
    display: flex;
    gap: 0.75rem;
    padding: 1rem 1.25rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
    font-size: 0.9375rem;
    align-items: flex-start;
}

.alert svg {
    flex-shrink: 0;
    margin-top: 0.125rem;
}

.alert-danger {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #991b1b;
}

.alert-danger svg {
    stroke: #dc2626;
}

.alert-danger ul {
    margin: 0.5rem 0 0 0;
    padding-left: 1.25rem;
}

.alert-danger li {
    margin-bottom: 0.25rem;
}

.alert-success {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #166534;
}

.alert-success svg {
    stroke: #22c55e;
}

/* Form Fields */
.comment-form {
    max-width: 100%;
}

.comment-form-comment {
    border: none;
    padding: 0;
    margin: 0 0 1.5rem 0;
}

.comment-form-textarea {
    width: 100%;
}

.form-label {
    display: block;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.5rem;
    font-size: 0.9375rem;
}

.comment-form textarea,
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"] {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 1px solid #e5e7eb;
    font-size: 1rem;
    font-family: inherit;
    transition: all 0.3s ease;
    background: #ffffff;
}

.comment-form textarea:focus,
.comment-form input[type="text"]:focus,
.comment-form input[type="email"]:focus,
.comment-form input[type="url"]:focus {
    outline: none;
    border-color: #ff6b35;
    box-shadow: 0 0 0 4px rgba(255, 107, 53, 0.1);
}

.comment-form textarea::placeholder,
.comment-form input::placeholder {
    color: #9ca3af;
}

.comment-form textarea {
    resize: vertical;
    min-height: 120px;
}

/* Form Grid */
.ast-comment-formwrap {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.comment-form-author,
.comment-form-email,
.comment-form-url {
    margin: 0;
}

/* Cookies Consent */
.comment-form-cookies-consent {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
    font-size: 0.9375rem;
    color: #4b5563;
    line-height: 1.6;
}

.comment-form-cookies-consent input[type="checkbox"] {
    width: 1.125rem;
    height: 1.125rem;
    margin-top: 0.125rem;
    cursor: pointer;
    flex-shrink: 0;
    accent-color: #ff6b35;
}

.comment-form-cookies-consent label {
    cursor: pointer;
    user-select: none;
}

/* Submit Button */
.form-submit {
    margin: 0;
}

.submit-button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, #ff6b35 0%, #f7931e 100%);
    color: white;
    border: none;
    padding: 0.875rem 2rem;
    border-radius: 0;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.submit-button:hover {
    background: #00214e;
    color: white;
}

.submit-button:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(255, 107, 53, 0.3);
}

.submit-button svg {
    width: 18px;
    height: 18px;
}

/* Hidden Elements */
.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-width: 0;
}

/* ============================================
   4. POST NAVIGATION
   ============================================ */

.navigation.post-navigation {
    margin: 3rem 0;
    padding: 2rem 0;
    border-top: 1px solid #e5e7eb;
    border-bottom: 1px solid #e5e7eb;
}

.post-navigation .nav-links {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
}

.post-navigation .nav-previous,
.post-navigation .nav-next {
    flex: 1;
    max-width: 50%;
}

.post-navigation .nav-previous {
    text-align: left;
}

.post-navigation .nav-next {
    text-align: right;
}

.post-navigation a {
    display: inline-block;
    color: #1f2937;
    text-decoration: none;
    font-size: 1rem;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
}

.post-navigation a:hover {
    color: #ff6b35;
}

.post-navigation .ast-left-arrow,
.post-navigation .ast-right-arrow {
    display: inline-block;
    font-size: 1.2rem;
    transition: transform 0.3s ease;
}

.post-navigation .nav-previous a:hover .ast-left-arrow {
    transform: translateX(-5px);
}

.post-navigation .nav-next a:hover .ast-right-arrow {
    transform: translateX(5px);
}

/* ============================================
   5. RELATED POSTS CARDS
   ============================================ */

.container {
    max-width: 1400px;
    margin: 0 auto;
}

h1 {
    text-align: center;
    font-size: 2.5rem;
    color: #1a1a1a;
    margin-bottom: 50px;
    font-weight: 500;
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.card {
    background: white;
    overflow: hidden;
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
}

.card:hover {
    transform: translateY(-5px);
}

.card-image {
    width: 100%;
    height: 240px;
    object-fit: cover;
}

.card-content {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.card-title {
    font-size: 1.35rem;
    color: #00214e;
    margin-bottom: 15px;
    line-height: 1.4;
    font-weight: 600;
    text-decoration: none;
    display: block;
}

.card-title:hover {
    color: #0056b3;
    text-decoration: none;
}

.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    font-size: 0.9rem;
    color: #00214e;
    margin-bottom: 15px;
    align-items: center;
}

.card-meta a {
    color: #022e6b;
    text-decoration: none;
}

.card-meta a:hover {
    text-decoration: none;
}

.card-meta-divider {
    color: #666;
}

.card-date {
    color: #666;
}

.card-excerpt {
    color: #333;
    line-height: 1.6;
    font-size: 0.95rem;
    margin-top: auto;
}

/* ============================================
   6. RESPONSIVE DESIGN
   ============================================ */

@media (max-width: 768px) {
    /* Blog Detail */
    .blog-detail-container {
        padding: 30px 15px;
    }

    .blog-detail-title {
        font-size: 2rem;
    }

    .blog-detail-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .blog-detail-content {
        font-size: 1rem;
    }

    .blog-detail-content h2 {
        font-size: 1.5rem;
    }

    .blog-detail-content h3 {
        font-size: 1.3rem;
    }

    .blog-detail-content h4 {
        font-size: 1.1rem;
    }

    /* Comments List */
    .comments-list-section,
    .comments-area {
        margin: 2rem 0;
        padding: 1.5rem 0;
    }

    .comments-title,
    .comment-reply-title {
        font-size: 1.5rem;
    }

    .comments-wrapper .comment-item {
        padding: 1.25rem;
    }

    .comments-wrapper .avatar-circle {
        width: 40px;
        height: 40px;
        font-size: 1.125rem;
    }

    .comments-wrapper .comment-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    /* Comment Form */
    .ast-comment-formwrap {
        grid-template-columns: 1fr;
    }

    .submit-button {
        width: 100%;
        justify-content: center;
    }

    /* Post Navigation */
    .post-navigation .nav-links {
        flex-direction: column;
        gap: 1.5rem;
    }

    .post-navigation .nav-previous,
    .post-navigation .nav-next {
        max-width: 100%;
        text-align: center;
    }

    /* Related Posts */
    h1 {
        font-size: 2rem;
        margin-bottom: 30px;
    }

    .cards-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .card-image {
        height: 200px;
    }

    .card-content {
        padding: 20px;
    }

    .card-title {
        font-size: 1.2rem;
    }
}

@media (max-width: 640px) {
    .comments-wrapper .comment-item {
        flex-direction: column;
    }

    .comment-form textarea,
    .comment-form input {
        font-size: 16px; /* Prevent zoom on iOS */
    }
}