/* Ferm: shared reading rules and second-hand machinery catalog. */
body { font-size: 15px; line-height: 1.65; }
.ferm-richtext { font-size: 15px; line-height: 1.7; overflow-wrap: anywhere; }
.ferm-richtext p { margin: 0 0 1em; }
.ferm-richtext ul, .ferm-richtext ol { padding-left: 1.5em; margin: 1em 0; }
.ferm-richtext li { margin-bottom: .5em; }
.ferm-richtext blockquote { border-left: 3px solid #A22E37; padding: .4em 1em; margin: 1.4em 0; }
.ferm-richtext h2, .ferm-richtext h3, .ferm-richtext h4 { margin: 1.5em 0 .7em; }
.ferm-richtext img { max-width: 100%; height: auto; }
.ferm-richtext table { max-width: 100%; display: block; overflow-x: auto; }
.ferm-richtext a { text-decoration: underline; text-underline-offset: .2em; }
.ferm-machinery { margin: 30px 0 60px; }
.ferm-machine-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 26px; }
.ferm-machine-card { border: 1px solid #e2e7eb; background: #fff; display: flex; flex-direction: column; border-radius: 6px; overflow: hidden; transition: box-shadow .2s; }
.ferm-machine-card:hover { box-shadow: 0 8px 28px rgba(0,0,0,.09); }
.ferm-machine-image { display: block; background: #f4f6f8; }
.ferm-machine-image img { width: 100%; height: auto; aspect-ratio: 4/3; object-fit: contain; }
.ferm-machine-content { padding: 22px; display: flex; flex-direction: column; flex: 1; }
.ferm-machine-content h3 { font-size: 19px; line-height: 1.35; overflow-wrap: anywhere; }
.ferm-machine-content p { white-space: normal; overflow-wrap: anywhere; }
.ferm-machine-download { margin-top: auto; padding-top: 18px; color: #A22E37; font-weight: 600; display: flex; justify-content: space-between; }
.ferm-machine-download:hover { text-decoration: underline; }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible { outline: 2px solid #A22E37; outline-offset: 3px; }
.vehicle-gallery img { max-width: 100%; height: auto; }
.ferm-video { width: 100%; max-width: 720px; aspect-ratio: 16/9; height: auto; border: 0; padding: 0; }
#footer-wrapper input, #footer-wrapper textarea { max-width: 100%; }
@media (max-width: 991px) { .ferm-machine-grid { grid-template-columns: repeat(2,minmax(0,1fr)); } .service-body { min-height: 0; } }
@media (max-width: 767px) { .ferm-machine-grid { grid-template-columns: 1fr; gap: 20px; } .ferm-machine-content { padding: 20px; } .row { margin-bottom: 40px; } .page-content img { max-width: 100%; height: auto; } .page-title-style01 h1 { overflow-wrap: anywhere; } .blog-posts .post-body { overflow-wrap: anywhere; } }
@media (prefers-reduced-motion: reduce) { .ferm-machine-card { transition: none; } }

.ferm-notices { position: relative; z-index: 3; margin-top: 210px; padding: 16px 24px; background: #f4f6f8; border-left: 3px solid #A22E37; }
@media(max-width:767px) { .ferm-notices { margin-top: 180px; } }

.ferm-richtext p, .ferm-richtext li { line-height: inherit; }
.ferm-richtext p { padding-bottom: 0; }

/* Optimized footer background */
#footer-wrapper {
    background-image: url('../img/footer-bkg.webp');
}

/* MasterSlider space reservation to prevent layout shift */
#masterslider.ferm-reserved-slider {
    width: 100%;
    aspect-ratio: 1140 / 854;
    max-height: 854px;
    background-color: #1a1a1a;
}

/* Standalone machinery detail: existing Ferm colours and heading fonts. */
.ferm-machine-detail { padding-bottom: 65px; }
.ferm-machine-back { display: inline-block; margin: 0 0 24px; color: #A22E37; font-weight: 600; }
.ferm-machine-hero { display: grid; grid-template-columns: minmax(0,1.2fr) minmax(0,1fr); gap: 44px; align-items: start; }
.ferm-machine-visual { background: #f4f6f8; border: 1px solid #e2e7eb; border-radius: 6px; overflow: hidden; }
.ferm-machine-visual img { display: block; width: 100%; height: auto; aspect-ratio: 4/3; object-fit: contain; }
.ferm-machine-eyebrow { display: block; color: #A22E37; font-weight: 600; margin: 0 0 12px; }
.ferm-machine-overview h2 { font-size: 28px; line-height: 1.3; overflow-wrap: anywhere; }
.ferm-machine-summary { line-height: 1.75; overflow-wrap: anywhere; }
.ferm-machine-document { margin-top: 26px; padding: 24px; background: #f4f6f8; border-left: 3px solid #A22E37; }
.ferm-machine-document h3 { font-size: 17px; margin-bottom: 12px; }
.ferm-machine-cta { display: flex; justify-content: space-between; padding: 12px 18px; background: #A22E37; color: #fff; border-radius: 3px; font-weight: 600; }
.ferm-machine-cta:hover, .ferm-machine-cta:focus { background: #82252c; color: #fff; }
.ferm-machine-enquiry { display: inline-block; margin-top: 24px; color: #A22E37; font-weight: 600; }
.ferm-machine-information { margin-top: 48px; padding-top: 32px; border-top: 1px solid #e2e7eb; }
.ferm-machine-information .ferm-richtext { max-width: 860px; }
@media (max-width: 991px) { .ferm-machine-hero { gap: 26px; } }
@media (max-width: 767px) { .ferm-machine-hero { grid-template-columns: minmax(0,1fr); } .ferm-machine-overview h2 { font-size: 24px; } .ferm-machine-information { margin-top: 32px; } }

/* Honeypot hidden fields */
.ferm-hp-field {
    display: none !important;
    position: absolute !important;
    left: -9999px !important;
    top: -9999px !important;
    width: 1px !important;
    height: 1px !important;
    opacity: 0 !important;
    pointer-events: none !important;
    z-index: -1 !important;
}

/* Turnstile container styling & mobile overflow protection */
.ferm-turnstile-wrap {
    margin: 14px 0 16px 0;
    max-width: 100%;
    overflow: hidden;
}

.ferm-turnstile-wrap .cf-turnstile {
    max-width: 100%;
    display: inline-block;
}

.ferm-turnstile-wrap iframe {
    max-width: 100% !important;
}

.ferm-turnstile-newsletter {
    clear: both;
    margin-top: 10px;
    margin-bottom: 6px;
    width: 100%;
}

/* The footer column can be narrower than Turnstile's 300px flexible minimum.
   Use its native 150x140 compact widget without cropping or scaling it. */
.ferm-turnstile-newsletter {
    overflow: visible;
    min-height: 140px;
}

.ferm-turnstile-newsletter .cf-turnstile {
    width: 150px;
    min-height: 140px;
}

.ferm-newsletter-input-wrap {
    position: relative;
    width: 100%;
    display: block;
}

.ferm-turnstile-noscript {
    margin-top: 8px;
    font-size: 13px;
    padding: 8px 12px;
    background-color: #fff3cd;
    color: #856404;
    border: 1px solid #ffeeba;
    border-radius: 4px;
}

.ferm-form-errors {
    margin-bottom: 15px;
    padding: 10px 15px;
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
    border-radius: 4px;
}

.ferm-privacy-note {
    margin-top: 10px;
    margin-bottom: 0;
    font-size: 11px;
    line-height: 1.4;
    color: #888888;
}


