/**
 * GoBoost Link - Modern Design System
 * Encurtador e Gestão Inteligente de Links
 */

:root {
    --gb-font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    --gb-font-mono: 'JetBrains Mono', SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    
    --gb-primary: #2563EB;
    --gb-primary-hover: #1D4ED8;
    --gb-primary-light: #EFF6FF;
    --gb-primary-border: #BFDBFE;
    
    --gb-boost-start: #2563EB;
    --gb-boost-end: #7C3AED;
    --gb-boost-gradient: linear-gradient(135deg, #2563EB 0%, #7C3AED 100%);
    --gb-boost-hover: linear-gradient(135deg, #1D4ED8 0%, #6D28D9 100%);
    
    --gb-bg: #F8FAFC;
    --gb-card-bg: #FFFFFF;
    --gb-card-border: #E2E8F0;
    
    --gb-text-main: #0F172A;
    --gb-text-muted: #64748B;
    --gb-text-light: #94A3B8;
    
    --gb-success: #10B981;
    --gb-success-bg: #ECFDF5;
    --gb-success-border: #A7F3D0;
    
    --gb-warning: #F59E0B;
    --gb-warning-bg: #FFFBEB;
    --gb-warning-border: #FDE68A;
    
    --gb-danger: #EF4444;
    --gb-danger-bg: #FEF2F2;
    --gb-danger-border: #FECACA;

    --gb-shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --gb-shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.07), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
    --gb-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -4px rgba(0, 0, 0, 0.04);
    --gb-shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
    --gb-radius: 12px;
}

*, *::before, *::after {
    box-sizing: border-box;
}

/* Base Body */
body {
    font-family: var(--gb-font-sans);
    font-size: 14px;
    line-height: 1.5;
    color: var(--gb-text-main);
    background-color: var(--gb-bg);
    margin: 0;
    padding: 0;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Links */
a, a:link, a:active, a:visited {
    color: var(--gb-primary);
    text-decoration: none;
    transition: color 0.15s ease, opacity 0.15s ease;
}
a:hover {
    color: var(--gb-primary-hover);
    text-decoration: underline;
}

/* Main Container Wrap */
#wrap {
    max-width: 1200px;
    width: 95%;
    margin: 24px auto 40px auto;
    background: var(--gb-card-bg);
    border: 1px solid var(--gb-card-border);
    border-radius: var(--gb-radius);
    box-shadow: var(--gb-shadow-md);
    padding: 24px 32px 32px 32px;
    text-align: left;
}

.hide-if-no-js { display: none !important; }

/* Top Header & Logo */
#site-header {
    padding-bottom: 20px;
    margin-bottom: 20px;
    border-bottom: 1px solid var(--gb-card-border);
}
.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
}
h1, h1.site-title {
    margin: 0;
    float: none;
    max-width: none;
    line-height: 1;
}
h1 a, h1.site-title a {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}
#yourls-logo {
    border: 0;
    height: 38px;
    width: auto;
    max-width: 300px;
    object-fit: contain;
    display: block;
    transition: transform 0.2s ease;
}
#yourls-logo:hover {
    transform: scale(1.02);
}

/* Admin Menu & Navigation */
nav[role="navigation"] {
    margin-bottom: 24px;
    background: #F1F5F9;
    border-radius: 10px;
    padding: 6px;
    border: 1px solid #E2E8F0;
}
ul#admin_menu {
    min-height: auto;
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
}
ul#admin_menu li {
    padding: 0;
    margin: 0;
    display: inline-flex;
    align-items: center;
}
ul#admin_menu li a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    font-size: 13px;
    font-weight: 600;
    color: var(--gb-text-muted);
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.15s ease;
}
ul#admin_menu li a:hover {
    background: #FFFFFF;
    color: var(--gb-text-main);
    box-shadow: var(--gb-shadow-sm);
    text-decoration: none;
}
ul#admin_menu li a svg {
    flex-shrink: 0;
}
ul#admin_menu li:hover {
    list-style-type: none;
}

