/*
Theme Name: PixelSage AI
Theme URI: https://pixelsageai.com
Author: PixelSage AI
Author URI: https://pixelsageai.com
Description: Custom theme for PixelSage AI, a Melbourne studio for kids animation, websites, e-commerce, mobile apps and API projects. Fast, self-hosted fonts, SEO-ready markup, editable through Appearance > Customize.
Version: 1.0.0
Requires at least: 6.2
Tested up to: 6.5
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: pixelsage
*/

/* ---------- Fonts (self-hosted, SIL OFL) ---------- */
@font-face {
	font-family: "Bricolage Grotesque";
	src: url("assets/fonts/bricolage-grotesque-latin-wght-normal.woff2") format("woff2");
	font-weight: 200 800;
	font-style: normal;
	font-display: swap;
}
@font-face {
	font-family: "DM Sans";
	src: url("assets/fonts/dm-sans-latin-wght-normal.woff2") format("woff2");
	font-weight: 100 1000;
	font-style: normal;
	font-display: swap;
}
@font-face {
	font-family: "DM Sans";
	src: url("assets/fonts/dm-sans-latin-wght-italic.woff2") format("woff2");
	font-weight: 100 1000;
	font-style: italic;
	font-display: swap;
}

/* ---------- Tokens ---------- */
:root {
	--ps-navy: #15173A;
	--ps-navy-2: #22254D;
	--ps-navy-3: #2A2D5C;
	--ps-accent: #4B33E0;
	--ps-accent-soft: #E4DFFF;
	--ps-sun: #FFC83D;
	--ps-sun-soft: #FFE7A3;
	--ps-mint-soft: #CDEBD9;
	--ps-ground: #F5F6FB;
	--ps-white: #FFFFFF;
	--ps-ink: #15173A;
	--ps-muted: #4A4D6A;
	--ps-on-dark: #D3D5EC;
	--ps-line: #E3E5F0;
	--ps-display: "Bricolage Grotesque", "Trebuchet MS", sans-serif;
	--ps-body: "DM Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
	--ps-wrap: 1200px;
	--ps-radius: 24px;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
	margin: 0;
	background: var(--ps-ground);
	color: var(--ps-ink);
	font-family: var(--ps-body);
	font-size: 17px;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--ps-accent); }
a:hover { color: var(--ps-navy); }
:focus-visible { outline: 3px solid var(--ps-sun); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3, h4 { font-family: var(--ps-display); line-height: 1.1; letter-spacing: -0.02em; margin: 0 0 .5em; }
p { margin: 0 0 1em; }

.screen-reader-text {
	border: 0; clip: rect(1px, 1px, 1px, 1px); clip-path: inset(50%);
	height: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute !important; width: 1px; word-wrap: normal !important;
}
.skip-link:focus {
	clip: auto; clip-path: none; height: auto; width: auto; left: 12px; top: 12px; z-index: 1000;
	background: var(--ps-sun); color: var(--ps-navy); padding: 12px 18px; border-radius: 999px; font-weight: 700; text-decoration: none;
}

.ps-wrap { max-width: var(--ps-wrap); margin: 0 auto; padding: 0 24px; }
.ps-section { padding: 96px 0; }
.ps-section--white { background: var(--ps-white); }
.ps-section--dark { background: var(--ps-navy); color: var(--ps-white); }
.ps-eyebrow { margin: 0 0 12px; font-size: 14px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--ps-accent); }
.ps-section--dark .ps-eyebrow, .ps-hero .ps-eyebrow { color: var(--ps-sun); }
.ps-heading { font-weight: 800; font-size: clamp(32px, 4vw, 48px); line-height: 1.08; margin: 0 0 12px; }
.ps-lede { font-size: 18px; color: var(--ps-muted); margin: 0; }
.ps-section--dark .ps-lede { color: var(--ps-on-dark); }
.ps-section-head { max-width: 720px; margin-bottom: 40px; }

