/* Modern Color Palette */
:root {
    --primary: #667f6a;
    --primary-dark: #4a5f4c;
    --primary-light: #7a9a7d;
    --secondary: #9CA3AF;
    --secondary-dark: #6b7280;
    --warning: #f59e0b;
    --error: #ef4444;
    --success: #10b981;
    --background: #FAFAF9;
    --text: #1F2937;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* Entries Page */
.entries-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 16px;
    padding: 20px 24px;
    background: #fff;
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
}

.entries-header-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.entries-header h2 {
    margin: 0;
    font-size: 24px;
    font-weight: 700;
    color: var(--gray-900);
}

.entries-header-right {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.entries-type-select {
    padding: 10px 36px 10px 14px;
    border: 2px solid var(--gray-200);
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    color: var(--gray-700);
    background-color: #fff;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236b7280' d='M2.5 4.5L6 8l3.5-3.5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    appearance: none;
    cursor: pointer;
    min-width: 180px;
    transition: all 0.2s ease;
}

.entries-type-select:hover {
    border-color: var(--gray-300);
}

.entries-type-select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(102, 127, 106, 0.1);
}

.entries-actions {
    display: flex;
    gap: 8px;
}

.entries-actions .button {
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border: 2px solid transparent;
}

.entries-actions .button-import {
    background: var(--gray-100);
    color: var(--gray-700);
    border-color: var(--gray-200);
}

.entries-actions .button-import:hover {
    background: var(--gray-200);
    border-color: var(--gray-300);
}

.entries-actions .button-export {
    background: var(--primary);
    color: white;
}

.entries-actions .button-export:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.entries-actions .button-export:disabled {
    background: var(--gray-300);
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.entries-search {
    display: flex;
    gap: 10px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.entries-search input {
    flex: 0.5;
    min-width: 200px;
    padding: 10px 14px;
    border: 2px solid var(--gray-200);
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.2s ease;
}

.entries-search input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(102, 127, 106, 0.1);
}

.entries-info-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: var(--gray-50);
    border-radius: 8px;
    margin-bottom: 16px;
    flex-wrap: wrap;
    gap: 12px;
}

.entries-count {
    font-size: 14px;
    font-weight: 600;
    color: var(--gray-700);
}

.entries-count span {
    color: var(--primary);
}

.entries-latest {
    font-size: 13px;
    color: var(--gray-500);
}

.entries-bulk-actions {
    display: flex;
    gap: 8px;
}

.entries-empty-state {
    text-align: center;
    padding: 60px 20px;
    background: #fff;
    border: 2px dashed var(--gray-300);
    border-radius: 12px;
}

.entries-empty-state h3 {
    margin: 0 0 8px 0;
    font-size: 18px;
    color: var(--gray-700);
}

.entries-empty-state p {
    margin: 0;
    color: var(--gray-500);
}

/* Upgrade Notice */
.upgrade-notice {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    border: 1px solid #f59e0b;
    border-radius: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 12px;
}

.upgrade-notice-content {
    display: flex;
    align-items: center;
    gap: 12px;
}

.upgrade-notice-icon {
    font-size: 24px;
}

.upgrade-notice-text h4 {
    margin: 0 0 4px 0;
    font-size: 15px;
    font-weight: 700;
    color: #92400e;
}

.upgrade-notice-text p {
    margin: 0;
    font-size: 13px;
    color: #b45309;
}

