/* Poly Journals - Frontend Styles */

.pj-submission-form,
.pj-author-dashboard {
    max-width: 800px;
    margin: 0 auto;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Guidelines */
.pj-guidelines {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 24px;
}
.pj-guidelines h3 {
    margin-top: 0;
    color: #1e40af;
}

/* Notices */
.pj-notice {
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 20px;
}
.pj-notice-success {
    background: #d1fae5;
    border: 1px solid #6ee7b7;
    color: #065f46;
}
.pj-notice-error {
    background: #fee2e2;
    border: 1px solid #fca5a5;
    color: #991b1b;
}
.pj-notice-warning {
    background: #fef3c7;
    border: 1px solid #fcd34d;
    color: #92400e;
}
.pj-notice-info {
    background: #dbeafe;
    border: 1px solid #93c5fd;
    color: #1e40af;
}

/* Form */
.pj-form-group {
    margin-bottom: 20px;
}
.pj-form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 6px;
    color: #1f2937;
    font-size: 14px;
}
.pj-form-group .required {
    color: #dc2626;
}
.pj-form-group input[type="text"],
.pj-form-group input[type="email"],
.pj-form-group input[type="url"],
.pj-form-group textarea,
.pj-form-group select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 14px;
    line-height: 1.5;
    transition: border-color 0.15s;
    box-sizing: border-box;
}
.pj-form-group input:focus,
.pj-form-group textarea:focus,
.pj-form-group select:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}
.pj-form-group input[type="file"] {
    padding: 8px 0;
}
.pj-help-text {
    display: block;
    margin-top: 4px;
    font-size: 12px;
    color: #6b7280;
}

/* Form layout */
.pj-form-row {
    display: flex;
    gap: 16px;
    align-items: flex-start;
}
.pj-form-half {
    flex: 1;
}
.pj-form-third {
    flex: 1;
}

/* Co-authors */
.pj-co-author-row {
    margin-bottom: 8px;
}
.pj-co-author-row .pj-form-row {
    align-items: center;
}
.pj-co-author-row input {
    padding: 8px 10px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 13px;
}
.pj-btn-remove-co-author {
    background: none;
    border: 1px solid #fca5a5;
    color: #dc2626;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    line-height: 1;
    padding: 6px 10px;
    flex-shrink: 0;
}
.pj-btn-remove-co-author:hover {
    background: #fee2e2;
}

/* Checklist */
.pj-checklist .pj-check-item {
    display: block;
    padding: 6px 0;
    font-weight: normal;
    cursor: pointer;
}
.pj-checklist .pj-check-item input {
    margin-right: 8px;
}

/* Buttons */
.pj-btn {
    display: inline-block;
    padding: 10px 20px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    border: 1px solid transparent;
    transition: background-color 0.15s, border-color 0.15s;
}
.pj-btn-primary {
    background: #2563eb;
    color: #fff;
    border-color: #2563eb;
}
.pj-btn-primary:hover {
    background: #1d4ed8;
}
.pj-btn-primary:disabled {
    background: #93c5fd;
    cursor: not-allowed;
}
.pj-btn-outline {
    background: #fff;
    color: #2563eb;
    border-color: #2563eb;
}
.pj-btn-outline:hover {
    background: #eff6ff;
}
.pj-btn-sm {
    padding: 6px 12px;
    font-size: 13px;
}

/* Form actions */
.pj-form-actions {
    padding-top: 10px;
    border-top: 1px solid #e5e7eb;
}

/* Author Dashboard */
.pj-dashboard-table {
    width: 100%;
    border-collapse: collapse;
}
.pj-dashboard-table th,
.pj-dashboard-table td {
    padding: 10px 12px;
    text-align: left;
    border-bottom: 1px solid #e5e7eb;
    font-size: 14px;
}
.pj-dashboard-table th {
    background: #f9fafb;
    font-weight: 600;
    color: #374151;
}
.pj-dashboard-table tr:hover td {
    background: #f9fafb;
}
.pj-dashboard-table a {
    color: #2563eb;
    text-decoration: none;
}
.pj-dashboard-table a:hover {
    text-decoration: underline;
}

/* Status badges (frontend) */
.pj-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}
.pj-badge-info { background: #dbeafe; color: #1e40af; }
.pj-badge-warning { background: #fef3c7; color: #92400e; }
.pj-badge-success { background: #d1fae5; color: #065f46; }
.pj-badge-danger { background: #fee2e2; color: #991b1b; }
.pj-badge-muted { background: #f3f4f6; color: #6b7280; }

/* Empty state */
.pj-empty {
    text-align: center;
    padding: 40px 20px;
    color: #6b7280;
}
.pj-empty p {
    margin: 8px 0;
}

/* Pagination */
.pj-pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 20px;
}

/* Manuscript detail */
.pj-manuscript-detail {
    max-width: 800px;
    margin: 0 auto;
}
.pj-detail-header {
    margin-bottom: 20px;
}
.pj-detail-meta {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    color: #6b7280;
    font-size: 13px;
    margin-top: 8px;
}
.pj-detail-section {
    margin-bottom: 24px;
}
.pj-detail-section h3 {
    font-size: 16px;
    margin-bottom: 8px;
    color: #1f2937;
}

/* Editor dashboard tabs */
.pj-tabs {
    border-bottom: 1px solid #e5e7eb;
    padding-bottom: 8px;
}
.pj-tab {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    color: #4b5563;
    text-decoration: none;
    border: 1px solid #e5e7eb;
    background: #fff;
    transition: all 0.15s;
}
.pj-tab:hover {
    border-color: #93c5fd;
    color: #2563eb;
}
.pj-tab-active {
    background: #2563eb;
    border-color: #2563eb;
    color: #fff;
}
.pj-tab-count {
    font-size: 11px;
    background: rgba(0,0,0,0.1);
    padding: 1px 6px;
    border-radius: 10px;
}
.pj-tab-active .pj-tab-count {
    background: rgba(255,255,255,0.25);
}

/* Action buttons */
.pj-action-buttons {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
}
.pj-btn-success {
    background: #059669;
    color: #fff;
    border-color: #059669;
}
.pj-btn-success:hover {
    background: #047857;
}
.pj-btn-danger {
    background: #fff;
    color: #dc2626;
    border-color: #fca5a5;
}
.pj-btn-danger:hover {
    background: #fee2e2;
}

/* Editor dashboard responsive */
.pj-editor-dashboard {
    max-width: 1000px;
    margin: 0 auto;
}

/* Responsive */
@media (max-width: 640px) {
    .pj-form-row {
        flex-direction: column;
        gap: 0;
    }
    .pj-form-half,
    .pj-form-third {
        width: 100%;
    }
    .pj-co-author-row .pj-form-row {
        flex-direction: column;
    }
}