/* User Greeting & Logout in Navigation */
#admin_menu_logout_link {
    margin-left: auto;
    display: inline-flex;
    align-items: center;
    gap: 12px;
}
.user-greeting {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: var(--gb-text-main);
    background: #FFFFFF;
    padding: 6px 12px;
    border-radius: 8px;
    border: 1px solid var(--gb-card-border);
    box-shadow: var(--gb-shadow-sm);
}
.user-greeting strong {
    color: var(--gb-primary);
}
.logout-btn {
    display: inline-flex !important;
    align-items: center;
    gap: 6px;
    background: #FEE2E2 !important;
    color: #DC2626 !important;
    padding: 6px 12px !important;
    border-radius: 8px !important;
    font-weight: 600 !important;
    font-size: 12px !important;
    transition: all 0.15s ease !important;
}
.logout-btn:hover {
    background: #FCA5A5 !important;
    color: #991B1B !important;
    transform: translateY(-1px);
}

/* Submenu dropdown if any */
ul#admin_menu li ul {
    display: none;
    position: absolute;
    background: #FFFFFF;
    border: 1px solid var(--gb-card-border);
    border-radius: 8px;
    box-shadow: var(--gb-shadow-lg);
    padding: 6px;
    z-index: 50;
    list-style: none;
    margin: 4px 0 0 0;
}
ul#admin_menu li:hover ul {
    display: block;
}

/* Admin Notices / Alerts */
.notice {
    border: 1px solid var(--gb-primary-border);
    background: var(--gb-primary-light);
    border-radius: 10px;
    width: 100%;
    margin: 0 0 16px 0;
    padding: 12px 18px;
    clear: both;
    font-size: 13px;
    color: #1E40AF;
}
.notice p {
    margin: 0;
}

/* Quick Metrics / Dashboard Overview */
.dashboard-kpis {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}
.kpi-card {
    background: #FFFFFF;
    border: 1px solid var(--gb-card-border);
    border-radius: 12px;
    padding: 18px 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: var(--gb-shadow-sm);
    transition: all 0.2s ease;
}
.kpi-card:hover {
    box-shadow: var(--gb-shadow-md);
    transform: translateY(-2px);
    border-color: #CBD5E1;
}
.kpi-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.kpi-icon.kpi-links {
    background: #EFF6FF;
    color: #2563EB;
}
.kpi-icon.kpi-clicks {
    background: #F5F3FF;
    color: #7C3AED;
}
.kpi-icon.kpi-status {
    background: #ECFDF5;
    color: #10B981;
}
.kpi-content {
    display: flex;
    flex-direction: column;
}
.kpi-label {
    font-size: 12px;
    font-weight: 600;
    color: var(--gb-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}
.kpi-value {
    font-size: 24px;
    font-weight: 800;
    color: var(--gb-text-main);
    line-height: 1.1;
    font-family: var(--gb-font-sans);
}
.kpi-status-active {
    font-size: 14px;
    color: #059669;
    font-weight: 700;
}
.search-feedback-bar {
    background: #EFF6FF;
    border: 1px solid #BFDBFE;
    color: #1E40AF;
    padding: 10px 16px;
    border-radius: 8px;
    font-size: 13px;
    margin-bottom: 16px;
}
.dashboard-pagination-info {
    margin-bottom: 16px;
    color: var(--gb-text-muted);
    font-size: 13px;
}
.dashboard-pagination-info p {
    margin: 0;
}
.dashboard-pagination-info strong {
    color: var(--gb-text-main);
}
#overall_tracking {
    display: none;
}

