/* Home. Desktop: presentation on the left, product cards in two columns on the right.
   Phone: a link page, the product cards come right after the name. */
.home .page-content { padding-bottom: var(--space-16); }

.home p { max-width: 38rem; color: var(--muted); font-size: var(--font-lg); line-height: 1.65; }
.home p + p { margin-top: var(--space-4); }
.home p a:not(.button) { color: var(--accent); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .2em; }
.home p a:not(.button):hover { color: var(--link-hover); text-decoration-thickness: 2px; }

.hub { display: grid; grid-template-columns: 19rem minmax(0, 1fr); grid-template-areas: "head links" "more links"; grid-template-rows: auto auto; column-gap: clamp(var(--space-10), 7vw, 7rem); align-content: center; min-height: calc(100svh - var(--header-height)); padding-block: var(--space-6) var(--space-12); }
.hub-head { grid-area: head; }
.hub-more { grid-area: more; }
.links { grid-area: links; align-self: start; margin-top: var(--space-4); }

.avatar { width: 144px; height: 144px; border-radius: var(--radius-full); object-fit: cover; box-shadow: 0 0 0 6px var(--background), 0 0 0 7px var(--line); }
.hub h1 { margin-top: var(--space-6); font-size: 2.5rem; font-weight: 600; line-height: 1.1; letter-spacing: -.015em; }
.home .hub-role { margin-top: var(--space-1); font-size: var(--font-lg); }
.home .hub-intro { margin-top: var(--space-5); color: var(--text); font-size: var(--font-lg); line-height: 1.6; }

/* Profiles: one compact row of icons instead of a tall list. */
.social { display: flex; flex-wrap: wrap; gap: var(--space-2); margin: var(--space-4) 0 0; padding: 0; list-style: none; }
.social a { display: grid; place-items: center; width: 2.75rem; height: 2.75rem; border-radius: var(--radius-full); color: var(--muted); background: var(--background); border: var(--border-width) solid var(--line); transition: color var(--duration-fast), border-color var(--duration-fast), transform var(--duration-fast) var(--ease-interface); }
.social a:hover { color: var(--accent); border-color: var(--accent); transform: translateY(-2px); }
.social svg { width: 20px; height: 20px; fill: currentColor; stroke: none; }

/* Product cards: two columns read left to right, in the same order as on the phone.
 */