.upgrade-notice .button-pro {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.upgrade-notice .button-pro:hover {
    background: linear-gradient(135deg, #d97706, #b45309);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.limit-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: var(--gray-100);
    border: 1px solid var(--gray-200);
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    color: var(--gray-600);
}

.limit-badge.limit-reached {
    background: #fef3c7;
    border-color: #f59e0b;
    color: #92400e;
}

.limit-badge .count {
    color: var(--primary);
    font-weight: 700;
}

.limit-badge.limit-reached .count {
    color: #d97706;
}

/* Dashboard Layout Fix */
.wrap {
    margin: 20px 20px 0 0;
}

.wrap h1,
.wrap h2 {
    margin: 0 0 20px 0;
    padding: 0;
}

.atlasly-dashboard {
    max-width: none;
    margin: 0;
    padding: 0;
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 32px;
    flex-wrap: wrap;
    gap: 16px;
}

.dashboard-content {
    display: grid;
    gap: 24px;
    grid-template-columns: 1fr;
}

.dashboard-widgets {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
    margin-top: 24px;
}

.dashboard-widget {
    background: #fff;
    border: 2px solid var(--gray-200);
    border-radius: 12px;
    padding: 24px;
    box-shadow: var(--shadow-md);
}

.dashboard-widget h3 {
    margin: 0 0 16px 0;
    color: var(--gray-800);
    font-size: 18px;
    font-weight: 600;
}

.recent-entries-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.recent-entry {
    padding: 12px;
    background: var(--gray-50);
    border-radius: 8px;
    border-left: 3px solid var(--primary);
}

.recent-entry-title {
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 4px;
}

.recent-entry-meta {
    font-size: 12px;
    color: var(--gray-500);
}

.atlasly-card {
    background: #fff;
    padding: 24px;
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--gray-200);
    transition: all 0.2s ease;
}

.atlasly-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-1px);
}

.atlasly-form {
    background: #fff;
    padding: 24px;
    border-radius: 12px;
    border: 1px solid var(--gray-200);
    margin-bottom: 24px;
    box-shadow: var(--shadow-sm);
}

.atlasly-grid {
    display: grid;
    gap: 24px;
}

.atlasly-flex {
    display: flex;
    gap: 16px;
    align-items: center;
}

.atlasly-loading {
    text-align: center;
    padding: 48px;
    color: var(--gray-500);
    font-size: 16px;
}

.atlasly-empty-state {
    text-align: center;
    padding: 48px;
    background: #fff;
    border-radius: 12px;
    border: 1px solid var(--gray-200);
    box-shadow: var(--shadow-sm);
}

.atlasly-stat-card {
    background: #fff;
    padding: 24px;
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--gray-200);
    flex: 1;
    min-width: 200px;
    transition: all 0.2s ease;
}

.atlasly-stat-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.atlasly-content-type-item {
    background: #fff;
    padding: 24px;
    border-radius: 12px;
    border: 1px solid var(--gray-200);
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.2s ease;
    box-shadow: var(--shadow-sm);
}

.atlasly-content-type-item:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-1px);
    border-color: var(--primary-light);
}

.atlasly-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(4px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.atlasly-modal {
    background: #fff;
    padding: 32px;
    border-radius: 16px;
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    overflow: auto;
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--gray-200);
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.atlasly-field-item {
    background: var(--gray-50);
    padding: 16px;
    border-radius: 8px;
    border: 1px solid var(--gray-200);
    margin-bottom: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.2s ease;
}

.atlasly-field-item:hover {
    background: var(--gray-100);
    border-color: var(--primary-light);
}

.atlasly-setup-wizard {
    max-width: 700px;
    margin: 48px auto;
    padding: 0 24px;
}

.atlasly-setup-wizard .button-large {
    padding: 16px 32px;
    height: auto;
    font-size: 16px;
    font-weight: 500;
}

.atlasly-setup-wizard pre {
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    padding: 20px;
    overflow-x: auto;
    font-family: 'Monaco', 'Consolas', 'SF Mono', monospace;
    font-size: 13px;
    line-height: 1.5;
    color: var(--gray-700);
}

.atlasly-setup-wizard ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.atlasly-setup-wizard li {
    padding: 12px 0;
    border-bottom: 1px solid var(--gray-200);
    color: var(--gray-700);
}

.atlasly-setup-wizard li:last-child {
    border-bottom: none;
}

.notice {
    background: #fff;
    border-left: 4px solid var(--secondary);
    box-shadow: var(--shadow-sm);
    border-radius: 0 8px 8px 0;
}

.notice-error {
    border-left-color: var(--error);
    background: #fef2f2;
}

.notice-success {
    border-left-color: var(--success);
    background: #ecfdf5;
}

.notice-warning {
    border-left-color: var(--warning);
    background: #fffbeb;
}

.notice-info {
    border-left-color: var(--primary);
    background: #eff6ff;
}

/* Modern Setup Wizard */
.atlasly-setup-wizard h1 {
    font-size: 32px;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 12px;
    text-align: center;
}

.setup-step {
    margin: 48px 0;
}

.setup-step h2 {
    font-size: 24px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 32px;
    text-align: center;
}

.setup-options {
    display: grid;
    gap: 16px;
    margin: 40px 0;
}

.setup-option {
    background: var(--background);
    border: 1px solid var(--gray-200);
    border-radius: 16px;
    padding: 32px;
    text-align: left;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
}

.setup-option::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    bottom: 0;
    width: 4px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-radius: 12px 0 0 12px;
    opacity: 0;
    transition: all 0.3s ease;
    transform: translateY(-50%);
    height: 90%;
}