/* New URL Card Box */
#new_url {
    background: #FFFFFF;
    border: 1px solid var(--gb-card-border);
    border-radius: var(--gb-radius);
    padding: 20px 24px;
    margin-bottom: 24px;
    box-shadow: var(--gb-shadow-sm);
    clear: both;
    text-align: left;
    position: relative;
    overflow: hidden;
}
#new_url::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gb-boost-gradient);
}
.new-url-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}
.boost-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--gb-primary-light);
    color: var(--gb-primary);
    border: 1px solid var(--gb-primary-border);
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}
.new-url-subtitle {
    color: var(--gb-text-muted);
    font-size: 13px;
}
.new-url-form-grid {
    display: flex;
    align-items: flex-end;
    gap: 16px;
    flex-wrap: wrap;
}
.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.form-group-url {
    flex: 3;
    min-width: 280px;
}
.form-group-keyword {
    flex: 1.5;
    min-width: 180px;
}
.form-group-submit {
    flex: 0 0 auto;
}
.form-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 600;
    color: var(--gb-text-main);
}
.form-label small {
    color: var(--gb-text-muted);
    font-weight: normal;
}
.form-label-spacer {
    user-select: none;
}
.form-control, input.text {
    width: 100%;
    height: 42px;
    padding: 8px 14px;
    font-family: var(--gb-font-sans);
    font-size: 14px;
    color: var(--gb-text-main);
    background-color: #FFFFFF;
    border: 1.5px solid #CBD5E1;
    border-radius: 8px;
    outline: none;
    transition: all 0.15s ease;
    box-sizing: border-box;
}
.form-control:focus, input.text:focus {
    border-color: var(--gb-primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}
#add-keyword {
    font-family: var(--gb-font-mono);
    font-size: 13px;
}

/* Primary Boost Button */
.btn-boost-primary, input.button.btn-boost-primary, input.primary {
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: var(--gb-boost-gradient) !important;
    color: #FFFFFF !important;
    border: none !important;
    border-radius: 8px !important;
    padding: 0 20px !important;
    font-family: var(--gb-font-sans) !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    cursor: pointer !important;
    box-shadow: var(--gb-shadow-sm) !important;
    transition: all 0.2s ease !important;
    white-space: nowrap;
}
.btn-boost-primary:hover, input.button.btn-boost-primary:hover, input.primary:hover {
    background: var(--gb-boost-hover) !important;
    box-shadow: var(--gb-shadow-md) !important;
    transform: translateY(-1px);
}
.btn-boost-primary:active, input.button.btn-boost-primary:active {
    transform: translateY(0);
}
#add-button.disabled, .button.disabled {
    opacity: 0.65;
    cursor: not-allowed !important;
    transform: none !important;
}
#add-button.loading, .button.loading {
    background-image: url(../images/loading.gif) !important;
    background-position: center !important;
    background-repeat: no-repeat !important;
    color: transparent !important;
}

/* Feedback message */
#new_url #feedback {
    margin-top: 14px;
    padding: 10px 16px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    width: 100%;
    box-sizing: border-box;
}
#new_url #feedback.success {
    background-color: var(--gb-success-bg);
    color: #065F46;
    border: 1px solid var(--gb-success-border);
}
#new_url #feedback.fail, #new_url #feedback.error {
    background-color: var(--gb-danger-bg);
    color: #991B1B;
    border: 1px solid var(--gb-danger-border);
}

/* Table Responsive Wrapper */
.table-responsive {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border: 1px solid var(--gb-card-border);
    border-radius: 10px;
    margin-top: 16px;
    box-shadow: var(--gb-shadow-sm);
    background: #FFFFFF;
}

/* Main Table Styling */
table#main_table.tblSorter {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin: 0;
    font-size: 13px;
    background: transparent;
}
table#main_table thead th {
    background: #F8FAFC;
    color: var(--gb-text-muted);
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 12px 16px;
    border: none;
    border-bottom: 1.5px solid var(--gb-card-border);
    text-align: left;
    white-space: nowrap;
}
table#main_table thead th.tablesorter-header {
    cursor: pointer;
    user-select: none;
}
table#main_table tbody td {
    padding: 12px 16px;
    border: none;
    border-bottom: 1px solid #F1F5F9;
    color: var(--gb-text-main);
    vertical-align: middle;
    background: #FFFFFF;
}
table#main_table tbody tr:last-child td {
    border-bottom: none;
}
table#main_table tbody tr:hover td {
    background-color: #F8FAFC;
}
table#main_table tbody tr.edit-row td {
    background: #EFF6FF !important;
}