.links { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-4); margin: 0; padding: 0; list-style: none; }
.links > li { display: flex; }
.link-card { display: flex; flex: 1; align-items: center; gap: var(--space-5); min-height: 7rem; padding: var(--space-5) var(--space-6); background: var(--surface); border: var(--border-width) solid var(--line); border-radius: var(--radius-large); transition: border-color var(--duration-fast), box-shadow var(--duration-normal), transform var(--duration-normal) var(--ease-interface); }
a.link-card:hover { border-color: var(--line-hover); box-shadow: 0 10px 24px -14px rgb(28 37 48 / 35%); transform: translateY(-2px); }
a.link-card:active { transform: translateY(0); }
.link-thumb { flex: 0 0 64px; width: 64px; height: 64px; border-radius: var(--radius-small); object-fit: cover; background: var(--panel); }
.link-thumb-start { object-position: left center; }
.link-thumb-logo { padding: 6px; object-fit: contain; background: var(--surface); }
.link-text { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.link-text strong { color: var(--text); font-size: 1.25rem; font-weight: 600; line-height: 1.3; }
.link-text > span { color: var(--muted); font-size: var(--font-base); line-height: 1.45; }
.link-card-featured { border-color: rgb(11 100 119 / 45%); }
a.link-card-featured:hover { border-color: var(--accent); }
.link-card-soon { background: transparent; border-style: dashed; border-color: var(--line-hover); }
.link-thumb-soon { display: grid; place-items: center; background: none; border: var(--border-width) dashed var(--line-hover); color: var(--muted); font-size: var(--font-xl); }

@media (max-width: 900px) {
    .hub { grid-template-columns: minmax(0, 1fr); grid-template-areas: "head" "links" "more"; grid-template-rows: none; row-gap: var(--space-5); align-content: start; min-height: 0; max-width: 34rem; margin-inline: auto; padding-block: var(--space-4) 0; }
    .hub-head { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; column-gap: var(--space-4); }
    .avatar { width: 76px; height: 76px; box-shadow: none; }
    .hub h1 { margin-top: 0; font-size: 1.625rem; }
    .home .hub-role { font-size: var(--font-base); }
    .social { margin-top: var(--space-2); gap: var(--space-1); }
    .social a { width: 2.5rem; height: 2.5rem; }
    .links { grid-template-columns: minmax(0, 1fr); gap: var(--space-3); }
    .link-card { min-height: 5.5rem; gap: var(--space-4); padding: var(--space-3) var(--space-4); }
    .link-thumb { flex-basis: 56px; width: 56px; height: 56px; }
    .link-text strong { font-size: var(--font-lg); }
    .link-text > span { font-size: var(--font-sm); }
    .home .hub-intro { margin-top: var(--space-2); font-size: var(--font-base); }
}

/* Sections */
.section { margin-top: var(--section-gap); }
.hub + .section { margin-top: var(--space-8); }
.section h2 { margin-bottom: var(--space-6); font-size: 2.25rem; font-weight: 600; line-height: 1.15; letter-spacing: -.01em; }
.actions { display: flex; flex-wrap: wrap; gap: var(--space-3); margin-block: var(--space-6); }
.home .actions + p { margin-top: 0; }

.project-card { display: grid; grid-template-columns: 13rem minmax(0, 1fr); gap: var(--space-6); align-items: start; }
.project-card + .project-card { margin-top: var(--space-8); }
.project-card > img { width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; border-radius: var(--radius-small); background: var(--panel); }
.project-card h3 { font-size: 1.375rem; font-weight: 600; line-height: 1.3; }
.home .project-card p { margin-top: var(--space-1); font-size: var(--font-lg); line-height: 1.6; }
.home .project-links { display: flex; flex-wrap: wrap; gap: 0 var(--space-5); margin-top: 0; }
.project-links a { display: inline-flex; align-items: center; min-height: var(--control-height); }

@media (max-width: 640px) {
    .home p { font-size: var(--font-base); }
    .project-card { grid-template-columns: 1fr; gap: var(--space-3); }
}

/* The name already opens the page, so the home header is just navigation and language. */
@media (max-width: 640px) {
    .home .header-inner { display: flex; flex-wrap: wrap; align-items: center; gap: 0 var(--space-4); padding-top: 0; }
    .home .header-inner { flex-wrap: nowrap; min-height: 3.5rem; }
    .home .main-nav { flex: 1; min-width: 0; flex-wrap: nowrap; justify-content: flex-start; gap: var(--space-3); overflow-x: auto; scrollbar-width: none; }
    .home .main-nav a { flex-shrink: 0; }
    .home .lang-switch button { min-width: 28px; }
    .home .main-nav a { font-size: var(--font-sm); padding-bottom: 0; }
    .home .main-nav a.active::after { bottom: 8px; }
}
@media (max-width: 360px) {
    .home .main-nav { gap: var(--space-2); }
    .home .main-nav a { font-size: .8125rem; }
    .avatar { width: 52px; height: 52px; }
    .link-card { gap: var(--space-3); }
    .link-thumb { flex-basis: 48px; width: 48px; height: 48px; }
    .link-text strong { font-size: var(--font-base); }
}

/* Background: soft off-white with a faint dot grid, and the mouse ripples (assets/js/ripple.js) behind everything. */
/* Two soft sea-green glows (top right, bottom left) fixed to the window, over a faint dot grid.
   A fixed layer instead of background-attachment: fixed, which phones handle badly. */
.home { background-color: var(--background); background-image: radial-gradient(rgb(28 37 48 / 7%) 1px, transparent 1.2px); background-size: 22px 22px; }
.home::before { content: ''; position: fixed; inset: 0; z-index: 0; pointer-events: none; background:
    radial-gradient(ellipse 70% 55% at 88% 0%, rgb(11 100 119 / 14%), transparent 70%),
    radial-gradient(ellipse 65% 60% at 6% 96%, rgb(11 100 119 / 17%), transparent 70%); }
.ripples { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 0; }
.home .site-header, .home .page-content { position: relative; z-index: 1; }
.home .site-header { background: transparent; }