.setup-option:hover {
    border-color: var(--primary);
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.setup-option:hover::before {
    opacity: 1;
}

.setup-option.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

.setup-option.disabled:hover {
    border-color: var(--gray-200);
    transform: none;
    box-shadow: none;
}

.setup-option h3 {
    margin: 0 0 12px 0;
    font-size: 18px;
    font-weight: 600;
    color: var(--text);
}

.setup-option p {
    margin: 0;
    color: var(--gray-600);
    font-size: 15px;
    line-height: 1.6;
}

.setup-form {
    background: var(--background);
    border: 1px solid var(--gray-200);
    border-radius: 16px;
    padding: 40px;
    box-shadow: var(--shadow-md);
}

.setup-form label {
    display: block;
    margin-bottom: 12px;
    font-weight: 600;
    color: var(--text);
    font-size: 15px;
}

.setup-form input {
    width: 100%;
    padding: 16px 20px;
    border: 1px solid var(--gray-300);
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.2s ease;
    background: #fff;
    color: var(--text);
}

.setup-form input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(95, 122, 97, 0.1);
}

.setup-buttons {
    display: flex;
    gap: 16px;
    justify-content: flex-end;
    margin-top: 40px;
}

.setup-buttons .button {
    padding: 14px 28px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    transition: all 0.2s ease;
    border: 2px solid transparent;
}

.setup-buttons .button:not(.button-primary) {
    background: var(--gray-100);
    color: var(--gray-700);
    border-color: var(--gray-300);
}

.setup-buttons .button:not(.button-primary):hover {
    background: var(--gray-200);
    transform: translateY(-1px);
}

.setup-buttons .button-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-color: var(--primary);
    color: white;
    box-shadow: var(--shadow-md);
}

.setup-buttons .button-primary:hover {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary));
    transform: translateY(-1px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-dark);
}

.setup-buttons .button-primary:disabled {
    background: var(--gray-400);
    border-color: var(--gray-400);
    transform: none;
    cursor: not-allowed;
    box-shadow: none;
}

/* Dashboard */
.dashboard-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
    margin: 32px 0;
}

.dashboard-stats>div {
    background: var(--background);
    padding: 32px;
    border-radius: 16px;
    border: 1px solid var(--gray-200);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.dashboard-stats>div::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
}

.dashboard-stats>div:nth-child(2)::before {
    background: linear-gradient(135deg, var(--primary), var(--secondary))
}

.dashboard-stats>div:nth-child(3)::before {
    background: linear-gradient(135deg, var(--primary), var(--secondary))
}

.dashboard-stats>div:nth-child(4)::before {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
}

.dashboard-stats>div:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    border-color: var(--primary-light);
}

.dashboard-stats>div>div:first-child {
    font-size: 13px;
    font-weight: 600;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.8px;
    margin-bottom: 12px;
}

.dashboard-stats>div>div:last-child {
    font-size: 36px;
    font-weight: 900;
    color: var(--text);
    margin-top: 8px;
    line-height: 1;
}