/* Table Cells Formatting */
td.keyword a {
    font-family: var(--gb-font-mono);
    font-size: 13px;
    font-weight: 700;
    color: var(--gb-primary);
    background: var(--gb-primary-light);
    border: 1px solid var(--gb-primary-border);
    padding: 4px 8px;
    border-radius: 6px;
    display: inline-block;
    transition: all 0.15s ease;
}
td.keyword a:hover {
    background: #DBEAFE;
    text-decoration: none;
}
td.url {
    max-width: 380px;
    word-break: break-word;
}
td.url a {
    font-weight: 600;
    color: var(--gb-text-main);
}
td.url small a {
    font-weight: normal;
    color: var(--gb-text-muted);
    font-size: 12px;
}
td.timestamp {
    color: var(--gb-text-muted);
    font-size: 12px;
    white-space: nowrap;
}
td.ip {
    color: var(--gb-text-light);
    font-family: var(--gb-font-mono);
    font-size: 11px;
}
td.clicks {
    text-align: center;
}
td.clicks {
    font-weight: 700;
    font-size: 13px;
    color: var(--gb-primary);
}

/* Action Buttons (MODERN PILLS WITH VISIBLE ICONS & TEXT) */
td.actions {
    white-space: nowrap;
    text-align: right;
    min-width: 330px;
}
.actions-wrapper {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    gap: 6px;
    flex-wrap: nowrap;
}
td.actions a.action-btn, td.actions a.button, td.actions input.button {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 5px !important;
    padding: 5px 10px !important;
    height: 30px !important;
    width: auto !important;
    border-radius: 7px !important;
    margin: 0 !important;
    float: none !important;
    text-indent: 0 !important;
    font-family: var(--gb-font-sans) !important;
    font-size: 11.5px !important;
    font-weight: 600 !important;
    line-height: 1 !important;
    text-decoration: none !important;
    cursor: pointer !important;
    opacity: 1 !important;
    pointer-events: auto !important;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04) !important;
    transition: all 0.15s ease !important;
}
td.actions a.action-btn svg, td.actions a.button svg {
    flex-shrink: 0;
}
td.actions a.action-btn span, td.actions a.button span {
    display: inline-block;
}

/* Action Button Color Variants */
td.actions a.button_stats {
    background: #EFF6FF !important;
    color: #2563EB !important;
    border: 1px solid #BFDBFE !important;
}
td.actions a.button_stats:hover {
    background: #DBEAFE !important;
    color: #1D4ED8 !important;
    transform: translateY(-1px);
    box-shadow: var(--gb-shadow-sm) !important;
}

td.actions a.button_share {
    background: #ECFDF5 !important;
    color: #059669 !important;
    border: 1px solid #A7F3D0 !important;
}
td.actions a.button_share:hover {
    background: #D1FAE5 !important;
    color: #047857 !important;
    transform: translateY(-1px);
    box-shadow: var(--gb-shadow-sm) !important;
}

td.actions a.button_edit {
    background: #FFFBEB !important;
    color: #D97706 !important;
    border: 1px solid #FDE68A !important;
}
td.actions a.button_edit:hover {
    background: #FEF3C7 !important;
    color: #B45309 !important;
    transform: translateY(-1px);
    box-shadow: var(--gb-shadow-sm) !important;
}

td.actions a.button_delete {
    background: #FEF2F2 !important;
    color: #DC2626 !important;
    border: 1px solid #FECACA !important;
}
td.actions a.button_delete:hover {
    background: #FEE2E2 !important;
    color: #B91C1C !important;
    transform: translateY(-1px);
    box-shadow: var(--gb-shadow-sm) !important;
}

