/*
Theme Name: Henrique Mauri
Theme URI: https://henriquemauri.net
Author: Henrique Mauri
Description: Tema autoral do blog henriquemauri.net: .NET, Azure e IA aplicada a negócios.
Version: 1.0.0
Requires at least: 6.6
Requires PHP: 8.0
License: GNU General Public License v2 or later
Text Domain: henriquemauri
*/

/* ---------- Base ---------- */
body { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility; }
::selection { background: #512BD4; color: #fff; }
a { text-underline-offset: .18em; text-decoration-thickness: 1px; }
img { height: auto; }
.hm-grad { background: linear-gradient(90deg, #00D4FF 0%, #A78BFF 100%); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* ---------- Header ---------- */
.hm-header { position: sticky; top: 0; z-index: 50; background: rgba(11, 9, 30, .92); backdrop-filter: saturate(160%) blur(14px); -webkit-backdrop-filter: saturate(160%) blur(14px); border-bottom: 1px solid rgba(255,255,255,.07); padding: 0 var(--wp--preset--spacing--40); }
.admin-bar .hm-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .hm-header { top: 46px; } }
.hm-header-inner { min-height: 68px; gap: 24px; }
.hm-brand { gap: 12px; align-items: center; }
.hm-logo { margin: 0; }
.hm-logo a { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 11px; background: linear-gradient(135deg, #512BD4, #00B8E6); color: #fff !important; font-weight: 800; font-size: 15px; letter-spacing: -.02em; text-decoration: none; box-shadow: 0 6px 18px rgba(81,43,212,.45); }
.hm-header .wp-block-site-title { margin: 0; font-size: 1.05rem; font-weight: 750; letter-spacing: -.01em; }
.hm-header .wp-block-site-title a { color: #fff; text-decoration: none; }
.hm-header .wp-block-navigation { font-size: .92rem; font-weight: 600; gap: 26px; }
.hm-header .wp-block-navigation a { color: rgba(255,255,255,.74); text-decoration: none; transition: color .15s; }
.hm-header .wp-block-navigation a:hover { color: #fff; }
.hm-header .wp-block-navigation__responsive-container.is-menu-open { background: #0B091E !important; color: #fff; }
.hm-header .wp-block-navigation__responsive-container-open svg, .hm-header .wp-block-navigation__responsive-container-close svg { fill: #fff; }
.hm-header-right { gap: 22px; align-items: center; }
.hm-social .wp-social-link { color: rgba(255,255,255,.7); }
.hm-social .wp-social-link:hover { color: #fff; transform: none; }
@media (max-width: 900px) { .hm-header .hm-social { display: none; } }

/* ---------- Hero (home) ---------- */
.hm-hero { position: relative; overflow: hidden; color: #fff; background: radial-gradient(60% 80% at 85% 0%, rgba(81,43,212,.55) 0%, rgba(81,43,212,0) 70%), radial-gradient(40% 60% at 0% 100%, rgba(0,184,230,.25) 0%, rgba(0,184,230,0) 70%), #0B091E; padding: clamp(3.5rem, 8vw, 6.5rem) var(--wp--preset--spacing--40) clamp(4rem, 9vw, 7rem) !important; margin-top: 0 !important; }
.hm-hero::before { content: ""; position: absolute; inset: 0; background-image: linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px); background-size: 56px 56px; mask-image: linear-gradient(90deg, transparent 10%, #000 70%); -webkit-mask-image: linear-gradient(90deg, transparent 10%, #000 70%); pointer-events: none; }
.hm-hero > * { position: relative; }
.hm-hero-cols { gap: clamp(2rem, 5vw, 4.5rem) !important; align-items: center !important; }
.hm-pill { display: inline-flex; align-items: center; gap: 10px; margin: 0 0 22px; padding: 7px 14px; border: 1px solid rgba(0,212,255,.45); border-radius: 999px; background: rgba(255,255,255,.05); color: #C8F0FF; font-family: var(--wp--preset--font-family--mono); font-size: .75rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; }
.hm-pill::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #00D4FF; box-shadow: 0 0 10px #00D4FF; }
.hm-hero h1 { color: #fff; font-size: clamp(2.4rem, 4.6vw, 3.9rem); line-height: 1.06; letter-spacing: -.035em; margin: 0 0 22px; }
.hm-hero .hm-lead { color: #CDC6F0; font-size: clamp(1.05rem, 1.4vw, 1.2rem); line-height: 1.7; max-width: 600px; margin: 0 0 32px; }
.hm-hero .wp-block-buttons { gap: 12px; }
.hm-btn-primary .wp-block-button__link { background: linear-gradient(135deg, #6A42F5, #512BD4); color: #fff; border-radius: 999px; padding: 14px 26px; font-weight: 700; font-size: .98rem; box-shadow: 0 10px 30px rgba(81,43,212,.45); transition: transform .15s, box-shadow .15s; }
.hm-btn-primary .wp-block-button__link:hover { transform: translateY(-2px); box-shadow: 0 14px 36px rgba(81,43,212,.6); }
.hm-btn-ghost .wp-block-button__link { background: transparent; color: #fff; border: 1px solid rgba(255,255,255,.28); border-radius: 999px; padding: 13px 24px; font-weight: 700; font-size: .98rem; transition: background .15s, border-color .15s; }
.hm-btn-ghost .wp-block-button__link:hover { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.5); }
.hm-stats { gap: 34px !important; margin-top: 44px !important; }
.hm-stat { margin: 0; color: #9F98C9; font-size: .85rem; line-height: 1.35; }
.hm-stat strong { display: block; color: #fff; font-size: 1.7rem; font-weight: 800; letter-spacing: -.02em; }
.hm-badge-card { position: relative; padding: 34px 28px !important; border: 1px solid rgba(255,255,255,.12); border-radius: 24px; background: linear-gradient(160deg, rgba(255,255,255,.09), rgba(255,255,255,.02)); backdrop-filter: blur(10px); box-shadow: 0 30px 80px rgba(0,0,0,.45); text-align: center; }
.hm-badge-card img { max-width: 150px; border-radius: 10px; filter: drop-shadow(0 12px 30px rgba(0,120,212,.45)); }
.hm-badge-card .hm-badge-title { color: #fff; font-size: 1.15rem; font-weight: 800; margin: 18px 0 6px; }
.hm-badge-card .hm-badge-sub { color: #A9A2D6; font-size: .9rem; margin: 0; }
.paged .hm-hero { display: none; }

/* ---------- Section headings ---------- */
.hm-section { padding: clamp(3.5rem, 7vw, 5.5rem) var(--wp--preset--spacing--40) !important; margin-top: 0 !important; }
.hm-eyebrow { margin: 0 0 8px; color: #512BD4; font-family: var(--wp--preset--font-family--mono); font-size: .78rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; }
.hm-section-title { margin: 0 0 36px !important; font-size: clamp(1.8rem, 3vw, 2.4rem); }

/* ---------- Post cards ---------- */
.hm-posts .wp-block-post-template { gap: 28px; }
.hm-card { height: 100%; display: flex; flex-direction: column; background: #fff; border: 1px solid #ECEBF3; border-radius: 20px; overflow: hidden; transition: transform .2s ease, box-shadow .2s ease, border-color .2s; }
.hm-card:hover { transform: translateY(-4px); border-color: #DCD5FA; box-shadow: 0 22px 50px -18px rgba(81,43,212,.35); }
.hm-card .wp-block-post-featured-image { margin: 0; overflow: hidden; }
.hm-card .wp-block-post-featured-image img { width: 100%; aspect-ratio: 2 / 1; object-fit: cover; transition: transform .4s ease; }
.hm-card:hover .wp-block-post-featured-image img { transform: scale(1.03); }
.hm-card-body { flex: 1; display: flex; flex-direction: column; gap: 10px; padding: 20px 22px 24px; }
.hm-card-body > * { margin: 0 !important; }
.hm-kicker, .hm-kicker a { color: #512BD4; font-family: var(--wp--preset--font-family--mono); font-size: .72rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; text-decoration: none; }
.hm-kicker .wp-block-post-terms__separator { color: #B9B4D3; }
.hm-card .wp-block-post-title { font-size: 1.22rem; line-height: 1.3; letter-spacing: -.015em; }
.hm-card .wp-block-post-title a { color: #14121F; text-decoration: none; }
.hm-card .wp-block-post-title a:hover { color: #512BD4; }
.hm-card .wp-block-post-excerpt { color: #5B5873; font-size: .95rem; line-height: 1.6; }
.hm-card .wp-block-post-excerpt__excerpt { margin: 0; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.hm-card .wp-block-post-excerpt__more-text { display: none; }
.hm-meta { margin-top: auto !important; padding-top: 6px; color: #8B87A3; font-size: .82rem; }
@media (min-width: 900px) {
  .home:not(.paged) .hm-posts .wp-block-post-template > li:first-child { grid-column: 1 / -1; }
  .home:not(.paged) .hm-posts li:first-child .hm-card { display: grid; grid-template-columns: 1.25fr 1fr; align-items: stretch; }
  .home:not(.paged) .hm-posts li:first-child .wp-block-post-featured-image, .home:not(.paged) .hm-posts li:first-child .wp-block-post-featured-image a { height: 100%; }
  .home:not(.paged) .hm-posts li:first-child .wp-block-post-featured-image img { height: 100%; }
  .home:not(.paged) .hm-posts li:first-child .hm-card-body { justify-content: center; padding: 40px; gap: 14px; }
  .home:not(.paged) .hm-posts li:first-child .wp-block-post-title { font-size: 2rem; line-height: 1.15; }
  .home:not(.paged) .hm-posts li:first-child .wp-block-post-excerpt { font-size: 1.05rem; }
}
@media (min-width: 600px) and (max-width: 899px) { .hm-posts .wp-block-post-template.is-layout-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.wp-block-query-pagination { margin-top: 48px !important; gap: 8px; font-weight: 600; }
.wp-block-query-pagination a, .wp-block-query-pagination .current { display: inline-grid; place-items: center; min-width: 42px; height: 42px; padding: 0 14px; border: 1px solid #E4E2EE; border-radius: 999px; color: #14121F; text-decoration: none; }
.wp-block-query-pagination .current { background: #512BD4; border-color: #512BD4; color: #fff; }

/* ---------- Archive header ---------- */
.hm-archive-hero { background: radial-gradient(50% 120% at 90% 0%, rgba(81,43,212,.5), rgba(81,43,212,0) 70%), #0B091E; color: #fff; padding: clamp(3rem, 6vw, 4.5rem) var(--wp--preset--spacing--40) !important; margin-top: 0 !important; }
.hm-archive-hero h1 { color: #fff; margin: 0; font-size: clamp(2rem, 4vw, 3rem); }
.hm-archive-hero p { color: #CDC6F0; margin: 12px 0 0; }

/* ---------- Single ---------- */
.hm-progress { position: fixed; top: 0; left: 0; height: 3px; width: 100%; margin: 0 !important; z-index: 100; transform-origin: 0 50%; transform: scaleX(0); background: linear-gradient(90deg, #00D4FF, #7C5CFF); animation: hm-progress linear both; animation-timeline: scroll(root); }
@keyframes hm-progress { to { transform: scaleX(1); } }
.hm-post-head { background: radial-gradient(45% 90% at 100% 0%, rgba(81,43,212,.10), rgba(81,43,212,0) 70%), #F6F6FB; padding: clamp(3rem, 6vw, 4.5rem) var(--wp--preset--spacing--40) clamp(7rem, 12vw, 9rem) !important; margin-top: 0 !important; }
.hm-post-head .wp-block-post-title { font-size: clamp(2.1rem, 4.2vw, 3.3rem); line-height: 1.1; letter-spacing: -.035em; margin: 14px 0 22px; }
.hm-post-meta { gap: 14px; align-items: center; color: #5B5873; font-size: .92rem; }
.hm-post-meta > * { margin: 0 !important; }
.hm-post-meta .wp-block-avatar img { border-radius: 50%; border: 2px solid #fff; box-shadow: 0 4px 14px rgba(20,18,31,.15); }
.hm-post-meta .wp-block-post-author-name { color: #14121F; font-weight: 700; }
.hm-post-meta .wp-block-post-author-name a { color: inherit; text-decoration: none; }
.hm-dot { color: #B9B4D3; }
.hm-cover { margin-top: clamp(-6.5rem, -10vw, -5rem) !important; padding: 0 var(--wp--preset--spacing--40); }
.hm-cover .wp-block-post-featured-image img { border-radius: 22px; box-shadow: 0 40px 80px -30px rgba(20,18,31,.45); }
.hm-content { padding: clamp(2.5rem, 5vw, 3.5rem) var(--wp--preset--spacing--40) 0 !important; margin-top: 0 !important; }
.hm-content > p, .hm-content > ul, .hm-content > ol { font-size: 1.125rem; line-height: 1.85; color: #2A2738; }
.hm-content > h2 { margin-top: 2.6em; margin-bottom: .6em; font-size: clamp(1.55rem, 2.4vw, 1.95rem); letter-spacing: -.025em; }
.hm-content > h3 { margin-top: 2em; font-size: 1.35rem; }
.hm-content li { margin-bottom: .45em; }
.hm-content li::marker { color: #512BD4; font-weight: 700; }
.hm-content :where(p, li) > code { padding: .15em .45em; border-radius: 6px; background: #F1EEFC; color: #4A25C9; font-size: .88em; }
.hm-content a:not(.wp-block-button__link) { color: #512BD4; text-decoration: underline; text-decoration-color: rgba(81,43,212,.35); }
.hm-content a:not(.wp-block-button__link):hover { text-decoration-color: #512BD4; }
.hm-content .wp-block-quote { margin: 2.2em 0; padding: 26px 30px; border: 0; border-left: 4px solid #512BD4; border-radius: 4px 16px 16px 4px; background: linear-gradient(135deg, #F3F0FF, #F7FBFF); }
.hm-content .wp-block-quote p { margin: 0; font-size: 1.3rem; line-height: 1.5; color: #14121F; letter-spacing: -.01em; }
.hm-content .hcb_wrap { margin: 1.8em 0; }
.hm-content .hcb_wrap pre { border-radius: 14px; font-family: var(--wp--preset--font-family--mono) !important; }
.hm-content .wp-block-image img { border-radius: 14px; }
.hm-tags { gap: 8px; padding: 0 var(--wp--preset--spacing--40); margin-top: 40px !important; }
.hm-tags a { display: inline-block; padding: 6px 14px; border: 1px solid #E4E2EE; border-radius: 999px; background: #fff; color: #5B5873; font-size: .82rem; font-weight: 600; text-decoration: none; transition: all .15s; }
.hm-tags a:hover { border-color: #512BD4; color: #512BD4; }
.hm-tags .wp-block-post-terms__separator { display: none; }
.hm-author { margin-top: 56px !important; padding: 32px !important; border-radius: 22px; background: radial-gradient(60% 120% at 100% 0%, rgba(81,43,212,.55), rgba(81,43,212,0) 70%), #0B091E; color: #fff; gap: 22px; }
.hm-author .wp-block-avatar img { border-radius: 50%; border: 3px solid rgba(255,255,255,.15); }
.hm-author h3 { color: #fff; margin: 0 0 6px; font-size: 1.25rem; }
.hm-author p { color: #CDC6F0; margin: 0 0 16px; font-size: .98rem; line-height: 1.65; }
.hm-author .wp-block-buttons { gap: 10px; }
.hm-author .wp-block-button__link { padding: 9px 18px; font-size: .88rem; }
.hm-comments { margin-top: 56px !important; padding: 0 var(--wp--preset--spacing--40); }
.hm-comments .wp-block-comments-title { font-size: 1.5rem; }
.hm-comments textarea, .hm-comments input[type=text], .hm-comments input[type=email], .hm-comments input[type=url] { border: 1px solid #DEDCEA; border-radius: 12px; padding: 12px 14px; font: inherit; }
.hm-comments input[type=submit] { background: #512BD4; color: #fff; border: 0; border-radius: 999px; padding: 12px 24px; font-weight: 700; cursor: pointer; }

/* ---------- CTA ---------- */
.hm-cta { margin-top: 0 !important; padding: 0 var(--wp--preset--spacing--40) clamp(3.5rem, 7vw, 5.5rem) !important; }
.hm-cta-box { padding: clamp(2rem, 5vw, 3.5rem) !important; border-radius: 28px; background: radial-gradient(50% 120% at 100% 0%, rgba(0,184,230,.35), rgba(0,184,230,0) 70%), radial-gradient(60% 120% at 0% 100%, rgba(81,43,212,.7), rgba(81,43,212,0) 70%), #0B091E; color: #fff; gap: 28px; }
.hm-cta-box h2 { color: #fff; margin: 0 0 10px; font-size: clamp(1.6rem, 3vw, 2.2rem); }
.hm-cta-box p { color: #CDC6F0; margin: 0; font-size: 1.05rem; }

/* ---------- Footer ---------- */
.hm-footer { background: #0B091E; color: #A9A2D6; padding: clamp(3rem, 6vw, 4.5rem) var(--wp--preset--spacing--40) 32px !important; margin-top: 0 !important; font-size: .95rem; }
.hm-footer h4 { color: #fff; font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; font-family: var(--wp--preset--font-family--mono); margin: 0 0 14px; }
.hm-footer a { color: #CDC6F0; text-decoration: none; }
.hm-footer a:hover { color: #fff; }
.hm-footer .hm-foot-brand { color: #fff; font-weight: 800; font-size: 1.15rem; margin: 0 0 10px; }
.hm-footer ul { list-style: none; padding: 0; margin: 0; }
.hm-footer li { margin: 0 0 8px; }
.hm-footer .hm-mvp img { max-width: 64px; margin-top: 14px; }
.hm-footer-bottom { margin-top: 44px !important; padding-top: 22px; border-top: 1px solid rgba(255,255,255,.08); font-size: .85rem; color: #7D77A8; }
.hm-footer-bottom p { margin: 0; }

/* ---------- Misc ---------- */
.wp-block-search__input { border-radius: 999px; border-color: #DEDCEA; padding: 12px 18px; }
.wp-block-search__button { border-radius: 999px; background: #512BD4; color: #fff; padding: 0 22px; }