/* Notifications */
.notice {
    border-radius: 8px;
    border-left-width: 4px;
    animation: slideIn 0.3s ease;
    box-shadow: var(--shadow-sm);
}

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

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Postbox improvements */
.postbox {
    border-radius: 8px;
    border: 1px solid var(--gray-200);
    transition: all 0.2s ease;
    box-shadow: none;
    background: #fff;
    margin: 0 0 16px 0;
}

.postbox:hover {
    box-shadow: var(--shadow-sm);
    border-color: var(--gray-300);
}

/* Button improvements */
.button {
    transition: all 0.2s ease;
    border-radius: 6px;
    font-weight: 500;
    border: 1px solid transparent;
    height: 36px;
    line-height: 34px;
    padding: 0 16px;
    font-size: 13px;
}

.button:hover {
    transform: none;
}

.button-primary {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
    box-shadow: none;
    font-weight: 600;
}

.button-primary:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    box-shadow: none;
}

.button-secondary {
    background: var(--gray-100);
    border-color: var(--gray-300);
    color: var(--gray-700);
}

.button-secondary:hover {
    background: var(--gray-200);
    border-color: var(--gray-400);
}

.button-small {
    height: 28px;
    line-height: 26px;
    padding: 0 10px;
    font-size: 12px;
}

.button-link-delete {
    color: var(--error);
    border-color: transparent;
    background: transparent;
}

.button-link-delete:hover {
    background: #fef2f2;
    border-color: var(--error);
    color: var(--error);
}

/* Form improvements */
input[type="text"],
input[type="email"],
input[type="url"],
input[type="number"],
input[type="search"],
select,
textarea {
    border: 1px solid var(--gray-300);
    border-radius: 6px;
    padding: 8px 12px;
    transition: all 0.2s ease;
    font-size: 13px;
    height: 46px;
    line-height: 1.4;
}

textarea {
    height: auto;
    min-height: 80px;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="url"]:focus,
input[type="number"]:focus,
input[type="search"]:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(95, 122, 97, 0.1);
}

