/*
Theme Name: Kazo Arquitectos
Theme URI: https://kazoarquitectos.cl
Author: Kazo Arquitectos
Description: Tema de bloques minimal editorial para Kazo Arquitectos. Portafolio de proyectos, servicios, estudio y contacto con WhatsApp. Todo editable desde Apariencia > Editor.
Version: 1.0.0
Requires at least: 6.4
Tested up to: 6.7
Requires PHP: 7.4
License: GPL-2.0-or-later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: kazo
*/

/* ---------- Base ---------- */
html { scroll-behavior: smooth; }
body { -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
img { display: block; }
::selection { background: var(--wp--preset--color--contrast); color: var(--wp--preset--color--base); }

/* ---------- Header ---------- */
.kazo-header { position: sticky; top: 0; z-index: 50; background: color-mix(in srgb, var(--wp--preset--color--base) 92%, transparent); backdrop-filter: blur(8px); border-bottom: 1px solid var(--wp--preset--color--line); }
.admin-bar .kazo-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .kazo-header { top: 46px; } }
.kazo-header .wp-block-site-title a { text-decoration: none; letter-spacing: .02em; }

/* ---------- Links ---------- */
.kazo-link-arrow a, a.kazo-link-arrow { text-decoration: none; border-bottom: 1px solid currentColor; padding-bottom: 2px; }
.kazo-link-arrow a::after, a.kazo-link-arrow::after { content: " →"; }

/* ---------- Etiqueta pequeña (eyebrow) ---------- */
.kazo-eyebrow, .is-style-eyebrow { text-transform: uppercase; letter-spacing: .14em; font-size: var(--wp--preset--font-size--x-small) !important; color: var(--wp--preset--color--muted); }

.kazo-eyebrow a { color: inherit; text-decoration: none; }
.kazo-eyebrow a:hover { color: var(--wp--preset--color--contrast); }

/* ---------- Grilla de proyectos ---------- */
.kazo-projects .wp-block-post { position: relative; }
.kazo-projects .wp-block-post-featured-image { overflow: hidden; margin-bottom: .9rem; }
.kazo-projects .wp-block-post-featured-image img { transition: transform .8s cubic-bezier(.2,.7,.2,1), filter .6s; filter: grayscale(.15); }
.kazo-projects .wp-block-post:hover .wp-block-post-featured-image img { transform: scale(1.035); filter: grayscale(0); }
.kazo-projects .wp-block-post-title a { text-decoration: none; }
.kazo-projects .wp-block-post-terms a { text-decoration: none; color: var(--wp--preset--color--muted); }

/* ---------- Lista de servicios ---------- */
.kazo-services > .wp-block-group { border-top: 1px solid var(--wp--preset--color--line); }
.kazo-services > .wp-block-group:last-child { border-bottom: 1px solid var(--wp--preset--color--line); }
.kazo-num { font-variant-numeric: tabular-nums; color: var(--wp--preset--color--muted); }

/* ---------- Ficha técnica de proyecto ---------- */
.kazo-ficha { border-top: 1px solid var(--wp--preset--color--line); }
.kazo-ficha > .wp-block-columns { border-bottom: 1px solid var(--wp--preset--color--line); margin: 0 !important; padding: .7rem 0; }

/* ---------- Botón flotante WhatsApp ---------- */
.kazo-whatsapp { position: fixed; right: 20px; bottom: 20px; z-index: 99; margin: 0 !important; }
.kazo-whatsapp .wp-block-button__link { display: inline-flex; align-items: center; gap: .5rem; border-radius: 999px !important; box-shadow: 0 6px 24px rgba(0,0,0,.18); background: #25D366 !important; color: #fff !important; }
.kazo-whatsapp .wp-block-button__link::before { content: ""; width: 20px; height: 20px; background: no-repeat center/contain url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23fff'%3E%3Cpath d='M17.47 14.38c-.3-.15-1.76-.87-2.03-.97-.27-.1-.47-.15-.67.15-.2.3-.77.97-.94 1.17-.17.2-.35.22-.64.07-.3-.15-1.26-.46-2.4-1.48-.89-.79-1.49-1.77-1.66-2.07-.17-.3-.02-.46.13-.61.13-.13.3-.35.45-.52.15-.17.2-.3.3-.5.1-.2.05-.37-.02-.52-.08-.15-.67-1.62-.92-2.22-.24-.58-.49-.5-.67-.51h-.57c-.2 0-.52.07-.79.37-.27.3-1.04 1.02-1.04 2.48s1.07 2.88 1.21 3.08c.15.2 2.1 3.2 5.08 4.49.71.31 1.26.49 1.69.63.71.23 1.36.2 1.87.12.57-.08 1.76-.72 2.01-1.41.25-.7.25-1.29.17-1.41-.07-.13-.27-.2-.57-.35M12.05 21.79h-.01a9.87 9.87 0 0 1-5.03-1.38l-.36-.21-3.74.98 1-3.65-.24-.37a9.86 9.86 0 0 1-1.51-5.26c0-5.45 4.44-9.88 9.89-9.88 2.64 0 5.12 1.03 6.99 2.9a9.82 9.82 0 0 1 2.89 6.99c0 5.45-4.44 9.88-9.88 9.88m8.41-18.3A11.82 11.82 0 0 0 12.05 0C5.5 0 .16 5.34.16 11.89c0 2.1.55 4.14 1.59 5.95L.06 24l6.3-1.65a11.88 11.88 0 0 0 5.68 1.45h.01c6.55 0 11.89-5.34 11.89-11.89a11.82 11.82 0 0 0-3.48-8.41'/%3E%3C/svg%3E"); }
@media (max-width: 600px) { .kazo-whatsapp .wp-block-button__link { padding: .85rem !important; font-size: 0 !important; } .kazo-whatsapp .wp-block-button__link::before { width: 24px; height: 24px; } }

/* ---------- Formulario de contacto ---------- */
.kazo-form { display: grid; gap: 1.1rem; }
.kazo-form label { display: block; font-size: var(--wp--preset--font-size--x-small); text-transform: uppercase; letter-spacing: .12em; color: var(--wp--preset--color--muted); margin-bottom: .35rem; }
.kazo-form input, .kazo-form textarea, .kazo-form select { width: 100%; border: 0; border-bottom: 1px solid var(--wp--preset--color--contrast); background: transparent; padding: .6rem 0; font: inherit; color: inherit; border-radius: 0; }
.kazo-form input:focus, .kazo-form textarea:focus, .kazo-form select:focus { outline: none; border-bottom-width: 2px; }
.kazo-form textarea { min-height: 140px; resize: vertical; }
.kazo-form .kazo-hp { position: absolute; left: -9999px; }
.kazo-form button { justify-self: start; background: var(--wp--preset--color--contrast); color: var(--wp--preset--color--base); border: 0; padding: .95rem 1.8rem; font: inherit; cursor: pointer; letter-spacing: .04em; }
.kazo-form button:hover { opacity: .85; }
.kazo-form-msg { padding: 1rem 1.2rem; border-left: 3px solid var(--wp--preset--color--contrast); background: var(--wp--preset--color--surface); }

/* ---------- Animación suave de entrada ---------- */
@media (prefers-reduced-motion: no-preference) {
  .kazo-fade { animation: kazoFade .9s cubic-bezier(.2,.7,.2,1) both; }
  @keyframes kazoFade { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
}