/* Top Modern Search & Filter Bar */
.search-filter-card {
    background: #FFFFFF;
    border: 1px solid var(--gb-card-border);
    border-radius: var(--gb-radius);
    padding: 16px 20px;
    margin-bottom: 20px;
    box-shadow: var(--gb-shadow-sm);
}
#top_search_form {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}
.search-input-group {
    position: relative;
    flex: 1 1 320px;
    display: flex;
    align-items: center;
}
.search-input-group .search-icon {
    position: absolute;
    left: 14px;
    color: #94A3B8;
    display: flex;
    align-items: center;
    pointer-events: none;
}
.search-control {
    width: 100%;
    height: 42px;
    padding: 8px 36px 8px 42px;
    font-family: var(--gb-font-sans);
    font-size: 14px;
    color: var(--gb-text-main);
    background-color: #F8FAFC;
    border: 1.5px solid #E2E8F0;
    border-radius: 8px;
    outline: none;
    transition: all 0.15s ease;
    box-sizing: border-box;
}
.search-control:focus {
    background-color: #FFFFFF;
    border-color: #8247FF;
    box-shadow: 0 0 0 3px rgba(130, 71, 255, 0.15);
}
.btn-clear-search {
    position: absolute;
    right: 12px;
    width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #E2E8F0;
    color: #64748B;
    font-size: 16px;
    line-height: 1;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.15s ease;
}
.btn-clear-search:hover {
    background: #CBD5E1;
    color: #0F172A;
    text-decoration: none;
}
.search-options-group {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}
.search-select {
    height: 42px;
    padding: 6px 12px;
    font-family: var(--gb-font-sans);
    font-size: 13px;
    color: var(--gb-text-main);
    background-color: #F8FAFC;
    border: 1.5px solid #E2E8F0;
    border-radius: 8px;
    outline: none;
    cursor: pointer;
    transition: all 0.15s ease;
}
.search-select:focus {
    background-color: #FFFFFF;
    border-color: #8247FF;
    box-shadow: 0 0 0 3px rgba(130, 71, 255, 0.15);
}
.btn-search-submit {
    height: 42px;
    padding: 0 18px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(135deg, #8247FF 0%, #6366F1 100%);
    color: #FFFFFF;
    border: none;
    border-radius: 8px;
    font-family: var(--gb-font-sans);
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: var(--gb-shadow-sm);
    transition: all 0.15s ease;
    white-space: nowrap;
}
.btn-search-submit:hover {
    background: linear-gradient(135deg, #7033F5 0%, #4F46E5 100%);
    box-shadow: var(--gb-shadow-md);
    transform: translateY(-1px);
}
.btn-reset-filters {
    height: 42px;
    padding: 0 14px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #F1F5F9;
    color: #64748B;
    border: 1px solid #E2E8F0;
    border-radius: 8px;
    font-family: var(--gb-font-sans);
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.15s ease;
    white-space: nowrap;
}
.btn-reset-filters:hover {
    background: #E2E8F0;
    color: #0F172A;
    text-decoration: none;
}

/* Modal Dialog: Delete Confirmation */
#delete-confirm-dialog {
    background-color: #FFFFFF;
    max-width: 480px;
    width: 90%;
    border: none;
    border-radius: 16px;
    box-shadow: var(--gb-shadow-xl);
    padding: 0;
    overflow: hidden;
}
#delete-confirm-dialog::backdrop {
    background-color: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(4px);
}
#delete-confirm-dialog > div[name="dialog_title"] {
    background: #FEF2F2;
    color: #991B1B;
    font-size: 16px;
    font-weight: 700;
    padding: 16px 20px;
    border-bottom: 1px solid #FEE2E2;
    text-align: left;
}
#delete-confirm-dialog div.confirm-message {
    padding: 20px;
    background: #FFFFFF;
    color: var(--gb-text-main);
    font-size: 14px;
}
#delete-confirm-dialog div.confirm-message ul {
    list-style: none;
    padding: 0;
    margin: 12px 0 0 0;
    background: #F8FAFC;
    border: 1px solid #E2E8F0;
    border-radius: 8px;
    padding: 12px;
}
#delete-confirm-dialog div.confirm-message ul li {
    margin-bottom: 6px;
    font-size: 13px;
    color: var(--gb-text-muted);
}
#delete-confirm-dialog div.confirm-message ul li:last-child {
    margin-bottom: 0;
}
#delete-confirm-dialog div.confirm-message ul li span {
    font-weight: 600;
    color: var(--gb-text-main);
}
#delete-confirm-dialog div.button-group {
    background: #F8FAFC;
    padding: 14px 20px;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    border-top: 1px solid #E2E8F0;
}
#delete-confirm-dialog div.button-group input.button.primary {
    background: #DC2626 !important;
    border-color: #DC2626 !important;
    color: #FFFFFF !important;
    padding: 8px 18px !important;
    border-radius: 8px !important;
    font-weight: 600 !important;
    font-size: 13px !important;
}
#delete-confirm-dialog div.button-group input.button.primary:hover {
    background: #B91C1C !important;
}
#delete-confirm-dialog div.button-group input[type="reset"] {
    background: #FFFFFF !important;
    border: 1px solid #CBD5E1 !important;
    color: var(--gb-text-main) !important;
    padding: 8px 16px !important;
    border-radius: 8px !important;
    font-weight: 600 !important;
    font-size: 13px !important;
}

