/**
 * NotedWP Demo - Override Styles
 * Banner, disabled dashboard button, tooltip, and layout adjustments.
 */

/* ── Demo Banner ── */

.notedwp-demo-banner {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 999999;
    background: #F9F7F3;
    border-bottom: 1px solid #E3E0D9;
    font-family: 'Inter Tight', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 13px;
    color: #111110;
    line-height: 1;
    -webkit-font-smoothing: antialiased;
}

.notedwp-demo-banner__inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 10px 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
}

.notedwp-demo-banner__text {
    font-size: 13px;
    color: #111110;
}

.notedwp-demo-banner__text strong {
    font-weight: 700;
}

.notedwp-demo-banner__cta {
    display: inline-flex;
    align-items: center;
    background: #D4920A;
    color: #fff;
    padding: 6px 16px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 12px;
    text-decoration: none;
    letter-spacing: -0.01em;
    white-space: nowrap;
    transition: opacity 0.15s ease;
}

.notedwp-demo-banner__cta:hover {
    opacity: 0.88;
}

.notedwp-demo-banner__dismiss {
    background: none;
    border: none;
    color: #6B6968;
    cursor: pointer;
    font-size: 18px;
    line-height: 1;
    padding: 2px 4px;
    margin-left: 4px;
    transition: color 0.15s ease;
}

.notedwp-demo-banner__dismiss:hover {
    color: #111110;
}

/* Push page content down to account for fixed banner height.
   The banner height varies with screen width and WP admin bar presence.
   JS in the banner template sets --notedwp-banner-h dynamically. */
body.notedwp-demo-active {
    padding-top: var(--notedwp-banner-h, 42px);
}

/* When WP admin bar is present, shift banner below it */
.admin-bar .notedwp-demo-banner {
    top: 32px;
}

@media screen and (max-width: 782px) {
    .admin-bar .notedwp-demo-banner {
        top: 46px;
    }
}


/* ── Disabled Dashboard Button ── */

.notedwp-demo-disabled {
    opacity: 0.4 !important;
    cursor: not-allowed !important;
    pointer-events: auto !important; /* Keep clickable for tooltip */
    position: relative;
}

.notedwp-demo-disabled:hover {
    opacity: 0.5 !important;
}


/* ── Dashboard Tooltip ── */

.notedwp-demo-tooltip {
    position: absolute;
    bottom: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%);
    background: #FFFFFF;
    border: 1px solid #E3E0D9;
    border-radius: 10px;
    padding: 14px 16px;
    width: 240px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    z-index: 1000000;
    font-family: 'Inter Tight', -apple-system, BlinkMacSystemFont, sans-serif;
    animation: notedwp-demo-tooltip-in 0.15s ease;
}

.notedwp-demo-tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: #FFFFFF;
}

.notedwp-demo-tooltip::before {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 7px solid transparent;
    border-top-color: #E3E0D9;
}

.notedwp-demo-tooltip p {
    font-size: 12px;
    color: #6B6968;
    line-height: 1.5;
    margin: 0 0 6px;
}

.notedwp-demo-tooltip p:last-of-type {
    margin-bottom: 10px;
}

.notedwp-demo-tooltip a {
    display: inline-flex;
    align-items: center;
    font-size: 12px;
    font-weight: 700;
    color: #D4920A;
    text-decoration: none;
}

.notedwp-demo-tooltip a:hover {
    text-decoration: underline;
}

@keyframes notedwp-demo-tooltip-in {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(4px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}


/* ── Mobile notice (optional, for small screens) ── */

@media (max-width: 768px) {
    .notedwp-demo-banner__inner {
        flex-wrap: wrap;
        gap: 8px;
        padding: 10px 16px;
    }

    .notedwp-demo-banner__text {
        font-size: 12px;
        flex: 1 1 100%;
        text-align: center;
    }

    .notedwp-demo-banner__cta {
        font-size: 11px;
    }
}
