/* Give the trial form priority over the supporting feature list on narrow screens. */
.page-home .landing-hero-inner {
    grid-template-areas: "intro trial" "features trial";
    row-gap: 24px;
}
.page-home .hero-copy { grid-area: intro; align-self: end; min-width: 0; }
.page-home .instant-panel { grid-area: trial; min-width: 0; scroll-margin-top: 8rem; }
.page-home .hero-proof {
    grid-area: features;
    align-self: start;
    margin: 0;
    padding-top: 20px;
    border-top: 1px solid #ccdbe6;
}
.page-home .hero-proof span { font-size: 13px; color: #475d72; }
.page-home .trial-input-row .field { min-width: 0; }
.page-home #trial-preview { overflow-wrap: anywhere; }
.page-home .hero-copy h1, .page-home .public-hero h1 { text-wrap: balance; }
.page-home .public-content .public-card { display: flex; flex-direction: column; align-items: flex-start; }
.page-home .public-card > a { margin-top: auto; }

#mailbox-guide { background: #fff; padding: clamp(18px, 3vw, 36px); }
#mailbox-guide .guide-steps {
    padding-bottom: 16px;
    border-bottom: 1px solid var(--panel-border);
    column-gap: clamp(12px, 2vw, 28px);
}
#mailbox-guide .guide-purpose {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-content: start;
    align-items: center;
    gap: 4px 14px;
    padding: 18px;
    border-radius: 12px;
    min-height: 0;
}
#mailbox-guide .guide-purpose .feature-icon {
    display: grid;
    place-items: center;
    grid-row: span 2;
    width: 40px;
    height: 40px;
    margin: 0;
    border-radius: 11px;
    background: #eaf1ff;
    color: #2859ae;
}
#mailbox-guide .guide-purpose[data-guide-purpose="ordinary"] .feature-icon { background: #e7f5f0; color: #176c5c; }
#mailbox-guide .guide-purpose strong { font-size: 16px; line-height: 1.4; }
#mailbox-guide .guide-purpose strong, #mailbox-guide .guide-purpose span { overflow-wrap: anywhere; }
#mailbox-guide .guide-purpose:not(:disabled):hover { border-color: #7697c4; color: #203b61; background: #f4f8ff; }
#mailbox-guide .guide-purpose[aria-pressed=true] { border-color: #285fe8; background: #eef4ff; }
#mailbox-guide .guide-choice { border-top: 1px solid var(--panel-border); padding-top: 20px; }
#mailbox-guide .guide-choice h3 { margin-top: 0; }
#mailbox-guide .guide-recommendation { border-left: 3px solid #5383ce; }
#mailbox-guide .guide-platforms button { overflow-wrap: anywhere; }