/* Buttons */
.ps-btn {
	display: inline-flex; align-items: center; justify-content: center; gap: 8px;
	min-height: 48px; padding: 12px 24px; border-radius: 999px; border: 2px solid transparent;
	font: inherit; font-weight: 700; font-size: 16px; text-decoration: none; cursor: pointer; transition: transform .15s ease, background-color .15s ease;
}
.ps-btn:hover { transform: translateY(-1px); }
.ps-btn--sun { background: var(--ps-sun); color: var(--ps-navy); }
.ps-btn--sun:hover { background: #FFD666; color: var(--ps-navy); }
.ps-btn--ghost { color: var(--ps-white); border-color: #4A4D7A; }
.ps-btn--ghost:hover { color: var(--ps-white); border-color: var(--ps-white); }
.ps-btn--navy { background: var(--ps-navy); color: var(--ps-white); }
.ps-btn--navy:hover { background: var(--ps-navy-3); color: var(--ps-white); }
.ps-btn--soft { background: var(--ps-ground); color: var(--ps-navy); padding: 10px 18px; min-height: 44px; font-size: 15px; }
.ps-btn--soft:hover { background: var(--ps-accent-soft); color: var(--ps-navy); }

/* ---------- Header ---------- */
.ps-header { background: var(--ps-navy); color: var(--ps-white); position: relative; z-index: 10; }
.ps-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 18px; padding-bottom: 18px; flex-wrap: wrap; }
.ps-brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ps-white); text-decoration: none; }
.ps-brand:hover { color: var(--ps-white); }
.ps-brand__name { font-family: var(--ps-display); font-weight: 800; font-size: 22px; letter-spacing: -.02em; }
.ps-brand__name span { color: var(--ps-sun); }
.ps-brand .custom-logo { max-height: 44px; width: auto; }
.ps-nav-toggle {
	display: none; background: transparent; color: var(--ps-white); border: 2px solid #4A4D7A; border-radius: 12px;
	width: 48px; height: 48px; align-items: center; justify-content: center; cursor: pointer;
}
.ps-nav { display: flex; align-items: center; gap: 8px 28px; flex-wrap: wrap; }
.ps-nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 28px; align-items: center; }
.ps-nav a { color: var(--ps-white); text-decoration: none; font-size: 15px; font-weight: 500; padding: 8px 0; display: inline-block; }
.ps-nav a:hover, .ps-nav .current-menu-item > a { color: var(--ps-sun); }
.ps-nav .ps-btn { padding: 10px 20px; min-height: 44px; }
.ps-nav .sub-menu { display: none; }

@media (max-width: 860px) {
	.ps-nav-toggle { display: inline-flex; }
	.ps-nav { display: none; width: 100%; flex-direction: column; align-items: stretch; padding: 8px 0 12px; }
	.ps-nav.is-open { display: flex; }
	.ps-nav ul { flex-direction: column; align-items: stretch; gap: 0; }
	.ps-nav a { padding: 12px 0; font-size: 17px; border-bottom: 1px solid var(--ps-navy-3); display: block; }
	.ps-nav .ps-btn { margin-top: 12px; border-bottom: 0; display: flex; padding: 12px 20px; }
}

/* ---------- Hero ---------- */
.ps-hero { background: var(--ps-navy); color: var(--ps-white); padding: 72px 0 112px; }
.ps-hero__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 56px; align-items: center; }
.ps-hero h1 { font-weight: 800; font-size: clamp(40px, 6vw, 68px); line-height: 1.02; letter-spacing: -.03em; margin: 0 0 24px; }
.ps-hero__text { font-size: 19px; color: var(--ps-on-dark); max-width: 540px; margin: 0 0 32px; }
.ps-hero__ctas { display: flex; flex-wrap: wrap; gap: 12px; }
.ps-tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.ps-tile { border-radius: 28px; padding: 28px; min-height: 200px; display: flex; flex-direction: column; justify-content: space-between; }
.ps-tile:nth-child(even) { margin-top: 40px; }
.ps-tile__title { font-family: var(--ps-display); font-weight: 700; font-size: 22px; line-height: 1.2; }
.ps-tile__sub { font-size: 15px; }
.ps-tile--accent { background: var(--ps-accent); color: var(--ps-white); }
.ps-tile--accent .ps-tile__sub { color: var(--ps-accent-soft); }
.ps-tile--sun { background: var(--ps-sun); color: var(--ps-navy); }
.ps-tile--white { background: var(--ps-white); color: var(--ps-navy); }
.ps-tile--white .ps-tile__sub { color: var(--ps-muted); }
.ps-tile--deep { background: var(--ps-navy-3); color: var(--ps-white); }
.ps-tile--deep .ps-tile__sub { color: var(--ps-on-dark); }
@media (max-width: 420px) {
	.ps-tile { padding: 20px; min-height: 160px; border-radius: 22px; }
	.ps-tile__title { font-size: 19px; }
}

