diff --git a/app/Http/Controllers/PortalServicesController.php b/app/Http/Controllers/PortalServicesController.php index 99fa1b3c..136eaebe 100644 --- a/app/Http/Controllers/PortalServicesController.php +++ b/app/Http/Controllers/PortalServicesController.php @@ -126,7 +126,7 @@ class PortalServicesController extends Controller 'r.source_url', 'r.language', 'r.version_label', 'r.document_group_id', 'r.territorial_scope', 'r.territory_id', 'r.source_confirmation', 'r.legal_status', 'r.rights_status', 'r.last_reviewed_at', 'r.last_reviewed_by', 'r.independent_review', 'r.metadata_version', 'r.source_reference', 'r.essential', 'd.file_name', 'd.media_type', 'd.size_bytes', 'd.issuer', 'd.issued_on', 'd.valid_until', 'd.version_no', - ])->paginate(5)->withQueryString(); + ])->paginate(3)->withQueryString(); $pageResult->getCollection()->transform(fn ($resource) => app(PublicDocumentPresentation::class)->resource($resource)); $props['resources'] = $pageResult; app(PublicSearchMetrics::class)->candidate($request, 'documents', $pageResult->total(), $filters); diff --git a/resources/css/app.css b/resources/css/app.css index 76527569..97738aee 100644 --- a/resources/css/app.css +++ b/resources/css/app.css @@ -69,10 +69,10 @@ gap: 0.35rem; font-size: 0.875rem; line-height: 1.25rem; - color: #e2e8f0; + color: #fff; transition: - color 0.2s, - transform 0.2s; + color 0.3s ease, + transform 0.3s ease; } .tempo-footer-link > svg { align-self: center; @@ -80,18 +80,18 @@ flex-shrink: 0; } .tempo-footer-link:hover { - color: #fb7185; + color: #ef4444; transform: translateX(3px); } .tempo-contact-link { display: flex; align-items: center; - gap: 0.75rem; + gap: 1rem; min-height: 40px; - transition: color 0.2s; + transition: color 0.3s ease; } .tempo-contact-link:hover { - color: #fb7185; + color: #ef4444; } .tempo-contact-icon { display: flex; @@ -100,9 +100,16 @@ flex-shrink: 0; align-items: center; justify-content: center; - border: 1px solid #ffffff12; - border-radius: 0.65rem; - background: #ffffff08; + border: 1px solid rgba(255, 255, 255, 0.05); + border-radius: 0.75rem; + background: rgba(255, 255, 255, 0.03); + transition: + background-color 0.3s ease, + border-color 0.3s ease; +} +.tempo-contact-link:hover .tempo-contact-icon { + background: #dc2626; + border-color: #dc2626; } .tempo-footer-social { display: flex; @@ -110,13 +117,15 @@ height: 44px; align-items: center; justify-content: center; - border: 1px solid #ffffff15; - border-radius: 0.65rem; + border: 1px solid rgba(255, 255, 255, 0.05); + border-radius: 0.75rem; + background: rgba(255, 255, 255, 0.03); color: #fff; transition: - color 0.2s, - border-color 0.2s, - transform 0.2s; + color 0.3s ease, + border-color 0.3s ease, + transform 0.3s ease, + background-color 0.3s ease; } .tempo-footer [aria-label='Redes sociais da Revista Tempo'] { gap: 0.75rem; @@ -206,7 +215,7 @@ } :root { - --background: oklch(1 0 0); + --background: #d8e2db; --foreground: oklch(0.145 0 0); --card: oklch(1 0 0); --card-foreground: oklch(0.145 0 0); @@ -242,7 +251,7 @@ } .dark { - --background: oklch(0.145 0 0); + --background: #0d302a; --foreground: oklch(0.985 0 0); --card: oklch(0.145 0 0); --card-foreground: oklch(0.985 0 0); diff --git a/resources/css/tempo-header.css b/resources/css/tempo-header.css index ddb0fb79..eede9ca7 100644 --- a/resources/css/tempo-header.css +++ b/resources/css/tempo-header.css @@ -1,21 +1,41 @@ /* Presentation choice for Tempo's 21/10/2026 request: one shared navigation. */ .tempo-header { - position: sticky; + position: fixed; top: 0; + right: 0; + left: 0; z-index: 40; - background: #090909; + background: rgba(0, 0, 0, 0.95); color: #fff; - border-bottom: 1px solid #ffffff14; + border-bottom: 1px solid transparent; + -webkit-backdrop-filter: blur(12px); + backdrop-filter: blur(12px); + box-shadow: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1); + transition: all 0.5s ease; +} +.tempo-header[data-home]:not([data-scrolled]):not([data-expanded]) { + background: transparent; + -webkit-backdrop-filter: none; + backdrop-filter: none; + box-shadow: none; +} +.tempo-header[data-scrolled], +.tempo-header[data-expanded] { + background: rgba(0, 0, 0, 0.95); + -webkit-backdrop-filter: blur(12px); + backdrop-filter: blur(12px); + box-shadow: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1); } .tempo-header-inner { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; - grid-template-rows: 71px; + grid-template-rows: 72px; align-items: center; column-gap: 0.5rem; - max-width: 1600px; + max-width: 1440px; margin-inline: auto; padding-inline: 0.75rem; + transition: grid-template-rows 0.28s ease; } .tempo-logo-link { grid-area: 1 / 1; @@ -24,6 +44,10 @@ width: 112px; max-width: 100%; border-radius: 0.25rem; + transition: opacity 0.2s ease; +} +.tempo-logo-link:hover { + opacity: 0.92; } .tempo-header-logo { width: 100%; @@ -45,28 +69,34 @@ display: flex; align-items: center; justify-content: space-between; - gap: 0.4rem; + gap: 0.35rem; width: 100%; - min-height: 44px; - padding: 0.5rem 0.75rem; + min-height: 40px; + padding: 0.375rem 0.625rem; + border: 0; border-radius: 0.5rem; + background: transparent; color: #e2e8f0; - font-size: 1rem; - line-height: 1.5; + font: inherit; + font-size: 0.9375rem; + line-height: 1.4; font-weight: 600; white-space: nowrap; + cursor: pointer; + appearance: none; transition: - color 0.2s, - background 0.2s; + color 0.2s ease, + background-color 0.2s ease, + box-shadow 0.2s ease; } .tempo-nav-trigger:hover, .tempo-nav-trigger[data-state='open'] { - background: #ffffff0d; + background: rgba(255, 255, 255, 0.08); color: #fff; } .tempo-nav-trigger[data-current-group] { color: #fff; - background: #ffffff08; + background: rgba(255, 255, 255, 0.05); box-shadow: inset 0 -2px #ed1c24; } .tempo-nav-trigger > svg { @@ -93,14 +123,18 @@ display: flex; align-items: center; gap: 0.4rem; - min-height: 44px; - padding: 0.4rem; + min-height: 40px; + padding: 0.35rem 0.4rem; border-radius: 0.5rem; color: #e2e8f0; font-size: 0.8125rem; + transition: + background-color 0.2s ease, + color 0.2s ease; } .tempo-utility-button:hover { - background: #ffffff10; + background: rgba(255, 255, 255, 0.08); + color: #fff; } .tempo-header-actions { grid-area: 1 / 2; @@ -112,22 +146,23 @@ .tempo-login-button { display: inline-flex; align-items: center; - gap: 0.5rem; - min-height: 44px; - padding: 0.5rem 0.625rem; - border: 1px solid #ffffff40; + gap: 0.45rem; + min-height: 40px; + padding: 0.4rem 0.625rem; + border: 1px solid rgba(255, 255, 255, 0.22); border-radius: 0.5rem; color: #fff; - font-size: 0.875rem; + font-size: 0.8125rem; font-weight: 600; white-space: nowrap; transition: - background 0.2s, - border-color 0.2s; + background-color 0.2s ease, + border-color 0.2s ease, + color 0.2s ease; } .tempo-login-button:hover { - background: #ffffff10; - border-color: #ffffff80; + background: rgba(255, 255, 255, 0.08); + border-color: rgba(255, 255, 255, 0.4); } .tempo-login-button > span { max-width: clamp(2rem, calc(100vw - 18rem), 6rem); @@ -137,14 +172,17 @@ display: inline-flex; align-items: center; justify-content: center; - width: 44px; - height: 44px; + width: 40px; + height: 40px; flex-shrink: 0; border-radius: 0.5rem; color: #e2e8f0; + transition: + background-color 0.2s ease, + color 0.2s ease; } .tempo-panel-summary:hover { - background: #ffffff10; + background: rgba(255, 255, 255, 0.08); color: #fff; } .tempo-panel-count { @@ -166,10 +204,10 @@ grid-area: 4 / 1 / auto / -1; align-items: center; justify-content: center; - gap: 0.5rem; - min-height: 44px; - margin-bottom: 1rem; - padding: 0.5rem 0.875rem; + gap: 0.45rem; + min-height: 40px; + margin-bottom: 0.875rem; + padding: 0.45rem 0.8rem; border: 1px solid #ed1c24; border-radius: 0.5rem; background: #ed1c24; @@ -177,26 +215,34 @@ font-size: 0.8125rem; font-weight: 600; white-space: nowrap; - transition: background 0.2s; + transition: + background-color 0.2s ease, + border-color 0.2s ease, + transform 0.2s ease; } .tempo-interest-button:hover { background: #c9151c; + border-color: #c9151c; } .tempo-header-toggle { grid-area: 1 / 3; display: inline-flex; align-items: center; justify-content: center; - width: 44px; - height: 44px; - border: 1px solid #ffffff33; + width: 40px; + height: 40px; + border: 1px solid rgba(255, 255, 255, 0.2); border-radius: 0.5rem; color: #fff; cursor: pointer; + transition: + background-color 0.2s ease, + border-color 0.2s ease; } .tempo-header-toggle:hover, .tempo-header-toggle[aria-expanded='true'] { - background: #ffffff10; + background: rgba(255, 255, 255, 0.08); + border-color: rgba(255, 255, 255, 0.32); } .tempo-header[data-expanded] .tempo-primary-navigation { display: block; @@ -221,7 +267,7 @@ .tempo-header-inner { grid-template-columns: minmax(0, 1fr) auto auto auto; column-gap: 0.75rem; - padding-inline: 1.5rem; + padding-inline: 1.25rem; } .tempo-logo-link { width: 132px; @@ -237,13 +283,13 @@ } @media (min-width: 1280px) { .tempo-header-inner { - grid-template-rows: minmax(71px, auto); + grid-template-rows: minmax(72px, auto); grid-template-columns: auto minmax(0, 1fr) auto auto auto; - column-gap: 0.25rem; + column-gap: 0.375rem; padding-inline: 1.25rem; } .tempo-logo-link { - width: 100px; + width: 120px; } .tempo-login-button > span { max-width: 3rem; @@ -260,13 +306,14 @@ display: flex; flex-wrap: wrap; align-items: center; - gap: 0; + gap: 0.125rem; } .tempo-nav-trigger { justify-content: center; - padding-inline: 0.25rem; - font-size: 1.125rem; - letter-spacing: 0.025em; + min-height: 40px; + padding: 0.375rem 0.5rem; + font-size: 0.9375rem; + letter-spacing: 0.01em; } .tempo-header-extras, .tempo-header[data-expanded] .tempo-header-extras { @@ -274,7 +321,7 @@ grid-area: 1 / 3; padding: 0 0.5rem 0 0; border: 0; - border-right: 1px solid #ffffff1a; + border-right: 1px solid rgba(255, 255, 255, 0.1); } .tempo-header-utilities { flex-wrap: nowrap; @@ -291,12 +338,12 @@ } @media (min-width: 1440px) { .tempo-header-inner { - column-gap: 0.75rem; - padding-inline: 2rem; + column-gap: 0.5rem; + padding-inline: 1.5rem; } .tempo-nav-trigger { - padding-inline: 0.375rem; - font-size: 1.125rem; + padding-inline: 0.625rem; + font-size: 1rem; } .tempo-logo-link { width: 132px; @@ -316,7 +363,7 @@ column-gap: 1rem; } .tempo-nav-trigger { - padding-inline: 0.75rem; + padding-inline: 0.875rem; } .tempo-login-button > span { max-width: 6rem; diff --git a/resources/js/components/country-select.tsx b/resources/js/components/country-select.tsx index 50732e4d..5b0c344b 100644 --- a/resources/js/components/country-select.tsx +++ b/resources/js/components/country-select.tsx @@ -9,6 +9,7 @@ export default function CountrySelect({ label = 'País', required = false, error, + className, }: { countries: Country[]; value: string; @@ -19,6 +20,7 @@ export default function CountrySelect({ required?: boolean; allowLegacyValue?: boolean; error?: string; + className?: string; }) { return ( ); } diff --git a/resources/js/components/portal-grouped-menu.tsx b/resources/js/components/portal-grouped-menu.tsx index 89115673..fdb187ca 100644 --- a/resources/js/components/portal-grouped-menu.tsx +++ b/resources/js/components/portal-grouped-menu.tsx @@ -88,11 +88,19 @@ export function PortalGroupedMenu() { const currentItem = currentNavigationItem(groups, url); const [loggingOut, setLoggingOut] = useState(false); const [expanded, setExpanded] = useState(false); + const [scrolled, setScrolled] = useState(false); const navigationId = useId(); const toolsId = useId(); const interestId = useId(); const toggle = useRef(null); + const isHome = url.split('?')[0] === '/'; useEffect(() => router.on('navigate', () => setExpanded(false)), []); + useEffect(() => { + const onScroll = () => setScrolled(window.scrollY > 30); + onScroll(); + window.addEventListener('scroll', onScroll, { passive: true }); + return () => window.removeEventListener('scroll', onScroll); + }, []); const items = (children: PortalNavItem[]) => children.map((item) => item.children ? ( @@ -150,12 +158,15 @@ export function PortalGroupedMenu() { 'administration', ].includes(group.id), ); + const workGroup = groups.find((group) => group.id === 'work'); const institutionalCurrent = url.split('?')[0] === '/contacto'; return (
{ if ( event.key === 'Escape' && @@ -265,76 +276,48 @@ export function PortalGroupedMenu() {
  • - - - Mais - - - - - {t('Revista Tempo')} - - - {[['/contacto', 'Contacto']].map( - ([href, label]) => ( - - - {t(label)} - - - ), - )} - {groups - .filter((group) => group.id === 'work') - .map((group) => ( - - - - {t(group.label)} - - {items(group.children ?? [])} - - ))} - - + + {t('Revista Tempo')} +
  • + {workGroup?.children?.length ? ( +
  • + + + {t('Mais')} + + + + {t(workGroup.label)} + + {items(workGroup.children ?? [])} + + +
  • + ) : null}
    diff --git a/resources/js/components/portal-hero.tsx b/resources/js/components/portal-hero.tsx index 6f3004e0..db65dccc 100644 --- a/resources/js/components/portal-hero.tsx +++ b/resources/js/components/portal-hero.tsx @@ -16,7 +16,7 @@ const slides = [ const heroTitle = 'INVISTA EM MOÇAMBIQUE'; const heroSubtitle = - 'Transforme informação em decisões e ideias em negócios reais.'; + 'O seu próximo investimento começa aqui.'; const typingStart = 250; const titleStep = 50; const subtitleStep = 28; @@ -198,11 +198,11 @@ export default function PortalHero({ ))}