/* Affordable Freedom — Personal Hub */

:root {
    --bg-page: #ebe7df;
    --bg-hub: #f7f5f0;
    --bg-card: #ffffff;
    --text: #17212b;
    --text-muted: #5a636c;
    --accent: #557a36;
    --accent-soft: rgba(85, 122, 54, 0.13);
    --border: rgba(23, 33, 43, 0.1);
    --border-strong: rgba(23, 33, 43, 0.14);
    --shadow: 0 1px 2px rgba(23, 33, 43, 0.045), 0 6px 18px rgba(23, 33, 43, 0.06);
    --shadow-hover: 0 4px 12px rgba(23, 33, 43, 0.08), 0 12px 28px rgba(23, 33, 43, 0.09);
    --shadow-photo: 0 2px 6px rgba(23, 33, 43, 0.06), 0 8px 20px rgba(23, 33, 43, 0.07);
    --radius: 18px;
    --hub-max: 480px;
    --space: 20px;
    --focus: 0 0 0 3px rgba(85, 122, 54, 0.35);
    --font: "DM Sans", "Segoe UI", sans-serif;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: var(--font);
    font-optical-sizing: auto;
    color: var(--text);
    background: var(--bg-page);
    line-height: 1.5;
}

img,
svg {
    display: block;
    max-width: 100%;
}

a {
    color: inherit;
}

code {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 0.92em;
}

.skip-link {
    position: absolute;
    left: -9999px;
    top: 0;
    z-index: 100;
    padding: 0.75rem 1rem;
    background: var(--text);
    color: #fff;
    text-decoration: none;
    border-radius: 0 0 8px 0;
}

.skip-link:focus {
    left: 0;
    outline: none;
    box-shadow: var(--focus);
}

.page {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    padding: 22px var(--space) 36px;
}

.hub {
    width: 100%;
    max-width: var(--hub-max);
    background: var(--bg-hub);
    border: 1px solid var(--border);
    border-radius: 28px;
    box-shadow: var(--shadow);
    padding: 24px 20px 20px;
}

.hub:focus {
    outline: none;
}

.hub--simple {
    padding-top: 28px;
}

/* Profile */

.profile {
    text-align: center;
    margin-bottom: 32px;
}

.profile__photo-wrap {
    width: 108px;
    height: 108px;
    margin: 0 auto 12px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.95);
    background: #fff;
    overflow: hidden;
    box-shadow:
        0 0 0 1px var(--border-strong),
        var(--shadow-photo);
}

.profile__photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.profile__name {
    margin: 0 0 5px;
    font-size: clamp(1.9rem, 5.4vw, 2.2rem);
    font-weight: 700;
    letter-spacing: -0.035em;
    line-height: 1.08;
}

.profile__meta {
    margin: 0 0 10px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.07em;
    color: var(--text-muted);
}

.profile__divider {
    display: none;
}

.profile__statement {
    margin: 0 auto;
    max-width: 21.5rem;
    font-size: 1.03rem;
    line-height: 1.45;
    color: var(--text);
    font-weight: 400;
}

.accent {
    color: var(--accent);
    font-weight: 600;
}

/* Reusable UK residency eligibility pill */
.eligibility-pill {
    display: flex;
    justify-content: center;
    margin: 0;
}

.eligibility-pill__badge {
    display: inline-flex;
    align-items: center;
    gap: 0.45em;
    margin: 0;
    padding: 0.38em 0.9em;
    border-radius: 999px;
    background: var(--accent-soft);
    border: 1px solid rgba(85, 122, 54, 0.28);
    color: #3f5c28;
    font-size: 0.8rem;
    font-weight: 500;
    line-height: 1.25;
    letter-spacing: 0.01em;
    white-space: nowrap;
}

.eligibility-pill__flag {
    display: inline-flex;
    align-items: center;
    line-height: 1;
    flex-shrink: 0;
}

.eligibility-pill__flag svg {
    display: block;
    width: 1.05em;
    height: 0.7em;
    border-radius: 1px;
}

.eligibility-pill__label {
    color: inherit;
}

.profile > .eligibility-pill {
    margin-top: 32px;
}

