/*
 * Theme F — Nixie-stil (lys versjon)
 * Qweb / ActiveWEB AS
 */

:root {
  --accent:    #E85124;
  --dark:      #1A1A2E;
  --text:      #666;
  --border:    #e8e8e8;
  --header-h:  110px;
  --font:      'DM Sans', sans-serif;
}

* { box-sizing: border-box; }

body {
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.7;
  color: var(--text);
  background: #fff;
  -webkit-font-smoothing: antialiased;
  margin: 0;
}

a { color: var(--accent); text-decoration: underline; }
a:hover { text-decoration: none; }

h1,h2,h3,h4,h5,h6 {
  font-family: var(--font);
  color: var(--dark);
  font-weight: 700;
  line-height: 1.2;
  margin: 0 0 16px;
}

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

p { margin: 0 0 20px; }

/* =============================================
   HEADER
   ============================================= */
.top-header {
  position: relative;
  width: 100%;
  z-index: 1000;
  transition: background-color 0.4s ease, padding 0.3s ease, box-shadow 0.3s ease;
  background: var(--dark);
}

/* Sticky */
.sticky-header .top-header.stuck {
  position: fixed;
  top: 0; left: 0; right: 0;
  padding: 8px 0;
  background: rgba(26,26,46,0.97) !important;
  box-shadow: 0 2px 20px rgba(0,0,0,0.2);
}

.top-header.stuck #logo a { height: 65px; line-height: 65px; }
.top-header.stuck #logo img { max-height: 50px; }
.top-header.stuck #logo .sitename { font-size: 18px; }

/* Header layout — table */
.header-elements {
  width: 100%;
  display: table;
  max-width: 100%;
  padding: 0 40px;
  margin: 0 auto;
  position: relative;
}

#logo {
  display: table-cell;
  vertical-align: middle;
  text-align: left;
}

#logo a {
  height: var(--header-h);
  line-height: var(--header-h);
  display: block;
  float: left;
  font-size: 0;
  text-decoration: none;
}

#logo img {
  display: inline-block;
  vertical-align: middle;
  max-height: 70px;
  width: auto;
}

.sitename {
  display: inline-block;
  vertical-align: middle;
  font-size: 22px;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.5px;
}

.header-right {
  display: table-cell;
  vertical-align: middle;
  text-align: right;
}

/* Mobile menu button */
.mobile-menu-button {
  display: none;
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  cursor: pointer;
  padding: 10px;
  flex-direction: column;
  gap: 5px;
  z-index: 10;
}
.mobile-menu-button span {
  display: block;
  width: 22px;
  height: 2px;
  background: rgba(255,255,255,0.85);
  border-radius: 2px;
}

/* =============================================
   NAVIGATION
   ============================================= */
#navigation_bar {
  display: inline-block;
  vertical-align: middle;
}

#navigation {
  list-style: none;
  margin: 0;
  padding: 0;
  display: inline-block;
}

#navigation > li {
  display: inline-block;
  float: left;
  position: relative;
}

#navigation > li > a {
  display: inline-block;
  padding: 0 18px;
  line-height: 3;
  text-decoration: none;
  color: rgba(255,255,255,0.8);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  transition: color 0.2s;
  position: relative;
}

#navigation > li > a:after {
  content: "";
  position: absolute;
  bottom: 15px;
  left: 18px;
  right: 18px;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transition: transform 0.25s ease;
}

#navigation > li > a:hover,
#navigation > li.current-menu-item > a { color: #fff; }

#navigation > li > a:hover:after,
#navigation > li.current-menu-item > a:after { transform: scaleX(1); }

/* Dropdown */
#navigation ul {
  display: none;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  top: calc(100% + 5px);
  min-width: 200px;
  background: #fff;
  border-radius: 3px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
  list-style: none;
  margin: 0;
  padding: 6px 0;
  z-index: 999;
}
#navigation li:hover > ul { display: block; }
#navigation ul li a {
  display: block;
  padding: 10px 20px;
  color: #444;
  font-size: 13px;
  text-decoration: none;
  text-transform: none;
  letter-spacing: 0;
  border-bottom: 1px solid #f0f0f0;
  transition: color 0.2s;
}
#navigation ul li:last-child a { border-bottom: none; }
#navigation ul li a:hover { color: var(--accent); background: #fafafa; }

