/* Door-specific layout only; every colour and font comes from the design-system tokens. */

* {
    box-sizing: border-box;
}

/* The backdrop comes from .clyffe-backdrop in the design system; this rule owns the door's
   layout only. */
.door-body {
    margin: 0;
    min-height: 100vh;
    font-family: var(--font-body);
    font-weight: 300;
    color: var(--ink);
    display: flex;
    align-items: center;
    justify-content: center;
}

.door-main {
    width: 100%;
    display: flex;
    justify-content: center;
    padding: 24px;
}

.door-card {
    background: var(--white);
    border: 1px solid var(--navy-08);
    border-radius: 8px;
    padding: 48px 40px;
    width: 100%;
    max-width: 420px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

/* The sign-up screen (epic #1548 decision 2) is wider than sign-in: the tagline, the offer and three
   tiles side by side. */
.door-card-wide {
    max-width: 600px;
    padding: 40px 44px;
    gap: var(--space-3);
}

/* The card and the quiet line under it, centred together on the backdrop. */
.door-stack {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-3);
}

.door-heading {
    font-family: var(--font-display);
    font-weight: 300;
    font-size: 30px;
    line-height: 1.2;
    color: var(--ink);
    margin: 0;
    text-wrap: balance;
}

.door-lede {
    font-size: 15px;
    line-height: 1.6;
    color: var(--ink-65);
    margin: 0 0 16px;
}

/* The business a claim link is for (#1675) and the one tagline (#1715), under the sign-up heading;
   the card's gap spaces them. */
.door-business,
.door-tagline {
    margin: 0;
}

.door-choices {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.door-provider {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    height: 48px;
    padding: 0 16px;
    border: 1px solid var(--navy-15);
    border-radius: 4px;
    background: var(--white);
    color: var(--ink);
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 14px;
    letter-spacing: 0.3px;
    text-decoration: none;
    transition: background-color var(--duration-micro) var(--ease-out), transform var(--duration-micro) var(--ease-out);
}

.door-provider:hover {
    background: var(--navy-05);
}

.door-provider:active {
    transform: scale(var(--press-scale));
}

.door-provider:focus-visible {
    outline: 2px solid var(--cove);
    outline-offset: 2px;
}

/* "Continue as" and "Use another account" on the sign-up screen of a signed-in browser (#1714). The
   primary carries the account name, so it wraps rather than truncating a long address. */
form .door-provider {
    width: 100%;
    cursor: pointer;
}

.door-provider-primary {
    height: auto;
    min-height: 48px;
    padding: 12px 16px;
    border-color: var(--action-primary);
    background: var(--action-primary);
    color: var(--action-primary-text);
    text-align: center;
    overflow-wrap: anywhere;
}

.door-provider-primary:hover {
    background: var(--navy-90);
}

.door-provider-mark {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.door-next {
    margin: 16px 0 0;
    font-size: 14px;
}

.door-link {
    color: var(--cove-text);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.door-offer {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    margin: 0;
    padding: 12px 14px;
    background: var(--parchment-50);
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: var(--weight-body-semibold);
    line-height: 1.5;
    color: var(--ink-90);
}

.door-offer svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    margin-top: 2px;
}

.door-tiles {
    margin: 0;
    padding: 0;
    list-style: none;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-2);
}

.door-tiles li {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    padding: 10px 10px 9px;
    border: 1px solid var(--navy-08);
    border-radius: var(--radius-sm);
    text-align: center;
}

.door-tiles svg {
    width: 18px;
    height: 18px;
    color: var(--cove);
    margin-bottom: 3px;
}

.door-tiles strong {
    font-weight: var(--weight-body-semibold);
    font-size: 13px;
    line-height: 1.4;
    color: var(--ink);
}

.door-tiles span {
    font-size: var(--text-caption-size);
    line-height: 1.4;
    color: var(--text-muted);
}

.door-legal {
    margin: 0;
    font-size: var(--text-caption-size);
    color: var(--ink-65);
    text-align: center;
}

.door-legal a {
    color: inherit;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.door-legal a:focus-visible {
    outline: 2px solid var(--cove);
    outline-offset: 2px;
}

/* A phone stacks the tiles as compact rows, the icon beside the title and its line: three columns
   of a few words each do not fit beside one another, and three tall centred boxes push the last
   one well below the fold. Every row takes the tallest row's height, so the three line up (#1715). */
@media (max-width: 600px) {
    .door-card-wide {
        padding: var(--space-4);
    }

    .door-tiles {
        grid-template-columns: 1fr;
        grid-auto-rows: 1fr;
        gap: 6px;
    }

    .door-tiles li {
        display: grid;
        grid-template-columns: auto 1fr;
        column-gap: 12px;
        row-gap: 0;
        align-items: start;
        align-content: center;
        padding: 9px 12px;
        text-align: left;
    }

    .door-tiles svg {
        grid-row: span 2;
        margin: 2px 0 0;
    }
}
