/*
Theme Name: PWIT — ProWise
Description: Practical engineering training with the shared ProWise visual identity. Includes native page templates and the PWIT homepage redesign.
Version: 1.0.1
Requires at least: 5.8
Requires PHP: 7.4
Author: ProWise Institute of Technology
Text Domain: pwit-prowise
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
*/

/* Native WordPress toolbar must sit above the sticky branded header. */
body.admin-bar .site-header { top: 32px; }
html:has(body.admin-bar) { scroll-padding-top: 140px; }
.legacy-main { min-height: 55vh; background: var(--cream); padding-block: 74px 94px; }
.legacy-wrap { max-width: 1120px; }
.legacy-heading { margin-bottom: 38px; }
.legacy-heading h1 { font-size: clamp(38px, 4.3vw, 58px); line-height: 1.18; overflow-wrap: anywhere; }
.legacy-heading .eyebrow { margin-bottom: 18px; }
.legacy-post { padding-bottom: 42px; margin-bottom: 42px; border-bottom: 1px solid var(--line); }
.legacy-post:last-of-type { margin-bottom: 22px; }
.legacy-post h2 { font-size: clamp(29px, 3vw, 40px); }
.entry-content { font-size: 17px; line-height: 1.85; overflow-wrap: break-word; }
.entry-content::after { content: ''; display: table; clear: both; }
.entry-content > *:first-child { margin-top: 0; }
.entry-content h1, .entry-content h2, .entry-content h3, .entry-content h4, .entry-content h5, .entry-content h6 { line-height: 1.3; margin-top: 1.6em; margin-bottom: .65em; color: var(--ink); }
.entry-content h1 { font-size: 42px; }
.entry-content h2 { font-size: 36px; }
.entry-content h3 { font-size: 29px; letter-spacing: -.35px; }
.entry-content h4 { font-size: 24px; }
.entry-content h5, .entry-content h6 { font-family: var(--font); font-size: 18px; }
.entry-content p, .entry-content ul, .entry-content ol, .entry-content dl { margin-bottom: 1.25em; }
.entry-content ul, .entry-content ol { padding-left: 1.5em; }
.entry-content li { margin-bottom: .4em; }
.entry-content a:not(.button):not(.fl-button) { color: #8a6210; text-decoration: underline; text-underline-offset: 3px; }
.entry-content a:hover { color: #5f450f; }
.entry-content .button { text-decoration: none; }
.entry-content blockquote { border-left: 4px solid #b78a25; background: #f3eddf; margin: 28px 0; padding: 22px 26px; }
.entry-content blockquote > *:last-child { margin-bottom: 0; }
.entry-content hr { border: 0; border-top: 1px solid var(--line); margin-block: 36px; }
.entry-content img { max-width: 100%; height: auto; }
.entry-content iframe, .entry-content video, .entry-content embed, .entry-content object { max-width: 100%; }
.entry-content figure { max-width: 100%; }
.entry-content figure:not(.wp-block-image) { margin-inline: 0; }
.entry-content figcaption, .entry-content .wp-caption-text { font-size: 14px; color: var(--muted); line-height: 1.65; margin-top: 8px; }
.entry-content .wp-caption { max-width: 100%; }
.entry-content .alignleft { float: left; margin: 0 26px 18px 0; }
.entry-content .alignright { float: right; margin: 0 0 18px 26px; }
.entry-content .aligncenter { margin-inline: auto; }
.entry-content .wp-block-table { overflow-x: auto; }
.entry-content table { border-collapse: collapse; width: 100%; max-width: 100%; font-size: 15px; margin-bottom: 26px; }
.entry-content th, .entry-content td { border: 1px solid #d8d1bf; padding: 12px 14px; text-align: left; vertical-align: top; }
.entry-content th { background: #f1e8d2; font-weight: 600; }
.entry-content pre { white-space: pre-wrap; overflow-wrap: anywhere; padding: 18px; background: #f0ecdf; font-size: 14px; }
.entry-content input:not([type='submit']):not([type='button']):not([type='checkbox']):not([type='radio']):not([type='hidden']), .entry-content textarea, .entry-content select, .search-form input[type='search'] { background: #fff; border: 1px solid #cfc8b6; border-radius: 5px; padding: 11px 13px; min-height: 48px; font-size: 16px; color: var(--ink); max-width: 100%; }
.entry-content textarea { width: 100%; min-height: 130px; }
.entry-content label { font-size: 15px; font-weight: 550; }
.entry-content input[type='submit'], .entry-content input[type='button'], .search-submit, .entry-content button:not(.fl-menu-mobile-toggle) { padding: 12px 24px; border: 1px solid transparent; border-radius: 999px; background: var(--yellow); color: #22231e; min-height: 48px; font-size: 15px; font-weight: 600; cursor: pointer; }
.entry-content .nf-form-fields-required { margin-bottom: 20px; font-size: 14px; }
.entry-content .nf-form-cont { max-width: 760px; }
.entry-content .nf-field-label label { font-size: 15px; }
.entry-content .nf-field-element input, .entry-content .nf-field-element select { width: 100%; }
.entry-content .nf-field-element input[type='checkbox'], .entry-content .nf-field-element input[type='radio'], .entry-content .nf-field-element input[type='submit'], .entry-content .nf-field-element input[type='button'] { width: auto; }
.entry-content .nf-error-msg, .entry-content .ninja-forms-req-symbol { color: #a13723; }
.entry-content .nf-response-msg { background: #edf2e6; padding: 16px; color: #354a27; }
.page-links, .nav-links { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; font-size: 15px; margin-top: 25px; }
.page-links a, .nav-links a, .nav-links .current { display: inline-block; border: 1px solid #d4cbb5; border-radius: 5px; padding: 8px 14px; }
.nav-links .current { background: #efe2bd; }
.search-form { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 26px; }
.search-form label { display: flex; max-width: 100%; }
.search-form .screen-reader-text, .screen-reader-text { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.screen-reader-text:focus { position: static; width: auto; height: auto; clip: auto; margin: 0; padding: 8px; }

@media (max-width: 782px) {
  body.admin-bar .site-header { top: 46px; }
  html:has(body.admin-bar) { scroll-padding-top: 145px; }
}
@media (max-width: 720px) {
  .legacy-main { padding-block: 44px 64px; }
  .legacy-heading { margin-bottom: 28px; }
  .legacy-heading h1 { font-size: 38px; letter-spacing: -.7px; }
  .entry-content { font-size: 16px; line-height: 1.8; }
  .entry-content h1 { font-size: 35px; }
  .entry-content h2 { font-size: 31px; }
  .entry-content h3 { font-size: 27px; }
  .entry-content h4 { font-size: 23px; }
  .entry-content th, .entry-content td { padding: 9px; font-size: 14px; }
  .entry-content blockquote { padding: 18px; }
  .entry-content .alignleft, .entry-content .alignright { float: none; margin: 0 auto 22px; }
}
@media (max-width: 600px) {
  /* WordPress lets its toolbar scroll away on small screens. */
  body.admin-bar .site-header { top: 0; }
}
@media print {
  .legacy-main { padding: 20px 0; }
  .entry-content { font-size: 12pt; }
}
