/* BGS licence pages - shared stylesheet
   Deploy at: licences/licences.css  (served as /licences/licences.css)
   Used by all licence pages and the licence index so styling cannot drift. */

body {
  background-color: #ffffff;
  font-family: Verdana, Arial, Helvetica, sans-serif;
  font-size: 0.75em;
  line-height: 150%;
  margin: 0px auto;
}

#hdr {
  background-color: #ffffff;
  clear: both;
  display: inline-block;
  margin: 6px 0 !important;
  padding: 0 !important;
}

#ogl-logo-holder {
  float: right;
  text-align: right;
  padding: 20px 20px 0px 80px;
}

#bgs-logo-holder {
  margin-left: 20px;
}

.bgs-logo-holder {
  margin-left: 20px;
}

#licence-logo-holder {
  padding: 20px 0px 0px 20px;
}

@media only screen and (min-width: 987px) {
  #bgs-logo-holder {
    float: right;
    text-align: right;
    padding: 20px 20px 0px 80px;
  }

  .bgs-logo-holder {
    float: right;
    text-align: right;
    margin-left: 140px;
    margin-top: 20px;
  }

  #licence-logo-holder {
    float: left;
  }
}

#open-licence-logo {
  width: 100%;
  max-width: 500px;
}

.back-to-bgs {
  display: block;
  text-align: left;
  margin-left: 12px;
}

@media only screen and (min-width: 1010px) {
  #license {
    border-left: 4px solid #ccc;
    border-right: 4px solid #ccc;
  }
}

#license {
  margin: 0px auto;
  padding: 0px 14px 100px 14px;
  max-width: 960px;
}

img {
  max-width: 100%;
}

#bgs-logo {
  width: 260px;
  height: auto;
}

#back-to-bgs {
  background-color: #fff;
  margin: 5px auto;
  padding: 10px 20px 10px 10px;
  text-align: right;
  width: 740px;
}

ul.redex {
  list-style-type: none;
  padding: 0px;
  margin: 0px;
}

ul.redex li {
  background: url("/images/infoman/licence-redex.gif") 0px 5px no-repeat;
  margin-left: 12px;
  margin-right: 12px;
  padding: 5px 0px 10px 40px;
  line-height: 200%;
}

ul.exempt {
  line-height: 200%;
}

p {
  padding: 12px 20px 0px;
}

h1 {
  padding: 12px 20px 0px;
}

h2 {
  padding: 12px 20px 0px;
}

h3 {
  padding: 12px 20px 0px;
}

#footer-bar {
  background-color: #eeeeee;
  border-top: 4px solid #d9d9d9;
  clear: both;
  font-size: 1em;
  padding: 12px 0;
  margin-top: 24px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.sr-only-focusable:active,
.sr-only-focusable:focus {
  position: static;
  width: auto;
  height: auto;
  margin: 0;
  overflow: visible;
  clip: auto;
}

.research-banner {
  background-color: #fbe2bc;
  border-bottom: 1px solid rgb(0 0 0 /0.15);
}
.research-banner__inner {
  max-width: 908px;
  margin: 0 auto;
  padding: 2px 40px 12px;
  display: flex;
  gap: 20px;
  align-items: center;
}
.research-banner__title {
  margin: 10px 0 0;
  padding: 0 5px;
  line-height: 1.5;
  background-color: #fff;
  text-transform: uppercase;
  font-size: 1.25em;
  display: inline-block;
}
.research-banner__body {
  margin: 10px 0 0;
  padding: 0;
  flex: 1;
  font-size: 1.25em;
}

.tick, .cross, .warn, .exempt {
  list-style: none;
  padding-left: 0;
}

.tick li, .cross li, .warn li, .exempt li {
  padding-left: 2em;
  margin-bottom: 1em;
  background-repeat: no-repeat;
  background-position: left 2px;
  background-size: 1.2em;
}

/* Green Tick SVG */
.tick li {
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%233d854d"><path d="M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"/></svg>');
}

/* Red Cross SVG */
.cross li {
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%23a31e22"><path d="M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"/></svg>');
}

/* Amber Warning Triangle SVG */
.warn li {
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%23ff9102"><path d="M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z"/></svg>');
}

/* Red Octagon "out of scope" SVG (Exempt) */
.exempt li {
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%23a31e22"><path d="M7.27 1.73 1.73 7.27v9.46l5.54 5.54h9.46l5.54-5.54V7.27L16.73 1.73H7.27zM11 7h2v6h-2V7zm0 8h2v2h-2v-2z"/></svg>');
}

/* ---- Top-level licence index page ---- */
.container { max-width: 960px; margin: 0 auto; padding: 2em; }
.licence-list { list-style: none; padding: 0; margin-top: 2em; }
.licence-list li { margin-bottom: 1em; }
.licence-list a {
  display: block; padding: 1em; border: 1px solid #ccc; border-radius: 4px;
  text-decoration: none; font-size: 1.2em;
}
.licence-list a:hover { background-color: #f5f5f5; border-color: #005ea5; }

/* Secondary PDF link - must override the block-button rules above */
.licence-list a.pdf-link {
  display: inline-block;
  margin: 0.5em 0 0 1em;
  padding: 0;
  border: none;
  border-radius: 0;
  font-size: 1em;
  text-decoration: underline;
}
.licence-list a.pdf-link:hover { background-color: transparent; border: none; }
.licence-list .file-meta { color: #555; text-decoration: none; }

/* ---- Definitions: two-column term / definition layout ----
   Kept as <dl>/<dt>/<dd> - the correct semantics for term/definition pairs -
   and floated into aligned columns. Floats (rather than CSS grid) so it renders
   identically in older engines and in PDF/print renderers. */
#license dl {
  margin: 12px 20px 0;
  padding: 0;
  overflow: hidden;                 /* contain the floats */
  border-bottom: 1px solid #d9d9d9;
}
#license dt {
  float: left;
  clear: left;                      /* each term starts a new row */
  width: 22%;
  margin: 0;
  padding: 0.85em 1.5% 0.85em 0;
  font-weight: bold;
  border-top: 1px solid #d9d9d9;
}
#license dd {
  float: left;
  width: 74%;
  margin: 0;
  padding: 0.85em 0;
  border-top: 1px solid #d9d9d9;
}

/* Stack to a single column on narrow screens */
@media only screen and (max-width: 700px) {
  #license dt,
  #license dd { float: none; width: auto; }
  #license dt { padding-bottom: 0.25em; }
  #license dd { padding-top: 0; border-top: none; }
}