/**
 * AKZ — izkārtojums (pārnests no D6, ar fluid/responsive uzlabojumiem).
 * Krāsas: zaļā #7d9144 / #92aa4f / #738935, teksts #3a3a3a, fons #efefef.
 */

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
}

body {
  font-family: Arial, Helvetica, sans-serif;
  font-size: 12px;
  color: #3a3a3a;
  background: #efefef;
  position: relative; /* atskaites punkts augšējai joslai (valodai) */
}

/* ---------- Augšējā josla: valodu pārslēgs (LV/ENG) augšā pa labi ---------- */
#top-bar {
  position: absolute;
  top: 8px;
  right: 14px;
  z-index: 300;
}

body.front {
  background: #ffffff;
}

img {
  max-width: 100%;
  height: auto;
}

.clear { clear: both; }

a { color: #92aa4f; }
a:hover { color: #516616; }

/* ---------- Header josla ---------- */
#header {
  position: relative;
  width: 100%;
  /* Smalka rūtaina tekstūra virs zaļā gradienta. */
  background:
    repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.06) 0 1px, rgba(0, 0, 0, 0.04) 1px 2px, transparent 2px 8px),
    repeating-linear-gradient(-45deg, rgba(255, 255, 255, 0.05) 0 1px, transparent 1px 8px),
    #7d9144 url(../images/header.png) repeat-x;
}

.header-inner {
  position: relative; /* atskaite logo (lai logo sakrīt ar konteinera malu) */
  width: 940px;
  max-width: 100%;
  margin: 0 auto;
  min-height: 50px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  padding: 0 90px 0 130px; /* kreisā: logo overlay; labā: LV/ENG cilnes */
}

/* Logo kā overlay — pie konteinera kreisās malas. */
#logo {
  position: absolute;
  left: 10px;
  top: 0; /* satura lapās: augša vienā līmenī ar joslas augšu */
  z-index: 100;
  padding: 0;
}

#logo img {
  display: block;
  height: 100px;
  width: auto;
  max-height: none;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

/* Sākumlapā logo vertikāli centrēts (straddle slaidrāde/josla). */
body.front #logo {
  top: 50%;
  transform: translateY(-50%);
}

/* Satura lapās saturs sākas zem logo pārkares. */
body.not-front #content { padding-top: 50px; }

#header-nav {
  flex: 1 1 auto;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 20px;
}

/* Mobilais izvēlnes slēdzis — paslēpts desktopā. */
.menu-toggle { display: none; }

/* ---------- Konteiners ---------- */
#container {
  width: 940px;
  max-width: 100%;
  margin: 0 auto;
  background: #ffffff;
  position: relative;
}

#content {
  padding: 26px 15px 40px;
  overflow: hidden; /* clearfix sānjoslai/saturam */
}

#header_step { height: 10px; }

/* ---------- Sānjosla + saturs ---------- */
#right-side {
  width: 225px;
  float: left;
  margin-right: 30px; /* atstarpe starp menu un topika tekstu */
}

.right-side-left {
  overflow: hidden; /* aizņem atlikušo platumu blakus sānjoslai */
}

/* Bez sānjoslas saturs aizņem visu platumu. */
#content > .right-side-left:first-child,
body:not(.has-sidebar) .right-side-left {
  float: none;
}

/* ---------- Footer ---------- */
#footer {
  clear: both;
  background: #7d9144;
  width: 100%;
  min-height: 50px;
}

#footer_inner {
  width: 940px;
  max-width: 100%;
  margin: 0 auto;
  padding: 0 15px;
}

#footer-text {
  display: flex;
  align-items: center;
  gap: 25px;
  min-height: 50px;
}

#footer-text #copy { flex: 0 0 auto; }
#footer-text #navigation { flex: 1 1 auto; }

/* ---------- Slaidrāde ---------- */
#slideshow {
  background: #000;
  position: relative;
  overflow: hidden;
}

#slideshow-inline {
  width: 940px;
  max-width: 100%;
  margin: 0 auto;
  position: relative;
  height: 317px;
}

/* Malu izgaišana melnajā (kreisā/labā + augša). */
#slideshow-inline::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 3;
  background:
    linear-gradient(to right, #000 0%, rgba(0, 0, 0, 0) 14%, rgba(0, 0, 0, 0) 86%, #000 100%),
    linear-gradient(to bottom, rgba(0, 0, 0, 0.6) 0%, rgba(0, 0, 0, 0) 18%);
}

/* Pogas — absolūti malās, vertikāli centrētas. */
#slideshow .button {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 43px;
  height: 152px;
  z-index: 5;
}
#slideshow .button-left { left: 0; background: url(../images/button-left.png) 0 0 no-repeat; }
#slideshow .button-right { right: 0; background: url(../images/button-right.png) 100% 0 no-repeat; }
#slideshow .button a { display: block; width: 100%; height: 100%; }

/* Skata konteineri aizpilda joslu. */
#slideshow-inline > div,
#slideshow .views-element-container,
#slideshow .view-slideshow,
#slideshow .view-content {
  height: 100%;
}

#slideshow .views-row {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  text-align: center;
  opacity: 0;
  z-index: 1;
  transition: opacity 0.8s ease-in-out;
}

/* JS pārvalda redzamo slaidu ar .active — mīksts crossfade (bez melnās starpas). */
#slideshow .views-row.active {
  opacity: 1;
  z-index: 2;
}
/* Bez JS — redzams pirmais slaids. */
html:not(.js) #slideshow .views-row:first-child { opacity: 1; }
#slideshow .views-row img {
  display: inline-block;
  height: 317px;
  width: auto;
  max-width: 100%;
}
