
/* =========================================================
   PÁGINAS PÚBLICAS: SERVICIOS / NOSOTROS / CONTACTO
   ========================================================= */
.public-page-header {
    position: relative;
    z-index: 50;
    background: #172434;
}

.public-page-header .main-nav a {
    color: #fff;
}

.public-hero {
    --public-parallax-y: 0px;
    position: relative;
    min-height: 500px;
    display: flex;
    align-items: center;
    overflow: hidden;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center calc(50% + var(--public-parallax-y));
}

.public-hero-services { background-color:#172434; }

.public-hero-about { background-color:#172434; }

.public-hero-contact { background-color:#172434; }

.public-hero-overlay {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(
            90deg,
            rgba(14, 31, 49, .90) 0%,
            rgba(14, 31, 49, .67) 55%,
            rgba(14, 31, 49, .52) 100%
        );
}

.public-hero-content {
    position: relative;
    z-index: 2;
    max-width: 860px;
    color: #fff;
}

.public-hero-content > span {
    display: inline-block;
    margin-bottom: 16px;
    color: #d5ab4d;
    font-family: Georgia, "Times New Roman", serif;
    font-weight: 700;
}

.public-hero-content h1 {
    max-width: 780px;
    margin: 0 0 18px;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(38px, 5vw, 64px);
    line-height: 1.06;
}

.public-hero-content p {
    max-width: 690px;
    margin: 0 0 28px;
    font-size: 17px;
    line-height: 1.7;
    color: rgba(255,255,255,.88);
}

.public-section {
    padding: 90px 0;
}

.alt-bg {
    background: #f4f6f8;
}

.two-column-intro {
    display: grid;
    grid-template-columns: .9fr 1.1fr;
    gap: 70px;
    align-items: start;
}

.two-column-intro h2,
.about-public-copy h2,
.faq-intro h2,
.appointment-public-copy h2 {
    margin: 14px 0 0;
    color: #10233a;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(31px, 3.2vw, 45px);
    line-height: 1.16;
}

.public-copy p,
.about-public-copy > p,
.faq-intro p,
.appointment-public-copy > p {
    margin: 0 0 18px;
    color: #556170;
    font-size: 16px;
    line-height: 1.75;
}

.service-cards-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}

.legal-service-card {
    min-height: 250px;
    padding: 30px;
    border-radius: 11px;
    background: #fff;
    box-shadow: 0 14px 40px rgba(18, 33, 50, .07);
}

.legal-service-card > span {
    color: #d5ab4d;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 34px;
    font-weight: 700;
}

.legal-service-card h3 {
    margin: 17px 0 10px;
    color: #10233a;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 22px;
}

.legal-service-card p {
    margin: 0;
    color: #62707c;
    line-height: 1.65;
}

.public-steps {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
}

.public-steps article {
    padding: 30px;
    border: 1px solid #e1e5e9;
    border-radius: 10px;
    text-align: center;
}

.public-steps strong {
    display: block;
    color: #c7d0db;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 54px;
}

.public-steps h3 {
    margin: 8px 0 10px;
    color: #10233a;
    font-family: Georgia, "Times New Roman", serif;
}

.public-steps p {
    margin: 0;
    color: #66717d;
    line-height: 1.6;
}

.faq-layout {
    display: grid;
    grid-template-columns: .8fr 1.2fr;
    gap: 60px;
}

.faq-list {
    display: grid;
    gap: 12px;
}

.faq-item {
    border: 1px solid #dde2e7;
    border-radius: 8px;
    background: #fff;
    overflow: hidden;
}

.faq-item button {
    width: 100%;
    min-height: 58px;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 0;
    background: #fff;
    color: #16273b;
    font: inherit;
    font-weight: 700;
    text-align: left;
    cursor: pointer;
}

.faq-item button span {
    color: #d5ab4d;
    font-size: 25px;
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height .25s ease;
}

.faq-answer p {
    margin: 0;
    padding: 0 20px 20px;
    color: #65707c;
    line-height: 1.6;
}

.faq-item.open .faq-answer {
    max-height: 220px;
}

.public-cta-band {
    --public-parallax-y: 0px;
    position: relative;
    min-height: 430px;
    display: flex;
    align-items: center;
    overflow: hidden;
    background-image:
        var(--public-cta-image, url("../img/practice.jpg"));
    background-position:
        center calc(48% + var(--public-parallax-y));
    background-size: cover;
    background-repeat: no-repeat;
}

.public-cta-overlay {
    position: absolute;
    inset: 0;
    background: rgba(13, 31, 49, .72);
}

.public-cta-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: #fff;
}

.public-cta-content h2 {
    max-width: 800px;
    margin: 0 auto 12px;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(34px, 4vw, 52px);
}

.public-cta-content p {
    margin: 0 0 25px;
    color: rgba(255,255,255,.84);
}

/* Nosotros */
.about-public-grid {
    display: grid;
    grid-template-columns: 1.15fr .85fr;
    gap: 70px;
    align-items: center;
}

.about-public-image {
    position: relative;
}

.about-public-image::after {
    content: "";
    position: absolute;
    top: -22px;
    right: -22px;
    width: 80%;
    height: 80%;
    z-index: -1;
    background: #d4aa4e;
}

.about-public-image img {
    width: 100%;
    max-height: 650px;
    object-fit: cover;
}

.mission-vision-grid {
    margin-top: 34px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.mission-vision-grid article {
    padding: 24px;
    background: #f4f6f8;
}

.mission-vision-grid article > span {
    color: #d4aa4e;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .09em;
}

.mission-vision-grid h3 {
    margin: 9px 0;
    color: #12243a;
    font-family: Georgia, "Times New Roman", serif;
}

.mission-vision-grid p {
    margin: 0;
    color: #65717d;
    line-height: 1.6;
}

.public-stats-band {
    padding: 58px 0;
    background: #eef1f4;
}

.public-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
}

.public-stats-grid article {
    padding: 18px 30px;
    text-align: center;
    border-right: 1px solid #d9dee3;
}

.public-stats-grid article:last-child {
    border-right: 0;
}

.public-stats-grid strong {
    display: block;
    color: #10233a;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 36px;
}

.public-stats-grid span {
    display: block;
    margin-top: 6px;
    color: #5e6975;
}

.values-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 22px;
}