.mailbox-totals { margin-bottom: 18px; }
.mailbox-totals .stat-card::before { display: none; }
.mailbox-totals .stat-card { padding: 16px 20px; }
.mailbox-totals .stat { line-height: 1.15; font-variant-numeric: tabular-nums; }
.mailbox-totals .stat-card:last-child { background: #eff7f4; border-color: #cce4da; }
.mailbox-totals .stat-card:last-child .stat { color: #166954; }
.mailbox-list tbody td { vertical-align: top; }
.mailbox-list .date-cell { width: clamp(10rem, 18vw, 14rem); }
.mailbox-list strong { overflow-wrap: anywhere; }
.mailbox-list .actions-cell { width: 32%; white-space: normal; }
.mailbox-list .row-actions { flex-wrap: wrap; gap: 6px; }
.mailbox-list .row-actions > a.button:first-child { color: #174888; background: #edf4ff; border-color: #c9dcf3; }
.mailbox-renewal { display: grid; justify-items: start; gap: 2px; margin-block: 6px; text-align: start; white-space: normal; }
.mailbox-renewal details { max-width: 100%; }
.mailbox-renewal summary { color: #24559a; font-size: 13px; padding-block: 3px; cursor: pointer; }
.mailbox-renewal .renewal-fields {
    display: grid;
    gap: 8px;
    width: min(100%, 15rem);
    margin-block: 4px 8px;
    padding: 10px;
    background: #f3f7fc;
    border-radius: 8px;
}
.renewal-fields :is(input, select, button) { min-width: 0; width: 100%; white-space: normal; }
.renewal-fields .visually-hidden {
    position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap;
}

@media (max-width: 760px) {
    .page-home .landing-hero-inner { grid-template-areas: "intro" "trial" "features"; padding: 24px 16px; gap: 22px; }
    .page-home .hero-copy h1 { margin: 14px 0 12px; font-size: clamp(30px, 7vw, 38px); }
    .page-home .hero-actions { margin-top: 16px; }
    .page-home .hero-proof div { grid-template-columns: minmax(5rem, 30%) 1fr; }
    .page-home .instant-panel { scroll-margin-top: 11rem; }
    .page-home .trial-form :is(input, select), #mailbox-guide .field :is(input, select) { font-size: 16px; }
    .page-home .public-content .public-actions { gap: 8px; margin-top: 20px; }
    #mailbox-guide .guide-steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
    #mailbox-guide .guide-steps li { flex-direction: column; align-items: flex-start; gap: 5px; line-height: 1.4; overflow-wrap: anywhere; }
    .mailbox-totals ~ .table-card .section-head > .pill { align-self: flex-start; }
    .grid.mailbox-totals { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 7px; }
    .mailbox-totals .stat-card { padding: 13px 10px; }
    .mailbox-totals .stat-label { font-size: 12px; overflow-wrap: anywhere; }
    .mailbox-totals .stat { font-size: 24px; }
    .table-scroll table.mailbox-list, .card .mailbox-list tbody {
        display: block; min-width: 0; width: 100%; white-space: normal;
    }
    .card .mailbox-list thead { position: absolute; width: 1px; height: 1px; min-width: 0; overflow: hidden; clip-path: inset(50%); }
    .mailbox-list tbody tr {
        display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px 14px; padding: 16px; border-top: 1px solid var(--panel-border);
    }
    .mailbox-list tbody td { grid-column: 1 / -1; width: auto; min-width: 0; padding: 0; border: 0; text-align: start; white-space: normal; }
    .mailbox-list tbody td.number-cell { grid-column: span 1; }
    .mailbox-list td[data-mobile-label]::before { content: attr(data-mobile-label); display: block; color: #546579; font-size: 12px; }
    .mailbox-list .actions-cell .row-actions { justify-content: flex-start; }
    .mailbox-list .row-actions > :is(.button, button, form.inline) { width: auto; max-width: 100%; }
    .mailbox-list .row-actions :is(button, .button) { white-space: normal; min-height: 42px; }
    .mailbox-renewal summary { padding-block: 8px; }
    .mailbox-renewal :is(input, select) { font-size: 16px; }
}

/* Main actions share a blue emphasis; secondary and destructive actions stay distinct. */
.page-home .hero-actions .button, .page-home #trial-submit,
#mailbox-guide .guide-primary, .mailbox-list .row-actions a.button {
    transition: background-color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.page-home .hero-actions .button:active, .page-home #trial-submit:enabled:active,
#mailbox-guide button:enabled:active, .mailbox-list .row-actions a.button:active {
    transform: translateY(1px);
}
.page-home #check-demo:focus-visible { outline: 3px solid #4e76c2; outline-offset: 3px; }
.page-home .instant-panel-head {
    background: linear-gradient(110deg, #eff6ff, #fbfdfd);
    border-radius: 18px 18px 0 0;
}
#mailbox-guide .guide-choice > h3 { scroll-margin-block-start: 7.5rem; }
#mailbox-guide .guide-choice > h3:focus { outline: none; }
#mailbox-guide .guide-purpose[aria-pressed=true] .feature-icon { color: #fff; background: #285fc1; }
#mailbox-guide .guide-platforms button[aria-pressed=true] { background: #214fa8; color: white; border-color: #214fa8; }
.mailbox-list .mailbox-address-link {
    display: inline-block; color: #204876; font-weight: 700; overflow-wrap: anywhere;
    text-decoration: underline; text-underline-offset: .2em; text-decoration-color: #b5cbe3;
}
.mailbox-list .mailbox-address-link:hover { color: #153f97; text-decoration-color: currentColor; }
.mailbox-list .row-actions > a.button:first-child { background: #2559b5; border-color: #2559b5; color: #fff; }
.mailbox-list .row-actions > a.button:first-child:hover { background: #1d4790; }
.mailbox-list .row-actions button.danger { background: #fff; border-color: #e4c9ca; color: #963b40; }
.mailbox-list .row-actions button.danger:hover { background: #fff1f1; border-color: #ce9397; }
.mailbox-renewal details[open] > summary { color: #183f74; font-weight: 700; }
@media (max-width: 720px) {
    #mailbox-guide .guide-choice > h3, .page-home #check-demo { scroll-margin-block-start: 16px; }
    .mailbox-list .mailbox-address-link { padding-block: 6px; }
}
@media (prefers-reduced-motion: no-preference) {
    html:has(.page-home) { scroll-behavior: smooth; }
}

.receiving-head .guide-disclosure { margin: 0; }
.received-mail-list .message-title-link { color: #204876; font-weight: 650; }
.received-mail-list .message-title-link:hover { text-decoration: underline; }
@media (max-width: 720px) {
    .receiving-head { gap: 10px; }
    .receiving-head .mailbox-renewal { display: flex; flex-wrap: wrap; gap: 4px 16px; margin: 0; }
    .table-scroll .received-mail-list, .card .received-mail-list tbody {
        display: block; width: 100%; min-width: 0; white-space: normal;
    }
    .card .received-mail-list thead { position: absolute; height: 1px; width: 1px; min-width: 0; overflow: hidden; clip-path: inset(50%); }
    .received-mail-list tbody tr {
        display: grid; min-width: 0; padding: 16px; gap: 4px; border-top: 1px solid var(--panel-border);
    }
    .received-mail-list tbody td { min-width: 0; padding: 0; border: 0; white-space: normal; overflow-wrap: anywhere; }
    .received-mail-list td:first-child { color: var(--muted); font-size: 12px; }
    .received-mail-list .message-subject { margin-block: 3px; }
    .received-mail-list .message-preview { white-space: normal; line-height: 1.5; }
    .received-mail-list .row-actions > :is(.button, form.inline) { width: auto; }
}


#mailbox-guide .guide-basic-platform { grid-template-columns: minmax(0, 1fr); }
#mailbox-guide .guide-popular-platforms h4, #guide-all-heading { margin: 16px 0 4px; }
#mailbox-guide .guide-popular-platforms .guide-platforms { margin: 4px 0 12px; max-height: none; overflow: visible; }
#mailbox-guide .guide-popular-platforms button { min-height: 44px; padding: 7px 10px; }
#guide-all-heading + .guide-platforms { margin-top: 8px; }
