/*
 Theme Name:   SevenIT - Divi / Karlsvognen Theme
 Author:       7it ApS
 Author URI:   https://7it.dk
 Template:     Divi
 Version:      1.0.1
*/

/*change hamburger icon to x when mobile menu is open*/

#et_mobile_nav_menu .mobile_nav.opened .mobile_menu_bar::before,
.et_pb_module.et_pb_menu .et_mobile_nav_menu .mobile_nav.opened .mobile_menu_bar::before {
	content: '\4d';
}


/*adjust the new toggle element which is added via jQuery*/

ul.et_mobile_menu li.menu-item-has-children .mobile-toggle,
ul.et_mobile_menu li.page_item_has_children .mobile-toggle,
.et-db #et-boc .et-l ul.et_mobile_menu li.menu-item-has-children .mobile-toggle,
.et-db #et-boc .et-l ul.et_mobile_menu li.page_item_has_children .mobile-toggle {
	width: 44px;
	height: 100%;
	padding: 0px !important;
	max-height: 44px;
	border: none;
	position: absolute;
	right: 0px;
	top: 0px;
	z-index: 999;
	background-color: transparent;
}


/*some code to keep everyting positioned properly*/

ul.et_mobile_menu>li.menu-item-has-children,
ul.et_mobile_menu>li.page_item_has_children,
ul.et_mobile_menu>li.menu-item-has-children .sub-menu li.menu-item-has-children,
.et-db #et-boc .et-l ul.et_mobile_menu>li.menu-item-has-children,
.et-db #et-boc .et-l ul.et_mobile_menu>li.page_item_has_children,
.et-db #et-boc .et-l ul.et_mobile_menu>li.menu-item-has-children .sub-menu li.menu-item-has-children {
	position: relative;
}


/*remove default background color from menu items that have children*/

.et_mobile_menu .menu-item-has-children>a,
.et-db #et-boc .et-l .et_mobile_menu .menu-item-has-children>a {
	background-color: transparent;
}


/*hide the submenu by default*/

ul.et_mobile_menu .menu-item-has-children .sub-menu,
#main-header ul.et_mobile_menu .menu-item-has-children .sub-menu,
.et-db #et-boc .et-l ul.et_mobile_menu .menu-item-has-children .sub-menu,
.et-db #main-header ul.et_mobile_menu .menu-item-has-children .sub-menu {
	display: none !important;
	visibility: hidden !important;
}


/*show the submenu when toggled open*/

ul.et_mobile_menu .menu-item-has-children .sub-menu.visible,
#main-header ul.et_mobile_menu .menu-item-has-children .sub-menu.visible,
.et-db #et-boc .et-l ul.et_mobile_menu .menu-item-has-children .sub-menu.visible,
.et-db #main-header ul.et_mobile_menu .menu-item-has-children .sub-menu.visible {
	display: block !important;
	visibility: visible !important;
}


/*adjust the toggle icon position and transparency*/

ul.et_mobile_menu li.menu-item-has-children .mobile-toggle,
.et-db #et-boc .et-l ul.et_mobile_menu li.menu-item-has-children .mobile-toggle {
	text-align: center;
	opacity: 1;
}


/*submenu toggle icon when closed*/

.style-2026 ul.et_mobile_menu li.menu-item-has-children .mobile-toggle::after,
.style-2026  .et-db #et-boc .et-l ul.et_mobile_menu li.menu-item-has-children .mobile-toggle::after {
	color: #EFECDF !important;
	background: transparent !important;
}

ul.et_mobile_menu li.menu-item-has-children .mobile-toggle::after,
.et-db #et-boc .et-l ul.et_mobile_menu li.menu-item-has-children .mobile-toggle::after {
	top: 10px;
	position: relative;
	font-family: "ETModules";
	content: '\33';
	color: #00d263;
	background: #f0f3f6;
	border-radius: 50%;
	padding: 3px;
}

/*submenu toggle icon when open*/

