@import url('https://fonts.googleapis.com/css2?family=Open+Sans:wght@300;400&display=swap');

.pb-barche-list-root,
.pb-barche-table-wrapper {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.griglia-barche {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    font-family: 'Open Sans', sans-serif;
    padding: 20px 0;
}

.card-barca {
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    display: flex;
    flex-direction: column;
}

.card-barca:hover {
    transform: translateY(-4px);
    box-shadow: 0 6px 16px rgba(0,0,0,0.08);
}

.card-barca img {
	aspect-ratio: 4 / 3;
    height: 180px;
    object-fit: cover;
    width: 100%;
}

.card-barca h3 {
    font-weight: 300;
    font-size: 1.3em;
    margin: 16px 16px 8px;
    color: #222;
}

.card-barca p {
    font-weight: 300;
    font-size: 0.95em;
    color: #555;
    margin: 0 16px 8px;
    line-height: 1.4em;
}

.card-barca .prezzo {
    font-weight: 400;
    color: #111;
    margin: 0 16px 12px;
}

.card-barca a {
    margin: 0 16px 16px;
    padding: 8px 12px;
    background: #0073aa;
    color: #fff;
    text-decoration: none;
    border-radius: 4px;
    font-weight: 400;
    text-align: center;
    display: inline-block;
    transition: background 0.2s ease;
}

.card-barca a:hover {
    background: #005f8d;
}

/* Tabella barche [elenco_barche_tabella] */
.pb-barche-table-wrapper {
    overflow-x: visible;
    -webkit-overflow-scrolling: touch;
}

.tabella-barche {
    width: 100%;
    max-width: 100%;
    border-collapse: collapse;
    font-family: 'Open Sans', sans-serif;
    box-sizing: border-box;
}

.tabella-barche thead th {
    padding: 10px 12px;
    border-bottom: 2px solid #e0e0e0;
    text-align: left;
    font-weight: 400;
    color: #222;
    white-space: nowrap;
}

.tabella-barche tbody td {
    padding: 10px 12px;
    border-bottom: 1px solid #eee;
    vertical-align: middle;
}

.tabella-barche tbody tr:hover {
    background: #fafafa;
}

.tabella-barche a {
    color: #0073aa;
    text-decoration: none;
    font-weight: 400;
}

.tabella-barche a:hover {
    text-decoration: underline;
}

@media (max-width: 768px) {
    .griglia-barche {
        grid-template-columns: 1fr;
        gap: 16px;
        padding: 12px 0;
    }

    .card-barca {
        width: 100%;
        max-width: 100%;
    }

    .pb-barche-table-wrapper {
        overflow-x: visible;
    }

    .tabella-barche {
        min-width: 0;
        display: block;
    }

    .tabella-barche thead {
        display: none;
    }

    .tabella-barche tbody {
        display: block;
        width: 100%;
    }

    .tabella-barche tbody tr {
        display: block;
        width: 100%;
        max-width: 100%;
        margin-bottom: 16px;
        border: 1px solid #e0e0e0;
        border-radius: 10px;
        overflow: hidden;
        background: #fff;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
        box-sizing: border-box;
    }

    .tabella-barche tbody tr:hover {
        background: #fff;
    }

    .tabella-barche tbody td {
        display: block;
        width: 100%;
        max-width: 100%;
        padding: 8px 16px;
        border: none;
        box-sizing: border-box;
        font-weight: 300;
        font-size: 0.95em;
        color: #555;
    }

    .tabella-barche tbody td:before {
        content: attr(data-label) ": ";
        font-weight: 400;
        color: #222;
    }

    .tabella-barche tbody td.pb-barca-nome {
        background: #f7f7f7;
        font-size: 1.2em;
        font-weight: 300;
        color: #222;
        padding: 14px 16px;
    }

    .tabella-barche tbody td.pb-barca-nome:before {
        content: "";
    }

    .tabella-barche tbody td.pb-barca-azioni {
        padding: 12px 16px 16px;
    }

    .tabella-barche tbody td.pb-barca-azioni:before {
        display: none;
    }

    .tabella-barche tbody td.pb-barca-azioni a {
        display: block;
        width: 100%;
        padding: 10px 12px;
        background: #0073aa;
        color: #fff;
        text-decoration: none;
        border-radius: 4px;
        text-align: center;
        box-sizing: border-box;
    }

    .tabella-barche tbody td.pb-barca-azioni a:hover {
        background: #005f8d;
        text-decoration: none;
    }
}
