/* TAAM photographic chapters: original typography, red/charcoal/white. */
html.motion-enabled .hero.is-in-view .hero-media img{animation:taam-photo-drift 18s ease-in-out infinite alternate}
@keyframes taam-photo-drift{from{transform:scale(1.025)}to{transform:scale(1.10)}}
.execution-journal{margin-top:80px;padding-top:60px;border-top:1px solid #41474e}
.execution-journal h2{font-size:clamp(2.6rem,4.6vw,4.5rem)}
.execution-gallery{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:28px}
.photo-story{margin:0;min-width:0;background:#fff;color:#0b0f14;overflow:hidden;border:1px solid #d4d5d5}
.execution-gallery .photo-story{background:#161c23;color:#fff;border-color:#41474e}
.photo-open{display:block;position:relative;overflow:hidden;background:#0b0f14}
.photo-open img{width:100%;aspect-ratio:16/11;object-fit:cover;transition:transform .85s cubic-bezier(.2,.65,.3,1),filter .45s}
.photo-open:hover img{transform:scale(1.045)}
.photo-open:focus-visible{outline:3px solid #fff;outline-offset:-7px;box-shadow:inset 0 0 0 3px #e31b23}
.photo-expand{position:absolute;right:18px;bottom:18px;background:#0b0f14;color:white;font-size:.875rem;padding:9px 13px;border:1px solid #9ca1a6}
.photo-story figcaption{padding:26px;text-transform:none;letter-spacing:normal;background:inherit;color:inherit}
.photo-story h3{font-family:'Barlow Condensed','Arial Narrow',sans-serif;font-size:2rem;line-height:1.1;margin:0 0 12px}
.photo-story p{font-size:1rem;line-height:1.65;color:#47515a}
.execution-gallery .photo-story p{color:#d2d5d9}
.execution-gallery .photo-wide{grid-column:1/-1}
.execution-gallery .photo-wide img{aspect-ratio:2.15/1}
.execution-gallery .photo-story:last-child{grid-column:1/-1;display:grid;grid-template-columns:1.1fr 1fr;align-items:center}
.execution-gallery .photo-story:last-child img{aspect-ratio:16/10}
.execution-gallery .photo-story:last-child figcaption{padding:38px}
.specialist-section{border-bottom:1px solid #d4d5d5}
.specialist-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));border-left:1px solid #c3c9cd;border-top:1px solid #c3c9cd}
.specialist-grid article{padding:32px;background:#fafaf7;border-right:1px solid #c3c9cd;border-bottom:1px solid #c3c9cd;position:relative;transition:background .3s}
.specialist-grid article:before{content:'';position:absolute;top:0;left:0;height:3px;width:0;background:#e31b23;transition:width .55s}
.specialist-grid article:hover{background:white}.specialist-grid article:hover:before{width:100%}
.specialist-grid .number{font-size:.875rem;color:#a1161c;margin-bottom:20px}
.specialist-grid h3{font-size:2rem;margin-bottom:20px}.specialist-grid p{font-size:1rem;color:#47515a}
.specialist-grid details{margin-top:20px}.specialist-grid summary{min-height:44px;cursor:pointer;font-size:.875rem;font-weight:700;display:list-item}
.specialist-grid details p{margin-top:14px}
.specialist-photo{margin:-32px -32px 26px;width:calc(100% + 64px)}
.specialist-photo img{aspect-ratio:16/11}
.specialist-photo .photo-expand{font-size:.8125rem;right:12px;bottom:12px}
.photo-open img[src*="automated-welding"]{object-position:center 25%}
.specialist-next{display:flex;align-items:center;justify-content:space-between;gap:25px;margin-top:32px}.specialist-next p{font-size:1rem}
.facility-detail-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:35px;margin-top:52px;padding:38px 0;border-top:1px solid #c3c9cd;border-bottom:1px solid #c3c9cd}
.facility-detail-grid h3{font-size:2rem;margin-bottom:18px}.facility-detail-grid p:not(.eyebrow){font-size:1rem;color:#47515a}
.facility-detail-grid ul{padding-left:20px;margin:22px 0 0;font-size:.9375rem;color:#47515a}.facility-detail-grid li{margin-top:10px}.facility-detail-grid li::marker{color:#a1161c}
.facility-gallery.facility-stories{grid-template-columns:repeat(2,minmax(0,1fr));gap:25px;margin-top:45px}
.facility-gallery .photo-story{background:white}.facility-gallery .photo-story figcaption{padding:24px;color:#0b0f14;font-size:1rem;text-transform:none;letter-spacing:normal}
.facility-gallery .photo-story img{aspect-ratio:16/11}
.photo-dialog:not([open]){display:none}
.photo-dialog{padding:24px;border:1px solid #626a72;background:#0b0f14;color:white;width:min(1200px,calc(100% - 32px));max-height:92dvh;overflow:auto}
.photo-dialog::backdrop{background:rgba(0,0,0,.9)}
.photo-dialog-bar,.photo-dialog-actions{display:flex;align-items:center;justify-content:space-between;gap:18px}
.photo-dialog-bar{margin-bottom:20px}.photo-dialog h2{font-size:1.8rem;line-height:1.15}
.photo-dialog img{width:100%;height:min(60dvh,750px);object-fit:contain;background:#05080b}
.photo-dialog figcaption{font-size:1rem;line-height:1.6;margin-top:18px;color:#e3e6e9}
.photo-dialog-actions{margin-top:20px}.photo-dialog button{min-height:44px;min-width:44px;padding:10px 16px;background:#161c23;color:#fff;border:1px solid #9399a0;font:inherit;cursor:pointer}
.photo-dialog button:hover{background:#b60d15}.photo-dialog-actions p{font-size:.875rem;white-space:nowrap}
body.photo-viewing{overflow:hidden}
.motion-off .photo-open:hover img{transform:none}
.motion-off .specialist-grid article:before{transition:none}
@media(max-width:1100px){.specialist-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.facility-detail-grid{gap:24px}}
@media(max-width:800px){.execution-journal{margin-top:50px;padding-top:42px}.execution-gallery{gap:20px}.execution-gallery .photo-story:last-child{display:block}.execution-gallery .photo-story:last-child figcaption{padding:26px}.facility-detail-grid{grid-template-columns:1fr}.facility-detail-grid article+article{padding-top:28px;border-top:1px solid #c3c9cd}.photo-story h3{font-size:1.8rem}.specialist-grid article{padding:26px}.specialist-photo{margin:-26px -26px 24px;width:calc(100% + 52px)}.specialist-next{align-items:flex-start;flex-direction:column}}
@media(max-width:580px){.execution-gallery,.facility-gallery.facility-stories,.specialist-grid{grid-template-columns:1fr}.execution-gallery .photo-wide img,.execution-gallery .photo-story:last-child img{aspect-ratio:16/11}.photo-story figcaption{padding:22px}.photo-expand{right:12px;bottom:12px}.photo-dialog{padding:16px;width:calc(100% - 20px)}.photo-dialog h2{font-size:1.5rem}.photo-dialog button{font-size:.875rem;padding:10px}.photo-dialog img{height:45dvh}.photo-dialog figcaption{font-size:.9375rem}.photo-dialog-actions{gap:10px}}
@media(prefers-reduced-motion:reduce){.photo-open img,.specialist-grid article,.specialist-grid article:before{transition:none!important}.photo-open:hover img{transform:none}}
@media print{.photo-dialog,.photo-expand{display:none!important}.execution-gallery,.specialist-grid,.facility-gallery.facility-stories{grid-template-columns:repeat(2,1fr)}.execution-gallery .photo-story{background:white;color:#111}.execution-gallery .photo-story p{color:#111}.photo-story{break-inside:avoid}.photo-open img{max-height:240px;object-fit:contain}}
/* Location-specific facilities and document-backed QHSE. */
.location-nav{display:flex;gap:12px;flex-wrap:wrap;margin:35px 0 60px}.location-nav a{padding:14px 24px;border:1px solid #aab0b6;font-weight:700;min-height:48px}.location-nav a:hover{background:#0b0f14;color:#fff}
.location-chapter{padding:58px 0;border-top:1px solid #bfc5ca;scroll-margin-top:110px}.location-heading{max-width:860px;margin-bottom:35px}.location-heading h3{font-size:clamp(2.6rem,4.2vw,4rem);line-height:1.05;margin:15px 0 24px}.location-heading p:not(.eyebrow){font-size:1.0625rem;line-height:1.8;color:#47515a}
.location-photo-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:26px}.location-photo,.specialist-image{margin:0;min-width:0}.location-photo img{aspect-ratio:16/10;object-fit:cover}.location-photo figcaption,.specialist-image figcaption{position:static;background:transparent;padding:14px 0 22px;color:#47515a;font-size:.875rem;line-height:1.5;text-transform:none;letter-spacing:normal}
.location-detail-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:32px;margin-top:28px}.location-detail-grid h4,.facility-subchapter h4{font-family:'Barlow Condensed','Arial Narrow',sans-serif;font-size:1.9rem;line-height:1.15;margin-bottom:18px}.facility-list{padding-left:19px;margin:20px 0;font-size:1rem;line-height:1.65;color:#47515a}.facility-list li{margin:10px 0}.facility-list li::marker{color:#a1161c}
.ratawi-pair{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:32px}.facility-subchapter{border:1px solid #c3c9cd;background:#fff;padding:28px}.facility-subchapter h4{font-size:2.2rem;margin-bottom:8px}.facility-subtitle{font-size:.875rem;color:#47515a;margin-bottom:25px}.facility-subchapter p:not(.facility-subtitle){font-size:1rem;line-height:1.75}.supporting-photos{margin-top:32px}.rumaila-details{grid-template-columns:repeat(2,minmax(0,1fr))}.rumaila-details p{font-size:1rem;line-height:1.75;color:#47515a}
.specialist-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:28px;border:0}.specialist-grid article{padding:28px;border:1px solid #c3c9cd;background:#fff}.specialist-image{margin:-28px -28px 24px}.specialist-image img{height:clamp(260px,28vw,430px);aspect-ratio:auto;object-fit:contain;background:#11171e}.specialist-image figcaption{padding:12px 28px;border-bottom:1px solid #d4d5d5;background:#f2f3f1}.specialist-grid .number{display:block;margin-bottom:14px}.specialist-grid h3{font-size:2.3rem;margin-bottom:18px}.specialist-grid .facility-list{font-size:.9375rem}
.qhse-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:32px;margin:42px 0}.qhse-grid article{padding:38px;border:1px solid #c3c9cd;background:#fff}.qhse-grid h3{font-size:2.6rem;line-height:1.05;margin:18px 0 24px}.qhse-grid p:not(.eyebrow),.qhse-support p{font-size:1rem;line-height:1.75;color:#47515a}.qhse-support{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:30px;margin-bottom:50px}.qhse-support h3{font-size:1.9rem;margin-bottom:18px}
.management-systems.certificate-section{display:block}.certificate-section>div:first-child{max-width:740px;margin-bottom:35px}.certificate-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:20px}.certificate-card{display:flex;flex-direction:column;gap:10px;padding:18px;background:#fff;color:#0b0f14;border:1px solid #aab0b6;min-width:0;transition:box-shadow .3s,border-color .3s}.certificate-card:hover{border-color:#a1161c;box-shadow:0 8px 24px #0b0f141a}.certificate-card:focus-visible{outline:3px solid #a1161c;outline-offset:4px}.certificate-card img{width:100%;height:260px;object-fit:contain;background:#f1f3f4;margin-bottom:12px}.certificate-card strong{font-family:'Barlow Condensed','Arial Narrow',sans-serif;font-size:1.9rem}.certificate-card span{font-size:.9375rem;line-height:1.5}.certificate-card .certificate-action{color:#a1161c;font-weight:700;padding-top:12px;margin-top:auto;min-height:44px}
@media(max-width:1000px){.certificate-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.certificate-card img{height:330px}.location-detail-grid,.qhse-support{gap:24px}.facility-subchapter{padding:22px}}
@media(max-width:800px){.location-chapter{padding:40px 0}.location-nav{margin-bottom:40px}.location-detail-grid,.qhse-support{grid-template-columns:1fr}.ratawi-pair,.qhse-grid{grid-template-columns:1fr}.qhse-grid article{padding:26px}.specialist-grid{grid-template-columns:1fr}.specialist-image img{height:auto;max-height:520px;aspect-ratio:16/11}.location-detail-grid>div+div,.qhse-support>article+article{border-top:1px solid #c3c9cd;padding-top:24px}}
@media(max-width:580px){.location-photo-grid{grid-template-columns:1fr}.certificate-grid{grid-template-columns:1fr}.certificate-card img{height:380px}.specialist-grid article{padding:22px}.specialist-image{margin:-22px -22px 22px}.specialist-image figcaption{padding:12px 22px}.location-nav a{padding:13px 18px}.qhse-grid h3{font-size:2.2rem}}
@media(prefers-reduced-motion:reduce){.certificate-card{transition:none}}

/* Part 8 — scoped project readability and centered reference introduction. */
#projects .project-secondary .project-copy > p:not(.eyebrow),
#projects .project-secondary .project-copy dd {
  color: #111111;
  font-size: clamp(1.08rem, 1.35vw, 1.25rem);
  line-height: 1.85;
}

#projects .project-archive .archive-heading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
  text-align: center;
}

#projects .project-archive .archive-heading > div {
  width: 100%;
}

#projects .project-archive .archive-heading h3 {
  font-size: clamp(2.3rem, 3.5vw, 3.4rem);
  line-height: 1.12;
}

#projects .project-archive .archive-heading > p {
  width: 100%;
  max-width: 850px;
  margin-inline: auto;
  color: #111111;
  font-size: clamp(1.08rem, 1.35vw, 1.25rem);
  line-height: 1.85;
}

/* Part 9 — enquiry introduction matches the specialist heading layout. */
#enquiries > .shell > .section-heading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 22px;
  text-align: center;
}

#enquiries > .shell > .section-heading > div {
  width: 100%;
}

#enquiries > .shell > .section-heading > p {
  width: 100%;
  max-width: 850px;
  margin-inline: auto;
  color: #111111;
  font-size: clamp(1.08rem, 1.5vw, 1.25rem);
  line-height: 1.85;
}

/* TAAM sign glow: lit signage on the facility photo (hero scene 03).
   The layer shares the photo's cover/position/scale so it stays locked to the sign. */
.hero-sign-glow{container-type:size;position:absolute;inset:0;z-index:-1;pointer-events:none;overflow:hidden;mix-blend-mode:screen;opacity:0;transform:scale(1.035);transition:opacity .6s ease}
.hero-sign-glow span{position:absolute;inset:0;background:url(assets/images/taam-sign-fill-2560.webp) 65% center/cover no-repeat;opacity:.9}
.hero-sign-glow span.halo{background-image:url(assets/images/taam-sign-halo-2560.webp);opacity:.55}
.hero.has-sign-glow .hero-sign-glow{opacity:1;transition:opacity 1.6s ease .5s}
html.motion-enabled .hero.is-in-view .hero-sign-glow{animation:taam-photo-drift 18s ease-in-out infinite alternate}
html.motion-enabled .hero.has-sign-glow .hero-sign-glow span{animation:taam-sign-breathe 5.5s ease-in-out infinite}
@keyframes taam-sign-breathe{0%,100%{opacity:.62}45%{opacity:1}52%{opacity:.93}}
@media(prefers-reduced-motion:reduce){.hero-sign-glow,.hero-sign-glow span{animation:none!important;transition:none!important;transform:none}}
@media print{.hero-sign-glow{display:none!important}}
.motion-off .hero-sign-glow{transform:none}

/* ENGINEERING lettering: letters light up one by one in white, in sync with the photo. */
.hero-sign-word{position:absolute;width:max(100cqw,150cqh);aspect-ratio:3/2;left:calc((100cqw - max(100cqw,150cqh))*.65);top:calc((100cqh - max(100cqw,150cqh)/1.5)*.5)}
.hero-sign-word i{position:absolute;display:block;width:3.1067%;height:4.6601%;background:url(assets/images/taam-engineering-letters.webp) no-repeat;background-size:1100% 100%;background-position:calc(var(--i)*10.0000%) 0;opacity:.85}
.hero-sign-word i:nth-child(1){left:73.2456%;top:56.3048%}
.hero-sign-word i:nth-child(2){left:74.6711%;top:56.2774%}
.hero-sign-word i:nth-child(3){left:76.1696%;top:56.2774%}
.hero-sign-word i:nth-child(4){left:77.4488%;top:56.2500%}
.hero-sign-word i:nth-child(5){left:78.7281%;top:56.2500%}
.hero-sign-word i:nth-child(6){left:80.0439%;top:56.2226%}
.hero-sign-word i:nth-child(7){left:81.4327%;top:56.1952%}
.hero-sign-word i:nth-child(8){left:82.8216%;top:56.1952%}
.hero-sign-word i:nth-child(9){left:84.0643%;top:56.1952%}
.hero-sign-word i:nth-child(10){left:85.3436%;top:56.1678%}
.hero-sign-word i:nth-child(11){left:86.7690%;top:56.1952%}
html.motion-enabled .hero.has-sign-glow .hero-sign-word i{animation:taam-letter-flash 4.6s linear infinite backwards;animation-delay:calc(var(--i)*.085s)}
@keyframes taam-letter-flash{0%{opacity:0}2.5%{opacity:1}45%{opacity:.95}62%{opacity:0}100%{opacity:0}}
@media(prefers-reduced-motion:reduce){.hero-sign-word i{animation:none!important;opacity:.7}}
@media print{.hero-sign-word{display:none!important}}
/* halo layer breathes within a tighter range than the crisp letter fill */
html.motion-enabled .hero.has-sign-glow .hero-sign-glow span.halo{animation-name:taam-halo-breathe}
@keyframes taam-halo-breathe{0%,100%{opacity:.3}45%{opacity:.62}52%{opacity:.55}}

/* Tank repairs & internals: fill the photo frame without dark letterboxing. */
@media screen {
  .specialist-image .photo-open img[src$="tank-refurbishment-1280.webp"] {
    object-fit: cover;
    object-position: center;
  }
}

/* Requested About TAAM heading size. */
#about > .shell > .section-label {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  line-height: 1.2;
}

/* Supplied client logos, kept in their original colours and proportions. */
.portfolio-clients > .shell {
  display: block;
}

.portfolio-clients #clients-title {
  margin: 0 0 30px;
  color: #fff;
  font-size: clamp(2.4rem, 4vw, 3.6rem);
  line-height: 1.05;
}

.client-logo-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 16px;
}

.client-logo-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-width: 0;
  margin: 0;
  padding: 20px 16px 15px;
  border-radius: 10px;
  background: #fff;
  color: #18232d;
}

.client-logo-card--dark {
  background: #162732;
  color: #fff;
}

.client-logo-frame {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100px;
}

.client-logo-frame img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  border: 0;
  filter: none;
}

.client-logo-card figcaption {
  margin-top: 16px;
  color: inherit;
  font: 700 13px/1.4 'Manrope', 'Segoe UI', Arial, sans-serif;
  text-align: center;
  overflow-wrap: anywhere;
}

@media (max-width: 1100px) {
  .client-logo-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

@media (max-width: 760px) {
  .client-logo-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
  .client-logo-card { padding: 16px 12px 13px; }
  .client-logo-frame { height: 85px; }
}

@media (max-width: 480px) {
  .client-logo-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .client-logo-card figcaption { font-size: 12px; }
}

@media print {
  .portfolio-clients #clients-title { color: #111; }
  .client-logo-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .client-logo-card { break-inside: avoid; }
  .client-logo-card--dark { print-color-adjust: exact; }
}