ul.et_mobile_menu li.menu-item-has-children.dt-open>.mobile-toggle::after,
.et-db #et-boc .et-l ul.et_mobile_menu li.menu-item-has-children.dt-open>.mobile-toggle::after {
	content: '\32';
}


/*add point on top of the menu submenu dropdown*/

.et_pb_menu_0.et_pb_menu .et_mobile_menu:after {
	position: absolute;
	right: 5%;
	margin-left: -40px;
	top: -14px;
	width: 0;
	height: 0;
	content: '';
	border-left: 20px solid transparent;
	border-right: 20px solid transparent;
	border-bottom: 20px solid #ffffff;
}



/*force the background color and add a rounded border*/

.et_pb_menu_0.et_pb_menu .et_mobile_menu,
.et_pb_menu_0.et_pb_menu .et_mobile_menu ul {
	background-color: #ffffff!important;
	border-radius: 10px;
}

/*Add MENU text to hamburger menu*/

.mobile_menu_bar:after {
 position: relative !important;
 content: 'MENU';
 bottom: 9px;
 left: 10%;
 color: #000000;
}
/* UNDTAGELSE: Nulstil dette for .style-2026 sider */
.style-2026 .mobile_menu_bar:after {
    content: none !important; /* Fjerner teksten MENU */
}


/* ekstra linje menutext*/
.nav li a span, .mobile_nav >ul>li>a span, .et_mobile_menu li a span {
	display: block;
	font-size: 60%;
	letter-spacing: 1px;
	line-height: 1.2em;
}




/*PAGE MENU - show desktop menu on phone*/

@media (max-width: 980px) {
	.page-mobile-menu .et_pb_menu__menu {
		display: flex!important;
	}
	.page-mobile-menu .et_mobile_nav_menu {
		display: none!important;
	}

.et_mobile_menu {
    overflow: auto!important;
    max-height: 75vh;
}
.style-2026 .et_mobile_menu {
	width: 98vw !important;
	margin-left: -60vw !important;
}
}


.one-row-button .et_pb_button_module_wrapper{
	display: inline-block;
}




/* --- DIVI STAIRCASE WRAPPER --- */
#divi-staircase-wrapper {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding-top: 10px;
    padding-bottom: 20px;
    font-family: 'Open Sans', Arial, sans-serif;
    box-sizing: border-box;
}

#divi-staircase-wrapper * {
    box-sizing: border-box;
}

