/* ! body */
body {
    background-image:
        linear-gradient(rgba(0, 0, 0, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 0, 0, 0.04) 1px, transparent 1px);
    background-size: 40px 40px;
}

/* ! Main */
main{
  display: flex;
  width: 100%;
  display: flex;align-items: center;flex-direction: column;
  margin-top: 25px;
  position: relative;
  min-height: 100vh;
  height: fit-content;
  padding-top: 100px;
  background-color: transparent;
}
main h2{
    font-weight: 860;
    line-height: 1.1;
    letter-spacing: -0.03em;
    color: var(--black-premium);
    margin-bottom: 20px;
    text-align: center;
    width: 100%;
}

/* ─── SECTION WRAPPER ─── */
.prezzi-section {
    padding: 0px 24px 140px 24px;
    max-width: 1100px;
    margin: 0 auto;
}

/* ─── HERO HEADING ─── */
.prezzi-hero {
    text-align: center;
    margin-bottom: 48px;
}

.prezzi-hero p {
    color: var(--gray-medium);
    font-size: 1rem;
    max-width: 520px;
    margin: 0 auto;
}

/* ! BRAND TAG */
/* ! APPLE */
.apple-brand-tag{border: 1px solid rgb(0, 0, 0);
    user-select: none;
    background-color: var(--black-premium);
    color: var(--white-premium);
    width: fit-content;height: 50px;
    margin: 0 auto;border-radius: 10px;
    display: flex;justify-content: center;align-items: center;padding: 14px;gap: 4px;
    margin-bottom: 20px;
}
.apple-brand-tag svg{
    transform: translateY(-1px);
}
@supports(corner-shape: squircle){
    .apple-brand-tag{
        border-radius: 30px;
        corner-shape: squircle;
    }
}

/* ! Huawei*/
.huawei-brand-tag{border: 1px solid #cf0a2b;
    user-select: none;
    background-color: #cf0a2b;
    color: var(--white-premium);
    width: fit-content;height: 50px;
    margin: 0 auto;border-radius: 10px;
    display: flex;justify-content: center;align-items: center;padding: 14px;gap: 4px;
    margin-bottom: 20px;
}
.huawei-brand-tag svg{
    transform: translateY(-1px);
}
@supports(corner-shape: squircle){
    .huawei-brand-tag{
        border-radius: 30px;
        corner-shape: squircle;
    }
}

/* ! Huawei*/
.xiaomi-brand-tag{
    user-select: none;
    color: var(--white-premium);
    width: fit-content;height: 50px;
    margin: 0 auto;
    display: flex;justify-content: center;align-items: center;
    margin-bottom: 20px;
}

/* ─── STEP SELECTORS ─── */
.selectors-wrap {
    display: flex;
    flex-direction: column;
    gap: 32px;
    margin-bottom: 48px;
}

.step-block {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.step-label {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--gray-dark);
}
.step-number {
    width: 26px; height: 26px;
    background: var(--black-premium);
    color: #fff;
    border-radius: 50%;
    font-size: 0.75rem;
    font-weight: 700;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}

/* Serie pills */
.serie-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}
.pill {
    padding: 9px 20px;
    border-radius: 999px;
    border: 1.5px solid var(--gray-light);
    background: var(--white-premium);
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.18s ease;
    color: var(--gray-dark);
    user-select: none;
}
.pill:hover {
    border-color: var(--black-premium);
    background: var(--white-soft);
}
.pill.active {
    background: var(--black-premium);
    color: #fff;
    border-color: var(--black-premium);
}

/* Model grid */
.model-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 10px;
}
.model-card {
    padding: 12px 16px;
    border-radius: 12px;
    border: 1.5px solid var(--gray-light);
    background: var(--white-premium);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.18s ease;
    color: var(--black-premium);
    text-align: center;
    user-select: none;
}
.model-card:hover {
    border-color: var(--blue-accent);
    background: var(--blue-soft);
}
.model-card.active {
    border-color: var(--blue-accent);
    background: var(--blue-accent);
    color: #fff;
}

/* ─── PLACEHOLDER / EMPTY ─── */
.step-placeholder {
    padding: 16px 20px;
    background: var(--white-soft);
    border-radius: 12px;
    font-size: 0.88rem;
    color: var(--gray-medium);
    text-align: center;
}