/* Action cards */

.actions {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* Worldwide divider + LiveGood card */
.actions--worldwide {
    margin-top: 32px;
    gap: 24px;
}

.action-card {
    display: grid;
    grid-template-columns: 48px 1fr 18px;
    align-items: center;
    gap: 14px;
    min-height: 92px;
    padding: 18px 16px 18px 17px;
    background: var(--bg-card);
    border: 1px solid var(--border-strong);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    text-decoration: none;
    transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
    -webkit-tap-highlight-color: transparent;
}

.action-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
    border-color: rgba(23, 33, 43, 0.18);
}

.action-card:active {
    transform: translateY(0);
    box-shadow: var(--shadow);
}

.action-card:focus {
    outline: none;
}

.action-card:focus-visible {
    box-shadow: var(--shadow-hover), var(--focus);
    border-color: var(--accent);
}

.action-card__icon {
    width: 48px;
    height: 48px;
    border-radius: 13px;
    background: var(--accent-soft);
    color: var(--accent);
    display: grid;
    place-items: center;
    flex-shrink: 0;
}

.action-card__icon svg {
    width: 24px;
    height: 24px;
}

.action-card__body {
    display: flex;
    flex-direction: column;
    gap: 5px;
    min-width: 0;
}

.action-card__title {
    font-size: 1.0625rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.25;
    color: var(--text);
}

.action-card__desc {
    font-size: 0.9rem;
    line-height: 1.45;
    color: var(--text-muted);
    font-weight: 400;
}

.action-card__chevron {
    color: #8a939c;
    align-self: center;
}

.action-card__chevron svg {
    width: 18px;
    height: 18px;
}

/* Social */

.connect {
    margin-top: 32px;
    text-align: center;
}

.connect__heading {
    margin: 0 0 16px;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.connect__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    gap: 16px;
}