/* Loading states */
.atlasly-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.atlasly-loading::before {
    content: '';
    width: 20px;
    height: 20px;
    border: 2px solid var(--gray-300);
    border-top: 2px solid var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* Setup Preview Styles */
.setup-preview {
    background: var(--background);
    border: 1px solid var(--gray-200);
    border-radius: 16px;
    padding: 32px;
    box-shadow: var(--shadow-md);
    margin: 24px 0;
}

.setup-preview h3 {
    color: var(--text);
    font-size: 20px;
    font-weight: 600;
    margin: 0 0 16px 0;
}

.setup-preview p {
    color: var(--gray-600);
    margin: 0 0 24px 0;
    line-height: 1.6;
}

.setup-preview h4 {
    color: var(--text);
    font-size: 16px;
    font-weight: 600;
    margin: 24px 0 12px 0;
}

.setup-preview ul {
    list-style: none;
    padding: 0;
    margin: 0 0 24px 0;
}

.setup-preview li {
    padding: 8px 0 8px 24px;
    color: var(--gray-700);
    border-bottom: 1px solid var(--gray-200);
    position: relative;
}

.setup-preview li:before {
    content: '?';
    position: absolute;
    left: 0;
    color: var(--primary);
    font-weight: bold;
}

.setup-preview li:last-child {
    border-bottom: none;
}

.setup-preview pre {
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    padding: 20px;
    overflow-x: auto;
    font-family: 'Monaco', 'Consolas', 'SF Mono', monospace;
    font-size: 13px;
    line-height: 1.5;
    color: var(--text);
    margin: 0;
}

/* Responsive improvements */
@media (max-width: 768px) {
    .atlasly-setup-wizard {
        padding: 0 16px;
        margin: 24px auto;
    }

    .setup-form {
        padding: 24px;
    }

    .dashboard-stats {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .setup-buttons {
        flex-direction: column;
    }

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

/* Table improvements */
.wp-list-table {
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: none;
    margin: 0;
}

.wp-list-table thead th {
    background: var(--gray-50);
    color: var(--gray-700);
    font-weight: 600;
    text-transform: uppercase;
    font-size: 11px;
    letter-spacing: 0.5px;
    padding: 12px;
    border-bottom: 1px solid var(--gray-200);
}

.wp-list-table tbody tr {
    transition: all 0.2s ease;
}

.wp-list-table tbody tr:hover {
    background: var(--gray-50);
}

.wp-list-table tbody td {
    padding: 12px;
    border-bottom: 1px solid var(--gray-100);
    vertical-align: middle;
}

.wp-list-table tbody td:first-child {
    width: 40px;
}

.wp-list-table .check-column {
    width: 40px;
    padding: 12px 8px;
}

/* Webhooks page */
.atlasly-webhooks {
    max-width: 1200px;
}

/* Security page improvements */
.atlasly-security-app {
    max-width: 900px;
}

/* Help page improvements */
.atlasly-help-page {
    max-width: 1000px;
    margin: 0 auto;
}

.atlasly-help-page h2 {
    color: var(--text);
    font-size: 24px;
    font-weight: 600;
    margin: 32px 0 16px 0;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--gray-200);
}

.atlasly-help-page h3 {
    color: var(--text);
    font-size: 18px;
    font-weight: 600;
    margin: 24px 0 12px 0;
}

.atlasly-help-page code {
    background: var(--gray-100);
    padding: 2px 8px;
    border-radius: 4px;
    font-family: 'Monaco', 'Consolas', monospace;
    font-size: 13px;
    color: var(--primary-dark);
}

.atlasly-help-page pre {
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    padding: 20px;
    overflow-x: auto;
    font-family: 'Monaco', 'Consolas', monospace;
    font-size: 13px;
    line-height: 1.6;
}

.atlasly-help-page pre code {
    background: none;
    padding: 0;
}

/* Badge styles */
.atlasly-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.atlasly-badge-success {
    background: #d1fae5;
    color: #065f46;
}

.atlasly-badge-warning {
    background: #fef3c7;
    color: #92400e;
}

.atlasly-badge-error {
    background: #fee2e2;
    color: #991b1b;
}

.atlasly-badge-info {
    background: #dbeafe;
    color: #1e40af;
}

/* Content type cards */
.atlasly-content-type-card {
    background: white;
    border: 2px solid var(--gray-200);
    border-radius: 12px;
    padding: 24px;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-sm);
}

.atlasly-content-type-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
}

.atlasly-content-type-card h3 {
    margin: 0 0 8px 0;
    color: var(--text);
    font-size: 18px;
    font-weight: 600;
}

.atlasly-content-type-card p {
    margin: 0;
    color: var(--gray-600);
    font-size: 14px;
}

/* Entry form improvements */
.atlasly-entry-form {
    background: white;
    border-radius: 12px;
    padding: 24px;
}

.atlasly-entry-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text);
    font-size: 14px;
}

.atlasly-entry-form .required {
    color: var(--error);
}

/* Filter bar */
.atlasly-filter-bar {
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    padding: 16px;
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 24px;
}

.atlasly-filter-bar input,
.atlasly-filter-bar select {
    flex: 1;
    min-width: 200px;
}

/* Action bar */
.atlasly-action-bar {
    background: linear-gradient(135deg, rgba(95, 122, 97, 0.1) 0%, rgba(95, 122, 97, 0.05) 100%);
    border: 1px solid var(--primary-light);
    border-radius: 8px;
    padding: 12px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    gap: 12px;
    flex-wrap: wrap;
}

.atlasly-action-bar strong {
    color: var(--text);
    font-size: 14px;
    margin: 0;
}