/* Search button */
.nixe-search-button {
  display: inline-block;
  vertical-align: middle;
  margin-left: 12px;
  color: rgba(255,255,255,0.6);
  text-decoration: none;
  font-size: 18px;
  transition: color 0.2s;
  padding: 5px 8px;
}
.nixe-search-button:hover { color: #fff; }

/* FS menu button */
.nixe-fs-menu-button {
  display: inline-block;
  vertical-align: middle;
  margin-left: 6px;
  text-decoration: none;
  padding: 5px 8px;
}
.nixe-fs-menu-button span,
.nixe-fs-menu-button span:before,
.nixe-fs-menu-button span:after {
  display: block;
  width: 18px;
  height: 2px;
  background: rgba(255,255,255,0.6);
  position: relative;
  transition: all 0.25s;
}
.nixe-fs-menu-button span:before { top: 5px; content: ""; position: absolute; width: 18px; background: rgba(255,255,255,0.6); }
.nixe-fs-menu-button span:after { top: -5px; content: ""; position: absolute; width: 18px; background: rgba(255,255,255,0.6); }
.nixe-fs-menu-button:hover span,
.nixe-fs-menu-button:hover span:before,
.nixe-fs-menu-button:hover span:after { background: #fff; }

/* =============================================
   MOBILE
   ============================================= */
.mobile-nav {
  background: var(--dark);
  position: absolute;
  width: 100%;
  z-index: 99;
  top: 100%;
  left: 0;
  border-top: 1px solid rgba(255,255,255,0.08);
}

#mobile-navigation {
  list-style: none;
  margin: 0;
  padding: 0;
}

#mobile-navigation > li > a {
  display: block;
  padding: 14px 25px;
  color: rgba(255,255,255,0.8);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 1px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  transition: color 0.2s;
}
#mobile-navigation > li > a:hover,
#mobile-navigation > li.current-menu-item > a { color: var(--accent); }

@media (max-width: 1024px) {
  .mobile-menu-button { display: flex; }
  #navigation_bar { display: none; }
  .nixe-search-button,
  .nixe-fs-menu-button { display: none; }
  .top-header { position: relative !important; box-shadow: none !important; }
  .header-elements { display: block; text-align: center; padding: 0; position: relative; }
  #logo { display: block; width: 100%; text-align: center; }
  #logo a { float: none; display: inline-block; height: 70px; line-height: 70px; }
  .header-right { display: none; }
}

/* =============================================
   FULLSCREEN MENU (search overlay)
   ============================================= */
.full-screen-menu-holder {
  position: fixed;
  inset: 0;
  background: rgba(20,20,35,0.97);
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
}
.full-screen-menu-holder.full-screen-menu-on { display: flex; }

.full-screen-menu-wrapper { text-align: center; width: 100%; }

.full-screen-menu-close {
  position: fixed;
  top: 30px;
  right: 40px;
  color: rgba(255,255,255,0.5);
  font-size: 24px;
  cursor: pointer;
  transition: color 0.2s;
  text-decoration: none;
}
.full-screen-menu-close:hover { color: #fff; }

#fullscreen_navigation {
  list-style: none; padding: 0; margin: 0 auto 40px;
  max-width: 400px;
}
#fullscreen_navigation > li { margin-bottom: 6px; }
#fullscreen_navigation > li > a {
  font-size: 26px;
  font-weight: 700;
  color: rgba(255,255,255,0.75);
  text-decoration: none;
  display: block;
  padding: 8px 0;
  transition: color 0.2s;
}
#fullscreen_navigation > li > a:hover,
#fullscreen_navigation > li.current-menu-item > a { color: var(--accent); }

