/* Loaded only for production pages, never for style-preview.php.
   Loaded after the screen styles so page margins have one final owner. */
@page {
  size: auto;
  margin: 56mm 18mm 24mm;
  @top-center {
    content: url("/core/images/gtabiri-letterhead.svg");
    text-align: center;
    vertical-align: middle;
    width: 100%;
  }
  @bottom-center {
    content: "Gyata Tabiri · Bethlehem, Pennsylvania\A gtabiri.com · info@gtabiri.com · +1 484 484 2601";
    white-space: pre;
    color: #666;
    font: 400 8pt/1.35 "Source Sans 3", Arial, sans-serif;
    text-align: center;
    vertical-align: top;
    border-top: .35pt solid #aaa;
    padding-top: 3mm;
    width: 100%;
  }
  @bottom-right {
    content: counter(page);
    color: #666;
    font: 400 8pt "Source Sans 3", Arial, sans-serif;
    vertical-align: bottom;
    padding-bottom: 7mm;
  }
}
@media print {
  html { color-scheme: light !important; }
  html body {
    page: auto;
    background: white !important;
    color: #010b13 !important;
    font: 400 11pt/1.45 "Source Sans 3", Arial, sans-serif;
    margin: 0 !important;
    padding: 0 !important;
  }
  .navbar, #site-footer, #read-progress, .skip-link, #topicsToolbar,
  .insights-topics-column, .site-appearance, .home-logo, body > header,
  .button-group, .calendly-inline-widget { display: none !important; }
  :is(main,.section,.gallery-shell) { padding-block: 0 !important; margin-block: 0 !important; }
  .section > .container { margin-top: 0 !important; }
  body .container, .gallery-shell { width: 100% !important; max-width: none !important; padding-inline: 0; }
  .insights-layout { display: block; padding-top: 0 !important; margin: 0 !important; }
  .insights-layout > main { max-width: 100%; width: 100%; padding: 0; }
  :is(main,.section) :is(p,li,td,th,dd) { font-size: 11pt; line-height: 1.45; }
  :is(main,.section) :is(h1,h2,h3,h4,h5,h6) { color: #951716; text-wrap: balance; }
  :is(h1,h2,h3,h4,h5,h6,dt) { break-after: avoid; }
  h1, .section-heading, .contact-intro h1 { font-size: 24pt !important; line-height: 1.15; margin-top: 0; }
  h2 { font-size: 18pt; }
  h3 { font-size: 14pt; }
  p, li, dd { widows: 3; orphans: 3; }
  a { color: #951716; text-decoration: underline; }
  .btn, .read-more-btn, .gallery-search, .gallery-size, .gallery-controls { display: none !important; }
  .row > [class*="col-"] { min-width: 0; }
  :is(.card,.case-highlights,.case-highlights-card,.contact-option,.contact-save-card,.contact-details-panel,.highlight-item) {
    background: white !important;
    color: #010b13;
    box-shadow: none !important;
    transform: none !important;
  }
  .card-custom { border: .5pt solid #ddd; border-radius: 2mm; }
  .card-custom .card-body { padding: 4mm; }
  .case-highlights, .case-highlights-card { padding: 4mm; border: .5pt solid #aaa; margin-block: 5mm; }
  figure, blockquote, tr { break-inside: avoid; }
  figure { margin-block: 5mm; }
  figcaption { font-size: 9pt !important; line-height: 1.35; break-before: avoid; }
  img { max-width: 100% !important; }
  figure img { max-height: 90mm; width: auto; height: auto; object-fit: contain; }
  .table-responsive { overflow: visible; }
  .timeline-table { table-layout: auto; font-size: 10pt; }
  .timeline-table :is(td,th) { padding: 2mm 3mm; font-size: 10pt !important; overflow-wrap: anywhere; }
  thead { display: table-header-group; }
  tfoot { display: table-row-group; }
  .quote-styled-block { position: relative; inset: auto; max-width: 100%; margin: 7mm 0 5mm; padding: 5mm 5mm 5mm 8mm; break-inside: avoid; box-shadow: none; border: .5pt solid #aaa; background: white; }
  .quote-styled-block .quote-mark { top: -3mm; left: 1mm; font-size: 36pt; }
  .quote-styled-block .quote-content p { font-size: 13pt; color: #010b13; }
  .quote-content footer { background: white; box-shadow: none; font-size: 9pt; }
  pre { white-space: pre-wrap; overflow-wrap: anywhere; border: .5pt solid #aaa; padding: 3mm; }
  /* Cards print as a compact catalogue rather than desktop-sized panels. */
  :is(#home,#case-studies,#portfolio,#services) .row { display: block; margin-inline: 0; }
  :is(#home,#case-studies,#portfolio,#services) .row > [class*="col-"] { width: 100%; max-width: 100%; padding-inline: 0; }
  :is(#home,#case-studies,#portfolio,#services) .card-custom { height: auto !important; break-inside: avoid; margin-bottom: 5mm; }
  :is(#home,#case-studies,#portfolio) .card-custom:has(> a > .card-img-top),
  :is(#home,#case-studies,#portfolio) .card-custom:has(> .card-img-top) { display: grid; grid-template-columns: 38mm minmax(0,1fr); gap: 4mm; }
  :is(#home,#case-studies,#portfolio) .card-img-top { width: 38mm !important; height: 38mm !important; object-fit: cover; }
  #home .jumbotron { padding: 0 !important; margin-bottom: 6mm; }
  #home .elevator-pitch { max-width: none; }
  #home section[aria-labelledby="home-work"] { break-before: auto; }
  #home section[aria-labelledby="home-work"] .card-custom { grid-template-columns: 38mm minmax(0,1fr); }
  #home section[aria-labelledby="home-work"] .card-body { padding: 4mm; }
  .contact-intro { padding-bottom: 5mm; }
  .contact-intro > [class*="col-"] { flex: 0 0 100%; max-width: 100%; }
  .contact-options { display: block; }
  .contact-options > [class*="col-"] { max-width: 100%; }
  .contact-option { min-height: 0; padding: 4mm; border: .5pt solid #aaa; break-inside: avoid; }
  .contact-save-card { padding: 4mm; margin: 5mm 0; border: .5pt solid #aaa; }
  /* Live interactions belong online; retain their surrounding explanation. */
  .gt-inquiry-form { display: none !important; }
  .gt-print-form-note { display: block !important; padding: 3mm 4mm; border-left: 2pt solid #951716; margin-block: 5mm; font-size: 10pt; }
  .gallery-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 4mm; }
  .gallery-card { box-shadow: none; break-inside: avoid; }
  .gallery-card img { height: auto; }
}
@page {
  @bottom-center { margin-top: 4mm; }
}
@media print {
  /* Readable even when the visitor leaves “Background graphics” switched off. */
  .timeline-table thead :is(th,td) {
    background: white !important;
    color: #951716 !important;
    font-weight: 700;
    border-bottom: .75pt solid #951716;
  }
  .timeline-table tfoot :is(th,td) { background: white !important; color: #010b13 !important; }
  .gallery-control { display: none !important; }
  .sched-fallback { font-size: 0 !important; }
  .sched-fallback a { font-size: 0; }
  .sched-fallback::after { content: "Book online: calendly.com/gtabiri/one-on-one"; font-size: 10pt; color: #4a4a4a; }
}
@media print {
  #contact .contact-save-card { display: none !important; }
  #contact .contact-option .contact-option-button {
    display: inline !important; align-self: flex-start; min-height: 0;
    padding: 0; margin: 2mm 0 0; border: 0; border-radius: 0;
    background: transparent; color: #951716; font-size: 10pt; font-weight: 600;
  }
  #contact .contact-option-button[href*="schedule-appointment"]::after { content: " (gtabiri.com/schedule-appointment.php)"; }
  .about-portrait { max-height: 65mm; width: auto; max-width: 100%; box-shadow: none; }
}
@media print {
  .about-page { position: relative; padding-block: 0 !important; }
  .about-page > .row { display: block; margin: 0 !important; }
  .about-page > .row > .col-md-7 { max-width: none; width: 100%; padding: 0 !important; }
  .about-page > .row > .col-md-5 { position: absolute; top: 0; right: 0; width: 42mm; padding: 0; }
  .about-page :is(h1,.lead,.about-kicker) { max-width: calc(100% - 48mm); }
  .about-page .lead { min-height: 35mm; }
  .about-page .about-portrait { width: 42mm; max-height: 55mm; object-fit: cover; }
}
