        * {
            box-sizing: border-box;
        }

        body {
            margin: 0;
            padding: 0;
            font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
            background-color: #f5f7fa;
            min-height: 100vh;
        }

        .submit-btn {
            background: rgba(255, 255, 255, 0.2);
            color: white;
            padding: 8px 20px;
            border: none;
            border-radius: 6px;
            cursor: pointer;
            font-weight: 500;
            transition: background 0.3s ease;
        }

        .submit-btn:hover {
            background: rgba(255, 255, 255, 0.3);
        }

        /* Main Content - Fixed container sizing */
        .container {
            width: 100%;
            max-width: 900px;
            margin: 40px auto;
            padding: 0 20px;
            min-width: 320px; /* Prevent container from becoming too small */
        }

        .post-card {
            margin-top: 55px;
            background: white;
            border-radius: 12px;
            box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
            overflow: hidden;
            margin-bottom: 30px;
            width: 100%;
        }

        .post-header {
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            color: white;
            padding: 30px;
            text-align: center;
        }

        .post-title {
            font-size: 2.2em;
            font-weight: 700;
            margin-bottom: 15px;
            line-height: 1.2;
        }

        .post-meta {
            display: flex;
            justify-content: center;
            gap: 20px;
            opacity: 0.9;
            font-size: 0.95em;
            flex-wrap: wrap;
        }

        .post-content {
            padding: 40px;
            line-height: 1.8;
            font-size: 1.1em;
            color: #444;
            word-wrap: break-word;
            overflow-wrap: break-word;
        }

        /* Comments Section - Ensure full width */
        .comments-section {
            background: white;
            border-radius: 12px;
            box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
            padding: 30px;
            width: 100%;
        }

        .comments-header {
            margin-bottom: 30px;
            padding-bottom: 20px;
            border-bottom: 2px solid #f0f0f0;
        }

        .comments-title {
            font-size: 1.5em;
            font-weight: 600;
            color: #333;
            margin-bottom: 10px;
        }

        .comments-count {
            color: #667eea;
            font-weight: 500;
        }

        /* Comment Form - Fixed width issues */
        .comment-form {
            margin-bottom: 40px;
            padding: 25px;
            background: linear-gradient(135deg, #f8f9ff 0%, #f0f2ff 100%);
            border-radius: 10px;
            border: 1px solid #e0e8ff;
            width: 100%;
        }

        .form-group {
            margin-bottom: 20px;
            width: 100%;
        }

        .form-group label {
            display: block;
            margin-bottom: 8px;
            font-weight: 600;
            color: #555;
        }

        .form-group input,
        .form-group textarea {
            width: 100%;
            padding: 12px 15px;
            border: 2px solid #e1e5e9;
            border-radius: 8px;
            font-size: 1em;
            transition: border-color 0.3s ease, box-shadow 0.3s ease;
            font-family: inherit;
            box-sizing: border-box;
            min-width: 0; /* Prevent overflow issues */
        }

        .form-group input:focus,
        .form-group textarea:focus {
            outline: none;
            border-color: #667eea;
            box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
        }

        .form-group textarea {
            resize: vertical;
            min-height: 100px;
        }

        .comment-btn {
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            color: white;
            padding: 12px 30px;
            border: none;
            border-radius: 8px;
            font-size: 1em;
            font-weight: 600;
            cursor: pointer;
            transition: transform 0.2s ease, box-shadow 0.2s ease;
        }

        .comment-btn:hover {
            transform: translateY(-2px);
            box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
        }

        /* Comments List */
        .comments-list {
            width: 100%;
        }

        .comment {
            background: #fafbfc;
            border-radius: 10px;
            padding: 25px;
            margin-bottom: 20px;
            border-left: 4px solid #667eea;
            transition: all 0.3s ease;
            position: relative;
            width: 100%;
            box-sizing: border-box;
        }

        .comment:hover {
            transform: translateX(5px);
        }

        .comment.highlighted {
            background: #fff3cd;
            border-left-color: #ffc107;
            transform: scale(1.02);
            box-shadow: 0 4px 20px rgba(255, 193, 7, 0.3);
        }

        .comment-number {
            position: absolute;
            top: 15px;
            right: 15px;
            background: #667eea;
            color: white;
            width: 25px;
            height: 25px;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 0.8em;
            font-weight: bold;
        }

        .comment-author {
            font-weight: 700;
            color: #333;
            margin-bottom: 8px;
            font-size: 1.1em;
            padding-right: 40px;
        }

        .comment-date {
            color: #888;
            font-size: 0.9em;
            margin-bottom: 15px;
            margin-left: -40px;
            margin-top: 8px;
            
        }

        .comment-text {
            color: #555;
            line-height: 1.6;
            margin-bottom: 15px;
            word-wrap: break-word;
            overflow-wrap: break-word;
        }

        .comment-actions {
            display: flex;
            gap: 15px;
            flex-wrap: wrap;
        }

        .reply-btn,
        .like-btn {
            background: none;
            border: none;
            color: #667eea;
            cursor: pointer;
            font-weight: 500;
            padding: 5px 10px;
            border-radius: 5px;
            transition: background 0.2s ease;
        }

        .reply-btn:hover,
        .like-btn:hover {
            background: rgba(102, 126, 234, 0.1);
        }

        /* Replies */
        .replies {
            margin-top: 20px;
            margin-left: 30px;
            border-left: 2px solid #e0e8ff;
            padding-left: 20px;
            width: calc(100% - 50px);
        }

        .reply {
            background: white;
            border-radius: 8px;
            padding: 20px;
            margin-bottom: 15px;
            box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
            position: relative;
            transition: all 0.3s ease;
            width: 100%;
            box-sizing: border-box;
        }

        .reply.highlighted {
            background: #fff3cd;
            transform: scale(1.02);
            box-shadow: 0 4px 15px rgba(255, 193, 7, 0.3);
        }

        .reply-number {
            position: absolute;
            top: 15px;
            right: 15px;
            background: #764ba2;
            color: white;
            width: 25px;
            height: 25px;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 0.8em;
            font-weight: bold;
        }

        .reply-form {
            margin-top: 15px;
            padding: 20px;
            background: white;
            border-radius: 8px;
            border: 1px solid #e0e8ff;
            display: none;
            width: 100%;
            box-sizing: border-box;
        }

        .reply-form.show {
            display: block;
        }

        .reply-to-info {
            background: #e8f0fe;
            color: #1565c0;
            padding: 8px 12px;
            border-radius: 5px;
            font-size: 0.9em;
            margin-bottom: 10px;
            display: none;
        }

        .reply-to-info.show {
            display: block;
        }

        .reply-reference {
            color: #667eea;
            cursor: pointer;
            text-decoration: underline;
            font-weight: 600;
        }

        .reply-reference:hover {
            color: #764ba2;
        }

        /* Responsive Design - Enhanced */
        @media (max-width: 768px) {
            .container {
                margin: 20px auto;
                padding: 0 15px;
            }

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

            .post-content {
                padding: 25px;
            }

            .comments-section {
                padding: 20px;
            }

            .replies {
                margin-left: 15px;
                padding-left: 15px;
                width: calc(100% - 30px);
            }

            .post-meta {
                font-size: 0.85em;
                gap: 10px;
            }

            .comment-actions {
                gap: 10px;
            }
            
            .comment-date {
            margin-left: 0px;
            margin-top: 0px;
                
            }
        }

        @media (max-width: 480px) {
            .container {
                padding: 0 10px;
            }

            .post-header {
                padding: 20px;
            }

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

            .post-content {
                padding: 20px;
                font-size: 1em;
            }

            .comments-section {
                padding: 15px;
            }

            .comment {
                padding: 20px;
            }

            .reply {
                padding: 15px;
            }

            .replies {
                margin-left: 10px;
                padding-left: 10px;
                width: calc(100% - 20px);
            }
        }

        /* Fix for potential server-side rendering issues */
        .submission-form {
            width: 100%;
        }

        /* Ensure no horizontal overflow */
        * {
            max-width: 100%;
        }

        img {
            max-width: 100%;
            height: auto;
        }