html, body
{
  -webkit-hyphens: auto;
  -moz-hyphens: auto;
  -ms-hyphens: auto;
   hyphens: auto;
}

td.text-center, th.text-center
{
  text-align: center;
  vertical-align: middle;
}

.table thead th {
   text-align: center;
   vertical-align: middle;
}

.galleryItem {
    color: #797478;
    font: 10px/1.5 Verdana, Helvetica, sans-serif;
    float: left;
    min-height: 170px;
    min-width:  170px;
}

.galleryItem h3 {
    text-transform: uppercase;
}

.galleryItem img {
    max-width: 100%;
    -webkit-border-radius: 5px;
    -moz-border-radius: 5px;
    border-radius: 5px;
    vertical-align: middle;
    margin: 0 auto;
}

img.news {
    max-width: 100%;
    -webkit-border-radius: 5px;
    -moz-border-radius: 5px;
    border-radius: 5px;
    vertical-align: middle;
    margin: 0 auto;
}

.model_vert_ads {
    width: 300px;
    height: 600px;
}

.railcar_description p {
    text-align: justify;
    text-indent: 1.5em;
}

.main_text {
    text-align: justify;
    text-indent: 1.5em;
    font-size: large;
}

.child-mn {
    padding-left: 20px;
}

nav.center
{
    margin: 0 auto;
    text-align: center;
}

.news h2, .cardescr h1
{
    font-size: 170%;
    font-weight: bolder;
}

.cardescr h2
{
    font-size: 130%;
    font-weight: bolder;
}

/* Was an <h4> nested inside its own link. It is the photo page's heading, so it is an
   <h1> now with the link inside it; this keeps the size it had. */
h1[itemprop="name"] {
    font-size: 1.5rem;
    font-weight: 500;
}

p
{
    text-align: justify;
    text-indent: 1em;
}

.sameval
{
   background-color:#d8f9bb;
}

.thebest
{
    background-color:#b5ddf7;
}

h1 {
    font-size: 2.0rem;
}

/* The site name beside the logo. It is an <h1> on the home page, where it is that
   page's heading, and a <div> everywhere else, where the page has its own. Both must
   look the same, so the rule matches on the class rather than the element -- and it
   restates the h1 metrics because a <div> inherits none of them. */
/* Bootstrap's .visually-hidden-focusable only restores the element to the flow; on focus the
   link would otherwise appear unstyled in the top-left corner over the header. */
.skip-link:focus,
.skip-link:active {
    display: inline-block;
    padding: .5rem 1rem;
    background: #fff;
    border: 2px solid #333;
    z-index: 1000;
}

.site-title {
    font-size: 2.0rem;
    font-weight: 500;
    line-height: 1.2;
    margin-top: 0;
    margin-bottom: .5rem;
}

h2 {
    font-size: 1.5rem;
}

/* Bootstrap 5 dropped the label spacing its reboot used to give every <label> and moved it
   to .form-label; labels here come from five rendering paths, so restore it in one place.
   :where() keeps it at zero specificity so any utility class on a label still wins. */
:where(label:not(.form-check-label)) {
    margin-bottom: .5rem;
}

.breadcrumb {
    --bs-breadcrumb-bg: var(--bs-secondary-bg);
    --bs-breadcrumb-padding-x: 1rem;
    --bs-breadcrumb-padding-y: .75rem;
    --bs-breadcrumb-border-radius: var(--bs-border-radius);
}

label.required:after {
    content:" *";
    color: red;
}

.calibration-columns {
    column-count: 4;
}

.gallery-photo {
    max-width: 100%;
    max-height: 100%;
}

/* Initial hidden state for elements jQuery's .show()/.hide() toggles at runtime.
   Deliberately not Bootstrap's .d-none: its !important would block .show() from
   overriding it with an inline display value. */
.initially-hidden {
    display: none;
}

/* Sign-in, registration, password and profile pages: one centred card instead of a
   bare form stretched across the content column. Same look as railwayz.info's
   .rzi-auth, which shares these accounts. */
.auth-card {
    max-width: 26rem;
    margin: 0 auto 20px;

    /* Below md the header collapses into a navbar that the card would touch. */
    @media (max-width: 767.98px) {
        margin-top: 1rem;
    }

    h1 {
        margin-top: 0;
    }

    .card {
        box-shadow: 0 2px 12px rgba(0, 0, 0, .06);
    }

    .card-body {
        padding: 1.75rem;
    }

    /* RenderForm wraps the submit button in .mb-3, which leaves a gap above the
       card's bottom edge. !important because Bootstrap's spacing utilities carry it. */
    form > :last-child {
        margin-bottom: 0 !important;
    }

    /* Field errors arrive as a <ul>; one or two short lines read better unbulleted. */
    ul.invalid-feedback {
        list-style: none;
        padding-left: 0;
        margin-bottom: 0;
    }

    .form-label {
        font-weight: 700;
    }

    /* The registration captcha: Laminas renders it as a fieldset, whose legend
       Bootstrap 5 sets at 1.5rem - a heading-sized label among bold small ones. */
    legend {
        font-size: inherit;
        font-weight: 700;
        margin-bottom: .5rem;
    }

    fieldset img {
        display: block;
        max-width: 100%;
        height: auto;
        margin-bottom: .5rem;
        border: 1px solid var(--bs-border-color);
        border-radius: var(--bs-border-radius);
    }
}

.auth-options {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: .5rem;
    margin-bottom: 1.5rem;

    .form-check {
        margin-bottom: 0;
    }
}

.auth-divider {
    display: flex;
    align-items: center;
    gap: .75rem;
    margin: 1.5rem 0;
    color: var(--bs-secondary-color);
    font-size: .8125rem;

    &::before,
    &::after {
        content: "";
        flex: 1;
        border-top: 1px solid var(--bs-border-color);
    }
}

.auth-social {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: .5rem;

    .btn {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: .5rem;
        --bs-btn-color: var(--bs-body-color);
        --bs-btn-hover-color: var(--bs-body-color);
        --bs-btn-hover-bg: var(--bs-tertiary-bg);
        --bs-btn-hover-border-color: var(--bs-secondary);
    }
}

/* Profile: the same card, wider, as a column of cards. */
.auth-card-wide {
    max-width: 36rem;

    > .card + .card {
        margin-top: 1rem;
    }

    h2 {
        margin-bottom: .25rem;
        font-weight: 700;
    }
}

.auth-hint {
    margin-bottom: 1rem;
    color: var(--bs-secondary-color);
    font-size: .8125rem;
}

/* A hint that belongs to the field just above it: pulled up into the field's own
   bottom margin, so it reads as that field's note rather than the next one's. */
.mb-3 + .auth-hint,
legend + .auth-hint {
    margin-top: -.5rem;
}

.auth-password {
    margin: 1.5rem 0 .5rem;
    padding-top: 1rem;
    border-top: 1px solid var(--bs-border-color-translucent);
}

.auth-lang-list {
    display: flex;
    flex-wrap: wrap;
    gap: .4rem;
    margin: 0 0 1rem;
    padding: 0;
    list-style: none;

    li {
        display: inline-flex;
        align-items: center;
        gap: .4rem;
        padding: .25rem .5rem .25rem .75rem;
        background: var(--bs-tertiary-bg);
        border: 1px solid var(--bs-border-color);
        border-radius: 999px;
    }

    .btn-close {
        width: .6em;
        height: .6em;
        padding: .25em;
        background-size: .6em;
    }
}

.auth-lang-add {
    display: flex;
    gap: .5rem;

    .form-select {
        flex: 1 1 auto;
        min-width: 0;
    }
}
