/* Inner pages (portfolio list and detail, blog list and post), shared by both options.
   Uses each option's tokens and fonts, so the pages follow the option they belong to. */

.page-hero { background: var(--navy-950); color: #fff; padding-block: clamp(36px, 6vw, 72px) clamp(40px, 6vw, 76px); position: relative; overflow: hidden; }
.page-hero::after { content: ""; position: absolute; right: -80px; top: -80px; width: 320px; height: 320px; border-radius: 50%; border: 48px solid rgba(255, 162, 0, .08); pointer-events: none; }
.page-hero .wrap { position: relative; z-index: 1; }
.crumbs ol { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 18px; padding: 0; list-style: none; font-size: 13.5px; color: rgba(255, 255, 255, .72); }
.crumbs li + li::before { content: "/"; margin-right: 6px; color: rgba(255, 255, 255, .4); }
.crumbs a { color: rgba(255, 255, 255, .9); text-decoration: none; }
.crumbs a:hover { text-decoration: underline; }
.page-hero h1 { font-size: clamp(30px, 4.4vw, 52px); font-weight: 800; line-height: 1.08; letter-spacing: -.025em; margin: 0 0 14px; max-width: 22ch; text-wrap: balance; }
.page-hero .lead { color: rgba(255, 255, 255, .8); font-size: 17px; max-width: 62ch; }
.hero-meta { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; }
.hero-meta span { display: inline-flex; align-items: center; gap: 7px; padding: 7px 12px; border-radius: 999px; background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .16); font-size: 13.5px; font-weight: 600; }
.hero-meta .i { width: 15px; height: 15px; color: var(--amber-500); }

.page-section { padding-block: clamp(36px, 6vw, 72px); }
.page-section.alt { background: var(--bg); }
.sec-title { font-size: clamp(24px, 2.6vw, 32px); font-weight: 800; letter-spacing: -.02em; line-height: 1.15; margin: 0 0 20px; }