/* Login Screen */
body.login {
    background: radial-gradient(circle at 10% 20%, rgba(130, 71, 255, 0.06) 0%, rgba(37, 99, 235, 0.04) 50%, #F8FAFC 100%), #F8FAFC;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}
body.login #wrap {
    max-width: 440px;
    width: 100%;
    margin: 0;
    padding: 36px 32px;
    border-radius: 20px;
    background: #FFFFFF;
    box-shadow: 0 20px 45px -15px rgba(15, 23, 42, 0.12), 0 0 1px 1px rgba(15, 23, 42, 0.05);
    border: 1px solid #E2E8F0;
}
body.login #site-header {
    display: none;
}
body.login .login-wrapper {
    width: 100%;
}
body.login .login-card {
    width: 100%;
}
body.login .login-header {
    text-align: center;
    margin-bottom: 24px;
}
body.login .login-logo {
    max-width: 180px;
    height: auto;
    margin-bottom: 12px;
    display: inline-block;
}
body.login .login-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    background: #F5F3FF;
    color: #7C3AED;
    border: 1px solid #DDD6FE;
    font-size: 11px;
    font-weight: 700;
    border-radius: 9999px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 12px;
}
body.login .login-title {
    font-size: 20px;
    font-weight: 800;
    color: #0F172A;
    margin: 0 0 6px 0;
    letter-spacing: -0.02em;
}
body.login .login-subtitle {
    font-size: 13px;
    color: #64748B;
    margin: 0;
    line-height: 1.45;
}
body.login .login-error-alert {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #FEF2F2;
    border: 1px solid #FECACA;
    border-radius: 10px;
    padding: 12px 14px;
    color: #991B1B;
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 18px;
    text-align: left;
}
body.login .login-error-alert svg {
    flex-shrink: 0;
    color: #DC2626;
}
body.login .form-group {
    margin-bottom: 18px;
    text-align: left;
}
body.login .form-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #334155;
    margin-bottom: 6px;
}
body.login .input-with-icon {
    position: relative;
    display: flex;
    align-items: center;
}
body.login .field-icon {
    position: absolute;
    left: 14px;
    display: flex;
    align-items: center;
    color: #94A3B8;
    pointer-events: none;
    transition: color 0.15s ease;
}
body.login .input-with-icon .text {
    width: 100%;
    height: 46px;
    padding: 0 42px 0 42px;
    border: 1.5px solid #CBD5E1;
    border-radius: 10px;
    font-size: 14px;
    font-family: inherit;
    color: #0F172A;
    background: #FFFFFF;
    transition: all 0.2s ease;
    box-sizing: border-box;
}
body.login .input-with-icon .text:focus {
    border-color: #8247FF;
    outline: none;
    box-shadow: 0 0 0 3px rgba(130, 71, 255, 0.15);
}
body.login .input-with-icon:focus-within .field-icon {
    color: #8247FF;
}
body.login .toggle-password {
    position: absolute;
    right: 10px;
    background: transparent;
    border: none;
    color: #94A3B8;
    cursor: pointer;
    padding: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    transition: color 0.15s ease;
}
body.login .toggle-password:hover {
    color: #334155;
}
body.login .toggle-password.active {
    color: #8247FF;
}
body.login .form-actions {
    margin-top: 22px;
}
body.login .btn-login {
    width: 100%;
    height: 48px;
    background: linear-gradient(135deg, #8247FF 0%, #6366F1 100%);
    color: #FFFFFF;
    border: none;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(130, 71, 255, 0.35);
    transition: all 0.2s ease;
}
body.login .btn-login:hover {
    background: linear-gradient(135deg, #743BE8 0%, #4F46E5 100%);
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(130, 71, 255, 0.45);
}
body.login .login-card-footer {
    text-align: center;
    margin-top: 24px;
    padding-top: 18px;
    border-top: 1px solid #F1F5F9;
    font-size: 12px;
    color: #94A3B8;
    font-weight: 500;
}
body.login #footer {
    display: none;
}

/* Footer */
#footer {
    text-align: center;
    margin-top: 24px;
    padding-top: 16px;
    color: var(--gb-text-muted);
    font-size: 13px;
}
#footer p {
    background: transparent;
    border: none;
    border-radius: 0;
    padding: 0;
    max-width: none;
    color: var(--gb-text-muted);
}
#footer p a {
    background: none !important;
    padding-left: 0 !important;
    color: var(--gb-primary);
    font-weight: 600;
}

