/* ====================================
   WP Robot - Custom Styles
   ==================================== */

:root {
    --wp-primary: #0073aa;
    --wp-primary-dark: #005a87;
    --wp-secondary: #23282d;
    --wp-sidebar: #1d2327;
    --wp-accent: #2271b1;
    --wp-success: #00a32a;
    --wp-warning: #dba617;
    --wp-danger: #d63638;
}

body {
    background-color: #f0f0f1;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
}

/* Login Page */
.login-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.login-card {
    width: 100%;
    max-width: 420px;
    border: none;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

.login-card .card-body {
    padding: 2.5rem;
}

.login-logo {
    font-size: 2.5rem;
    color: var(--wp-primary);
}

/* Navbar */
.navbar-app {
    background-color: var(--wp-secondary) !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.navbar-brand-icon {
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--wp-primary);
    border-radius: 6px;
    color: white;
    font-size: 1.1rem;
    margin-right: 8px;
}

/* Sidebar */
.app-layout {
    display: flex;
    min-height: calc(100vh - 56px);
}

.app-sidebar {
    width: 260px;
    min-width: 260px;
    background-color: var(--wp-sidebar);
    color: #c3c4c7;
    padding-top: 1rem;
    transition: all 0.3s ease;
}

.app-sidebar .nav-link {
    color: #c3c4c7;
    padding: 0.6rem 1.2rem;
    border-radius: 0;
    transition: all 0.2s;
    font-size: 0.9rem;
}

.app-sidebar .nav-link:hover {
    color: #72aee6;
    background-color: rgba(255, 255, 255, 0.04);
}

.app-sidebar .nav-link.active {
    color: #fff;
    background-color: var(--wp-accent);
}

.app-sidebar .nav-link .bi {
    width: 20px;
    margin-right: 10px;
    text-align: center;
}

.sidebar-section-title {
    color: #8c8f94;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 1rem 1.2rem 0.4rem;
    margin: 0;
}

.app-content {
    flex: 1;
    padding: 1.5rem;
    overflow-x: auto;
}

/* Cards */
.site-card {
    border: none;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
    transition: all 0.2s ease;
    cursor: pointer;
    position: relative;
}

.site-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.site-card .card-body {
    padding: 1.25rem;
}

.site-status {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
}

.site-status.active {
    background-color: var(--wp-success);
}

.site-status.inactive {
    background-color: var(--wp-danger);
}

/* Tables */
.table-wp th {
    background-color: #f6f7f7;
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    border-bottom: 2px solid #c3c4c7;
}

.table-wp td {
    vertical-align: middle;
}

/* Post status badges */
.badge-publish {
    background-color: var(--wp-success);
}

.badge-draft {
    background-color: #8c8f94;
}

.badge-pending {
    background-color: var(--wp-warning);
    color: #1d2327;
}

.badge-private {
    background-color: var(--wp-accent);
}

.badge-trash {
    background-color: var(--wp-danger);
}

/* Action buttons */
.btn-wp-primary {
    background-color: var(--wp-accent);
    border-color: var(--wp-accent);
    color: #fff;
}

.btn-wp-primary:hover {
    background-color: var(--wp-primary-dark);
    border-color: var(--wp-primary-dark);
    color: #fff;
}

/* Loading overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

/* Toast container */
.toast-container {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 10000;
}

/* Pagination */
.pagination-wp .page-link {
    color: var(--wp-accent);
}

.pagination-wp .page-item.active .page-link {
    background-color: var(--wp-accent);
    border-color: var(--wp-accent);
}

/* Empty state */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: #8c8f94;
}

.empty-state .bi {
    font-size: 3rem;
    margin-bottom: 1rem;
}

/* Responsive */
@media (max-width: 768px) {
    .app-sidebar {
        position: fixed;
        left: -260px;
        top: 56px;
        bottom: 0;
        z-index: 1000;
    }

    .app-sidebar.show {
        left: 0;
    }

    .app-content {
        padding: 1rem;
    }
}

/* Content editor */
.content-editor {
    min-height: 300px;
    font-family: monospace;
    font-size: 0.9rem;
}

/* Highlight row on hover */
.table-hover tbody tr:hover {
    background-color: #f0f6fc;
}

/* WP site URL display */
.site-url {
    color: #8c8f94;
    font-size: 0.85rem;
    word-break: break-all;
}

/* Dropdown fix for dark navbar */
.navbar-app .dropdown-menu {
    border: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}
