/**
 * Activity Log Pro - Help System Styles
 */

/* Help dropdown styling */
.alp-help-dropdown {
    cursor: pointer;
}

/* Help dropdown items */
#wpadminbar .alp-help-item {
    cursor: pointer;
}

/* Help divider */
.alp-help-divider {
    height: 1px;
    background-color: rgba(240, 245, 250, 0.2);
    margin: 8px 0;
}

.alp-help-divider-item {
    padding: 0 !important;
    height: 1px !important;
}

/* System Info Header */
.alp-system-info-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.alp-system-info-header h2 {
    margin: 0;
}

.alp-system-info-header #alp-copy-system-info {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    font-size: 13px;
    line-height: 1.4;
    border-radius: 4px;
    border: 1px solid #2271b1;
    background: #2271b1;
    color: #ffffff;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 500;
}

.alp-system-info-header #alp-copy-system-info:hover {
    background: #135e96;
    border-color: #135e96;
    color: #ffffff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.alp-system-info-header #alp-copy-system-info:focus {
    box-shadow: 0 0 0 1px #2271b1;
    outline: none;
}

.alp-system-info-header #alp-copy-system-info.copied {
    background: #46b450;
    border-color: #46b450;
    color: #ffffff;
}

.alp-system-info-header #alp-copy-system-info svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

@media (max-width: 768px) {
    .alp-system-info-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .alp-system-info-header #alp-copy-system-info {
        align-self: flex-start;
    }
}

/* Help dialog */
.alp-help-dialog {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    max-width: 90%;
    max-height: 80vh;
    background-color: #fff;
    border-radius: 4px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    z-index: 999999;
    overflow: hidden;
}

.alp-help-dialog-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background-color: #1e88e5;
    color: #fff;
}

.alp-help-dialog-title {
    font-size: 18px;
    font-weight: 600;
    margin: 0;
}

.alp-help-dialog-close {
    cursor: pointer;
    color: #fff;
    font-size: 20px;
    line-height: 1;
}

.alp-help-dialog-content {
    padding: 20px;
    overflow-y: auto;
    max-height: calc(80vh - 60px);
}

.alp-help-dialog-content h3 {
    margin-top: 0;
    color: #1e88e5;
    font-size: 16px;
    font-weight: 600;
}

.alp-help-dialog-content p {
    margin-bottom: 15px;
    line-height: 1.5;
}

.alp-help-dialog-content ul {
    margin-left: 20px;
    margin-bottom: 15px;
}

.alp-help-dialog-content li {
    margin-bottom: 8px;
    line-height: 1.5;
}

.alp-help-dialog-content code {
    background-color: #f5f5f5;
    padding: 2px 5px;
    border-radius: 3px;
    font-size: 13px;
}

.alp-help-dialog-content img {
    max-width: 100%;
    height: auto;
    margin: 10px 0;
    border: 1px solid #ddd;
    border-radius: 4px;
}

/* Help overlay */
.alp-help-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 999998;
}

/* External link icon */
.alp-help-external-link:after {
    content: '\f504';
    font: normal 16px/1 dashicons;
    display: inline-block;
    vertical-align: middle;
    margin-left: 5px;
}

/* ================================
   Settings Tabs Styles
   ================================ */

/* Licence Tab Styles */
.alp-licence-info-container {
    margin-top: 20px;
}

.alp-licence-status {
    display: flex;
    align-items: center;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 30px;
    border: 2px solid #e5e7eb;
}

.alp-licence-status.alp-licence-free {
    background-color: #f0f9ff;
    border-color: #3b82f6;
}

.alp-licence-status.alp-licence-premium {
    background-color: #ecfdf5;
    border-color: #10b981;
}

.alp-licence-icon {
    margin-right: 15px;
    flex-shrink: 0;
}

.alp-licence-details h3 {
    margin: 0 0 5px 0;
    font-size: 18px;
    font-weight: 600;
}

.alp-licence-type {
    font-weight: 600;
    margin: 0 0 10px 0;
    color: #4b5563;
}

.alp-feature-list {
    margin: 0;
    padding-left: 20px;
}

.alp-feature-list li {
    margin-bottom: 5px;
    position: relative;
}

.alp-feature-list li:before {
    content: "✓";
    color: #10b981;
    font-weight: bold;
    position: absolute;
    left: -20px;
}

.alp-upgrade-cta {
    background-color: #f8fafc;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    text-align: center;
    margin-top: 20px;
}

.alp-upgrade-cta h3 {
    margin: 0 0 10px 0;
    color: #1e40af;
}

.alp-upgrade-cta p {
    margin: 0 0 15px 0;
    color: #64748b;
}

/* Help Tab Styles */
.alp-help-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.alp-help-card {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    transition: box-shadow 0.2s ease;
}

.alp-help-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.alp-help-card-icon {
    margin-bottom: 15px;
}

.alp-help-card h3 {
    margin: 0 0 10px 0;
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
}

.alp-help-card p {
    margin: 0 0 15px 0;
    color: #6b7280;
    font-size: 14px;
    line-height: 1.5;
}

/* FAQ Styles */
.alp-faq-container {
    margin-top: 20px;
}

.alp-faq-item {
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    margin-bottom: 10px;
    overflow: hidden;
}

.alp-faq-item summary {
    padding: 15px 20px;
    background-color: #f8fafc;
    cursor: pointer;
    font-weight: 600;
    color: #374151;
    user-select: none;
    list-style: none;
    outline: none;
}

