/*
 * Product tour theme — Steelhive overrides for vendored driver.js popovers.
 *
 * Loaded AFTER /static/vendor/driver/driver.css (see index.html) so these
 * rules win on equal specificity. The welcome modal reuses the existing
 * `.modal-overlay` / `.modal` classes from styles.css (manifest § 12), so
 * it needs no extra CSS here — only the driver.js popover surface does.
 *
 * Tokens only (manifest § 2 / § 12.1). No raw hex, no soft shadows.
 */

/* Popover surface ------------------------------------------------------- */
.driver-popover {
    background: var(--surface-container-highest);
    color: var(--on-surface);
    border: 1px solid var(--outline-variant);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    font-family: var(--font-body);
    padding: var(--space-4);
    max-width: 340px;
}

.driver-popover-title {
    color: var(--on-surface);
    font-size: var(--text-md);
    font-weight: 600;
    line-height: 1.3;
}

.driver-popover-description {
    color: var(--on-surface-variant);
    font-size: var(--text-sm);
    line-height: 1.5;
    margin-top: var(--space-2);
}

.driver-popover-progress-text {
    color: var(--on-surface-variant);
    font-size: var(--text-xs);
    font-family: var(--font-mono);
}

/* Close button (top-right) — mirrors .modal-close affordance ----------- */
.driver-popover-close-btn {
    color: var(--on-surface-variant);
    background: none;
    border: none;
}

.driver-popover-close-btn:hover {
    color: var(--on-surface);
}

/* Footer + navigation buttons ------------------------------------------ */
.driver-popover-footer {
    border-top: 1px solid var(--outline-variant);
    margin-top: var(--space-3);
    padding-top: var(--space-3);
}

.driver-popover-navigation-btns button {
    font-family: var(--font-body);
    font-size: var(--text-sm);
    font-weight: 500;
    border-radius: var(--radius-default);
    padding: var(--space-1) var(--space-3);
    border: 1px solid var(--outline-variant);
    background: var(--surface-container-high);
    color: var(--on-surface);
    text-shadow: none;
}

.driver-popover-navigation-btns button:hover {
    background: var(--surface-bright);
}

.driver-popover-navigation-btns button:focus-visible {
    box-shadow: var(--shadow-focus);
    outline: none;
}

/* The "next/done" button is the primary CTA of each step. driver.js
   marks the last step's next button with data-disabled-state, but the
   stable class is the same; we promote the last button via :last-child. */
.driver-popover-navigation-btns button:last-of-type {
    background: var(--primary-container);
    border-color: var(--primary-container);
    color: var(--on-primary-container, var(--on-surface));
}

.driver-popover-navigation-btns button:last-of-type:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: var(--on-primary, var(--surface));
}

.driver-popover-btn-disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

/* Arrow ----------------------------------------------------------------- */
.driver-popover-arrow-side-bottom.driver-popover-arrow {
    border-top-color: var(--surface-container-highest);
}
.driver-popover-arrow-side-top.driver-popover-arrow {
    border-bottom-color: var(--surface-container-highest);
}
.driver-popover-arrow-side-left.driver-popover-arrow {
    border-right-color: var(--surface-container-highest);
}
.driver-popover-arrow-side-right.driver-popover-arrow {
    border-left-color: var(--surface-container-highest);
}

/* Welcome modal lead paragraph — reuses .modal-overlay/.modal from
   styles.css; this only tunes the lead copy spacing. */
.tour-welcome__lede {
    color: var(--on-surface-variant);
    font-size: var(--text-md);
    line-height: 1.5;
    margin: 0;
}

.tour-welcome__hint {
    color: var(--on-surface-variant);
    font-size: var(--text-sm);
    margin-top: var(--space-3);
    margin-bottom: 0;
}
