/* Layout base */
.trova-section {
    background: #0a0a0a;
    padding: 100px 20px 80px;
}

.trova-container {
    max-width: 1400px;
    margin: 0 auto;
}

.trova-section h1 {
    font-size: 3.5rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 1.5rem;
    text-align: center;
    line-height: 1.15;
}

.trova-desc {
    font-size: 1.6rem;
    color: #999999;
    text-align: center;
    margin: 0 auto 50px;
    max-width: 860px;
}

/* Legend */
.tipi-centri-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px;
    margin-bottom: 42px;
}

.tipo-centro-card {
    background: linear-gradient(135deg, #1a1a1a 0%, #252525 100%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 22px;
    padding: 32px 28px;
    transition: all 0.35s ease;
    position: relative;
    overflow: hidden;
    min-height: 100%;
}

.tipo-centro-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, transparent 0%, rgba(212, 35, 29, 0.09) 50%, transparent 100%);
    opacity: 0;
    transform: translateX(-20%);
    transition: opacity 0.35s ease, transform 0.35s ease;
}

.tipo-centro-card:hover {
    border-color: rgba(212, 35, 29, 0.7);
    transform: translateY(-6px);
    box-shadow: 0 18px 50px rgba(212, 35, 29, 0.18);
}

.tipo-centro-card:hover::before {
    opacity: 1;
    transform: translateX(0);
}

.tipo-centro-copy {
    position: relative;
    z-index: 1;
}

.tipo-icon {
    width: 86px;
    height: 86px;
    margin: 0 0 24px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 1;
}

.tipo-icon--marker {
    overflow: visible;
}

.tipo-icon .pk-marker--legend {
    width: 40px;
    height: 40px;
    border-width: 3px;
    box-shadow: 0 16px 30px rgba(0,0,0,0.42);
}

.tipo-icon .pk-marker--legend .pk-marker__inner {
    width: 14px;
    height: 14px;
}

.tipo-centro-card h3 {
    font-size: 1.75rem;
    font-weight: 700;
    color: #ffffff;
    margin: 0 0 14px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.tipo-centro-card p {
    font-size: 1.42rem;
    color: #cccccc;
    line-height: 1.75;
    margin: 0;
}

/* Map + search */
.pk-centri-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.6fr) minmax(320px, 0.9fr);
    gap: 28px;
    align-items: start;
}

.mappa-wrapper,
.pk-centri-search-panel,
.pk-centri-contact-card {
    background: linear-gradient(145deg, #121212 0%, #191919 100%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 24px;
    box-shadow: 0 20px 70px rgba(0, 0, 0, 0.35);
}

.mappa-wrapper {
    padding: 12px;
    min-height: 640px;
}

.pk-centri-map {
    height: 616px;
    border-radius: 18px;
    overflow: hidden;
}

.pk-centri-search-panel {
    padding: 28px;
    min-height: 640px;
    display: flex;
    flex-direction: column;
}

.pk-centri-search-head h2 {
    margin: 0 0 14px;
    color: #ffffff;
    font-size: 2.2rem;
    line-height: 1.2;
}

.pk-centri-search-head p {
    margin: 0 0 24px;
    color: #b8b8b8;
    font-size: 1.45rem;
    line-height: 1.75;
}

.pk-centri-search-form {
    margin-bottom: 22px;
}

.pk-centri-search-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
}

.pk-centri-search-row input {
    min-height: 58px;
    border-radius: 14px;
    border: 1px solid rgba(255,255,255,0.12);
    background: #0c0c0c;
    color: #ffffff;
    padding: 0 18px;
    font-size: 1.45rem;
}

.pk-centri-search-row .pk-btn--secondary {
    grid-column: 1 / -1;
}

.pk-centri-search-feedback {
    min-height: 24px;
    margin: 12px 0 0;
    color: #cfcfcf;
    font-size: 1.35rem;
}

.pk-centri-search-feedback.is-error {
    color: #ff8686;
}

.pk-centri-results {
    display: grid;
    gap: 14px;
    margin-top: auto;
}

.pk-centri-results-empty {
    display: grid;
    gap: 8px;
    padding: 22px;
    border-radius: 18px;
    border: 1px dashed rgba(255, 255, 255, 0.12);
    background: rgba(255,255,255,0.03);
    color: #d4d4d4;
    font-size: 1.4rem;
    line-height: 1.7;
}

.pk-centri-results-empty strong {
    color: #ffffff;
    font-size: 1.5rem;
}

.pk-centri-results-empty--warning {
    border-color: rgba(212, 35, 29, 0.45);
}

.pk-centro-result-card {
    padding: 20px;
    border-radius: 18px;
    border: 1px solid rgba(255,255,255,0.08);
    background: rgba(255,255,255,0.03);
}