/* ─── RESULTS TABLE ─── */
.results-wrap {
    display: none;
    animation: fadeUp 0.3s ease;
}
.results-wrap.visible { display: block; }

@keyframes fadeUp {
    from { opacity: 0; transform: translateY(16px); }
    to   { opacity: 1; transform: translateY(0); }
}

.results-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 24px;
}
.results-title {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--black-premium);
}
.results-subtitle {
    font-size: 0.82rem;
    color: var(--gray-medium);
    margin-top: 2px;
}

/* Search filter */
.search-input {
    padding: 10px 16px;
    border-radius: 999px;
    border: 1.5px solid var(--gray-light);
    font-size: 0.88rem;
    font-family: "Inter", sans-serif;
    background: var(--white-premium);
    color: var(--black-premium);
    width: 220px;
    transition: border-color 0.18s;
}
.search-input:focus { border-color: var(--blue-accent); }
.search-input::placeholder { color: var(--gray-medium); }

/* Table */
.prezzi-table-wrap {
    overflow-x: auto;
    border-radius: 16px;
    border: 1.5px solid var(--gray-light);
    box-shadow: var(--shadow-soft);
}
table {
    background-color: var(--white-premium);
    width: 100%;
    border-collapse: collapse;
    font-size: 0.92rem;
}
thead th {
    background: var(--black-premium);
    color: #fff;
    padding: 14px 20px;
    text-align: left;
    font-weight: 600;
    font-size: 0.8rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    white-space: nowrap;
}
thead th:last-child { text-align: right; }

tbody tr {
    border-bottom: 1px solid var(--gray-light);
    transition: background-color 0.12s;
}
tbody tr:last-child { border-bottom: none; }
tbody tr:hover { background: var(--white-soft); }

tbody td {
    padding: 14px 20px;
    color: var(--black-premium);
    vertical-align: middle;
}
tbody td:last-child {
    text-align: right;
    font-weight: 700;
    font-size: 1rem;
    color: var(--black-premium);
    white-space: nowrap;
}

/* Category icon */
.cat-icon {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}
.cat-dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}
.cat-dot.sostituzione { background: var(--blue-accent); }
.cat-dot.diagnosi { background: var(--warning-soft); }
.cat-dot.servizio { background: var(--success-trust); }

/* Price badge */
.price-val { color: var(--black-premium); }

/* No results */
.no-results {
    text-align: center;
    padding: 40px;
    color: var(--gray-medium);
    font-size: 0.9rem;
}
/* ─── RESPONSIVE ─── */
@media (max-width: 768px) {
    .prezzi-hero h2 { font-size: 2rem; }
    .model-grid { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); }
    .search-input { width: 100%; }
    .results-header { flex-direction: column; align-items: flex-start; }
}

/* ! DYNAMIC ISLAND PREZZI */
.brand-dock {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9999;
    display: flex;
    align-items: center;
    gap: 14px;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 0.5px solid rgba(0, 0, 0, 0.12);
    border-radius: 999px;
    padding: 8px 12px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.12);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.brand-dock.dock-hidden {
    opacity: 0;
    transform: translateX(-50%) translateY(10px);
    pointer-events: none;
}

.dock-item {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.2s ease;
    text-decoration: none;
    flex-shrink: 0;
    position: relative;
    overflow: hidden;
}
@media (max-width: 768px) {
  .dock-item{
    padding: 2px;
  }
}

.dock-item 

.dock-item:hover {
    transform: scale(1.05);
}

.dock-item.dock-active {
    outline: 2.5px solid #0A3D91;
    outline-offset: 2px;
}

.dock-tooltip {
    position: absolute;
    bottom: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%);
    background: #0B0D12;
    color: #fff;
    font-size: 11px;
    font-family: inherit;
    white-space: nowrap;
    padding: 4px 8px;
    border-radius: 6px;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.15s ease;
}

.dock-item:hover .dock-tooltip {
    opacity: 1;
}

@media (max-width: 600px) {
    .brand-dock {
        gap: 8px;
        padding: 6px 10px;
        bottom: 16px;
    }
    .dock-item {
        width: 30px;
        height: 30px;
    }
}
