/*
Theme Name: KS Pueblo
Theme URI: 
Author: KickStart Dental Marketing
Author URI: https://kickstartdental.com
Description: A dental block theme by KickStart Dental Marketing.
Requires at least: 6.0
Tested up to: 6.3.2
Requires PHP: 5.7
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: kspueblo
Tags: full-site-editing
*/

/* Extend Responsive Layouts
--------------------------------------------- */

/* Extend responsive layouts to 991px (default is max 781px) */
@media (max-width: 991px) {

    /* Extend responsive column layouts to 991px (default is max 781px) */
    .wp-block-columns {
        flex-wrap: wrap !important;
    }

    .wp-block-columns .wp-block-column {
        flex-basis: 100% !important;
    }

    /* Extend responsive query loop > post template grid layouts to 991px (default is max 599px) */
    .wp-block-post-template li {
        width: 100% !important;
    }
}

/* Query Loop Grid
--------------------------------------------- */

/* Make query loop post template grid layouts more responsive using 'auto-fit' */
.wp-block-query .wp-block-post-template-is-layout-grid {
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
}

/* Make query loop post template grid layouts more responsive using 'auto-fit' */
.wp-block-query .locations {
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
}

/* Add 'auto-fit' to footer grid */
.wp-block-query.footer-location-grid .wp-block-post-template-is-layout-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

/* Service Grid
--------------------------------------------- */

/* Allow service title fill width of cover block */
.wp-block-cover.has-custom-content-position.has-custom-content-position .wp-block-cover__inner-container {
    width: 100%;
}

.service-card-title {
    transition: all 0.25s ease-out;
}

.service-card-title a:first-child:hover {
    text-decoration: none;
    color: var(--wp--preset--color--secondary);
}

.service-card:hover .service-card-title,
.service-card-title:hover {
    transform: translateY(calc(var(--wp--preset--spacing--10) * -1));
    box-shadow: var(--wp--preset--shadow--large);
}

/* Primary Navigation
--------------------------------------------- */

/* Add padding to submenu dropdown container */
header .wp-block-navigation .wp-block-navigation__submenu-container {
    padding: var(--wp--preset--spacing--20);
    border-radius: 16px;
    @media (min-width: 600px) {    
        box-shadow: var(--wp--preset--shadow--small);
    }    
}

/* Remove padding-right on navigations items with children */
header .wp-block-navigation .wp-block-navigation__container .has-child > a {
    padding-right: 8px;
}

/* Add hover transition to submenu links */
.wp-block-navigation .has-child .wp-block-navigation__submenu-container > .wp-block-navigation-item > .wp-block-navigation-item__content {
    transition: all 0.25s ease-out;
    &:hover {
        transform: translateX(4px);
    }
}

/* Fix submenu not fitting content */
.wp-block-navigation__submenu-container {
    width: max-content !important;
}

/* Homepage Hero
--------------------------------------------- */

@media (max-width: 991px) {
    .hero-spacer {
        height: 30vh !important;
    }
}

/* Read More Link
--------------------------------------------- */

.wp-block-read-more {
    transition: all 0.25s ease-out;
    &:hover {
        color: var(--wp--preset--color--base);
        background-color: var(--wp--preset--color--secondary);
        border-color: var(--wp--preset--color--secondary);
    }
}

/* Template Parts
--------------------------------------------- */

/* Remove margin-top from template part containers */
.wp-block-template-part {
    margin-top: 0 !important;
}

/* Custom Block Types
--------------------------------------------- */

.location-address p,
.location-phone p,
.location-email p,
.location-map p,
.location-hours p,
.team-job-title p,
.special-price p,
.service-title h3 {
    margin-block-start: 0 !important;
    margin-block-end: 0 !important;
}

.team-job-title {
    color: var(--wp--preset--color--secondary);
    letter-spacing: 1px;
    text-transform: uppercase;
}

.special-price {
    font-size: var(--wp--preset--font-size--large);
    font-family: var(--wp--preset--font-family--headings);
    font-weight: 700;
    line-height: 1.6;
}

.special-details ul {
    list-style-type: disc;
}

.special-terms {
    font-size: 12px;
}

.service-title a {
    color: var(--wp--preset--color--contrast);
    &:hover {
        text-decoration: none;
    }
}

/* Map
--------------------------------------------- */

.map {
    overflow: hidden;
}

/* Misc
--------------------------------------------- */

/* Remove line-height added when logo "link image to home" is enabled */
.custom-logo-link {
    line-height: 0;
}

.img-square {
	aspect-ratio: 1;
}

.img-3-4 {
	aspect-ratio: 3 / 4 !important;
}

.img-2-3 {
	aspect-ratio: 2 / 3 !important;
}

iframe {
	display: block !important;
}

summary::marker {
  color: var(--wp--preset--color--secondary);
}

.container {
    margin-right: var(--wp--preset--spacing--20);
    margin-left: var(--wp--preset--spacing--20);
    /* Reduce border radius on parent containers on mobile so nested radius looks better */
    @media (max-width: 599px) {
        border-radius: 48px !important;
    }
}

/* Reduce border radius on cards nested w/i containers on mobile so nested radius looks better */
.card {
    @media (max-width: 599px) {
        border-radius: 32px !important;
    }
}

/* Adjust TrustIndex widget styling */
.ti-widget.ti-goog .ti-review-item>.ti-inner {
    border-radius: 40px !important;
    box-shadow: var(--wp--preset--shadow--small);
    @media (max-width: 599px) {
        border-radius: 32px !important;
    }
}

.location-card {
    max-width: 50%;
}