/* ===== RESET & BASE ===== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    font-size: 15px;
    line-height: 1.6;
    color: #2b2d42;
    background: #f5f5f9;
    -webkit-font-smoothing: antialiased;
}

body {
    min-height: 100vh;
    display: flex;
}

a { color: #4361ee; text-decoration: none; }
a:hover { color: #3451d1; text-decoration: underline; }

h1 { font-size: 1.75rem; font-weight: 700; margin-bottom: 0.5rem; }
h2 { font-size: 1.35rem; font-weight: 600; margin-bottom: 0.5rem; }
h3 { font-size: 1.15rem; font-weight: 600; margin-bottom: 0.4rem; }
p { margin-bottom: 0.75rem; }
small { font-size: 0.85rem; color: #8d99ae; }
hr { border: none; border-top: 1px solid #e0e0e0; margin: 1.5rem 0; }
mark { background: #fff3cd; padding: 0.2em 0.5em; border-radius: 4px; }
ul, ol { padding-left: 1.25rem; margin-bottom: 0.75rem; }
li { margin-bottom: 0.25rem; }

/* ===== LAYOUT ===== */
.app-layout {
    display: flex;
    width: 100%;
    min-height: 100vh;
}

/* ===== SIDEBAR ===== */
.sidebar {
    width: 260px;
    min-width: 260px;
    background: #1e1e2d;
    color: #a2a3b7;
    display: flex;
    flex-direction: column;
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 100;
    transition: width 0.2s ease, min-width 0.2s ease;
    overflow: hidden;
}

.sidebar.collapsed {
    width: 48px;
    min-width: 48px;
}

.sidebar-header {
    display: flex;
    align-items: center;
    padding: 16px 12px;
    gap: 10px;
    border-bottom: 1px solid #2d2d44;
    min-height: 56px;
}

.sidebar-header .logo {
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
    overflow: hidden;
    color: #fff;
    font-weight: 700;
    font-size: 1rem;
    flex: 1;
}

.sidebar-header .logo svg {
    flex-shrink: 0;
}

.sidebar.collapsed .sidebar-header .logo span {
    display: none;
}

.hamburger-btn {
    background: none;
    border: none;
    color: #a2a3b7;
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.hamburger-btn:hover {
    background: #2d2d44;
    color: #fff;
}

/* Sidebar explorer */
.sidebar-explorer {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 8px 0;
}

.sidebar-explorer::-webkit-scrollbar {
    width: 4px;
}

.sidebar-explorer::-webkit-scrollbar-thumb {
    background: #2d2d44;
    border-radius: 2px;
}

.sidebar-section-label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 6px 14px;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #6c6e85;
    font-weight: 600;
}

.sidebar.collapsed .sidebar-section-label span {
    display: none;
}

.sidebar-add-btn {
    background: none;
    border: none;
    color: #6c6e85;
    cursor: pointer;
    padding: 2px;
    border-radius: 4px;
    display: flex;
    align-items: center;
}

.sidebar-add-btn:hover {
    color: #fff;
    background: #2d2d44;
}

.sidebar.collapsed .sidebar-add-btn {
    display: none;
}

/* Tree items */
.tree-item {
    display: flex;
    align-items: center;
    padding: 5px 14px;
    cursor: pointer;
    gap: 6px;
    font-size: 0.875rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: #a2a3b7;
    text-decoration: none;
    transition: background 0.1s ease;
    position: relative;
}

.tree-item:hover {
    background: #2d2d44;
    color: #d4d5e9;
    text-decoration: none;
}

.tree-item.active {
    background: #2d2d44;
    color: #fff;
}

.tree-item svg {
    flex-shrink: 0;
}

.tree-item .tree-label {
    overflow: hidden;
    text-overflow: ellipsis;
}

.tree-item .chevron {
    transition: transform 0.2s ease;
    flex-shrink: 0;
}

.tree-item .chevron.expanded {
    transform: rotate(90deg);
}

.tree-children {
    overflow: hidden;
    max-height: 0;
    transition: max-height 0.2s ease;
}

.tree-children.expanded {
    max-height: 1000px;
}

.tree-children .tree-item {
    padding-left: 32px;
}

/* Status dot */
.status-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    flex-shrink: 0;
    display: inline-block;
}