/* ---------- Shows ---------- */
.ps-shows { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(340px, 100%), 1fr)); gap: 28px; }
.ps-show { background: var(--ps-white); border-radius: 28px; overflow: hidden; display: flex; flex-direction: column; box-shadow: 0 1px 0 var(--ps-line); }
.ps-show__media { aspect-ratio: 16 / 9; display: flex; align-items: center; justify-content: center; text-align: center; padding: 16px; font-weight: 500; overflow: hidden; }
.ps-show__media img { width: 100%; height: 100%; object-fit: cover; }
.ps-show__media--has-img { padding: 0; }
.ps-show__media--sun { background: var(--ps-sun-soft); color: #6B5310; }
.ps-show__media--mint { background: var(--ps-mint-soft); color: #1E5A3B; }
.ps-show__placeholder { font-family: var(--ps-display); font-weight: 800; font-size: clamp(28px, 4vw, 44px); letter-spacing: -.02em; }
.ps-show__body { padding: 28px; display: flex; flex-direction: column; gap: 16px; }
.ps-show__title-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.ps-show__title { margin: 0; font-weight: 800; font-size: 30px; }
.ps-show__text { margin: 0; color: var(--ps-muted); }
.ps-badge { font-size: 13px; font-weight: 700; padding: 5px 12px; border-radius: 999px; }
.ps-badge--live { background: #17734B; color: var(--ps-white); }
.ps-badge--soon { background: var(--ps-sun); color: var(--ps-navy); }
.ps-show__label { margin: 0; font-size: 14px; font-weight: 700; }
.ps-platforms { display: flex; flex-wrap: wrap; gap: 10px; }

/* ---------- Forms ---------- */
.ps-form { display: flex; flex-direction: column; gap: 8px; }
.ps-form label { font-size: 14px; font-weight: 700; }
.ps-form input[type="text"], .ps-form input[type="email"], .ps-form select, .ps-form textarea {
	font: inherit; font-size: 16px; color: var(--ps-navy); background: var(--ps-white);
	border: 1.5px solid #C9CCE0; border-radius: 14px; padding: 12px 16px; width: 100%; min-height: 48px;
}
.ps-form textarea { resize: vertical; min-height: 120px; }
.ps-form__row { display: flex; flex-wrap: wrap; gap: 10px; }
.ps-form__row input { flex: 1 1 200px; min-width: 0; width: auto; border-radius: 999px !important; }
.ps-form__fine { font-size: 13px; color: var(--ps-muted); margin: 0; }
.ps-form .ps-btn { margin-top: 8px; align-self: flex-start; }
.ps-form__row .ps-btn { margin-top: 0; }
.ps-hp { position: absolute !important; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.ps-notice { border-radius: 14px; padding: 12px 16px; font-weight: 500; margin: 0 0 8px; }
.ps-notice--ok { background: #DDF3E6; color: #0F5132; }
.ps-notice--err { background: #FDE2E2; color: #842029; }

/* ---------- Services ---------- */
.ps-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 20px; }
.ps-card { background: var(--ps-ground); border-radius: var(--ps-radius); padding: 28px; display: flex; flex-direction: column; gap: 12px; }
.ps-section:not(.ps-section--white) .ps-card { background: var(--ps-white); }
.ps-card__num { width: 48px; height: 48px; border-radius: 14px; display: flex; align-items: center; justify-content: center; font-family: var(--ps-display); font-weight: 800; font-size: 20px; color: var(--ps-navy); }
.ps-card__title { margin: 0; font-weight: 700; font-size: 23px; }
.ps-card__text { margin: 0; color: var(--ps-muted); }
.ps-card__tech { margin: 0; font-size: 14px; font-weight: 700; color: var(--ps-accent); }
.ps-tint-1 { background: var(--ps-accent-soft); }
.ps-tint-2 { background: var(--ps-sun-soft); }
.ps-tint-3 { background: var(--ps-mint-soft); }
.ps-tint-4 { background: #FFD9C7; }
.ps-tint-5 { background: #D6E9FF; }
.ps-tint-6 { background: var(--ps-accent-soft); }

/* ---------- Industries ---------- */
.ps-split { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr)); gap: 48px; align-items: start; }
.ps-stack { display: flex; flex-direction: column; gap: 14px; }
.ps-industry { background: var(--ps-navy-2); border-radius: 20px; padding: 22px 24px; }
.ps-industry h3 { font-weight: 700; font-size: 21px; margin: 0 0 4px; }
.ps-industry p { color: var(--ps-on-dark); margin: 0; }

/* ---------- Process ---------- */
.ps-steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); gap: 20px; }
.ps-step { background: var(--ps-white); border-radius: var(--ps-radius); padding: 28px; display: flex; flex-direction: column; gap: 8px; }
.ps-step__num { font-family: var(--ps-display); font-weight: 800; font-size: 40px; color: var(--ps-accent); line-height: 1; }
.ps-step__title { font-weight: 700; font-size: 20px; }
.ps-step__text { color: var(--ps-muted); }

/* ---------- Team ---------- */
.ps-person { background: var(--ps-ground); border-radius: var(--ps-radius); padding: 28px; display: flex; flex-direction: column; gap: 14px; }
.ps-avatar { width: 72px; height: 72px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-family: var(--ps-display); font-weight: 800; font-size: 28px; overflow: hidden; }
.ps-avatar img { width: 100%; height: 100%; object-fit: cover; }
.ps-avatar--1 { background: var(--ps-accent-soft); color: var(--ps-accent); }
.ps-avatar--2 { background: var(--ps-sun-soft); color: #6B5310; }
.ps-avatar--3 { background: var(--ps-mint-soft); color: #1E5A3B; }
.ps-person__name { font-family: var(--ps-display); font-weight: 700; font-size: 23px; margin: 0; }
.ps-person__role { font-weight: 700; color: var(--ps-accent); margin: 0; font-size: 15px; }
.ps-person__bio { color: var(--ps-muted); margin: 0; }

/* ---------- Blog teaser + listing ---------- */
.ps-posts { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 24px; }
.ps-post-card { background: var(--ps-white); border-radius: var(--ps-radius); overflow: hidden; display: flex; flex-direction: column; box-shadow: 0 1px 0 var(--ps-line); }
.ps-section--white .ps-post-card { background: var(--ps-ground); box-shadow: none; }
.ps-post-card__img { aspect-ratio: 16 / 9; background: var(--ps-accent-soft); overflow: hidden; }
.ps-post-card__img img { width: 100%; height: 100%; object-fit: cover; }
.ps-post-card__body { padding: 24px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.ps-post-card__meta { font-size: 14px; color: var(--ps-muted); margin: 0; }
.ps-post-card__title { font-size: 23px; font-weight: 700; margin: 0; }
.ps-post-card__title a { color: var(--ps-navy); text-decoration: none; }
.ps-post-card__title a:hover { color: var(--ps-accent); }
.ps-post-card__excerpt { color: var(--ps-muted); margin: 0; }
.ps-post-card__excerpt p { margin: 0; }
.ps-more { margin-top: 32px; }

/* ---------- Contact ---------- */
.ps-contact { background: var(--ps-accent); color: var(--ps-white); border-radius: 36px; padding: clamp(28px, 5vw, 64px); display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 40px; }
.ps-contact .ps-heading { color: var(--ps-white); }
.ps-contact__text { font-size: 18px; color: var(--ps-accent-soft); }
.ps-contact a { color: var(--ps-white); font-weight: 700; }
.ps-contact .ps-form label { color: var(--ps-white); }
.ps-contact .ps-form input, .ps-contact .ps-form select, .ps-contact .ps-form textarea { border-color: transparent; }
.ps-contact .ps-form__fine { color: var(--ps-accent-soft); }

/* ---------- Page / single ---------- */
.ps-page-head { background: var(--ps-navy); color: var(--ps-white); padding: 64px 0 72px; }
.ps-page-head h1 { font-weight: 800; font-size: clamp(34px, 5vw, 56px); margin: 0; max-width: 900px; }
.ps-page-head p { color: var(--ps-on-dark); margin: 16px 0 0; font-size: 18px; max-width: 720px; }
.ps-page-head .ps-eyebrow { color: var(--ps-sun); }
.ps-content { max-width: 760px; margin: 0 auto; padding: 64px 24px 96px; }
.ps-content > * + * { margin-top: 1.1em; }
.ps-content h2 { font-size: 32px; margin-top: 1.6em; }
.ps-content h3 { font-size: 24px; margin-top: 1.4em; }
.ps-content img { border-radius: 16px; }
.ps-content blockquote { margin-left: 0; padding: 4px 0 4px 20px; border-left: 4px solid var(--ps-sun); font-size: 20px; }
.ps-content pre { background: var(--ps-navy); color: var(--ps-white); padding: 20px; border-radius: 16px; overflow-x: auto; }
.ps-content .alignwide { max-width: 1100px; margin-left: auto; margin-right: auto; }
.ps-content .wp-block-button__link { background: var(--ps-accent); color: var(--ps-white); border-radius: 999px; padding: 12px 24px; font-weight: 700; text-decoration: none; }
.ps-featured { max-width: 1000px; margin: -40px auto 0; padding: 0 24px; }
.ps-featured img { border-radius: 24px; width: 100%; }
.ps-post-nav { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; border-top: 1px solid var(--ps-line); padding-top: 24px; margin-top: 48px; }
.ps-pagination { margin-top: 48px; }
.ps-pagination .nav-links { display: flex; gap: 8px; flex-wrap: wrap; }
.ps-pagination .page-numbers { min-width: 44px; min-height: 44px; display: inline-flex; align-items: center; justify-content: center; border-radius: 999px; background: var(--ps-white); color: var(--ps-navy); text-decoration: none; font-weight: 700; padding: 0 14px; }
.ps-pagination .page-numbers.current { background: var(--ps-navy); color: var(--ps-white); }
.ps-empty { text-align: center; padding: 40px 0; }
.ps-search { display: flex; gap: 10px; flex-wrap: wrap; max-width: 520px; margin: 24px auto 0; }
.ps-search input[type="search"] { flex: 1 1 220px; min-height: 48px; padding: 12px 18px; border-radius: 999px; border: 1.5px solid #C9CCE0; font: inherit; }

/* ---------- Footer ---------- */
.ps-footer { background: var(--ps-navy); color: var(--ps-on-dark); padding: 48px 0; font-size: 14px; }
.ps-footer__inner { display: flex; flex-wrap: wrap; gap: 16px 32px; justify-content: space-between; align-items: center; }
.ps-footer a { color: var(--ps-on-dark); }
.ps-footer a:hover { color: var(--ps-sun); }
.ps-footer ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 20px; }
.ps-footer .ps-brand__name { font-size: 18px; color: var(--ps-white); }

@media (max-width: 600px) {
	body { font-size: 16px; }
	.ps-section { padding: 64px 0; }
	.ps-hero { padding: 48px 0 72px; }
	.ps-wrap { padding: 0 16px; }
	.ps-content { padding: 48px 16px 72px; }
}
@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	.ps-btn { transition: none; }
	.ps-btn:hover { transform: none; }
}