/* Search in FS menu */
.wp-search-form { max-width: 500px; margin: 0 auto; }
.wp-search-form ul { list-style: none; padding: 0; margin: 0; position: relative; }
.wp-search-form input[type="text"] {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 2px solid rgba(255,255,255,0.25);
  padding: 14px 50px 14px 0;
  font-size: 22px;
  color: #fff;
  font-family: var(--font);
  outline: none;
  transition: border-color 0.2s;
}
.wp-search-form input:focus { border-bottom-color: var(--accent); }
.wp-search-form input::placeholder { color: rgba(255,255,255,0.3); }
.wp-search-form span {
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  color: rgba(255,255,255,0.4);
  font-size: 20px;
  cursor: pointer;
  line-height: 1;
}
.wp-search-form span:hover { color: #fff; }

/* Search popup */
.rt-popup-search {
  position: fixed;
  inset: 0;
  background: rgba(20,20,35,0.97);
  z-index: 9999;
  display: flex !important;
  align-items: center;
  justify-content: center;
}
.rt-popup-content-wrapper { position: relative; width: 100%; max-width: 600px; padding: 40px; }
.rt-popup-close {
  position: absolute; top: -10px; right: 40px;
  background: none; border: none;
  color: rgba(255,255,255,0.5);
  font-size: 20px; cursor: pointer;
  transition: color 0.2s;
}
.rt-popup-close:hover { color: #fff; }
.rt-popup-content input[type="text"] {
  width: 100%; background: transparent;
  border: none; border-bottom: 2px solid rgba(255,255,255,0.25);
  padding: 14px 50px 14px 0;
  font-size: 22px; color: #fff;
  font-family: var(--font); outline: none;
  transition: border-color 0.2s;
}
.rt-popup-content input:focus { border-bottom-color: var(--accent); }
.rt-popup-content input::placeholder { color: rgba(255,255,255,0.3); }

/* =============================================
   MAIN CONTENT — lys
   ============================================= */
#main_content { padding: 0; background: #fff; min-height: 60vh; }

.content_row { margin: auto; position: relative; }

.content_row_wrapper {
  max-width: 960px;
  margin: 0 auto;
  padding: 60px 40px;
}
.content_row_wrapper.fullwidth { max-width: 100%; }
.content_row_wrapper.nopadding { padding: 0; }

/* Sub page header */
.sub_page_header {
  background: var(--dark);
  padding: 70px 0 50px;
}
.sub_page_header h1 { color: #fff; font-size: 28px; margin: 0; }
.sub_page_header .content_row_wrapper { padding: 0 40px; }

/* =============================================
   BUTTONS
   ============================================= */
.button_ {
  display: inline-block;
  padding: 10px 26px;
  background: var(--accent);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  text-decoration: none;
  border: 2px solid var(--accent);
  transition: all 0.25s;
  cursor: pointer;
}
.button_.style-1 { background: transparent; color: var(--text); border-color: var(--text); }
.button_.style-1:hover,
.button_:hover { background: var(--dark); border-color: var(--dark); color: #fff; text-decoration: none; }
.button_.style-2 { background: transparent; color: var(--accent); }
.button_.style-2:hover { background: var(--accent); color: #fff; }

.read_more {
  display: inline-block;
  margin-top: 10px;
  text-decoration: none;
  color: var(--accent);
  font-weight: 600;
  font-size: 13px;
}
.read_more:before {
  border: 1px solid;
  content: "\f105";
  font-family: fontello;
  display: inline-block;
  font-size: 13px;
  height: 24px;
  line-height: 24px;
  margin-right: 8px;
  width: 24px;
  border-radius: 50%;
  text-align: center;
}

/* =============================================
   FOOTER — Funnesdal-inspirert
   ============================================= */
#footer { width: 100%; }

#footer .footer_widgets {
  background-color: #6D6863;
  background-size: cover;
  background-position: center;
  color: rgba(255,255,255,0.85);
}

#footer h5 {
  color: #fff;
  font-size: 11px;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  padding-bottom: 12px;
  margin-bottom: 18px;
  border-bottom: 1px solid rgba(255,255,255,0.25);
  display: block;
}

#footer a { color: rgba(255,255,255,0.75); text-decoration: none; }
#footer a:hover { color: #fff; }
#footer p { color: rgba(255,255,255,0.75); margin-bottom: 10px; }

#footer .footer_widgets .content_row_wrapper { padding: 50px 40px; }
#footer .widgets_holder { padding: 0 20px; }
#footer .widgets_holder ul { list-style: none; padding: 0; margin: 0; }
#footer .widgets_holder ul li { padding: 5px 0; border-bottom: 1px solid rgba(255,255,255,0.08); }
#footer .widgets_holder ul li a { color: rgba(255,255,255,0.75); }
#footer .widgets_holder ul li a:hover { color: #fff; }

/* Footer info bar */
.footer_info_bar {
  background: #1A1715 !important;
  color: #888;
}

.footer_info_bar .content_row_wrapper {
  max-width: 100%;
  padding: 18px 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.copyright { color: #888; font-size: 13px; }

#footer-navigation {
  list-style: none; margin: 0; padding: 0; display: flex;
}
#footer-navigation li a {
  padding: 0 12px;
  color: #888;
  font-size: 13px;
  border-right: 1px solid rgba(255,255,255,0.08);
  text-decoration: none;
}
#footer-navigation li:last-child a { border-right: none; }
#footer-navigation li a:hover { color: #fff; }

/* with_icons */
.with_icons.style-1 > div {
  display: flex;
  gap: 10px;
  padding: 6px 0;
  align-items: flex-start;
}
.with_icons.style-1 .icon { color: rgba(255,255,255,0.5); min-width: 18px; }

/* =============================================
   GO TO TOP
   ============================================= */
.go-to-top {
  position: fixed;
  right: 15px;
  bottom: -60px;
  z-index: 90;
  cursor: pointer;
  opacity: 0;
  width: 36px;
  height: 36px;
  line-height: 36px;
  text-align: center;
  background: rgba(0,0,0,0.5);
  color: #fff;
  transition: all 0.35s;
}
.go-to-top.visible { opacity: 1; bottom: 15px; }
.go-to-top:hover { background: var(--accent); }

/* =============================================
   PORTFOLIO + TEAM
   ============================================= */
.loop.type-portfolio { position: relative; overflow: hidden; }
.loop.type-portfolio .image-thumbnail { overflow: hidden; }
.loop.type-portfolio .image-thumbnail img { transition: all 0.4s ease; }
.loop.type-portfolio:hover .image-thumbnail img { transform: scale(1.06); opacity: 0.15; }
.loop.type-portfolio .overlay {
  position: absolute; inset: 0; opacity: 0;
  transition: opacity 0.3s;
  display: flex; align-items: center; justify-content: center;
}
.loop.type-portfolio:hover .overlay { opacity: 1; }
.loop.type-portfolio .overlay .title a { color: #fff; text-decoration: none; font-size: 18px; font-weight: 700; }
.loop.type-portfolio .overlay .terms { color: var(--accent); display: block; margin-top: 8px; }

.type-staff.loop .person_image img { filter: grayscale(0.7); transition: all 0.4s; border-radius: 50%; }
.type-staff.loop:hover .person_image img { filter: grayscale(0); }
.type-staff.loop .person_links_wrapper { opacity: 0; transition: opacity 0.4s; }
.type-staff.loop:hover .person_links_wrapper { opacity: 1; }
.type-staff.loop .position { color: var(--accent); font-size: 13px; }

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 768px) {
  .content_row_wrapper { padding: 40px 20px; }
  .footer_info_bar .content_row_wrapper { flex-direction: column; gap: 12px; padding: 20px; text-align: center; }
  #footer .footer_widgets .content_row_wrapper { padding: 40px 20px; }
  #footer .widgets_holder { padding: 0; margin-bottom: 30px; }
  #footer-navigation { flex-wrap: wrap; justify-content: center; }
}