.values-grid article {
    padding: 28px;
    background: #fff;
    border-top: 4px solid #d4aa4e;
    box-shadow: 0 12px 30px rgba(19, 34, 49, .05);
}

.values-grid h3 {
    margin: 0 0 10px;
    color: #10233a;
    font-family: Georgia, "Times New Roman", serif;
}

.values-grid p {
    margin: 0;
    color: #66717d;
    line-height: 1.6;
}

/* Contacto */
.contact-full-map {
    height: 440px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 18px 50px rgba(17, 31, 48, .08);
}

.contact-full-map iframe {
    width: 100%;
    height: 100%;
    border: 0;
}

.contact-info-grid {
    margin-top: 28px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}

.contact-info-grid article {
    padding: 28px;
    border: 1px solid #e0e5e9;
    background: #fff;
}

.contact-info-grid article > span {
    color: #d4aa4e;
    font-size: 27px;
}

.contact-info-grid h3 {
    margin: 12px 0 9px;
    color: #10233a;
    font-family: Georgia, "Times New Roman", serif;
}

.contact-info-grid p,
.contact-info-grid a {
    color: #5f6b77;
    line-height: 1.55;
}

.appointment-public-grid {
    display: grid;
    grid-template-columns: .8fr 1.2fr;
    gap: 60px;
    align-items: start;
}

.public-appointment-form {
    padding: 34px;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 18px 48px rgba(16, 32, 49, .08);
}

.public-appointment-form > h2 {
    margin: 0 0 22px;
    color: #10233a;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 29px;
}

.appointment-contact-summary {
    margin-top: 28px;
    display: grid;
    gap: 14px;
}

.appointment-contact-summary div {
    padding: 15px 17px;
    border-left: 4px solid #d4aa4e;
    background: #fff;
}

.appointment-contact-summary strong,
.appointment-contact-summary span {
    display: block;
}

.appointment-contact-summary strong {
    margin-bottom: 4px;
    color: #10233a;
}

.appointment-contact-summary span {
    color: #6b7580;
}

.appointment-submit {
    width: 100%;
    border: 0;
    cursor: pointer;
}

.public-offices-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.public-offices-grid article {
    padding: 28px;
    border-radius: 9px;
    background: #f4f6f8;
}

.public-offices-grid h3 {
    margin: 0 0 12px;
    color: #10233a;
    font-family: Georgia, "Times New Roman", serif;
}

.public-offices-grid p {
    color: #606b76;
    line-height: 1.6;
}