.social-btn {
    width: 58px;
    height: 58px;
    border-radius: 50%;
    border: 1px solid var(--border-strong);
    background: var(--bg-card);
    color: var(--text);
    display: grid;
    place-items: center;
    text-decoration: none;
    box-shadow: var(--shadow);
    transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.social-btn svg {
    width: 24px;
    height: 24px;
    display: block;
}

.social-btn:hover {
    transform: translateY(-3px) scale(1.03);
    color: var(--text);
    background: #fff;
    border-color: rgba(23, 33, 43, 0.2);
    box-shadow: 0 6px 16px rgba(23, 33, 43, 0.1), 0 14px 28px rgba(23, 33, 43, 0.1);
}

.social-btn:active {
    transform: translateY(-1px) scale(1.01);
}

.social-btn:focus {
    outline: none;
}

.social-btn:focus-visible {
    color: var(--text);
    background: #fff;
    box-shadow: 0 6px 16px rgba(23, 33, 43, 0.1), 0 14px 28px rgba(23, 33, 43, 0.1), var(--focus);
    border-color: var(--accent);
}

.social-btn.is-placeholder {
    opacity: 0.78;
}

/* Footer */

.footer {
    margin-top: 18px;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.78rem;
}

.footer__line,
.footer__copy {
    margin: 0;
}

.footer__line {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.45rem;
    flex-wrap: wrap;
}

.footer__line a {
    color: var(--text-muted);
    text-decoration: none;
    border-bottom: 1px solid transparent;
}

.footer__line a:hover,
.footer__line a:focus-visible {
    color: var(--accent);
    border-bottom-color: currentColor;
    outline: none;
}

.footer__portal {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 0;
    border-bottom-color: transparent;
}

.footer__portal svg {
    width: 15px;
    height: 15px;
    display: block;
}

.footer__portal:hover,
.footer__portal:focus-visible {
    border-bottom-color: transparent;
}

.footer__copy {
    margin-top: 5px;
}

.footer__dot {
    opacity: 0.6;
}

/* Simple inner pages */

.simple-header {
    margin-bottom: 22px;
}

.simple-header__eyebrow {
    margin: 0 0 12px;
    font-size: 0.9rem;
}

.simple-header__eyebrow a {
    color: var(--text-muted);
    text-decoration: none;
}

.simple-header__eyebrow a:hover,
.simple-header__eyebrow a:focus-visible {
    color: var(--accent);
    outline: none;
}

.simple-header__title {
    margin: 0;
    font-size: 1.75rem;
    letter-spacing: -0.03em;
}

.simple-content {
    background: var(--bg-card);
    border: 1px solid var(--border-strong);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 22px 20px;
}

.simple-content p {
    margin: 0 0 1rem;
    color: var(--text-muted);
    font-size: 0.98rem;
}

.simple-content p:last-child {
    margin-bottom: 0;
}

/* Coming soon stubs */

.soon {
    text-align: center;
    padding: 12px 0 8px;
}

.soon__title {
    margin: 0 0 8px;
    font-size: 1.35rem;
    letter-spacing: -0.02em;
}

.soon__text {
    margin: 0;
    color: var(--text-muted);
}

/* Desktop: keep hub centred and mobile-like */

@media (min-width: 640px) {
    .page {
        padding: 44px 24px 56px;
        align-items: center;
    }

    .hub {
        padding: 30px 28px 24px;
    }

    .profile__name {
        font-size: 2.2rem;
    }

    .action-card {
        padding: 19px 18px 19px 18px;
    }

    .action-card__title {
        font-size: 1.1rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .action-card,
    .social-btn {
        transition: none;
    }

    .action-card:hover,
    .social-btn:hover {
        transform: none;
    }

    .social-btn:active {
        transform: none;
    }
}

/* Cookie consent — small fixed banner, site colours */

.cookie-banner {
    position: fixed;
    left: 12px;
    right: 12px;
    bottom: 12px;
    z-index: 80;
    max-width: 520px;
    margin: 0 auto;
    pointer-events: none;
}

.cookie-banner:not([hidden]) {
    pointer-events: auto;
}

.cookie-banner__inner {
    background: var(--bg-card);
    border: 1px solid var(--border-strong);
    border-radius: var(--radius);
    box-shadow: var(--shadow-hover);
    padding: 14px 16px 16px;
}

.cookie-banner__text {
    margin: 0 0 12px;
    color: var(--text-muted);
    font-size: 0.86rem;
    line-height: 1.5;
}

.cookie-banner__text a {
    color: var(--accent);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.cookie-banner__text a:hover,
.cookie-banner__text a:focus-visible {
    color: var(--text);
    outline: none;
}

.cookie-banner__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.cookie-banner__btn {
    appearance: none;
    border: 1px solid transparent;
    border-radius: 10px;
    font: inherit;
    font-size: 0.84rem;
    font-weight: 600;
    line-height: 1.2;
    padding: 0.55rem 0.85rem;
    cursor: pointer;
    transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.cookie-banner__btn:focus-visible {
    outline: none;
    box-shadow: var(--focus);
}

.cookie-banner__btn--primary {
    background: var(--accent);
    color: #fff;
}

.cookie-banner__btn--primary:hover {
    background: #4c6b31;
}

.cookie-banner__btn--secondary {
    background: var(--bg-hub);
    color: var(--text);
    border-color: var(--border-strong);
}

.cookie-banner__btn--secondary:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.cookie-banner__btn--text {
    background: transparent;
    color: var(--text-muted);
    padding-left: 0.35rem;
    padding-right: 0.35rem;
}

.cookie-banner__btn--text:hover {
    color: var(--accent);
}

.cookie-banner__option {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    margin: 0 0 12px;
    color: var(--text-muted);
    font-size: 0.86rem;
    line-height: 1.45;
    cursor: pointer;
}

.cookie-banner__option input {
    margin-top: 3px;
    accent-color: var(--accent);
}

.cookie-banner__option strong {
    display: block;
    color: var(--text);
    font-weight: 600;
    margin-bottom: 2px;
}

.cookie-banner__prefs[hidden],
.cookie-banner__main[hidden] {
    display: none;
}

@media (max-width: 480px) {
    .cookie-banner {
        left: 8px;
        right: 8px;
        bottom: 8px;
    }

    .cookie-banner__btn--primary,
    .cookie-banner__btn--secondary {
        flex: 1 1 auto;
        text-align: center;
    }
}
