/*
Theme Name: BB Custom Theme
Theme URI: https://www.labombonierabeb.it/
Author: La Bomboniera Room & Breakfast
Author URI: https://www.labombonierabeb.it/
Description: Tema personalizzato leggero e ottimizzato per Gutenberg per La Bomboniera Room & Breakfast.
Version: 0.2.0
Requires at least: 6.6
Tested up to: 7.1
Requires PHP: 8.0
Text Domain: bb-custom-theme
*/

/**
 * Identita visiva
 *
 * Palette ispirata alla locandina di La Casa sulla Via del Mare:
 * blu profondo, azzurro mare, avorio caldo e bronzo sabbia.
 */
:root {
    --bb-color-navy: #243a63;
    --bb-color-sea: #78a6bd;
    --bb-color-sky: #b8d1df;
    --bb-color-ivory: #f7efe3;
    --bb-color-sand: #a6764f;
    --bb-color-ink: #263342;
    --bb-color-white: #ffffff;

    --bb-font-heading: Georgia, "Times New Roman", serif;
    --bb-font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

    --bb-radius-sm: 0.375rem;
    --bb-radius-md: 0.75rem;
    --bb-shadow-soft: 0 0.75rem 2rem rgb(36 58 99 / 10%);
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--bb-color-ink);
    background: var(--bb-color-white);
    font-family: var(--bb-font-body);
    font-size: 1rem;
    line-height: 1.7;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}

.site-content {
    min-height: 60vh;
}

.site-main {
    overflow: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--bb-color-navy);
    font-family: var(--bb-font-heading);
    font-weight: 500;
    line-height: 1.2;
    text-wrap: balance;
}

a {
    color: var(--bb-color-navy);
    text-decoration-thickness: 0.08em;
    text-underline-offset: 0.18em;
}

a:hover {
    color: var(--bb-color-sand);
}

:focus-visible {
    outline: 3px solid var(--bb-color-sea);
    outline-offset: 3px;
}

::selection {
    color: var(--bb-color-navy);
    background: var(--bb-color-sky);
}

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

button,
input,
select,
textarea {
    font: inherit;
}

.wp-element-button,
.wp-block-button__link {
    border-radius: var(--bb-radius-sm);
    transition: background-color 160ms ease, color 160ms ease, transform 160ms ease;
}

.wp-element-button:hover,
.wp-block-button__link:hover {
    transform: translateY(-1px);
}

.btn-primary {
    --bs-btn-bg: var(--bb-color-navy);
    --bs-btn-border-color: var(--bb-color-navy);
    --bs-btn-hover-bg: var(--bb-color-sand);
    --bs-btn-hover-border-color: var(--bb-color-sand);
    --bs-btn-active-bg: var(--bb-color-sand);
    --bs-btn-active-border-color: var(--bb-color-sand);
    --bs-btn-focus-shadow-rgb: 120, 166, 189;
}

.site-header {
    border-bottom: 1px solid rgb(36 58 99 / 10%);
    background: rgb(255 255 255 / 96%);
    box-shadow: 0 0.25rem 1rem rgb(36 58 99 / 6%);
}

.site-branding .custom-logo {
    width: auto;
    max-height: 4rem;
}

.site-title {
    color: var(--bb-color-navy);
    font-family: var(--bb-font-heading);
    font-size: clamp(1.15rem, 2.5vw, 1.6rem);
    letter-spacing: 0.02em;
    text-decoration: none;
}

.site-title:hover {
    color: var(--bb-color-sand);
}

.navbar-nav .menu-item > a,
.bb-page-menu a {
    display: block;
    padding: 0.65rem 0.8rem;
    color: var(--bb-color-ink);
    font-weight: 500;
    text-decoration: none;
}

.navbar-nav .current-menu-item > a,
.navbar-nav .menu-item > a:hover,
.bb-page-menu a:hover {
    color: var(--bb-color-sand);
}

.bb-page-menu ul,
.footer-menu {
    margin: 0;
    padding: 0;
    list-style: none;
}

.bb-language-switcher {
    list-style: none;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.bb-language-switcher a {
    color: var(--bb-color-navy);
    text-decoration: none;
}

.bb-language-switcher .current-lang a,
.bb-language-switcher a:hover {
    color: var(--bb-color-sand);
}

.bb-hero {
    color: var(--bb-color-navy);
    background:
        radial-gradient(circle at 85% 20%, rgb(184 209 223 / 75%), transparent 30%),
        linear-gradient(135deg, var(--bb-color-ivory), #ffffff);
}

.bb-eyebrow {
    color: var(--bb-color-sand);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.bb-property-card,
.bb-info-card {
    height: 100%;
    border: 1px solid rgb(36 58 99 / 10%);
    border-radius: var(--bb-radius-md);
    background: var(--bb-color-white);
    box-shadow: var(--bb-shadow-soft);
}

.bb-property-card {
    padding: clamp(1.5rem, 4vw, 2.5rem);
}

.bb-section-soft {
    background: var(--bb-color-ivory);
}

.bb-contact-panel {
    padding: clamp(1.5rem, 4vw, 3rem);
    border-radius: var(--bb-radius-md);
    background: var(--bb-color-ivory);
}

.wpcf7 label {
    width: 100%;
    color: var(--bb-color-navy);
    font-weight: 600;
}

.wpcf7 .form-control,
.wpcf7 .form-select {
    margin-top: 0.4rem;
}

.entry-content > :where(:not(.alignwide):not(.alignfull)) {
    max-width: 45rem;
    margin-right: auto;
    margin-left: auto;
}

.entry-content > .alignwide {
    width: min(100% - 2rem, 75rem);
    margin-right: auto;
    margin-left: auto;
}

.entry-content > .alignfull {
    width: 100%;
}

.entry-content::after {
    display: table;
    clear: both;
    content: "";
}

.site-footer {
    color: var(--bb-color-ivory);
    background: var(--bb-color-navy);
}

.site-footer a {
    color: var(--bb-color-white);
}

.site-footer a:hover {
    color: var(--bb-color-sky);
}

.footer-menu {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 1.25rem;
}

.skip-link {
    position: fixed;
    z-index: 1100;
    top: 0.75rem;
    left: 0.75rem;
    transform: translateY(-200%);
}

.skip-link:focus {
    transform: translateY(0);
}

.alignwide {
    max-width: 75rem;
}

.alignfull {
    max-width: none;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
    }
}