.public-offices-grid a {
    color: #087bff;
    font-weight: 700;
}

.public-footer {
    margin-top: 0;
}

@media (max-width: 980px) {
    .service-cards-grid,
    .values-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .two-column-intro,
    .faq-layout,
    .about-public-grid,
    .appointment-public-grid {
        grid-template-columns: 1fr;
        gap: 38px;
    }

    .public-stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .public-stats-grid article:nth-child(2) {
        border-right: 0;
    }
}

@media (max-width: 680px) {
    .public-hero {
        min-height: 440px;
    }

    .public-section {
        padding: 65px 0;
    }

    .service-cards-grid,
    .public-steps,
    .mission-vision-grid,
    .values-grid,
    .contact-info-grid,
    .public-offices-grid {
        grid-template-columns: 1fr;
    }

    .public-stats-grid {
        grid-template-columns: 1fr;
    }

    .public-stats-grid article {
        border-right: 0;
        border-bottom: 1px solid #d9dee3;
    }

    .public-stats-grid article:last-child {
        border-bottom: 0;
    }

    .public-appointment-form {
        padding: 25px 18px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .public-parallax {
        background-position: center center !important;
    }
}


.public-page-header .site-custom-logo {
    display: block;
    width: auto;
    height: calc(62px * var(--logo-desktop-scale, 1));
    max-width: calc(260px * var(--logo-desktop-scale, 1));
    object-fit: contain;
}


/* =========================================================
   LOGO VISIBLE SOBRE ENCABEZADOS OSCUROS
   ========================================================= */
.public-page-header .brand {
    min-width: 245px;
}

.public-page-header .site-custom-logo {
    display: block;
    width: auto;
    height: 58px;
    max-width: 255px;
    object-fit: contain;
    padding: 6px 10px;
    border: 1px solid rgba(212, 170, 78, .48);
    border-radius: 7px;
    background: rgba(255, 255, 255, .94);
    box-shadow:
        0 5px 16px rgba(0, 0, 0, .20),
        inset 0 0 0 1px rgba(255, 255, 255, .55);
}

/* En Inicio el logo conserva el aspecto transparente sobre la imagen */
.site-header:not(.public-page-header) .site-custom-logo {
    background: transparent;
    border: 0;
    box-shadow: none;
    padding: 0;
}

@media (max-width: 760px) {
    .public-page-header .brand {
        min-width: 0;
    }

    .public-page-header .site-custom-logo {
        height: calc(46px * var(--logo-mobile-scale, 1));
        max-width: calc(205px * var(--logo-mobile-scale, 1));
        padding: 5px 8px;
    }
}

/* Cabecera de páginas internas con la misma proporción visual que Inicio */
.public-page-header{
    position:absolute !important;
    top:0;
    left:0;
    right:0;
    z-index:40;
    background:transparent !important;
    padding-top:18px;
}
.public-page-header .site-custom-logo{
    width:calc(205px * var(--logo-desktop-scale,1)) !important;
    height:calc(58px * var(--logo-desktop-scale,1)) !important;
    max-width:none !important;
    object-fit:cover !important;
    object-position:center top !important;
    padding:0 !important;
    border:0 !important;
    border-radius:0 !important;
    background:transparent !important;
    box-shadow:none !important;
}
.public-page-header .header-social a{color:#05080c}
.public-hero{padding-top:78px}


/* Redes sociales dinámicas en páginas internas */
.public-page-header .header-social a {
    transition: opacity .15s ease, transform .15s ease;
}

.public-page-header .header-social a:hover {
    opacity: .72;
    transform: translateY(-1px);
}


/* =========================================================
   PAGINAS INTERNAS: MENU / LOGO / TITULOS NITIDOS
   ========================================================= */
.public-page-header,
.public-page-header .header-inner{
    background:transparent !important;
    border:0 !important;
    box-shadow:none !important;
    backdrop-filter:none !important;
    -webkit-backdrop-filter:none !important;
}
.public-page-header::before,
.public-page-header::after,
.public-page-header .header-inner::before,
.public-page-header .header-inner::after{
    content:none !important;
    display:none !important;
}

.public-page-header .site-custom-logo{
    width:auto !important;
    height:calc(62px * var(--logo-desktop-scale,1)) !important;
    max-width:calc(230px * var(--logo-desktop-scale,1)) !important;
    max-height:none !important;
    object-fit:contain !important;
    object-position:center !important;
    padding:0 !important;
    border:0 !important;
    border-radius:0 !important;
    background:transparent !important;
    box-shadow:none !important;
    filter:
        drop-shadow(0 0 1px rgba(255,255,255,.95))
        drop-shadow(0 3px 6px rgba(0,0,0,.58)) !important;
}

.public-page-header .main-nav a{
    color:#fff !important;
    font-weight:700 !important;
    text-shadow:
        0 1px 2px rgba(0,0,0,.95),
        0 0 5px rgba(0,0,0,.65);
}
.public-page-header .main-nav a:hover{
    color:#d8ae4e !important;
}
.public-page-header .header-social a{
    color:#fff !important;
    text-shadow:0 1px 3px rgba(0,0,0,.95);
    filter:drop-shadow(0 1px 2px rgba(0,0,0,.75));
}

/* Menos velo gris para conservar detalle de la fotografia. */
.public-hero-overlay{
    background:
        linear-gradient(
            180deg,
            rgba(10,24,38,.35) 0%,
            rgba(10,24,38,.18) 24%,
            rgba(10,24,38,.09) 100%
        ),
        linear-gradient(
            90deg,
            rgba(10,27,44,.78) 0%,
            rgba(10,27,44,.53) 47%,
            rgba(10,27,44,.28) 100%
        ) !important;
}

/* El h1 heredaba color oscuro; se fuerza a blanco. */
.public-hero-content > span{
    text-shadow:0 1px 4px rgba(0,0,0,.72);
}
.public-hero-content h1{
    color:#fff !important;
    text-shadow:0 2px 8px rgba(0,0,0,.65);
}
.public-hero-content p{
    color:#fff !important;
    text-shadow:0 1px 4px rgba(0,0,0,.72);
}

@media(max-width:760px){
    .public-page-header .site-custom-logo{
        height:calc(48px * var(--logo-mobile-scale,1)) !important;
        max-width:calc(185px * var(--logo-mobile-scale,1)) !important;
    }
}


/* =========================================================
   PARALLAX EN SERVICIOS / NOSOTROS / CONTACTO
   ========================================================= */
.public-hero.public-parallax {
    background-position:
        center calc(50% + var(--public-parallax-y, 0px)) !important;
    background-size: 110% auto !important;
    background-repeat: no-repeat !important;
    will-change: background-position;
}

.public-cta-band.public-parallax {
    background-position:
        center calc(48% + var(--public-parallax-y, 0px)) !important;
    background-size: 115% auto !important;
    background-repeat: no-repeat !important;
    will-change: background-position;
}

@media (max-width: 1100px) {
    .public-hero.public-parallax,
    .public-cta-band.public-parallax {
        background-size: cover !important;
    }
}

@media (prefers-reduced-motion: reduce) {
    .public-hero.public-parallax,
    .public-cta-band.public-parallax {
        background-position: center center !important;
        will-change: auto;
    }
}


/* FEATURES PUBLICAS COMPARTIDAS */
.public-page-header + main .team-public-section { background: #fff; }


/* =========================================================
   RESPONSIVE FINAL - PAGINAS INTERNAS
   ========================================================= */
@media (max-width: 960px) {
    .public-hero.public-parallax,
    .public-cta-band.public-parallax {
        background-size: cover !important;
    }

    .public-hero-content {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    .public-appointment-form input,
    .public-appointment-form select,
    .public-appointment-form textarea,
    .contact-form input,
    .contact-form select,
    .contact-form textarea {
        font-size: 16px; /* evita zoom automático en iOS */
    }
}

@media (max-width: 600px) {
    .public-hero-content {
        max-width: 100% !important;
    }

    .public-hero-content > span {
        margin-bottom: 12px !important;
    }

    .public-hero-content h1 {
        max-width: 100% !important;
    }

    .public-hero-content p {
        max-width: 100% !important;
    }

    .service-card,
    .value-card,
    .public-step-card,
    .contact-info-card,
    .public-office-card {
        padding: 22px 18px !important;
    }

    .public-appointment-form .form-row,
    .contact-form .form-row {
        grid-template-columns: 1fr !important;
    }
}


/* =========================================================
   AVISO DE PRIVACIDAD / MISIÓN Y VISIÓN OFICIAL
   ========================================================= */
.legal-page-header {
    background: #172536 !important;
    position: relative !important;
}
.legal-hero {
    padding: 92px 0 58px;
    background: linear-gradient(135deg, #172536 0%, #26394b 100%);
    color: #fff;
}
.legal-hero-content { max-width: 980px; }
.legal-kicker { margin: 12px 0 8px; color: #d4aa4e; font-weight: 800; letter-spacing: .08em; font-size: 12px; }
.legal-hero h1 { margin: 0; max-width: 900px; color:#fff; font-size: clamp(32px, 4vw, 54px); line-height:1.08; }
.legal-language-note { margin-top:16px; color:rgba(255,255,255,.78); }
.legal-document { max-width: 1050px; }
.legal-document > section { padding: 28px 0; border-bottom: 1px solid #dfe4e8; }
.legal-document h2 { margin: 0 0 14px; color:#14263b; font-size: 25px; }
.legal-document p { margin:0; color:#3f4d5b; font-size:15px; line-height:1.8; white-space:normal; }
.legal-contact-box { margin-top:32px; padding:22px 24px; border-left:4px solid #d4aa4e; background:#f7f4ec; display:grid; gap:5px; color:#394857; }
.legal-contact-box strong { color:#14263b; font-size:18px; }
.privacy-consent { display:flex; align-items:flex-start; gap:10px; margin: 14px 0 6px; color:#4d5965; font-size:12px; line-height:1.5; }
.privacy-consent input { width:18px; height:18px; margin-top:1px; flex:0 0 18px; accent-color:#b7923f; }
.privacy-consent a { color:#9a741c; font-weight:700; text-decoration:underline; }
.mission-vision-official article { height:auto; }
.mission-vision-official p { line-height:1.72; }
@media (max-width:760px) {
  .legal-hero { padding:70px 0 42px; }
  .legal-document h2 { font-size:22px; }
  .legal-document p { font-size:14px; line-height:1.7; }
}

/* =========================================================
   ESCALA DE ESCRITORIO - PAGINAS PUBLICAS
   Servicios / Nosotros / Contacto
   ========================================================= */
@media (min-width: 1200px) {
    .public-hero {
        min-height: 590px !important;
    }

    .public-hero-content {
        max-width: 980px !important;
    }

    .public-hero-content > span {
        font-size: 17px !important;
        margin-bottom: 20px !important;
    }

    .public-hero-content h1 {
        max-width: 900px !important;
        font-size: clamp(54px, 4.2vw, 72px) !important;
        line-height: 1.06 !important;
        margin-bottom: 24px !important;
    }

    .public-hero-content p {
        max-width: 800px !important;
        font-size: 18px !important;
        line-height: 1.7 !important;
    }

    .public-section {
        padding: 110px 0 !important;
    }

    .two-column-intro {
        gap: 90px !important;
    }

    .two-column-intro h2,
    .about-public-copy h2,
    .faq-intro h2,
    .appointment-public-copy h2 {
        font-size: 48px !important;
    }

    .public-copy p,
    .about-public-copy > p,
    .faq-intro p,
    .appointment-public-copy > p {
        font-size: 17px !important;
    }

    .service-cards-grid {
        gap: 30px !important;
    }

    .legal-service-card {
        min-height: 285px !important;
        padding: 36px !important;
    }

    .legal-service-card h3 {
        font-size: 24px !important;
    }

    .legal-service-card p {
        font-size: 16px !important;
    }

    .public-steps {
        gap: 34px !important;
    }

    .public-steps article {
        padding: 36px !important;
    }

    .public-steps h3 {
        font-size: 23px !important;
    }

    .public-steps p {
        font-size: 16px !important;
    }

    .faq-layout {
        gap: 85px !important;
    }
}

@media (min-width: 1600px) {
    .public-hero {
        min-height: 620px !important;
    }

    .public-hero-content h1 {
        font-size: 72px !important;
    }
}

/* DESKTOP GRANDE V2 - paginas internas */
@media (min-width: 1400px) {
    .public-main .container,
    .public-section .container,
    .public-content .container {
        width: min(1440px, calc(100% - 96px)) !important;
        max-width: none !important;
    }

    .public-hero {
        min-height: 650px !important;
    }

    .public-hero-content {
        max-width: 1040px !important;
    }

    .public-hero-content h1 {
        font-size: clamp(64px, 4.6vw, 82px) !important;
        line-height: 1.03 !important;
    }

    .public-copy,
    .public-copy p,
    .public-page-copy,
    .public-page-copy p {
        font-size: 18px !important;
        line-height: 1.75 !important;
    }
}