.pk-centro-result-card__top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.pk-centro-result-card__rank,
.pk-centro-result-card__distance {
    font-size: 1.25rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.pk-centro-result-card__rank {
    color: #ffffff;
}

.pk-centro-result-card__distance {
    color: #f6b7b4;
}

.pk-centro-result-card h3 {
    margin: 0 0 6px;
    color: #ffffff;
    font-size: 1.7rem;
    text-transform: uppercase;
}

.pk-centro-result-card p {
    margin: 0 0 16px;
    color: #cccccc;
    font-size: 1.35rem;
    line-height: 1.6;
}

.pk-centro-result-card__type--sede {
    color: #ffc7c4;
}

.pk-centro-result-card__type--service {
    color: #ffd3a7;
}

.pk-centro-result-card__type--installazione {
    color: #bed4ff;
}

.pk-centro-result-card__type--rivendita {
    color: #e0e0e0;
}

/* Buttons */
.pk-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 52px;
    padding: 0 24px;
    border-radius: 999px;
    border: 0;
    font-size: 1.35rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
    text-decoration: none;
}

.pk-btn:hover {
    transform: translateY(-2px);
}

.pk-btn--primary {
    background: linear-gradient(135deg, #D4231D 0%, #ff4a43 100%);
    color: #ffffff;
    box-shadow: 0 14px 34px rgba(212, 35, 29, 0.28);
}

.pk-btn--secondary {
    background: #ffffff;
    color: #111111;
}

.pk-btn--popup,
.pk-btn--full {
    width: 100%;
}

.pk-btn--large {
    min-height: 58px;
    padding: 0 30px;
}

/* Leaflet */
.leaflet-container {
    background: #101010;
    font-family: inherit;
}

.leaflet-control-attribution {
    background: rgba(0, 0, 0, 0.75) !important;
    color: rgba(255, 255, 255, 0.8);
    font-size: 11px;
}

.leaflet-control-attribution a {
    color: #ffffff;
}

.leaflet-popup-content-wrapper,
.leaflet-popup-tip {
    background: #101010;
    color: #ffffff;
}

.leaflet-popup-content {
    margin: 0;
}

.pk-marker-wrapper {
    background: transparent;
    border: 0;
}

.pk-marker {
    display: inline-flex;
    width: 28px;
    height: 28px;
    border-radius: 50% 50% 50% 0;
    transform: rotate(-45deg);
    box-shadow: 0 12px 24px rgba(0,0,0,0.35);
    border: 2px solid rgba(255,255,255,0.9);
}

.pk-marker__inner {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #ffffff;
    margin: auto;
}

.pk-marker--sede {
    background: linear-gradient(135deg, #D4231D 0%, #8c1612 100%);
}

.pk-marker--service {
    background: linear-gradient(135deg, #f08a24 0%, #bf5a00 100%);
}

.pk-marker--installazione {
    background: linear-gradient(135deg, #1d6cff 0%, #003a99 100%);
}

.pk-marker--rivendita {
    background: linear-gradient(135deg, #5f5f5f 0%, #2f2f2f 100%);
}

.pk-map-popup {
    padding: 18px;
    width: min(270px, 100%);
}

.pk-map-popup__tag {
    display: inline-flex;
    margin-bottom: 12px;
    padding: 6px 10px;
    border-radius: 999px;
    font-size: 1.15rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.pk-map-popup__tag--sede {
    background: rgba(212,35,29,0.16);
    color: #ffc7c4;
}

.pk-map-popup__tag--service {
    background: rgba(240,138,36,0.18);
    color: #ffd3a7;
}

.pk-map-popup__tag--installazione {
    background: rgba(29,108,255,0.18);
    color: #bed4ff;
}

.pk-map-popup__tag--rivendita {
    background: rgba(120,120,120,0.22);
    color: #e0e0e0;
}

.pk-map-popup h3 {
    margin: 0 0 8px;
    font-size: 1.7rem;
    color: #ffffff;
    text-transform: uppercase;
}

.pk-map-popup p {
    margin: 0 0 16px;
    color: #c9c9c9;
    font-size: 1.3rem;
    line-height: 1.6;
}

/* Contact form */
.pk-centri-contact-section {
    margin-top: 32px;
}

.pk-centri-contact-section.is-hidden {
    display: none;
}

.pk-centri-contact-card {
    padding: 34px;
}

.pk-centri-contact-intro {
    margin-bottom: 22px;
}

.pk-contact-kicker {
    display: inline-flex;
    margin-bottom: 12px;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(212,35,29,0.16);
    color: #ffc8c6;
    font-size: 1.15rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.pk-centri-contact-intro h2 {
    margin: 0 0 12px;
    color: #ffffff;
    font-size: 2.6rem;
    line-height: 1.2;
}

.pk-centri-contact-intro p {
    margin: 0;
    color: #cccccc;
    font-size: 1.45rem;
    line-height: 1.8;
    max-width: 900px;
}

.pk-centri-selected-center {
    display: grid;
    gap: 6px;
    padding: 18px 20px;
    border-radius: 18px;
    border: 1px solid rgba(255,255,255,0.08);
    background: rgba(255,255,255,0.03);
    margin-bottom: 22px;
}

.pk-centri-selected-center__label {
    color: #bcbcbc;
    font-size: 1.2rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.pk-centri-selected-center strong {
    color: #ffffff;
    font-size: 1.55rem;
    text-transform: uppercase;
}

.pk-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    margin-bottom: 16px;
}

.pk-centri-contact-form label {
    display: grid;
    gap: 8px;
}

.pk-centri-contact-form label > span {
    color: #e7e7e7;
    font-size: 1.32rem;
    font-weight: 600;
}

.pk-centri-contact-form input,
.pk-centri-contact-form textarea {
    width: 100%;
    min-height: 56px;
    border-radius: 14px;
    border: 1px solid rgba(255,255,255,0.12);
    background: #0c0c0c;
    color: #ffffff;
    padding: 14px 18px;
    font-size: 1.42rem;
}

.pk-centri-contact-form textarea {
    min-height: 150px;
    resize: vertical;
}

.pk-form-full {
    margin-bottom: 16px;
}

.pk-checkbox {
    display: flex !important;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 22px;
}

.pk-checkbox input {
    width: 20px;
    min-height: 20px;
    height: 20px;
    margin-top: 2px;
    padding: 0;
    accent-color: #D4231D;
}

.pk-checkbox span {
    color: #cfcfcf !important;
    font-size: 1.34rem !important;
    line-height: 1.7;
    font-weight: 400 !important;
}

.pk-form-actions {
    display: flex;
    justify-content: flex-start;
}

.pk-form-message {
    padding: 16px 18px;
    border-radius: 16px;
    margin-bottom: 18px;
    font-size: 1.38rem;
    line-height: 1.7;
}

.pk-form-message ul {
    margin: 10px 0 0 18px;
}

.pk-form-message--success {
    background: rgba(59, 130, 92, 0.14);
    border: 1px solid rgba(59, 130, 92, 0.35);
    color: #d8ffde;
}

.pk-form-message--error {
    background: rgba(212, 35, 29, 0.12);
    border: 1px solid rgba(212, 35, 29, 0.35);
    color: #ffd0ce;
}

.pk-honeypot {
    position: absolute !important;
    left: -9999px !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

/* CTA Partner */
.cta-partner {
    background: linear-gradient(135deg, #D4231D 0%, #a01a15 100%);
    padding: 100px 20px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.cta-partner::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    animation: pulse 4s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 0.5; }
    50% { transform: scale(1.2); opacity: 0.8; }
}

.cta-partner-content {
    max-width: 900px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.cta-partner h2 {
    font-size: 3rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 30px;
    line-height: 1.3;
    text-transform: uppercase;
}

.cta-partner p {
    font-size: 1.6rem;
    color: rgba(255,255,255,0.9);
    margin-bottom: 40px;
}

.btn-partner {
    display: inline-block;
    background: #ffffff;
    color: #D4231D;
    padding: 20px 60px;
    font-size: 1.6rem;
    font-weight: 700;
    text-transform: uppercase;
    text-decoration: none;
    border-radius: 50px;
    transition: all 0.3s ease;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    letter-spacing: 1px;
}

.btn-partner:hover {
    background: #000000;
    color: #ffffff;
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.5);
}

/* Responsive */
@media (max-width: 1100px) {
    .pk-centri-layout {
        grid-template-columns: 1fr;
    }

    .pk-centri-search-panel {
        min-height: auto;
    }
}

@media (max-width: 968px) {
    .trova-section {
        padding: 80px 20px 60px;
    }

    .trova-section h1 {
        font-size: 2.6rem;
    }

    .trova-desc {
        font-size: 1.4rem;
        margin-bottom: 36px;
    }

    .tipo-centro-card {
        padding: 24px 22px;
    }

    .tipo-icon {
        width: 70px;
        height: 70px;
        margin-bottom: 18px;
    }

    .mappa-wrapper {
        min-height: auto;
    }

    .pk-centri-map {
        height: 460px;
    }

    .pk-centri-search-panel,
    .pk-centri-contact-card {
        padding: 24px;
    }

    .pk-form-grid {
        grid-template-columns: 1fr;
    }

    .cta-partner {
        padding: 70px 20px;
    }

    .cta-partner h2 {
        font-size: 2.2rem;
    }
}

@media (max-width: 640px) {
    .trova-section h1 {
        font-size: 2.1rem;
    }

    .pk-centri-search-row {
        grid-template-columns: 1fr;
    }

    .pk-btn,
    .pk-btn--large {
        width: 100%;
    }

    .pk-centri-map {
        height: 380px;
    }

    .pk-centri-contact-intro h2 {
        font-size: 2.1rem;
    }

    .btn-partner {
        width: 100%;
        padding: 18px 26px;
    }
}
