/*
Theme Name: IREP IGP Institucional
Theme URI: https://www.igp.gob.pe/irep_igp/
Author: Instituto Geofisico del Peru - IGP
Author URI: https://www.igp.gob.pe/
Description: Tema institucional ultra-ligero para el portal IREP del IGP. Creado a medida para una integracion optima con Elementor Pro y Polylang bajo PHP 8.2+.
Version: 1.0.4
Text Domain: irep-igp
Requires at least: 5.8
Requires PHP: 7.4
*/

/* Reset y base institucional */
*, *::before, *::after {
    box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    color: #333333;
    background-color: #ffffff;
    line-height: 1.6;
    overflow-x: hidden;
}

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

a {
    color: #0056b3;
    text-decoration: none;
}

a:hover, a:focus {
    color: #003366;
    text-decoration: underline;
}

/* Integracion exacta con Header/Footer y secciones de Elementor */
.site-main {
    width: 100%;
    position: relative;
}

/* El contenedor principal NO debe tener margen, ni sombras, ni esquinas redondeadas flotantes */
.main {
    position: relative;
    background: #ffffff;
    margin: 0;
    border-radius: 0;
    box-shadow: none;
    z-index: 3;
}

/* Eliminamos cualquier efecto de marco o separacion que traiga .main-raised */
.main-raised,
.page .main-raised,
.single .main-raised,
.archive .main-raised,
.header-layout-classic-blog .main-raised {
    margin: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
}

/* Ocultar titulo duplicado del tema en paginas editadas con Elementor */
.elementor-page .title-in-content,
.elementor-page .image-in-page {
    display: none !important;
}

/* Compatibilidad de relleno con Elementor */
.elementor-page .pagebuilder-section,
.elementor-page article.section,
.elementor-page.page-template-template-fullwidth article.section {
    padding: 0 !important;
}

.elementor-page .blog-post > .container,
.elementor-page.page-template-template-fullwidth .blog-post > .container {
    width: 100% !important;
    max-width: 100% !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
}

/* Integracion limpia con Elementor en paginas de plantilla completa */
.elementor-page.page-template-template-fullwidth .blog-post > .container,
.elementor-page.page-template-template-fullwidth .container {
    width: 100% !important;
    max-width: 100% !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
}

.elementor-page.page-template-template-fullwidth .container .col-md-12 {
    padding-left: 0 !important;
    padding-right: 0 !important;
}

.elementor-page.page-template-template-fullwidth .container .row {
    margin-left: 0 !important;
    margin-right: 0 !important;
}

.elementor-page.page-template-template-fullwidth article.section {
    padding: 0 !important;
}

/* Clases de contenedor para compatibilidad con estilos heredados en pantallas grandes */
.container {
    width: 100%;
    padding-right: 15px;
    padding-left: 15px;
    margin-right: auto;
    margin-left: auto;
}

@media (min-width: 768px) {
    .container { width: 750px; }
}
@media (min-width: 992px) {
    .container { width: 970px; }
}
@media (min-width: 1200px) {
    .container { width: 1170px; }
}

.container-fluid {
    width: 100%;
    padding-right: 15px;
    padding-left: 15px;
    margin-right: auto;
    margin-left: auto;
}

.p-0 {
    padding: 0 !important;
}

/* Fallback Header & Footer cuando no aplica Elementor Theme Builder */
.site-header {
    background: #ffffff;
    border-bottom: 1px solid #e0e0e0;
    padding: 10px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.site-footer {
    background: #1a202c;
    color: #ffffff;
    padding: 20px;
    text-align: center;
    font-size: 0.9em;
}

.site-footer a {
    color: #cbd5e0;
}

/* En pantallas pequenas (tablets y moviles < 992px), cero margen izquierdo adicional */
@media (max-width: 991px) {
    .main,
    .main .blog-post,
    .main .container,
    div.container,
    .page-template-template-fullwidth .container,
    .elementor-page .container {
        width: 100% !important;
        max-width: 100% !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }

    .main .row,
    .page-template-template-fullwidth .row,
    .elementor-page .row {
        margin-left: 0 !important;
        margin-right: 0 !important;
    }

    .main .col-md-12,
    .page-template-template-fullwidth .col-md-12,
    .elementor-page .col-md-12 {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    article.section,
    .elementor-page article.section {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }
}

/* Definicion de fuentes Futura */
@font-face {
    font-family: "Futura";
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url("../../uploads/2021/08/FuturaStdMedium.woff2") format("woff2");
}
@font-face {
    font-family: "Futura2";
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url("../../uploads/2021/08/FuturaStdMedium.woff2") format("woff2");
}
@font-face {
    font-family: "FuturaBold";
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url("../../uploads/2021/07/Futura-Bold.woff") format("woff");
}