.alp-faq-item summary::-webkit-details-marker {
    display: none;
}

.alp-faq-item summary:before {
    content: "+";
    float: right;
    font-weight: bold;
    color: #6b7280;
    font-size: 18px;
    line-height: 1;
}

.alp-faq-item[open] summary:before {
    content: "−";
}

.alp-faq-item summary:hover {
    background-color: #f1f5f9;
}

.alp-faq-content {
    padding: 20px;
    background-color: #fff;
    border-top: 1px solid #e2e8f0;
}

.alp-faq-content p {
    margin: 0 0 15px 0;
    line-height: 1.6;
    color: #4b5563;
}

.alp-faq-content p:last-child {
    margin-bottom: 0;
}

.alp-faq-content ul {
    margin: 0 0 15px 20px;
    color: #4b5563;
}

.alp-faq-content li {
    margin-bottom: 5px;
    line-height: 1.5;
}

/* System Information Styles */
.alp-system-diagnostics-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 40px;
}

.alp-diagnostic-section {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 15px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.alp-diagnostic-section h3 {
    margin-top: 0 !important;
    margin-bottom: 15px;
    font-size: 14px;
    font-weight: 600;
    color: #1f2937;
    border-bottom: 1px solid #e5e7eb;
    padding-bottom: 8px;
    text-align: center;
}

.alp-diagnostic-section .form-table {
    margin-bottom: 0;
}

.alp-diagnostic-section .form-table th {
    width: 50%;
    padding: 8px 0;
    font-size: 12px;
    font-weight: 600;
    color: #6b7280;
}

.alp-diagnostic-section .form-table td {
    padding: 8px 0;
    font-size: 12px;
    color: #1f2937;
    word-wrap: break-word;
}

/* Responsive grid layout */
@media (max-width: 1200px) {
    .alp-system-diagnostics-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .alp-diagnostic-section .form-table th,
    .alp-diagnostic-section .form-table td {
        font-size: 13px;
        padding: 10px 0;
    }
}

@media (min-width: 1201px) and (max-width: 1400px) {
    .alp-system-diagnostics-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.alp-plugins-list,
.alp-dropins-list,
.alp-themes-list {
    margin-top: 15px;
    margin-bottom: 30px;
}

.alp-plugins-list table,
.alp-dropins-list table,
.alp-themes-list table {
    margin-top: 10px;
}

.alp-plugins-list th,
.alp-dropins-list th,
.alp-themes-list th {
    font-weight: 600;
    color: #1f2937;
    background-color: #f9fafb;
}

.plugin-status,
.theme-status {
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.plugin-status.active,
.theme-status.active {
    background-color: #dcfce7;
    color: #166534;
}

.plugin-status.inactive,
.theme-status.inactive {
    background-color: #f3f4f6;
    color: #6b7280;
}

/* System Information section spacing */
.alp-settings-section h3 {
    margin-top: 30px;
    margin-bottom: 15px;
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
    border-bottom: 1px solid #e5e7eb;
    padding-bottom: 8px;
}

.alp-settings-section h3:first-child {
    margin-top: 20px;
}

/* Responsive tables for system info */
@media (max-width: 768px) {
    .alp-plugins-list table,
    .alp-dropins-list table,
    .alp-themes-list table {
        font-size: 14px;
    }
    
    .alp-plugins-list th,
    .alp-plugins-list td,
    .alp-dropins-list th,
    .alp-dropins-list td,
    .alp-themes-list th,
    .alp-themes-list td {
        padding: 8px 4px;
    }
}

/* Help Page Bottom Actions */
.alp-help-bottom-actions {
    text-align: center;
    margin-top: 40px;
    padding-top: 30px;
    border-top: 2px solid #e5e7eb;
}

.alp-help-bottom-actions #alp-copy-system-info-bottom {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    font-size: 14px;
    line-height: 1.4;
    border-radius: 6px;
    border: 1px solid #2271b1;
    background: #2271b1;
    color: #ffffff;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 600;
    box-shadow: 0 2px 4px rgba(34, 113, 177, 0.2);
}

.alp-help-bottom-actions #alp-copy-system-info-bottom:hover {
    background: #135e96;
    border-color: #135e96;
    color: #ffffff;
    box-shadow: 0 4px 8px rgba(34, 113, 177, 0.3);
    transform: translateY(-1px);
}

.alp-help-bottom-actions #alp-copy-system-info-bottom:focus {
    box-shadow: 0 0 0 2px rgba(34, 113, 177, 0.5);
    outline: none;
}

.alp-help-bottom-actions #alp-copy-system-info-bottom.copied {
    background: #46b450;
    border-color: #46b450;
    color: #ffffff;
    transform: scale(1.02);
}

.alp-help-bottom-actions #alp-copy-system-info-bottom svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

.alp-help-bottom-actions .description {
    margin-top: 12px;
    margin-bottom: 0;
    color: #6b7280;
    font-size: 13px;
    line-height: 1.5;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

@media (max-width: 768px) {
    .alp-help-bottom-actions {
        margin-top: 30px;
        padding-top: 20px;
    }
    
    .alp-help-bottom-actions #alp-copy-system-info-bottom {
        padding: 10px 20px;
        font-size: 13px;
    }
    
    .alp-help-bottom-actions .description {
        margin-top: 10px;
        padding: 0 15px;
    }
}