/* Geometry verbatim from the Figma welcome layout (1896:25510): desktop =
 * neutral shell around a white top-card; mobile = single white card. */

.root {
    /* No consumer global border-box reset — without this, .mobile's 20px
     * padding + 1px border (same element) would grow past the slot width. */
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    height: 470px;
    background: var(--color-bg-neutral-light);
    /* No border on the desktop shell: the top-card fills it edge-to-edge, so a
     * shell border renders as a double outline 1px inside the card's own.
     * In Figma the two borders coincide. */
    border-radius: var(--border-radius-sm);
}

.topCard {
    box-sizing: border-box;
    display: flex;
    flex: 1 0 0;
    flex-direction: column;
    justify-content: space-between;
    min-height: 1px;
    padding: 20px;
    background: var(--color-bg-base-light);
    border: 1px solid var(--border-color-light);
    border-radius: var(--border-radius-sm);
    box-shadow: 0 12px 10px -5px rgba(0, 0, 0, 0.04);
}

.mobile {
    height: auto;
    gap: 24px;
    padding: 20px;
    background: var(--color-bg-base-light);
    border: 1px solid var(--border-color-light);
    /* box-shadow, not filter: a filter here makes the card a filter root, so
     * the tooltip (which paints above/outside the card) would reshape the
     * card's shadow and get its own shadow double-filtered — same reason
     * .topCard uses box-shadow. */
    box-shadow: 0 12px 5px rgba(0, 0, 0, 0.04);
}

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

.titleRow {
    /* Tooltip anchor — the bubble positions against the row (card-bounded),
     * not the icon, so it cannot overflow the viewport on narrow screens. */
    position: relative;
    display: flex;
    align-items: center;
    gap: 12px;
}

.title {
    margin: 0;
    font-family: var(--font-default), sans-serif;
    font-weight: var(--font-weight-regular);
    font-size: 24px;
    line-height: 1.1;
    letter-spacing: -0.96px;
    font-feature-settings: 'case';
    color: var(--color-text-primary);
}

.mobile .title {
    font-size: 20px;
    letter-spacing: -0.6px;
}

.infoButton {
    display: inline-flex;
    margin: 0;
    padding: 0;
    border: none;
    background: none;
    color: inherit;
    cursor: pointer;
}

.infoIcon {
    width: 24px;
    height: 24px;
}

/* Tooltip per the DS Tooltip component (Side=Bottom, Size=Big — Figma
 * I1923:36022;1888:16354): white bubble, 12px pad/radius, 12px centered text,
 * 16x8 tail below, drop-shadow 0 20px 12.5px / 0 8px 5px rgba(0,0,0,.1).
 * CSS-driven on hover/focus-within so it also opens on tap (button focus). */
.tooltip {
    position: absolute;
    bottom: calc(100% + 4px);
    /* Centered on the info icon but clamped inside the row (card-bounded, so
     * never past the viewport) — measured on open in LabsWelcomeCard.tsx. */
    left: var(--bubble-left, 0);
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    /* 340px = DS Tooltip Size=Big; keep in sync with TOOLTIP_MAX_WIDTH in the TSX. */
    width: min(340px, 100%);
    filter: drop-shadow(0 20px 12.5px rgba(0, 0, 0, 0.1)) drop-shadow(0 8px 5px rgba(0, 0, 0, 0.1));
}

.tooltipContent {
    width: 100%;
    padding: 12px;
    background: var(--color-bg-base-light);
    border-radius: var(--border-radius-sm);
    font-family: var(--font-default), sans-serif;
    font-size: 12px;
    line-height: 1.35;
    letter-spacing: -0.12px;
    text-align: center;
    color: var(--color-text-primary);
}

.tooltipTail {
    display: block;
    width: 16px;
    height: 8px;
    /* Tail tracks the icon center (--tail-x, measured relative to the bubble's
     * clamped position); falls back to the bubble's center pre-measurement. */
    margin-left: calc(var(--tail-x, 50%) - 8px);
}

.subtitle {
    margin: 0;
    font-family: var(--font-default), sans-serif;
    font-size: 14px;
    line-height: 1.35;
    letter-spacing: -0.28px;
    color: var(--color-neutral-400);
}

.cells {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.mobile .cells {
    gap: 16px;
}

.cell {
    display: flex;
    align-items: center;
    gap: 14px;
}

.cellImage {
    width: 40px;
    height: 40px;
    border-radius: 6px;
    object-fit: cover;
    filter: drop-shadow(0 9px 6.75px rgba(0, 0, 0, 0.1));
}

.mobile .cellImage {
    width: 36px;
    height: 36px;
}

.cellCopy {
    display: flex;
    flex: 1 0 0;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.cellTitle {
    font-family: var(--font-default), sans-serif;
    font-size: 16px;
    line-height: 1.35;
    letter-spacing: -0.32px;
    color: var(--color-text-primary);
}

.mobile .cellTitle {
    font-size: 14px;
    letter-spacing: -0.28px;
}

.cellSubtitle {
    font-family: var(--font-default), sans-serif;
    font-size: 12px;
    line-height: 1.35;
    letter-spacing: -0.12px;
    color: var(--color-neutral-300);
}

.buttons {
    display: flex;
    gap: 12px;
    width: 100%;
}

.primaryButton,
.secondaryButton {
    display: flex;
    flex: 1 0 0;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-width: 0;
    height: 48px;
    padding: 0 16px;
    border: none;
    border-radius: var(--border-radius-xs);
    background: none;
    font-family: var(--font-decorative), monospace;
    font-size: 14px;
    line-height: 1;
    letter-spacing: 1.4px;
    text-transform: uppercase;
    color: var(--color-text-primary);
    cursor: pointer;
}

.primaryButton {
    background: var(--color-indigo-200);
}

.mobile .primaryButton,
.mobile .secondaryButton {
    height: 40px;
    border-radius: 4px;
    font-size: 12px;
    letter-spacing: 1.2px;
}

.buttonIcon {
    width: 20px;
    height: 20px;
}

.mobile .buttonIcon {
    width: 16px;
    height: 16px;
}

.divider {
    width: 100%;
    margin: 0;
    border: none;
    border-top: 1px solid var(--border-color-light);
}
