/* =============================================
   weInteract GP — Sign In Header Widget
   Inline icon + text. Renders both signed-in and
   signed-out variants; JS reveals one of them.
   Hidden by default; revealed once icon font ready
   (1s safety timeout).
   ============================================= */

.gp-signin-header {
    display: inline-flex;
    align-items: center;
    line-height: 1;
    opacity: 1;
    transition: opacity 0.2s ease;
    position: relative;
}

.gp-signin-header.is-loading {
    opacity: 0;
}

/* The [hidden] attribute must win over the display rules below. */
.gp-signin-header [hidden] {
    display: none !important;
}

.gp-signin-header__trigger {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    line-height: 1;
    color: inherit;
    cursor: pointer;
    transition: color 0.15s ease;
}

.gp-signin-header__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    transition: color 0.15s ease;
}

.gp-signin-header__icon svg {
    display: block;
}

.gp-signin-header__text {
    transition: color 0.15s ease;
}

.gp-signin-header__caret {
    display: inline-flex;
    align-items: center;
    transition: transform 0.15s ease;
}

.gp-signin-header__caret svg {
    width: 1em;
    height: 0.7em;
    display: block;
}

.gp-signin-header.is-open .gp-signin-header__caret {
    transform: rotate(180deg);
}

/* ----- Account dropdown ----- */

.gp-signin-header__account {
    position: relative;
    display: inline-flex;
}

.gp-signin-header__menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    min-width: 160px;
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.08);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    overflow: hidden;
    z-index: 1000;
}

.gp-signin-header__menu-item {
    display: block;
    padding: 10px 14px;
    background: transparent;
    color: inherit;
    text-decoration: none;
    font: inherit;
    line-height: 1.3;
    white-space: nowrap;
    transition: background-color 0.15s ease, color 0.15s ease;
}

@media (prefers-reduced-motion: reduce) {
    .gp-signin-header,
    .gp-signin-header__trigger,
    .gp-signin-header__icon,
    .gp-signin-header__text,
    .gp-signin-header__caret,
    .gp-signin-header__menu-item {
        transition: none;
    }
}