.atlasly-action-bar>div {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.atlasly-action-bar button {
    margin: 0;
    height: 32px;
    padding: 0 12px;
    font-size: 13px;
}

/* Empty state */
.atlasly-empty {
    text-align: center;
    padding: 48px 24px;
    background: white;
    border: 2px dashed var(--gray-300);
    border-radius: 12px;
    margin: 16px 0;
}

.atlasly-empty h3 {
    color: var(--gray-600);
    font-size: 18px;
    margin: 0 0 8px 0;
}

.atlasly-empty p {
    color: var(--gray-500);
    margin: 0 0 16px 0;
    font-size: 14px;
}

.atlasly-empty pre {
    text-align: left;
    max-width: 600px;
    margin: 16px auto 0;
}

/* Smooth transitions */
* {
    transition-property: background-color, border-color, color, fill, stroke, opacity, box-shadow, transform;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
    transition-duration: 150ms;
}

/* Enhanced Entries Page */
.atlasly-entries-container {
    max-width: 100%;
    margin: 0;
    padding: 0;
}

.atlasly-entries-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
    gap: 16px;
}

.atlasly-entries-header h2 {
    margin: 0;
    padding: 0;
    font-size: 24px;
    font-weight: 600;
}

.atlasly-entries-toolbar {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}

.atlasly-entries-toolbar select,
.atlasly-entries-toolbar button {
    margin: 0;
    height: 36px;
    line-height: 1;
}

.atlasly-filter-bar {
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    padding: 12px;
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 16px;
}

.atlasly-filter-bar input,
.atlasly-filter-bar select {
    flex: 1;
    min-width: 180px;
    margin: 0;
    height: 36px;
}

.atlasly-filter-bar button {
    margin: 0;
    height: 36px;
    white-space: nowrap;
}

.atlasly-view-toggle {
    display: flex;
    gap: 4px;
    background: var(--gray-100);
    padding: 4px;
    border-radius: 8px;
}

.atlasly-view-toggle button {
    padding: 8px 16px;
    border: none;
    background: transparent;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    color: var(--gray-600);
    transition: all 0.2s ease;
}

.atlasly-view-toggle button.active {
    background: white;
    color: var(--primary);
    box-shadow: var(--shadow-sm);
}

.atlasly-entries-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.atlasly-entry-card {
    background: white;
    border: 2px solid var(--gray-200);
    border-radius: 12px;
    padding: 20px;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.atlasly-entry-card::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.atlasly-entry-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
}

.atlasly-entry-card:hover::before {
    opacity: 1;
}

.atlasly-entry-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 16px;
}

.atlasly-entry-card-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text);
    margin: 0 0 4px 0;
    line-height: 1.4;
}

.atlasly-entry-card-id {
    font-size: 12px;
    color: var(--gray-500);
    font-weight: 500;
}

.atlasly-entry-card-body {
    margin-bottom: 16px;
}

.atlasly-entry-field {
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--gray-100);
}

.atlasly-entry-field:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.atlasly-entry-field-label {
    font-size: 11px;
    font-weight: 600;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.atlasly-entry-field-value {
    font-size: 14px;
    color: var(--gray-700);
    line-height: 1.5;
    word-break: break-word;
}

.atlasly-entry-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 16px;
    border-top: 1px solid var(--gray-200);
}

.atlasly-entry-date {
    font-size: 12px;
    color: var(--gray-500);
}

.atlasly-entry-actions {
    display: flex;
    gap: 8px;
}

.atlasly-entry-actions button {
    padding: 6px 12px;
    font-size: 12px;
    border-radius: 6px;
}

/* Stats bar */
.atlasly-stats-bar {
    background: linear-gradient(135deg, rgba(95, 122, 97, 0.08) 0%, rgba(95, 122, 97, 0.03) 100%);
    border: 1px solid var(--primary-light);
    border-radius: 12px;
    padding: 16px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.atlasly-stats-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.atlasly-stats-label {
    font-size: 11px;
    font-weight: 600;
    color: var(--gray-600);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.atlasly-stats-value {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary-dark);
}

/* Pagination */
.atlasly-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 32px;
    padding: 20px;
}

.atlasly-pagination button {
    padding: 8px 16px;
    border-radius: 8px;
    font-weight: 500;
}

.atlasly-pagination button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.atlasly-pagination-info {
    padding: 0 16px;
    color: var(--gray-600);
    font-size: 14px;
}

.wp-core-ui select {
    min-width: 200px;
}

.wp-core-ui .button,
.wp-core-ui .button-secondary {
    height: auto;
    padding: 8px 20px !important;
}