/* --- FLEX CONTAINER (RÆKKEN) --- */
.staircase-row {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 15px;
    width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 10px;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.staircase-row::-webkit-scrollbar { display: none; }

/* --- PRIS KORT (CARD) --- */
.pricing-card {
    position: relative;
    display: flex;
    flex-direction: column;
    width: 23%;
    min-width: 280px; 
    background: #fff;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(0,0,0,0.05);
    transition: box-shadow 0.2s ease, height 0.3s ease;
    overflow: hidden;
    flex-shrink: 0;
    scroll-snap-align: center;
    border-style: solid;
    border-width: 2px; 
    border-radius: 0 0 30px 0;
}

.pricing-radio { display: none; }

/* --- TRAPPE EFFEKT (MARGINS) --- */
.card-basic { height: 436px; margin-top: 100px; }
.card-pro { height: 486px; margin-top: 50px; }
.card-premium { height: 536px; margin-top: 0px; }

/* --- ACTIVE STATE & EXPANSION --- */
.pricing-radio:checked + .pricing-card {
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
    height: auto !important;
    min-height: 500px;
}

.pricing-radio:checked + .pricing-card .card-footer {
    height: auto !important;
}

.pricing-radio:checked + .pricing-card .footer-expanded {
    display: block;
    animation: fadeIn 0.4s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* --- SELECTION BOX --- */
.selection-box {
    position: absolute;
    top: 0;
    right: 0;
    width: 30px;
    height: 30px;
    background-color: #E3E57F;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 20;
    margin: 20px 20px 0 0;
    padding: 0 0 15px 10px;
}

.selection-box::after {
    content: '✔';
    font-size: 40px;
    font-weight: 500;
    color: #000;
    display: none;
    line-height: 1;
}

.pricing-radio:checked + .pricing-card .selection-box::after { display: block; }

/* --- CARD TOP --- */
.card-top {
    background-color: #fff;
    padding: 25px 20px;
    flex: 1; 
    display: flex;
    flex-direction: column;
}

.card-title {
    font-size: 20px;
    font-weight: 800;
    color: #333;
    padding-right: 40px;
    margin-bottom: auto; 
}

.card-icon {
    display: block;
    width: 160px;
    max-width: 90%;
    height: auto;
    margin: 0 auto 20px auto;
}

.price-wrapper { text-align: left; width: 100%; }
.price-tag { font-size: 18px; font-weight: 800; color: #000; margin-bottom: 5px; }
.price-sub { font-size: 11px; color: #777; line-height: 1.3; }

/* --- CARD FOOTER --- */
.card-footer {
    height: 156px;
    flex-shrink: 0;
    padding: 15px 20px; 
    display: flex;
    flex-direction: column;
    transition: height 0.3s ease;
}

.footer-title { font-size: 11px; font-weight: 700; margin-bottom: 12px; color: #000; }

.feature-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    /* RETTET: repeat syntax accepteres oftere af Divi validatoren */
    grid-template-columns: repeat(2, 1fr); 
    gap: 8px 5px;
}

.feature-list li {
    font-size: 10px;
    display: flex;
    align-items: center;
    line-height: 1.2;
    color: #333;
}

.check-icon {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 16px;
    height: 16px;
    background-color: #E3E57F;
    border-radius: 3px;
    margin-right: 8px;
    font-size: 10px;
    font-weight: bold;
    color: #000;
    flex-shrink: 0;
}

.footer-expanded {
    display: none;
    padding-top: 20px;
}

/* --- AUTOMATISK TABEL STYLING --- */
/* Vi bruger #divi-staircase-wrapper foran alle regler for at overtrumfe pluginets CSS */

#divi-staircase-wrapper table.doRentIt-product-price-table,
#divi-staircase-wrapper table.doRentIt-product-price-table tbody,
#divi-staircase-wrapper table.doRentIt-product-price-table thead,
#divi-staircase-wrapper table.doRentIt-product-price-table tr,
#divi-staircase-wrapper table.doRentIt-product-price-table th,
#divi-staircase-wrapper table.doRentIt-product-price-table td {
    background: transparent !important;
    background-color: transparent !important;
    border: none;
    margin: 0;
}

#divi-staircase-wrapper table.doRentIt-product-price-table {
    width: 100%;
    border-collapse: collapse;
    font-family: 'Open Sans', Arial, sans-serif;
    font-size: 13px;
    color: inherit; /* Arv farve fra kortet */
    margin-bottom: 20px;
    margin-top: 10px;
}

/* Celler */
#divi-staircase-wrapper table.doRentIt-product-price-table th,
#divi-staircase-wrapper table.doRentIt-product-price-table td {
    text-align: left;
    padding: 6px 0 !important;
    border-bottom: 1px solid rgba(0,0,0,0.1) !important;
    font-weight: normal;
    vertical-align: bottom;
}

/* Priser til højre */
#divi-staircase-wrapper table.doRentIt-product-price-table .price { 
    text-align: right; 
    white-space: nowrap; 
}

/* Valuta */
#divi-staircase-wrapper table.doRentIt-product-price-table .currency { 
    text-align: center; 
    width: 30px; 
    color: #999; 
    font-size: 11px; 
}

/* Overskrift (Første thead) */
#divi-staircase-wrapper .table-header {
    font-weight: 800;
    margin-bottom: 15px;
    font-size: 14px;
    color: #000;
    text-align: left;
}

#divi-staircase-wrapper table.doRentIt-product-price-table thead:first-of-type th {
    font-weight: 800 !important;
    font-size: 14px !important;
    color: inherit !important;
    border-bottom: 2px solid #000 !important;
    padding-bottom: 8px !important;
}

