/*
Theme Name: Pageking Flex (child)
Template: pk-theme
Author: Pageking
Author URI: https://www.pageking.nl/
Description: Pageking is een thema voor WordPress dat is ontworpen voor Pageking websites.
Requires at least: 5.9
Tested up to: 6.7.2
Requires PHP: 8.3
Version: 1.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
*/

* {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}
/* SPEED OPTIMIZATIONS */
/* Layout Shift Prevention - CLS Optimization */
img {
    max-width: 100%;
    height: auto;
    /* Preserve aspect ratio to prevent layout shifts */
    aspect-ratio: attr(width) / attr(height);
}

img[width][height] {
    /* Browser calculates aspect-ratio from width/height attributes */
    aspect-ratio: auto;
}

/* Ensure hero images maintain aspect ratio */
.hero-bg {
    width: 100%;
    height: auto;
    object-fit: cover;
}

/* HEADER */
.pk-menu .menu .submenu-toggle {
    border: 0px;
    background-image: url("data:image/svg+xml,%3Csvg width='14' height='8' viewBox='0 0 14 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0.75 0.75L6.75 6.75L12.75 0.75' stroke='black' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-color: transparent;
    background-position: center;
    background-size: contain;
    background-repeat: no-repeat;
    height: 1em;
}
.pk-menu ul.menu li:not(.menu-button) a {
    text-decoration: none;
    color: black;
}
.pk-menu .pk-submenu {
    min-width: 200px;
}

/* FOOTER */
.pk-footer {
    padding-inline: var(--pk-site-gutter);
}

button {
    font-family: var(--pk-text-font-family);
}

/* DEFAULTS PAGE-CONTENT */
.pk-page-content h1,
.pk-page-content h2,
.pk-page-content h3,
.pk-page-content h4,
.pk-page-content h5,
.pk-page-content h6 {
    margin-top: 0rem;
    margin-bottom: 1rem;
}
.pk-page-content p {
    margin-top: 0;
    margin-bottom: 1.25rem;
}
.pk-page-content ul,
.pk-page-content ol {
    margin-top: 0;
    margin-bottom: 1.5rem;
    padding-left: 1.1rem;
}
.pk-page-content li {
    margin-bottom: 0.5rem;
}
.pk-page-content img {
    max-width: 100%;
    height: auto;
    display: block;
}
.pk-page-content table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 2rem;
}
.pk-page-content th,
.pk-page-content td {
    padding: 0.75rem 1rem;
    border: 1px solid #e0e0e0;
    text-align: left;
}
.pk-page-content blockquote {
    margin: 1.5rem 0;
    padding: 1rem 1.5rem;
}
.pk-page-content hr {
    border: none;
    border-top: 1px solid #e0e0e0;
    margin: 2rem 0;
}
.sidebar {
    padding: var(--pk-row-spacing);
    border-radius: 5px;
}
.gallery-item,
.image {
    border-radius: 5px;
    overflow: hidden;
}

/* DIALOG */
body dialog {
    border-radius: 10px;
}
body dialog h3 {
    margin-bottom: 1rem;
}
