/* Portal discovery replaces the home dashboard completely. */
.nav>.desktop-links{order:1;margin-left:auto}.nav>.site-search{order:2}.nav>.manage{order:3}
.desktop-links a[aria-current=page]{color:var(--wine);text-decoration:underline;text-underline-offset:8px;text-decoration-thickness:2px}
.page-home .portal-hero{display:grid;grid-template-columns:.95fr 1.1fr;align-items:center;gap:40px;padding:30px 0 20px}
.portal-hero h1{font:600 clamp(2.4rem,4vw,3.4rem)/1.08 var(--serif);color:var(--wine);letter-spacing:-.035em;max-width:17ch;margin:10px 0 20px}
.portal-hero-copy>p:last-child{font-size:15px;line-height:1.75;max-width:45ch;margin:0;color:var(--muted)}
.portal-banner{display:block;height:260px;overflow:hidden;border-radius:14px;min-width:0;background:var(--beige)}
.portal-banner img{display:block;width:100%;height:100%;object-fit:cover;object-position:50% 64%}
.portal-search{margin:0 0 30px;max-width:790px}
.portal-search form{display:flex;align-items:center;gap:12px;background:var(--paper);border:1px solid #bfa5af;padding:7px;border-radius:12px}
.portal-search form:focus-within{border-color:var(--wine)}
.portal-search label{flex:1;min-width:0}.portal-search input{margin:0;border:0;min-height:44px;font-size:14px;background:transparent;padding:9px 12px}
.portal-search button{min-height:46px;min-width:110px;border-radius:8px}
.portal-search .search-results{max-height:450px;overflow:auto;padding-left:24px}
.portal-search .search-results p{font-size:13px;line-height:1.7}.portal-search .search-results li{margin:16px 0}
.portal-search .search-status:empty,.portal-search .search-results:empty{display:none}
.portal-search .search-status{font-size:13px;margin:14px 0 0;color:var(--wine)}
.portal-tools>h2,.portal-section-heading h2,.portal-faq>h2{font:600 29px/1.25 var(--serif);color:var(--wine);margin:0}
.portal-tools>h2{margin-bottom:20px}.portal-groups{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:20px;align-items:stretch}
.portal-tool-group{min-width:0;border:1px solid #ddc6c8;border-radius:12px;overflow:hidden;background:var(--paper);box-shadow:0 3px 12px #49304407}
.portal-tool-group>summary{display:flex;align-items:center;gap:10px;list-style:none;min-height:60px;padding:16px;font-size:15px;line-height:1.35;color:var(--plum);background:#f9e5e6;cursor:default}
.portal-tool-group>summary::-webkit-details-marker{display:none}.portal-tool-group>summary svg{width:24px;height:24px;flex:none;color:var(--wine)}
.portal-tool-group.group-birthday-age>summary{background:#eee6f4}.portal-tool-group.group-anniversary>summary{background:#f3e8d8}
.portal-tool-list{padding:0 12px 5px}
.portal-tool-link{display:flex;gap:14px;align-items:center;min-width:0;padding:17px 2px;text-decoration:none;border-bottom:1px solid var(--line);border-radius:2px;color:var(--ink)}
.portal-tool-link:last-child{border-bottom:0}.portal-tool-link:hover{background:#fbf3ef}.portal-tool-link:focus-visible{outline-offset:-2px;border-radius:7px}
.portal-tool-link>img{width:78px;height:86px;border-radius:8px;object-fit:cover;flex:none;background:var(--beige)}
.portal-tool-text{display:flex;flex-direction:column;gap:6px;min-width:0}.portal-tool-text>strong{font-size:14px;font-weight:650;line-height:1.4;color:var(--plum)}
.portal-tool-text>span:not(.portal-open){font-size:11px;line-height:1.6;color:var(--muted)}
.portal-tool-text .portal-open{font-size:10px;font-weight:650;color:var(--wine);line-height:1.4}
.portal-reading{margin-top:34px}.portal-section-heading{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:18px}
.portal-section-heading>a{font-size:11px;font-weight:650;min-height:44px;display:inline-flex;align-items:center;gap:8px;text-decoration:none}
.portal-reading-cards{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:20px}
.portal-reading-card{display:block;min-width:0;border:1px solid var(--line);background:var(--paper);border-radius:12px;overflow:hidden;color:var(--ink);text-decoration:none;box-shadow:0 3px 12px #49304404}
.portal-reading-card>img{display:block;width:100%;height:160px;object-fit:cover;background:var(--beige)}
.portal-reading-card>span{display:flex;flex-direction:column;gap:10px;padding:18px}
.portal-reading-card strong{font-size:15px;line-height:1.45;font-weight:650;color:var(--plum)}
.portal-reading-card>span>span:not(.portal-read-more){font-size:12px;line-height:1.7;color:var(--muted)}
.portal-read-more{font-size:10px;font-weight:650;color:var(--wine)}
.portal-reading-card:hover{border-color:#b990a0}
.portal-faq{margin:36px 0 48px;max-width:900px}.portal-faq>h2{margin-bottom:18px}.portal-faq details{border-top:1px solid var(--line)}
.portal-faq summary{font-size:14px;font-weight:600;min-height:52px;padding:15px 0;color:var(--plum)}
.portal-faq p{font-size:14px;line-height:1.8;max-width:75ch;margin:0 0 20px;padding-right:20px}
.saved-highlights .milestone-list{margin:0}.saved-highlights .milestone-list li:last-child{border-bottom:0}
.tool-faq-section{max-width:900px;margin-inline:auto}.tool-faq-section .tool-chapter{margin:0}
@media(min-width:769px){.portal-tool-group>summary{pointer-events:none}.portal-tool-group{height:100%}}
@media(min-width:769px) and (max-width:1050px){.nav{gap:16px}.nav .desktop-links{gap:18px}.page-home .portal-hero{gap:24px}.portal-hero h1{font-size:2.8rem}.portal-tool-link{gap:10px;align-items:start}.portal-tool-link>img{width:58px;height:68px}.portal-tool-text>strong{font-size:13px}.portal-tool-group>summary{font-size:13px;padding:14px;gap:8px}.portal-groups{gap:12px}.portal-tool-list{padding-inline:10px}}
@media(max-width:768px){
 .nav>.site-search{order:initial}.nav>.desktop-links,.nav>.manage{display:none}
 .page-home .portal-hero{display:flex;flex-direction:column;align-items:stretch;gap:18px;padding:24px 0 0}
 .portal-hero .eyebrow{display:none}.portal-hero h1{font-size:clamp(2rem,8vw,2.8rem);max-width:18ch;margin:0 0 14px;line-height:1.1}
 .portal-hero-copy>p:last-child{font-size:13px;line-height:1.7;max-width:none}
 .portal-banner{height:148px;border-radius:10px}.portal-banner img{object-position:50% 67%}
 .portal-search{margin:16px 0 28px;max-width:none}.portal-search form{gap:7px;padding:5px;border-radius:10px}.portal-search input{font-size:16px;min-height:46px;padding:9px 8px}.portal-search button{font-size:12px;padding:10px 13px;min-width:70px;min-height:46px}
 .portal-tools>h2,.portal-section-heading h2,.portal-faq>h2{font-size:24px}
 .portal-tools>h2{margin-bottom:16px}.portal-groups{display:flex;flex-direction:column;gap:10px}
 .portal-tool-group{box-shadow:none;border:0;border-radius:10px}.portal-tool-group>summary{min-height:58px;padding:15px 16px;font-size:14px;cursor:pointer}
 .portal-tool-group>summary:after{content:"⌄";margin-left:auto;font-size:20px}.portal-tool-group[open]>summary:after{content:"⌃"}
 .portal-tool-group>summary svg{width:23px;height:23px}.portal-tool-list{padding:0 12px 4px;border:1px solid var(--line);border-top:0;border-radius:0 0 10px 10px}
 .portal-tool-link{padding:16px 2px;gap:14px;min-height:115px}.portal-tool-link>img{width:76px;height:80px}.portal-tool-text>strong{font-size:14px}.portal-tool-text>span:not(.portal-open){font-size:12px;line-height:1.6}.portal-tool-text .portal-open{font-size:11px}
 .portal-reading{margin-top:28px}.portal-section-heading{gap:10px;margin-bottom:15px}.portal-section-heading>a{font-size:10px;gap:4px;flex-shrink:0}
 .portal-reading-cards{display:flex;flex-direction:column;gap:12px}
 .portal-reading-card{display:grid;grid-template-columns:96px minmax(0,1fr);gap:13px;padding:12px;border-radius:10px}
 .portal-reading-card>img{width:96px;height:112px;border-radius:7px;align-self:start}.portal-reading-card>span{padding:2px 0;gap:7px}
 .portal-reading-card strong{font-size:14px;line-height:1.4}.portal-reading-card>span>span:not(.portal-read-more){font-size:11px;line-height:1.55}.portal-read-more{font-size:10px}
 .portal-faq{margin:28px 0 34px}.portal-faq summary{font-size:14px;min-height:52px;padding:14px 0}.portal-faq p{font-size:14px;padding-right:0}
 .tool-faq-section{margin-block:28px}.tool-faq-section .tool-chapter>h2{font-size:25px}
}
@media(max-width:360px){.portal-hero h1{font-size:1.9rem}.portal-banner{height:132px}.portal-search form{gap:3px}.portal-search input{font-size:15px}.portal-search button{min-width:64px;padding-inline:10px}.portal-reading-card{grid-template-columns:80px minmax(0,1fr);gap:12px}.portal-reading-card>img{width:80px;height:110px}.portal-section-heading h2{font-size:22px}.portal-tool-text>span:not(.portal-open){font-size:11px}}
@media print{.portal-tool-group:not([open])>.portal-tool-list{display:block}.portal-groups{display:block}.portal-tool-group{break-inside:avoid;margin-bottom:20px}}

/* Search-only layout */
.site-search form,.portal-search form{flex-wrap:wrap}.site-search form label,.portal-search form label{flex:1 1 180px;min-width:0}.site-search input{width:100%;box-sizing:border-box}.search-results{list-style:none;padding:0!important;max-height:60vh;overflow:auto;overflow-wrap:anywhere}.search-results li{padding:10px 4px;border-bottom:1px solid #d9c7ce}.search-results a{font-weight:650}.search-results p{margin:5px 0;font-size:14px}.search-results .search-group{font-size:16px;font-weight:700;background:#f4e9ed;position:sticky;top:0}.search-results mark{background:#ffe4a5;color:#38231f}.site-search{max-width:calc(100vw - 24px)}.site-search form button,.portal-search form button{min-width:60px}.search-results+button[hidden]{display:none}

/* Reading cards without an optional photo use the full text column. */
.portal-reading-card:not(:has(>img)){grid-template-columns:minmax(0,1fr)}

/* Shared footer: scoped to preserve all page and tool layouts. */
.site-footer{background:#f4ede4;border-top:1px solid #d9c9bc;margin-top:48px;color:#352b35}
.site-footer .footer-grid{display:grid;grid-template-columns:1.25fr 1fr .85fr 1fr;gap:36px;padding:44px 0 28px;align-items:start}
.site-footer .footer-grid>*{min-width:0}
.site-footer .brand{display:inline-flex;gap:10px;align-items:center;font-size:22px;color:#69384d;min-height:44px}
.site-footer .brand-icon{width:28px;flex-shrink:0}.site-footer .brand-icon svg{width:28px;height:32px}
.site-footer h2{font-family:"Segoe UI",Arial,sans-serif;font-size:15px;line-height:1.5;color:#512d45;margin:10px 0 14px;font-weight:700}
.site-footer p{font-family:"Segoe UI",Arial,sans-serif;font-size:14px;line-height:1.75;margin:12px 0 0;color:#61515b}
.site-footer .footer-tagline{font-family:var(--serif);font-size:18px;line-height:1.5;color:#69384d;margin-top:14px;max-width:26ch}
.site-footer .footer-column{display:block}.site-footer ul{list-style:none;margin:0;padding:0}
.site-footer li{margin:0;padding:0}.site-footer .footer-column a{display:flex;align-items:center;min-height:44px;padding:5px 0;font-size:14px;line-height:1.5;color:#512d45;overflow-wrap:anywhere;text-decoration:none}
.site-footer a:hover{color:#753149;text-decoration:underline;text-underline-offset:4px}.site-footer a:focus-visible{outline:2px solid #753149;outline-offset:4px;border-radius:3px}
.site-footer .footer-privacy{border-top:1px solid #d9c9bc;border-bottom:1px solid #d9c9bc;padding:20px 0 22px}
.site-footer .footer-privacy h2{margin:0 0 6px}.site-footer .footer-privacy p{margin:0;max-width:85ch}
.site-footer .footer-bottom{display:flex;justify-content:space-between;flex-wrap:wrap;gap:8px 24px;padding:20px 0 28px}
.site-footer .footer-bottom p{font-size:12px;margin:0}
@media(max-width:1100px){.site-footer .footer-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:28px 44px}.site-footer .footer-introduction p{max-width:40ch}}
@media(max-width:620px){.site-footer{margin-top:32px}.site-footer .footer-grid{grid-template-columns:minmax(0,1fr);gap:24px;padding-top:28px}.site-footer h2{margin-top:0;margin-bottom:10px}.site-footer .footer-column a{min-height:44px}.site-footer .footer-bottom{flex-direction:column;padding-bottom:28px}}