.status-dot.pending { background: #8d99ae; }
.status-dot.running { background: #4361ee; animation: pulse-dot 0.8s ease-in-out infinite; box-shadow: 0 0 0 0 rgba(67,97,238,0.5); }
.status-dot.completed { background: #2dc653; }
.status-dot.failed { background: #e63946; }
.status-dot.cancelled { background: #ff9f1c; }

@keyframes pulse-dot {
    0% { opacity: 1; box-shadow: 0 0 0 0 rgba(67,97,238,0.6); }
    50% { opacity: 0.5; box-shadow: 0 0 0 4px rgba(67,97,238,0); }
    100% { opacity: 1; box-shadow: 0 0 0 0 rgba(67,97,238,0); }
}

/* Sidebar bottom */
.sidebar-bottom {
    border-top: 1px solid #2d2d44;
    padding: 8px 0;
}

.sidebar-bottom .tree-item {
    font-size: 0.85rem;
}

.sidebar-version {
    padding: 6px 14px;
    font-size: 0.7rem;
    color: #4a4b63;
}

.sidebar.collapsed .sidebar-version,
.sidebar.collapsed .tree-item .tree-label {
    display: none;
}

/* Tooltip for collapsed state */
.sidebar.collapsed .tree-item {
    justify-content: center;
    padding: 8px;
}

.sidebar.collapsed .tree-item[data-tooltip] {
    position: relative;
}

.sidebar.collapsed .tree-item[data-tooltip]:hover::after {
    content: attr(data-tooltip);
    position: absolute;
    left: 48px;
    top: 50%;
    transform: translateY(-50%);
    background: #2b2d42;
    color: #fff;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.8rem;
    white-space: nowrap;
    z-index: 200;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

.sidebar.collapsed .tree-children,
.sidebar.collapsed .chevron {
    display: none;
}

/* Sidebar loading */
.sidebar-loading {
    padding: 12px 14px;
    font-size: 0.8rem;
    color: #6c6e85;
}

/* Tree item row */
.tree-item-row {
    display: flex;
    align-items: center;
}
.tree-item-row .tree-item {
    flex: 1;
    min-width: 0;
}
.tree-delete-btn {
    display: none;
    background: none;
    border: none;
    color: #6c6e85;
    cursor: pointer;
    padding: 3px;
    border-radius: 4px;
    flex-shrink: 0;
    margin-right: 4px;
}
.tree-item-row:hover .tree-delete-btn {
    display: flex;
}
.tree-delete-btn:hover {
    color: #e63946;
    background: transparent;
}
.sidebar.collapsed .tree-delete-btn {
    display: none !important;
}

/* Drag and drop */
.tree-item[draggable="true"] {
    cursor: grab;
}
.tree-item[draggable="true"]:active {
    cursor: grabbing;
}
.tree-item.dragging {
    opacity: 0.4;
}
.tree-item-group.drop-hover > .tree-item-row > .tree-item,
.tree-item-group.drop-hover > .tree-item {
    background: #2d2d44;
    color: #fff;
    outline: 2px solid #4361ee;
    outline-offset: -2px;
    border-radius: 4px;
}

/* Button icon danger (for tables) */
.btn-icon-danger {
    background: transparent;
    border: none;
    color: #e63946;
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    display: flex;
    align-items: center;
}
.btn-icon-danger:hover {
    color: #c92a2a;
    background: transparent;
}

/* ===== MAIN CONTENT ===== */
.main-wrapper {
    flex: 1;
    margin-left: 260px;
    transition: margin-left 0.2s ease;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.sidebar.collapsed ~ .main-wrapper {
    margin-left: 48px;
}

/* Mobile top bar */
.mobile-topbar {
    display: none;
    align-items: center;
    padding: 10px 16px;
    background: #fff;
    border-bottom: 1px solid #e0e0e0;
    gap: 10px;
    position: sticky;
    top: 0;
    z-index: 50;
}

.mobile-topbar .logo {
    font-weight: 700;
    color: #2b2d42;
    font-size: 1rem;
}

.main-content {
    flex: 1;
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: 24px 32px;
}

.main-footer {
    text-align: center;
    padding: 16px 32px;
    border-top: 1px solid #e0e0e0;
    color: #8d99ae;
    font-size: 0.8rem;
}

/* Backdrop for mobile */
.sidebar-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.4);
    z-index: 99;
}

.sidebar-backdrop.visible {
    display: block;
}

/* ===== CARDS ===== */
.card {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    padding: 20px 24px;
    margin-bottom: 20px;
}

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

.card-header h2, .card-header h3 {
    margin-bottom: 0;
}

/* ===== PROJECT GRID ===== */
.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}

.project-card {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    padding: 20px 24px;
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.project-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
    transform: translateY(-1px);
}

.project-card h3 {
    margin-bottom: 0.4rem;
}

.project-card h3 a {
    color: #2b2d42;
    text-decoration: none;
}

.project-card h3 a:hover {
    color: #4361ee;
    text-decoration: none;
}

.project-card p {
    color: #8d99ae;
    font-size: 0.9rem;
    margin-bottom: 0.75rem;
}

.project-card .card-footer {
    font-size: 0.8rem;
    color: #8d99ae;
    padding-top: 12px;
    border-top: 1px solid #f0f0f0;
}

/* ===== BADGES ===== */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.2em 0.65em;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    gap: 5px;
}

.badge.pending { background: #e9ecef; color: #6c757d; }
.badge.running { background: #dbe4ff; color: #3b5bdb; animation: pulse-badge 0.9s ease-in-out infinite; box-shadow: 0 0 0 0 rgba(67,97,238,0.4); }
.badge.completed { background: #d3f9d8; color: #1b7a3d; }
.badge.failed { background: #ffe0e3; color: #c92a2a; }
.badge.cancelled { background: #fff3e0; color: #e67700; }

@keyframes pulse-badge {
    0% { opacity: 1; box-shadow: 0 0 0 0 rgba(67,97,238,0.5); }
    50% { opacity: 0.7; box-shadow: 0 0 0 6px rgba(67,97,238,0); }
    100% { opacity: 1; box-shadow: 0 0 0 0 rgba(67,97,238,0); }
}

/* ===== BUTTONS ===== */
button, .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: 6px;
    border: 1px solid transparent;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.15s ease;
    font-family: inherit;
    line-height: 1.4;
    text-decoration: none;
    white-space: nowrap;
}

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

/* Primary button */
.btn-primary, button[type="submit"], button:not(.btn-secondary):not(.btn-outline):not(.hamburger-btn):not(.sidebar-add-btn):not(.modal-close):not(.tab-btn):not(.chevron-btn) {
    background: #4361ee;
    color: #fff;
    border-color: #4361ee;
}

.btn-primary:hover, button[type="submit"]:hover {
    background: #3451d1;
    border-color: #3451d1;
    text-decoration: none;
}

/* Secondary / outline button */
.btn-secondary, button.secondary {
    background: #fff;
    color: #2b2d42;
    border-color: #d0d5dd;
}

.btn-secondary:hover, button.secondary:hover {
    background: #f5f5f9;
    border-color: #b0b5bd;
}

.btn-outline, a[role="button"].outline {
    background: transparent;
    color: #4361ee;
    border: 1px solid #4361ee;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.15s ease;
}

.btn-outline:hover, a[role="button"].outline:hover {
    background: #4361ee;
    color: #fff;
    text-decoration: none;
}

a[role="button"]:not(.outline) {
    background: #4361ee;
    color: #fff;
    border: 1px solid #4361ee;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.15s ease;
}

a[role="button"]:not(.outline):hover {
    background: #3451d1;
    border-color: #3451d1;
    text-decoration: none;
}

/* ===== FORMS ===== */
label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 4px;
    color: #2b2d42;
}

input[type="text"],
input[type="url"],
input[type="email"],
input[type="password"],
input[type="number"],
textarea,
select {
    display: block;
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #d0d5dd;
    border-radius: 6px;
    font-size: 0.9rem;
    font-family: inherit;
    line-height: 1.5;
    color: #2b2d42;
    background: #fff;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
    margin-bottom: 12px;
}

input:focus, textarea:focus, select:focus {
    outline: none;
    border-color: #4361ee;
    box-shadow: 0 0 0 3px rgba(67, 97, 238, 0.15);
}

textarea {
    min-height: 80px;
    resize: vertical;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 12px;
}

.input-hint {
    display: block;
    font-size: 0.7rem;
    color: #8d99ae;
    margin-top: -8px;
    margin-bottom: 8px;
}

.form-footer {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 16px;
}

/* ===== TABLES ===== */
.overflow-auto {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

thead th {
    text-align: left;
    padding: 10px 12px;
    border-bottom: 2px solid #e9ecef;
    font-weight: 600;
    color: #6c757d;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

tbody td {
    padding: 10px 12px;
    border-bottom: 1px solid #f0f0f3;
    vertical-align: middle;
}

tbody tr:hover {
    background: #f8f9fa;
}

tbody tr:last-child td {
    border-bottom: none;
}

.sortable th[data-sort] {
    cursor: pointer;
    user-select: none;
    position: relative;
}

.sortable th[data-sort]::after {
    content: "\2195";
    margin-left: 0.3em;
    opacity: 0.4;
    font-size: 0.8em;
}

.sortable th[data-sort].sort-asc::after {
    content: "\2191";
    opacity: 1;
}

.sortable th[data-sort].sort-desc::after {
    content: "\2193";
    opacity: 1;
}

/* ===== PROGRESS BAR ===== */
.progress-bar-wrapper {
    width: 100%;
    height: 10px;
    background: #e9ecef;
    border-radius: 999px;
    overflow: hidden;
    margin-top: 8px;
}

.progress-bar-fill {
    height: 100%;
    background: #4361ee;
    border-radius: 999px;
    transition: width 0.3s ease;
}

progress {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 10px;
    border-radius: 999px;
    overflow: hidden;
    border: none;
    margin-top: 8px;
    background: #e9ecef;
}

progress::-webkit-progress-bar {
    background: #e9ecef;
    border-radius: 999px;
}

progress::-webkit-progress-value {
    background: #4361ee;
    border-radius: 999px;
}

progress::-moz-progress-bar {
    background: #4361ee;
    border-radius: 999px;
}

/* ===== BREADCRUMB ===== */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 0;
    list-style: none;
    padding: 0;
    margin: 0 0 16px 0;
    font-size: 0.85rem;
}

.breadcrumb li {
    display: flex;
    align-items: center;
    margin-bottom: 0;
}

.breadcrumb li:not(:last-child)::after {
    content: "/";
    margin: 0 8px;
    color: #8d99ae;
}

.breadcrumb li:last-child {
    color: #8d99ae;
}

.breadcrumb a {
    color: #2b2d42;
}

.breadcrumb a:hover {
    color: #4361ee;
}

/* ===== DIALOGS / MODALS ===== */
dialog {
    border: none;
    border-radius: 12px;
    padding: 0;
    max-width: 480px;
    width: 90%;
    box-shadow: 0 16px 48px rgba(0,0,0,0.15);
    animation: dialog-in 0.2s ease;
}

dialog::backdrop {
    background: rgba(0,0,0,0.4);
    backdrop-filter: blur(4px);
}

@keyframes dialog-in {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

dialog article,
dialog .dialog-content {
    max-width: 100%;
}

.dialog-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 24px;
    border-bottom: 1px solid #e9ecef;
}

.dialog-header h3 {
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    cursor: pointer;
    color: #8d99ae;
    padding: 4px;
    border-radius: 4px;
    display: flex;
    align-items: center;
}

.modal-close:hover {
    background: #f0f0f3;
    color: #2b2d42;
}

.dialog-body {
    padding: 20px 24px;
}

.dialog-footer {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    padding: 16px 24px;
    border-top: 1px solid #e9ecef;
}

/* ===== TAB NAVIGATION ===== */
.tabs {
    display: flex;
    gap: 0;
    border-bottom: 2px solid #e9ecef;
    margin-bottom: 20px;
    list-style: none;
    padding: 0;
}

.tabs li {
    margin-bottom: -2px;
}

.tab-link {
    display: inline-block;
    padding: 10px 16px;
    font-size: 0.875rem;
    font-weight: 500;
    color: #8d99ae;
    text-decoration: none;
    border-bottom: 2px solid transparent;
    transition: all 0.15s ease;
}

.tab-link:hover {
    color: #2b2d42;
    text-decoration: none;
}

.tab-link.active {
    color: #4361ee;
    border-bottom-color: #4361ee;
    font-weight: 600;
}

/* ===== SECTION HEADER ===== */
.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.section-header h1,
.section-header h2 {
    margin-bottom: 0;
}

/* ===== HGROUP replacement ===== */
.page-heading p {
    color: #8d99ae;
    margin-bottom: 0.25rem;
}

/* ===== STATUS SECTION (crawl detail) ===== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 16px;
    margin-bottom: 16px;
}

.stat-item {
    text-align: center;
    padding: 12px;
}

.stat-item .stat-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    color: #8d99ae;
    letter-spacing: 0.04em;
    font-weight: 600;
    margin-bottom: 4px;
}

.stat-item .stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2b2d42;
}

/* ===== SEVERITY COLORS ===== */
.severity-error { color: #e63946; }
.severity-warning { color: #ff9f1c; }
.severity-info { color: #4361ee; }

/* ===== EMPTY STATE ===== */
.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: #8d99ae;
}

.empty-state p {
    margin-bottom: 16px;
}

/* ===== ACTIONS ROW ===== */
.actions-row {
    display: flex;
    gap: 8px;
    margin-top: 16px;
    flex-wrap: wrap;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 767px) {
    .sidebar {
        transform: translateX(-100%);
        width: 260px;
        min-width: 260px;
    }

    .sidebar.mobile-open {
        transform: translateX(0);
    }

    .sidebar.collapsed {
        transform: translateX(-100%);
    }

    .main-wrapper {
        margin-left: 0 !important;
    }

    .mobile-topbar {
        display: flex;
    }

    .main-content {
        padding: 16px;
    }

    .project-grid {
        grid-template-columns: 1fr;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .dialog-footer, .form-footer {
        flex-direction: column;
    }

    .dialog-footer button, .form-footer button {
        width: 100%;
    }
}

@media (min-width: 768px) and (max-width: 1024px) {
    .sidebar {
        width: 48px;
        min-width: 48px;
    }

    .sidebar:not(.collapsed) .sidebar-section-label span,
    .sidebar:not(.collapsed) .tree-item .tree-label,
    .sidebar:not(.collapsed) .sidebar-version,
    .sidebar:not(.collapsed) .tree-children,
    .sidebar:not(.collapsed) .chevron {
        /* On tablet, start collapsed */
    }

    .main-wrapper {
        margin-left: 48px;
    }

    .sidebar.expanded-tablet {
        width: 260px;
        min-width: 260px;
    }

    .sidebar.expanded-tablet ~ .main-wrapper {
        margin-left: 260px;
    }
}

@media (min-width: 1025px) {
    .sidebar.collapsed ~ .main-wrapper {
        margin-left: 48px;
    }
}

/* ===== UTILITY ===== */
.text-muted { color: #8d99ae; }
.text-center { text-align: center; }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.flex { display: flex; }
.flex-between { display: flex; justify-content: space-between; align-items: center; }
.gap-1 { gap: 8px; }
.gap-2 { gap: 16px; }

/* ===== SHARE BUTTON ===== */
.share-btn-container {
    position: fixed;
    top: 12px;
    right: 16px;
    z-index: 90;
}
.share-btn {
    background: #fff !important;
    border: 1px solid #d0d5dd !important;
    border-radius: 8px !important;
    padding: 7px 8px !important;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    display: flex;
    align-items: center;
    color: #495057;
}
.share-btn:hover {
    background: #f0f0f3 !important;
    color: #4361ee;
}
.share-menu {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 4px;
    background: #fff;
    border: 1px solid #d0d5dd;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
    min-width: 160px;
    padding: 4px 0;
}
.share-menu.hidden { display: none; }
.share-menu button {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    text-align: left;
    background: none !important;
    border: none !important;
    padding: 8px 12px !important;
    font-size: 0.82rem;
    color: #2b2d42 !important;
    cursor: pointer;
    border-radius: 0 !important;
}
.share-menu button:hover {
    background: #f0f0f3 !important;
}
@media (max-width: 767px) {
    .share-btn-container { top: auto; bottom: 16px; right: 16px; }
}