/* Notifications Bar */
.jquery-notify-bar {
    width: 100%;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 32768;
    background-color: #FFFFFF;
    font-size: 15px;
    font-weight: 600;
    color: var(--gb-text-main);
    text-align: center;
    padding: 14px 20px;
    border-bottom: 1px solid var(--gb-card-border);
    box-shadow: var(--gb-shadow-lg);
}
.jquery-notify-bar.success {
    color: #065F46;
    background-color: #D1FAE5;
    border-bottom: 2px solid #10B981;
}
.jquery-notify-bar.error, .jquery-notify-bar.fail {
    color: #991B1B;
    background-color: #FEE2E2;
    border-bottom: 2px solid #EF4444;
}

/* Responsive Breakpoints */
@media (max-width: 840px) {
    #wrap {
        padding: 18px 16px;
        width: 96%;
        margin-top: 12px;
    }
    .header-inner {
        flex-direction: column;
        align-items: flex-start;
    }
    ul#admin_menu {
        flex-direction: column;
        align-items: stretch;
    }
    ul#admin_menu li {
        width: 100%;
    }
    ul#admin_menu li a {
        width: 100%;
        box-sizing: border-box;
    }
    #admin_menu_logout_link {
        margin-left: 0;
        width: 100%;
        justify-content: space-between;
    }
    .new-url-form-grid {
        flex-direction: column;
        align-items: stretch;
    }
    .form-group-url, .form-group-keyword, .form-group-submit {
        width: 100%;
        min-width: 0;
    }
    .btn-boost-primary {
        width: 100%;
    }
    #top_search_form {
        flex-direction: column;
        align-items: stretch;
    }
    .search-input-group {
        width: 100%;
        flex: none;
    }
    .search-options-group {
        width: 100%;
        flex-direction: column;
        align-items: stretch;
    }
    .search-select, .btn-search-submit, .btn-reset-filters {
        width: 100%;
        justify-content: center;
    }
    td.actions {
        min-width: 290px;
    }
    .actions-wrapper {
        justify-content: flex-start;
        flex-wrap: wrap;
    }
}
