/*
Theme Name: ABN
Description: Tema za ABN d.o.o., Celje – oblikovno povzeta po stari strani abn.si.
Version: 1.3
Author: ABN d.o.o.
Text Domain: abn
*/

:root {
	--abn-red: #ba0000;
	--abn-grey: #777777;
	--abn-text: #000000;
	--abn-muted: #666666;
	--abn-light: #efefef;
	--abn-footer: #ececec;
	--abn-wide: 1600px;
	--abn-content: 1410px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
	margin: 0;
	font-family: "Open Sans", Helvetica, Arial, sans-serif;
	font-size: 17px;
	line-height: 24px;
	color: var(--abn-text);
	background: #fff;
}
a { color: var(--abn-red); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; border: 0; }
.screen-reader-text { position: absolute !important; clip: rect(1px,1px,1px,1px); width: 1px; height: 1px; overflow: hidden; }

/* ---------- Glava ---------- */
.abn-header-wrap { background: linear-gradient(#f3f3f3, #fff 60%); }
.abn-header {
	max-width: var(--abn-wide);
	margin: 0 auto;
	background: #fff;
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 18px 30px 14px 48px;
	min-height: 130px;
	box-shadow: -6px 0 8px -8px rgba(0,0,0,.35), 6px 0 8px -8px rgba(0,0,0,.35);
}
.abn-brand { display: flex; align-items: center; gap: 26px; text-decoration: none !important; }
.abn-brand img { display: block; width: 139px; height: auto; }
.abn-brand .abn-logo-text { font: bold 64px/1 Arial, sans-serif; color: #9d0000; text-shadow: 2px 3px 3px rgba(0,0,0,.35); }
.abn-slogan { font-size: 14px; line-height: 20px; }
.abn-slogan .sl { color: var(--abn-red); display: block; }
.abn-slogan .en { color: var(--abn-muted); display: block; }

.abn-util { display: flex; font-size: 12px; line-height: 28px; }
.abn-util ul { list-style: none; margin: 0; padding: 0 20px; }
.abn-util ul + ul { border-left: 1px solid #ccc; }
.abn-util .abn-langs { border-left: 1px solid #ccc; }
.abn-util a { color: #3a3a3a; }
.abn-util .current a, .abn-util a:hover { color: var(--abn-red); text-decoration: none; }

/* ---------- Glavni meni ---------- */
.abn-nav-wrap { background: var(--abn-grey); border-bottom: 2px solid #fff; box-shadow: 0 2px 0 var(--abn-red); position: relative; z-index: 50; }
.abn-nav { max-width: var(--abn-wide); margin: 0 auto; text-align: center; }
.abn-nav ul { list-style: none; margin: 0; padding: 0; }
.abn-nav > ul > li { display: inline-block; position: relative; }
.abn-nav > ul > li + li::before { content: ""; position: absolute; left: 0; top: 13px; height: 20px; border-left: 1px solid #8f8f8f; }
.abn-nav > ul > li > a {
	display: block;
	padding: 10px 15px;
	color: #f4f4f4;
	font-size: 21px;
	line-height: 26px;
	text-transform: uppercase;
}
.abn-nav > ul > li:hover > a,
.abn-nav > ul > li.current-menu-item > a,
.abn-nav > ul > li.current-menu-ancestor > a,
.abn-nav > ul > li.current-page-ancestor > a { background: #fff; color: var(--abn-red); text-decoration: none; }
.abn-nav ul ul {
	display: none;
	position: absolute;
	left: 0;
	top: 100%;
	min-width: 280px;
	background: #fff;
	text-align: left;
	box-shadow: 0 6px 14px rgba(0,0,0,.18);
	padding: 8px 0;
}
.abn-nav ul ul ul { position: static; box-shadow: none; display: block; padding: 0 0 0 16px; min-width: 0; }
.abn-nav li:hover > ul { display: block; }
.abn-nav ul ul a { display: block; padding: 5px 18px; color: var(--abn-grey); font-size: 16px; line-height: 22px; }
.abn-nav ul ul ul a { font-size: 14px; padding: 3px 18px; }
.abn-nav ul ul a:hover, .abn-nav ul ul .current-menu-item > a { color: var(--abn-red); text-decoration: none; }
.abn-nav-toggle { display: none; }

/* ---------- Vsebina ---------- */
.abn-main { max-width: var(--abn-content); margin: 0 auto; padding: 40px 20px 70px; min-height: 360px; }
.abn-main h1, .abn-page-title { color: var(--abn-red); font-size: 26px; line-height: 32px; font-weight: 400; margin: 0 0 40px; }
.abn-main h2 { color: var(--abn-red); font-size: 18px; line-height: 24px; font-weight: 400; margin: 22px 0 4px; }
.abn-main h3, .abn-main h4 { color: var(--abn-red); font-size: 17px; font-weight: 400; margin: 18px 0 4px; }
.abn-main p { margin: 0 0 14px; }
.abn-main ul { padding-left: 20px; }
.abn-main table { border-collapse: collapse; margin: 0 0 20px; }
.abn-main td, .abn-main th { padding: 4px 18px 4px 0; vertical-align: top; text-align: left; }
.abn-main td table { margin: 0; }
.abn-main td p { margin: 0 0 4px; }
.abn-main td h3 { margin-top: 12px; }
.abn-main strong, .abn-main b { font-weight: 700; }

/* ---------- Naslovnica ---------- */
.home .abn-main, .abn-front .abn-main { padding-top: 40px; }
.abn-slider { position: relative; overflow: hidden; background: #ddd; aspect-ratio: 988 / 280; }
.abn-slider img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 1s ease; }
.abn-slider img.is-active { opacity: 1; }
.abn-slider-dots { position: absolute; left: 0; right: 0; bottom: 14px; text-align: center; z-index: 2; }
.abn-slider-dots button { width: 11px; height: 11px; border-radius: 50%; border: 0; margin: 0 6px; padding: 0; background: rgba(0,0,0,.45); cursor: pointer; }
.abn-slider-dots button.is-active { background: #fff; box-shadow: 0 0 0 2px rgba(0,0,0,.4); }
.abn-slider-arrow { position: absolute; top: 50%; transform: translateY(-50%); z-index: 2; width: 44px; height: 44px; border: 0; border-radius: 50%; background: rgba(0,0,0,.35); color: #fff; font-size: 22px; cursor: pointer; opacity: 0; transition: opacity .2s; }
.abn-slider:hover .abn-slider-arrow { opacity: 1; }
.abn-slider-arrow.prev { left: 14px; } .abn-slider-arrow.next { right: 14px; }

.abn-boxes { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 28px; margin-top: 46px; }
.abn-box { border: 1px solid #e3e3e3; border-radius: 10px; padding: 28px 28px 34px; background: #fff; }
.abn-box.abn-box--grey { background: var(--abn-light); border-color: var(--abn-light); }
.abn-box p { margin: 0 0 4px; }
.abn-box p:first-child strong:first-child { color: var(--abn-red); font-weight: 400; }
.abn-box--grey p:first-child strong:first-child { font-weight: 400; }
.abn-box .abn-more { font-size: 14px; text-transform: uppercase; }

/* ---------- Galerije (reference) ---------- */
.abn-gallery { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 26px; margin: 0 0 20px; }
.abn-gallery a { display: block; width: calc((68% - 4 * 26px) / 4); line-height: 0; }
.abn-gallery a:first-child { width: 32%; }
.abn-gallery img { width: 100%; aspect-ratio: 1.42; object-fit: cover; display: block; transition: opacity .2s; }
.abn-gallery a:hover img { opacity: .85; }

.abn-lightbox { position: fixed; inset: 0; background: rgba(0,0,0,.85); display: none; align-items: center; justify-content: center; z-index: 9999; }
.abn-lightbox.is-open { display: flex; }
.abn-lightbox img { max-width: 90vw; max-height: 86vh; box-shadow: 0 0 30px rgba(0,0,0,.6); background: #fff; padding: 6px; }
.abn-lightbox button { position: absolute; background: none; border: 0; color: #fff; font-size: 44px; cursor: pointer; padding: 10px 18px; line-height: 1; }
.abn-lightbox .close { top: 10px; right: 14px; font-size: 38px; }
.abn-lightbox .prev { left: 10px; top: 50%; transform: translateY(-50%); }
.abn-lightbox .next { right: 10px; top: 50%; transform: translateY(-50%); }

/* ---------- Kontakt ---------- */
.abn-page-contact .abn-entry p { margin: 0; }
.abn-page-contact .abn-entry img { float: right; width: 300px; margin: 0 0 20px 40px; }
.abn-page-contact .abn-map { clear: both; padding-top: 30px; }
.abn-map { margin-top: 40px; }
.abn-map iframe { width: 100%; height: 420px; border: 0; display: block; }
.abn-map[data-src] { background: #efefef; border-radius: 6px; min-height: 160px; display: flex; align-items: center; justify-content: center; }
.abn-map-consent { max-width: 620px; padding: 28px; text-align: center; font-size: 15px; line-height: 21px; color: #444; }
.abn-map-consent button { margin-top: 6px; background: var(--abn-grey); color: #fff; border: 0; padding: 9px 22px; font: inherit; cursor: pointer; }
.abn-map-consent button:hover { background: var(--abn-red); }

/* ---------- Kazalo, iskanje ---------- */
.abn-sitemap ul { list-style: none; padding-left: 0; }
.abn-sitemap ul ul { padding-left: 22px; }
.abn-sitemap li { margin: 3px 0; }
.abn-search-form { margin: 0 0 30px; display: flex; gap: 8px; max-width: 520px; }
.abn-search-form input[type=search] { flex: 1; padding: 8px 10px; font: inherit; border: 1px solid #bbb; }
.abn-search-form button { background: var(--abn-grey); color: #fff; border: 0; padding: 8px 18px; font: inherit; cursor: pointer; }
.abn-header-search { max-width: var(--abn-wide); margin: 0 auto; padding: 0 30px 14px; justify-content: flex-end; background: #fff; }
.abn-header-search[hidden] { display: none; }
.abn-header-search input[type=search] { max-width: 320px; }
.abn-search-results article { margin: 0 0 22px; }
.abn-search-results h2 { margin: 0; }

/* ---------- Noga ---------- */
.abn-footer { background: var(--abn-footer); border-top: 1px solid var(--abn-red); color: var(--abn-muted); font-size: 11px; line-height: 18px; text-transform: uppercase; }
.abn-footer-inner { max-width: 1100px; margin: 0 auto; padding: 14px 20px 10px; }
.abn-footer .abn-company { font-weight: 700; margin-bottom: 10px; }
.abn-footer-cols { display: flex; flex-wrap: wrap; }
.abn-footer-col { padding: 0 24px; border-left: 1px solid #cfcfcf; min-height: 54px; }
.abn-footer-col:first-child { padding-left: 0; border-left: 0; }
.abn-footer-col ul { list-style: none; margin: 0; padding: 0; }
.abn-footer-col.menu ul { columns: 2; column-gap: 46px; }
.abn-footer a { color: var(--abn-muted); }
.abn-footer a:hover { color: var(--abn-red); text-decoration: none; }
.abn-footer .abn-email { text-transform: none; }
.abn-copy { text-align: center; color: #aaa; font-size: 11px; padding: 22px 16px 40px; }
.abn-copy a { color: #999; }
.abn-totop { position: fixed; right: 18px; bottom: 30px; width: 34px; height: 34px; border: 1px solid #ccc; background: #fff; color: #555; font-size: 18px; cursor: pointer; display: none; }
.abn-totop.is-visible { display: block; }

/* ---------- Manjši zasloni ---------- */
.abn-sub-toggle { display: none; }
.abn-nav-extra[hidden] { display: none !important; }

/* Tablica (761–1100 px): vodoraven meni v več vrsticah, okvirčki 2 + 1 (kot na stari strani) */
@media (max-width: 1100px) {
	.abn-header { padding: 14px 20px 12px 24px; min-height: 0; }
	.abn-nav > ul > li > a { font-size: 17px; padding: 9px 11px; }
	.abn-nav > ul > li + li::before { top: 11px; }
	.abn-main { padding: 30px 24px 50px; }
	.abn-boxes { grid-template-columns: 1fr 1fr; gap: 22px; margin-top: 30px; }
	.abn-boxes .abn-box:last-child { grid-column: 1 / -1; }
	.abn-gallery { gap: 16px; }
	.abn-gallery a { width: calc((100% - 2 * 16px) / 3); }
	.abn-gallery a:first-child { width: 100%; max-width: 560px; }
	.abn-footer-inner { padding: 14px 24px 10px; }
	.abn-footer-col { padding: 0 16px; margin-bottom: 10px; }
	.abn-page-contact .abn-entry img { width: 240px; }
}

/* Telefon (do 760 px): logotip + gumb za meni, harmonika podmenijev, galerija: velika slika + 2 stolpca */
@media (max-width: 760px) {
	body { font-size: 16px; line-height: 23px; }
	.abn-header { flex-wrap: nowrap; align-items: center; padding: 10px 14px; gap: 10px; box-shadow: none; }
	.abn-brand img { width: 92px; }
	.abn-slogan { display: none; }
	.abn-util { font-size: 13px; line-height: 22px; }
	.abn-util ul { padding: 0 10px; }
	.abn-util ul:last-child { display: none; }          /* iskanje, kazalo, kontakt so v meniju */
	.abn-util .abn-langs { border-left: 0; display: flex; gap: 14px; }
	.abn-header-search { padding: 0 14px 12px; }

	.abn-nav-wrap { box-shadow: 0 2px 0 var(--abn-red); }
	.abn-nav-toggle { display: block; width: 100%; background: none; border: 0; color: #fff; font-size: 18px; line-height: 24px; padding: 11px 16px; text-align: left; cursor: pointer; }
	.abn-nav > ul { display: none; text-align: left; background: #fff; border-top: 1px solid #999; }
	.abn-nav.is-open > ul { display: block; }
	.abn-nav li, .abn-nav > ul > li { display: block; position: relative; }
	.abn-nav > ul > li { border-bottom: 1px solid #e3e3e3; }
	.abn-nav > ul > li + li::before { display: none; }
	.abn-nav > ul > li > a { color: #444; font-size: 17px; padding: 12px 52px 12px 16px; }
	.abn-nav > ul > li:hover > a { background: none; color: var(--abn-red); }
	.abn-nav > ul > li.current-menu-item > a,
	.abn-nav > ul > li.current-menu-ancestor > a,
	.abn-nav > ul > li.current-page-ancestor > a { background: none; color: var(--abn-red); }
	.abn-nav ul ul, .abn-nav li:hover > ul { display: none; position: static; box-shadow: none; background: #f6f6f6; padding: 4px 0 8px; min-width: 0; }
	.abn-nav ul ul ul { display: none; }
	.abn-nav li.is-open > ul { display: block; }
	.abn-nav ul ul ul { padding-left: 14px; background: none; }
	.abn-nav ul ul a { font-size: 16px; padding: 9px 52px 9px 28px; }
	.abn-nav ul ul ul a { font-size: 15px; padding: 7px 18px 7px 28px; }
	.abn-sub-toggle { display: block; position: absolute; right: 0; top: 0; width: 50px; height: 46px; border: 0; background: none; color: #777; font-size: 22px; cursor: pointer; }
	.abn-nav ul ul .abn-sub-toggle { height: 40px; }
	.abn-sub-toggle::before { content: "+"; }
	li.is-open > .abn-sub-toggle::before { content: "–"; }
	.abn-nav-extra { display: block; padding: 8px 16px 12px; background: #fff; border-bottom: 1px solid #e3e3e3; }
	.abn-nav-extra a { display: inline-block; margin-right: 18px; color: #555; font-size: 14px; padding: 6px 0; }

	.abn-main { padding: 22px 16px 40px; min-height: 0; }
	.abn-main h1, .abn-page-title { font-size: 23px; line-height: 29px; margin-bottom: 22px; }
	.abn-slider { aspect-ratio: 16 / 8; }
	.abn-slider-arrow { display: none; }
	.abn-boxes { grid-template-columns: 1fr; gap: 16px; margin-top: 22px; }
	.abn-box { padding: 20px 18px 22px; }

	.abn-gallery { gap: 10px; }
	.abn-gallery a { width: calc((100% - 10px) / 2); }
	.abn-gallery a:first-child { width: 100%; max-width: none; }

	.abn-entry { overflow-x: auto; }
	.abn-main td, .abn-main th { padding: 4px 10px 4px 0; }
	.abn-main table table td:first-child { white-space: nowrap; }
	.abn-entry > table > tbody > tr > td { display: block; width: 100%; padding-right: 0; }  /* dvostolpčne tabele (npr. Mlekarstvo) eno pod drugo */
	.abn-entry table table td { display: table-cell; }

	.abn-page-contact .abn-entry img { float: none; width: 220px; margin: 0 0 18px; }
	.abn-map iframe { height: 320px; }

	.abn-footer { font-size: 12px; line-height: 20px; }
	.abn-footer-inner { padding: 16px; }
	.abn-footer-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 18px; }
	.abn-footer-col { border-left: 0; padding: 0; min-height: 0; margin: 0; }
	.abn-footer-col.menu ul { columns: 1; }
	.abn-copy { padding: 16px 16px 70px; line-height: 20px; }
	.abn-totop { bottom: 18px; }
	.abn-lightbox img { max-width: 96vw; padding: 3px; }
	.abn-lightbox .prev, .abn-lightbox .next { font-size: 38px; padding: 10px; }
}