/* Total Række */
#divi-staircase-wrapper table.doRentIt-product-price-table tbody + thead th {
    border-top: 2px solid #000 !important;
    padding-top: 8px !important;
    font-weight: 800 !important;
    color: inherit !important;
}

/* DIN PRIS (GUL BOKS) */
#divi-staircase-wrapper table.doRentIt-product-price-table thead.yourPrice th {
    background-color: #E3E57F !important;
    color: #000 !important; /* Altid sort tekst */
    font-weight: 800 !important;
    padding: 10px !important;
    border-bottom: none !important;
    border-top: none !important;
}

#divi-staircase-wrapper table.doRentIt-product-price-table thead.yourPrice th:first-child { border-radius: 4px 0 0 4px; }
#divi-staircase-wrapper table.doRentIt-product-price-table thead.yourPrice th:last-child { border-radius: 0 4px 4px 0; }

/* Skjul tomme rækker */
#divi-staircase-wrapper table.doRentIt-product-price-table .spacerRow td { height: 10px !important; padding: 0 !important; border: none !important; }


/* --- KNAP --- */
.order-btn-wrapper { margin-top: 15px; text-align: center; }
.btn-order-wagon {
    background-color: #E3E57F;
    color: #000;
    font-weight: 800;
    font-size: 18px;
    text-transform: uppercase;
    border: none;
    width: 100%;
    padding: 15px 0;
    cursor: pointer;
    transition: background 0.2s;
}
.btn-order-wagon:hover { background-color: #d0d26e; }


/* --- FARVE TEMAER --- */

/* Basic */
.theme-basic { border-color: #A8D5BA; }
.theme-basic .card-footer { background-color: #A8D5BA; color: #333; }

/* Pro */
.theme-pro { border-color: #C3D9EA; }
.theme-pro .card-footer { background-color: #C3D9EA; color: #333; }

/* Premium */
.theme-premium { border-color: #5D6D7A; }
.theme-premium .card-footer { background-color: #5D6D7A; color: #fff; }
.theme-premium .feature-list li { color: #fff; }
.theme-premium .footer-title { color: #fff; }

/* PREMIUM TABEL (HVIDE LINJER OG TEKST) */
.theme-premium .footer-expanded .table-header,
.theme-premium table.doRentIt-product-price-table,
.theme-premium table.doRentIt-product-price-table th, 
.theme-premium table.doRentIt-product-price-table td,
.theme-premium table.doRentIt-product-price-table .price {
    color: #fff !important;
    border-bottom-color: rgba(255,255,255,0.4) !important;
}

.theme-premium table.doRentIt-product-price-table .currency { color: #ccc !important; }

/* Premium Tykke Linjer (Hvid) */
.theme-premium table.doRentIt-product-price-table thead:first-of-type th {
    border-bottom-color: #fff !important;
    color: #fff !important;
}
.theme-premium table.doRentIt-product-price-table tbody + thead th {
    border-top-color: #fff !important;
    color: #fff !important;
}

/* SIKRING AF SORT TEKST PÅ GUL BOKS I PREMIUM */
.theme-premium table.doRentIt-product-price-table thead.yourPrice th {
    color: #000 !important;
    background-color: #E3E57F !important;
}


/* --- MOBIL PRIKKER --- */
.mobile-dots {
    display: none;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
    width: 100%;
}

.dot {
    height: 12px;
    width: 12px;
    background-color: #bbb;
    border-radius: 50%;
    display: inline-block;
    transition: background-color 0.3s ease;
}

.dot.active { background-color: #333; }


/* --- RESPONSIVT --- */
@media screen and (min-width: 981px) {
    .pricing-card {
        width: 30%;
    }
}

@media screen and (max-width: 980px) {
    .staircase-row {
        justify-content: flex-start;
        padding-left: 5vw;
        padding-right: 5vw;
    }
    .mobile-dots { display: flex; }
}