/* CivicSpan Municipal Web Suite 4.2 — theme "Heritage Navy" — customized for City of Perttula, 2014
   Grid based on Bootstrap 3. See docs/design-tokens.md section 3. */

@font-face { font-family: "Open Sans"; src: url("/fonts/open-sans-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Open Sans"; src: url("/fonts/open-sans-600.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Open Sans"; src: url("/fonts/open-sans-700.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Oswald"; src: url("/fonts/oswald-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }

:root {
  --civic-navy: #1C2E5B;
  --roughneck-gold: #C99A1E;
  --panel: #EEF2F6;
  --alert: #FFF1BF;
  --link: #0B57A4;
  --text: #232323;
}

* { box-sizing: border-box; }
html { font-size: 15px; }
body.fs-lg { font-size: 17px; }
body.fs-xl { font-size: 19px; }
body { margin: 0; font-family: "Open Sans", Arial, sans-serif; font-size: 1rem; line-height: 1.6; color: var(--text); background: #fff; }
body.fs-lg { font-size: 1.14rem; } body.fs-xl { font-size: 1.28rem; }
a { color: var(--link); }
a:hover, a:focus { color: #073B70; }
:focus-visible { outline: 0; box-shadow: 0 0 0 3px rgba(102, 175, 233, .9); border-radius: 2px; }
img { max-width: 100%; height: auto; }
h1, h2, h3, h4 { font-weight: 600; color: var(--civic-navy); line-height: 1.25; }
h1 { font-size: 2em; margin: 0 0 .5em; }
h2 { font-size: 1.45em; margin: 1.2em 0 .5em; }
h3 { font-size: 1.15em; margin: 1em 0 .4em; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 10px; top: 10px; background: #fff; padding: 8px; z-index: 100; }

.container { max-width: 1170px; margin: 0 auto; padding: 0 15px; }
.row { display: flex; flex-wrap: wrap; margin: 0 -15px; }
.col-3, .col-4, .col-6, .col-8, .col-9, .col-12 { padding: 0 15px; }
.col-3 { width: 25%; } .col-4 { width: 33.333%; } .col-6 { width: 50%; } .col-8 { width: 66.666%; } .col-9 { width: 75%; } .col-12 { width: 100%; }

/* Alert bar */
.alertbar { background: var(--alert); border-left: 6px solid #D4A300; border-bottom: 1px solid #E8D48A; font-size: .93em; }
.alertbar .container { padding-top: 7px; padding-bottom: 7px; }
.alertbar strong { font-family: "Oswald", "Arial Narrow", sans-serif; font-weight: 500; text-transform: uppercase; letter-spacing: .5px; margin-right: 6px; }

/* Utility bar */
.utility { background: #F5F7FA; border-bottom: 1px solid #D5DCE4; font-size: .87em; }
.utility .container { display: flex; justify-content: flex-end; align-items: center; gap: 18px; padding-top: 5px; padding-bottom: 5px; flex-wrap: wrap; }
.utility button.fs { background: none; border: 1px solid #C3CCD6; border-radius: 3px; padding: 0 6px; cursor: pointer; font-family: Georgia, serif; color: var(--civic-navy); }
.utility select, .utility input { font: inherit; padding: 2px 6px; border: 1px solid #B8C2CD; border-radius: 3px; }

/* Header banner: the one bold place */
.banner { position: relative; background: var(--civic-navy) center / cover no-repeat; min-height: 230px; color: #fff; }
.banner::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(20, 33, 66, .88) 0%, rgba(20, 33, 66, .55) 45%, rgba(20, 33, 66, 0) 75%); }
.banner .container { position: relative; z-index: 1; display: flex; align-items: center; gap: 22px; min-height: 230px; }
.banner .seal { width: 128px; height: 128px; flex: none; filter: drop-shadow(0 2px 3px rgba(0, 0, 0, .4)); }
.banner .cityname { font-family: "Oswald", "Arial Narrow", sans-serif; font-weight: 500; font-size: 2.9em; line-height: 1.05; text-transform: uppercase; letter-spacing: 1px; margin: 0; color: #fff; text-shadow: 0 2px 4px rgba(0, 0, 0, .5); }
.banner .motto { font-style: italic; font-size: 1.25em; margin: 4px 0 0; color: #F3E3B0; text-shadow: 0 1px 3px rgba(0, 0, 0, .6); }
.banner a { color: #fff; text-decoration: none; }

/* Main navigation */
.mainnav { background: var(--civic-navy); border-top: 3px solid var(--roughneck-gold); position: relative; z-index: 20; }
.mainnav > .container > ul { list-style: none; margin: 0; padding: 0; display: flex; }
.mainnav li { position: relative; }
.mainnav > .container > ul > li > a { display: block; padding: 13px 18px; color: #fff; text-decoration: none; font-family: "Oswald", "Arial Narrow", sans-serif; font-weight: 500; text-transform: uppercase; font-size: 1.07em; letter-spacing: .6px; border-bottom: 3px solid transparent; }
.mainnav > .container > ul > li > a:hover, .mainnav > .container > ul > li:focus-within > a { border-bottom-color: var(--roughneck-gold); background: #243A70; }
.mainnav .drop { display: none; position: absolute; left: 0; top: 100%; background: #fff; min-width: 240px; border: 1px solid #D5DCE4; border-top: 3px solid var(--roughneck-gold); padding: 8px 0; list-style: none; margin: 0; box-shadow: 0 6px 12px rgba(0, 0, 0, .175); }
.mainnav .drop.mega { display: none; min-width: 620px; padding: 14px 18px; column-count: 3; column-gap: 24px; }
.mainnav li:hover > .drop, .mainnav li:focus-within > .drop { display: block; }
.mainnav .drop a { display: block; padding: 5px 16px; color: var(--link); text-decoration: none; font-size: .95em; }
.mainnav .drop.mega a { padding: 4px 0; break-inside: avoid; }
.mainnav .drop a:hover, .mainnav .drop a:focus { background: var(--panel); text-decoration: underline; }
.navtoggle { display: none; }

/* Quick link tiles */
.tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; border-left: 1px solid #D5DCE4; margin: 24px 0; }
.tile { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; padding: 22px 10px; background: var(--panel); border: 1px solid #D5DCE4; border-left: 0; margin-top: -1px; text-align: center; text-decoration: none; color: var(--civic-navy); font-weight: 600; border-radius: 0; }
.tile svg { width: 40px; height: 40px; fill: var(--civic-navy); transition: fill .15s; }
.tile:hover { background: #fff; color: var(--link); }
.tile:hover svg { fill: var(--roughneck-gold); }

/* Modules */
.module { margin-bottom: 26px; }
.module-title { font-family: "Oswald", "Arial Narrow", sans-serif; font-weight: 500; text-transform: uppercase; color: #fff; background: var(--civic-navy); font-size: 1.07em; padding: 8px 14px; margin: 0; letter-spacing: .5px; border-bottom: 3px solid var(--roughneck-gold); }
.module-body { border: 1px solid #D5DCE4; border-top: 0; padding: 12px 14px; }
.newsflash { list-style: none; margin: 0; padding: 0; }
.newsflash li { padding: 9px 0; border-bottom: 1px solid #E4E9EF; }
.newsflash li:last-child { border-bottom: 0; }
.newsflash .posted { display: block; font-size: .85em; color: #5B6573; }
.events { list-style: none; margin: 0; padding: 0; }
.events li { display: flex; gap: 12px; padding: 9px 0; border-bottom: 1px solid #E4E9EF; }
.datebox { flex: none; width: 54px; text-align: center; border: 1px solid #C3CCD6; border-radius: 4px; overflow: hidden; line-height: 1.1; }
.datebox .m { display: block; background: var(--roughneck-gold); color: #1C1C1C; font: 500 .8em "Oswald", sans-serif; text-transform: uppercase; padding: 2px 0; }
.datebox .d { display: block; font-size: 1.35em; font-weight: 700; color: var(--civic-navy); padding: 3px 0; }
.viewall { display: inline-block; margin-top: 8px; font-weight: 600; }

/* Interior */
.breadcrumb { font-size: .87em; padding: 12px 0; color: #5B6573; }
.breadcrumb a { color: #5B6573; }
.sidebar .module-body ul { list-style: none; margin: 0; padding: 0; }
.sidebar .module-body li a { display: block; padding: 6px 0; border-bottom: 1px dotted #C3CCD6; text-decoration: none; }
.sidebar .module-body li a:hover { text-decoration: underline; }
.sidebar .module-body li a[aria-current="page"] { font-weight: 700; color: var(--text); }
.content { padding-bottom: 30px; min-height: 380px; }
.lastupdated { text-align: right; font-size: .85em; color: #5B6573; border-top: 1px solid #E4E9EF; padding-top: 8px; margin-top: 30px; }
.docs { list-style: none; padding: 0; }
.docs li { padding: 6px 0 6px 26px; position: relative; border-bottom: 1px solid #EEF1F4; }
.docs li::before { content: "PDF"; position: absolute; left: 0; top: 9px; font: 700 8px/1 Arial, sans-serif; color: #fff; background: #B0282C; padding: 2px 2px; border-radius: 1px; }
.docs .size { color: #5B6573; font-size: .87em; }
.docs li.none::before { background: #9AA3AD; content: "—"; }
table.table { width: 100%; border-collapse: collapse; margin: 10px 0 18px; font-size: .95em; }
table.table th { text-align: left; background: var(--panel); color: var(--civic-navy); padding: 8px 10px; border: 1px solid #D5DCE4; }
table.table td { padding: 8px 10px; border: 1px solid #D5DCE4; vertical-align: top; }
table.table tbody tr:nth-child(odd) td { background: #FAFBFC; }
.well { background: var(--panel); border: 1px solid #D5DCE4; border-radius: 4px; padding: 14px 16px; margin: 14px 0; }
.status-box { border: 2px solid #3C7A3C; background: #EEF7EE; border-radius: 4px; padding: 16px; margin: 12px 0 18px; }
.status-box.on { border-color: #B0282C; background: #FBEDED; }
.status-box .big { font-family: "Oswald", sans-serif; font-weight: 500; font-size: 1.6em; text-transform: uppercase; color: #2B5E2B; }
.status-box.on .big { color: #8E1F22; }
.photo-right { float: right; margin: 0 0 12px 18px; max-width: 45%; border: 1px solid #D5DCE4; padding: 4px; background: #fff; }
.photo-right figcaption { font-size: .85em; color: #5B6573; padding: 4px 2px 0; }

/* Forms */
.form-group { margin-bottom: 14px; }
.form-group label { display: block; font-weight: 600; margin-bottom: 4px; }
.form-control { display: block; width: 100%; max-width: 440px; padding: 7px 10px; font: inherit; color: #333; border: 1px solid #A9B4C0; border-radius: 4px; box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075); }
.form-control:focus { border-color: #66AFE9; box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 8px rgba(102, 175, 233, .6); outline: 0; }
textarea.form-control { max-width: 640px; min-height: 120px; }
.help-block { font-size: .87em; color: #5B6573; }
.btn { display: inline-block; font: 600 1em "Open Sans", Arial, sans-serif; padding: 8px 16px; border-radius: 4px; border: 1px solid #16244A; color: #fff; background: linear-gradient(#2A4380, var(--civic-navy)); cursor: pointer; text-decoration: none; }
.btn:hover { background: #16244A; color: #fff; }
.btn-default { background: linear-gradient(#fff, #E6E9ED); color: #333; border-color: #B8C2CD; }
.btn-default:hover { background: #E6E9ED; color: #333; }
.required { color: #B0282C; }

/* Footer */
.footer { background: var(--civic-navy); color: #DDE3EE; margin-top: 30px; border-top: 4px solid var(--roughneck-gold); font-size: .93em; }
.footer .container { padding-top: 22px; padding-bottom: 16px; }
.footer a { color: #fff; }
.footer h3 { color: #fff; font-family: "Oswald", sans-serif; font-weight: 500; text-transform: uppercase; font-size: 1.05em; margin: 0 0 8px; }
.footer ul { list-style: none; padding: 0; margin: 0; }
.footer li { margin: 3px 0; }
.footer .powered { border-top: 1px solid #34487A; margin-top: 16px; padding-top: 10px; font-size: .85em; color: #B8C3D6; }
.footer .powered p { margin: 3px 0; }

@media (max-width: 991px) {
  .tiles { grid-template-columns: repeat(2, 1fr); }
  .mainnav .drop.mega { min-width: 0; column-count: 1; }
}
@media (max-width: 767px) {
  .col-3, .col-4, .col-6, .col-8, .col-9 { width: 100%; }
  .banner .container { min-height: 180px; }
  .banner .seal { width: 84px; height: 84px; }
  .banner .cityname { font-size: 2em; }
  .navtoggle { display: flex; justify-content: space-between; align-items: center; width: 100%; background: none; border: 0; color: #fff; font: 500 1.1em "Oswald", sans-serif; text-transform: uppercase; padding: 12px 0; cursor: pointer; }
  .mainnav > .container > ul { display: none; flex-direction: column; }
  .mainnav.open > .container > ul { display: flex; }
  .mainnav .drop, .mainnav .drop.mega { position: static; box-shadow: none; border: 0; min-width: 0; }
  .utility .container { justify-content: flex-start; }
  .photo-right { float: none; max-width: 100%; margin: 0 0 12px; }
  .sidebar { order: 2; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
@media print { .utility, .mainnav, .sidebar, .footer .row, .alertbar { display: none; } }