/* Filter bar */
.toolbar { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: flex-start; gap: 16px 40px; margin-bottom: 26px; }
.toolbar-group { display: grid; gap: 8px; min-width: 0; }
.toolbar-group > span, .toolbar-group > label > span { display: block; font-size: 12.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.toolbar .chips { margin: 0; }
.toolbar-select { width: min(280px, 100%); }
.result-count { margin: 0 0 16px; font-size: 14px; color: var(--muted); }
.result-count b { color: var(--ink); }
.empty { display: none; padding: 40px 20px; text-align: center; border: 1.5px dashed var(--line); border-radius: 16px; color: var(--muted); }
.empty.is-shown { display: block; }

/* Project cards */
.pj-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.pj-card { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; text-decoration: none; color: var(--ink); transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease; }
.pj-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--navy-100); }
.pj-card[hidden] { display: none; }
.pj-photo { position: relative; aspect-ratio: 16 / 10; background: var(--navy-50); overflow: hidden; }
.pj-photo img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.pj-card:hover .pj-photo img { transform: scale(1.04); }
.no-photo { width: 100%; height: 100%; display: grid; place-content: center; justify-items: center; gap: 8px; color: var(--navy-700); font-size: 13px; font-weight: 600; background: linear-gradient(135deg, var(--navy-50), #fff); }
.no-photo .i { width: 34px; height: 34px; stroke-width: 1.5; }
.status { position: absolute; top: 12px; left: 12px; font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 999px; background: #fff; color: var(--navy-900); box-shadow: 0 2px 8px rgba(0, 13, 46, .12); }
.status.ongoing { background: var(--amber-500); color: var(--navy-950); }
.pj-body { display: flex; flex-direction: column; gap: 8px; padding: 18px 18px 20px; flex: 1; }
.pj-body h2, .pj-body h3 { font-size: 18px; font-weight: 800; line-height: 1.25; margin: 0; }
.pj-status { display: inline-flex; align-items: center; gap: 7px; width: fit-content; margin: 0; padding: 3px 10px 3px 8px; border-radius: 999px; font-size: 12.5px; font-weight: 700; background: var(--navy-50); color: var(--navy-900); }
.pj-status::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--navy-700); }
.pj-status.is-ongoing { background: var(--amber-100, #ffefcc); color: #5c3a00; }
.pj-status.is-ongoing::before { background: var(--amber-500); }
.pj-facts { display: grid; gap: 6px; margin: 2px 0 4px; }
.pj-facts div { display: flex; gap: 8px; align-items: flex-start; }
.pj-facts dt { flex: none; margin-top: 2px; color: var(--navy-700); }
.pj-facts dt .i { width: 15px; height: 15px; }
.pj-facts dd { margin: 0; font-size: 13.5px; line-height: 1.45; color: var(--muted); overflow-wrap: anywhere; }
.toolbar-selects { display: flex; flex-wrap: wrap; gap: 14px; flex-basis: 100%; }
.ptags { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; list-style: none; }
.ptags li { font-size: 12px; font-weight: 700; color: var(--navy-700); background: var(--navy-50); padding: 3px 8px; border-radius: 6px; }
.pj-more { margin-top: auto; padding-top: 6px; display: inline-flex; align-items: center; gap: 6px; font-weight: 700; font-size: 14px; color: var(--navy-700); }

/* Project detail */
.detail { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 48px); align-items: start; }
.detail-photo { margin: 0; }
.detail-photo .frame { border-radius: 18px; overflow: hidden; background: var(--navy-50); aspect-ratio: 16 / 10; }
.detail-photo img { width: 100%; height: 100%; object-fit: cover; }
.detail-photo figcaption { margin-top: 10px; font-size: 13px; color: var(--muted); }
.facts { position: sticky; top: 96px; background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: 24px; box-shadow: var(--shadow-md); }
.facts h2 { font-size: 18px; font-weight: 800; margin: 0 0 14px; }
.facts dl { margin: 0; display: grid; gap: 0; }
.facts dl > div { display: grid; grid-template-columns: 112px 1fr; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.facts dt { font-size: 13px; font-weight: 700; color: var(--muted); }
.facts dd { margin: 0; font-size: 15px; font-weight: 600; overflow-wrap: anywhere; }
.facts .btn { width: 100%; justify-content: center; margin-top: 18px; }
.svc-related { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.svc-mini { display: flex; flex-direction: column; gap: 8px; padding: 20px; background: #fff; border: 1px solid var(--line); border-radius: 14px; text-decoration: none; color: var(--ink); transition: border-color .2s ease, box-shadow .2s ease; }
.svc-mini:hover { border-color: var(--navy-700); box-shadow: var(--shadow-md); }
.svc-mini small { font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--amber-700); }
.svc-mini b { font-size: 18px; }
.svc-mini span { font-size: 14px; color: var(--muted); }
.note-box { display: flex; gap: 10px; margin-top: 16px; padding: 14px 16px; border-radius: 12px; background: var(--navy-50); color: var(--navy-900); font-size: 14px; }
.note-box .i { margin-top: 2px; color: var(--navy-700); flex: none; }
.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.pager a { display: flex; flex-direction: column; gap: 4px; padding: 18px 20px; border: 1px solid var(--line); border-radius: 14px; text-decoration: none; color: var(--ink); background: #fff; transition: border-color .2s ease; min-width: 0; }
.pager a:hover { border-color: var(--navy-700); }
.pager small { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 700; color: var(--navy-700); }
.pager b { font-size: 16px; overflow-wrap: anywhere; }
.pager .next { text-align: right; align-items: flex-end; }

.facts-lead { margin: 0 0 16px; font-size: 14.5px; color: var(--muted); }
.facts .facts-second { margin-top: 10px; }
.facts h3 { font-size: 14px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin: 24px 0 10px; }
.facts-links { display: grid; gap: 4px; }
.facts-links a { display: flex; justify-content: space-between; align-items: center; min-height: 44px; padding: 0 2px; border-bottom: 1px solid var(--line); color: var(--ink); font-weight: 700; text-decoration: none; }
.facts-links a:hover { color: var(--navy-700); }
.facts-list { margin: 0 0 8px; padding-left: 22px; display: grid; gap: 10px; font-size: 16.5px; line-height: 1.65; }
.facts-list li::marker { color: var(--amber-500); }
.pj-grid-2 { grid-template-columns: repeat(2, 1fr); }
.hero-actions-plain { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }

/* CTA band */
.cta-band { display: grid; grid-template-columns: 1fr auto; gap: 20px 32px; align-items: center; padding: clamp(24px, 4vw, 40px); border-radius: 22px; background: var(--navy-900); color: #fff; }
.cta-band h2 { font-size: clamp(22px, 2.6vw, 30px); font-weight: 800; letter-spacing: -.02em; margin: 0 0 6px; }
.cta-band p { color: rgba(255, 255, 255, .78); margin: 0; }
.cta-band .actions { display: flex; flex-wrap: wrap; gap: 10px; }

/* Blog list */
.post-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.post-card { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; text-decoration: none; color: var(--ink); transition: transform .25s ease, box-shadow .25s ease; }
.post-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.post-card[hidden] { display: none; }
.post-card.featured { grid-column: span 2; flex-direction: row; }
.post-card.featured .cover { aspect-ratio: auto; min-height: 260px; flex: 1 1 50%; }
.post-card.featured .post-text { flex: 1 1 50%; justify-content: center; padding: 28px; }
.post-card.featured h2 { font-size: 26px; }
.cover { position: relative; aspect-ratio: 16 / 9; display: grid; place-items: center; color: var(--amber-500); background: radial-gradient(circle at 80% 20%, rgba(255, 162, 0, .22), transparent 45%), linear-gradient(135deg, var(--navy-700), var(--navy-950)); overflow: hidden; }
.cover .i { width: 56px; height: 56px; stroke-width: 1.4; }
.cover em { position: absolute; left: 16px; bottom: 14px; font-style: normal; font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: rgba(255, 255, 255, .85); }
.post-text { display: flex; flex-direction: column; gap: 10px; padding: 20px; flex: 1; }
.post-meta { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 13px; color: var(--muted); }
.post-meta b { color: var(--amber-700); font-weight: 700; }
.post-text h2, .post-text h3 { font-size: 19px; font-weight: 800; line-height: 1.28; margin: 0; }
.post-text p { color: var(--muted); font-size: 14.5px; margin: 0; }

/* Blog post */
.article-wrap { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: clamp(28px, 5vw, 64px); align-items: start; }
.article { max-width: 72ch; font-size: 17px; line-height: 1.75; color: var(--ink); }
.article .cover { aspect-ratio: 21 / 9; border-radius: 18px; margin-bottom: 30px; }
.article h2 { font-size: clamp(22px, 2.4vw, 28px); font-weight: 800; letter-spacing: -.015em; line-height: 1.25; margin: 38px 0 12px; scroll-margin-top: 96px; }
.article h3 { font-size: 20px; font-weight: 800; margin: 28px 0 10px; }
.article p { margin: 0 0 16px; }
.article ul { margin: 0 0 18px; padding-left: 22px; }
.article li { margin: 6px 0; }
.article li::marker { color: var(--amber-500); }
.article a { color: var(--navy-700); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1.5px; }
.article strong { font-weight: 800; }
.aside { position: sticky; top: 96px; display: grid; gap: 16px; }
.toc { border: 1px solid var(--line); border-radius: 16px; padding: 18px 20px; background: #fff; }
.toc b { display: block; font-size: 13px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.toc ol { margin: 0; padding-left: 18px; display: grid; gap: 8px; font-size: 14.5px; }
.toc a { color: var(--ink); text-decoration: none; }
.toc a:hover { color: var(--navy-700); text-decoration: underline; }
.aside-cta { border-radius: 16px; padding: 20px; background: var(--navy-900); color: #fff; }
.aside-cta b { display: block; font-size: 18px; margin-bottom: 6px; }
.aside-cta p { font-size: 14px; color: rgba(255, 255, 255, .78); margin: 0 0 14px; }
.aside-cta .btn { width: 100%; justify-content: center; }
.share { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 30px; padding-top: 20px; border-top: 1px solid var(--line); }
.share span { font-size: 14px; font-weight: 700; color: var(--muted); }
.share a, .share button { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 8px 14px; border-radius: 999px; border: 1.5px solid var(--line); background: #fff; color: var(--ink); font: inherit; font-size: 14px; font-weight: 700; text-decoration: none; cursor: pointer; }
.share a:hover, .share button:hover { border-color: var(--navy-700); }
.share .i { width: 16px; height: 16px; }
.share .wa .i { color: #1aa652; }
.disclaimer { margin-top: 18px; font-size: 13.5px; color: var(--muted); }

@media (max-width: 1100px) {
  .pj-grid, .post-grid, .svc-related { grid-template-columns: repeat(2, 1fr); }
  .article-wrap { grid-template-columns: minmax(0, 1fr) 260px; }
}
@media (max-width: 960px) {
  .detail, .article-wrap { grid-template-columns: 1fr; }
  .facts, .aside { position: static; }
  .aside { order: -1; }
  .aside-cta { display: none; }
  .toc { padding: 14px 16px; }
  .post-card.featured { grid-column: auto; flex-direction: column; }
  .post-card.featured .cover { min-height: 0; aspect-ratio: 16 / 9; }
  .post-card.featured .post-text { padding: 20px; }
  .post-card.featured h2 { font-size: 21px; }
  .cta-band { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .pj-grid, .post-grid, .svc-related, .pager { grid-template-columns: 1fr; }
  .pager .next { text-align: left; align-items: flex-start; }
  .toolbar { flex-direction: column; align-items: stretch; }
  .toolbar-select { width: 100%; }
  .toolbar-selects { flex-direction: column; }
  .facts dl > div { grid-template-columns: 1fr; gap: 2px; }
  .article { font-size: 16.5px; }
  .article .cover { aspect-ratio: 16 / 9; }
  .cta-band .actions .btn { flex: 1 1 100%; justify-content: center; }
}
