/**
 * Anelli Appointments — wizard modale
 */

.anelli-appt-trigger {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    margin: 8px 0 0;
    padding: 14px 18px;
    background: transparent;
    border: 1px solid var(--gray-dark, #1a1a1a);
    color: var(--gray-dark, #1a1a1a);
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.02em;
    cursor: pointer;
    transition: all 0.25s ease;
    text-transform: none;
    box-sizing: border-box;
}

.single-product form.cart .anelli-appt-btn--product {
    display: flex;
    margin-top: 8px;
    margin-bottom: 20px;
}

.anelli-appt-trigger:hover {
    background: var(--theme-color, #63512d);
    border-color: var(--theme-color, #63512d);
    color: #fff;
}

.anelli-appt-btn--header,
.anelli-appt-btn--footer {
    width: auto;
    margin: 0;
}

.anelli-appt-btn--footer {
    display: inline-flex;
}

.anelli-appt-modal {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.anelli-appt-modal.is-open {
    display: flex;
}

.anelli-appt-modal__overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
}

.anelli-appt-modal__panel {
    position: relative;
    z-index: 2;
    width: min(560px, 100%);
    max-height: min(92vh, 900px);
    overflow: auto;
    background: #fff;
    padding: 28px 24px 32px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
}

.anelli-appt-modal__close {
    position: absolute;
    top: 12px;
    right: 14px;
    border: 0;
    background: none;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    color: #666;
}

.anelli-appt-wizard__back {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    margin: 0 0 24px;
    padding: 0;
    border: 0;
    background: none;
    font-family: inherit;
    font-size: 15px;
    font-weight: 500;
    letter-spacing: 0.01em;
    line-height: 1.3;
    color: var(--gray-dark, #1a1a1a);
    cursor: pointer;
    text-align: left;
    transition: color 0.2s ease;
    appearance: none;
    -webkit-appearance: none;
}

.anelli-appt-wizard__back-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: 1px solid #ddd;
    border-radius: 50%;
    flex-shrink: 0;
    transition: border-color 0.2s ease, background 0.2s ease;
}

.anelli-appt-wizard__back-icon::before {
    content: '‹';
    display: block;
    margin-top: -3px;
    font-size: 22px;
    font-weight: 300;
    line-height: 1;
}

.anelli-appt-wizard__back-label {
    display: block;
}

.anelli-appt-wizard__back:hover {
    color: var(--theme-color, #63512d);
}

.anelli-appt-wizard__back:hover .anelli-appt-wizard__back-icon {
    border-color: var(--gray-dark, #1a1a1a);
    background: #fafafa;
}

.anelli-appt-wizard__back:focus-visible {
    outline: none;
}

.anelli-appt-wizard__back:focus-visible .anelli-appt-wizard__back-icon {
    outline: 2px solid var(--theme-color, #63512d);
    outline-offset: 2px;
}

.anelli-appt-wizard__title {
    margin: 0 0 24px;
    font-size: 24px;
    font-weight: 500;
    line-height: 1.25;
}

.anelli-appt-step-label {
    margin: 0 0 16px;
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #888;
}

.anelli-appt-options {
    display: grid;
    gap: 12px;
}

.anelli-appt-option {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    width: 100%;
    padding: 16px 18px;
    border: 1px solid #ddd;
    background: #fff;
    color: #1a1a1a;
    -webkit-text-fill-color: #1a1a1a;
    font: inherit;
    text-align: left;
    text-decoration: none;
    cursor: pointer;
    transition: border-color 0.2s ease;
    -webkit-appearance: none;
    appearance: none;
}

/* Evita il blu di sistema di Safari/iOS su link e bottoni del wizard */
.anelli-appt-modal a,
.anelli-appt-modal a:visited,
.anelli-info-modal a,
.anelli-info-modal a:visited {
    color: #1a1a1a;
    -webkit-text-fill-color: #1a1a1a;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.anelli-appt-modal a:hover,
.anelli-appt-modal a:focus,
.anelli-info-modal a:hover,
.anelli-info-modal a:focus {
    color: var(--theme-color, #63512d);
    -webkit-text-fill-color: var(--theme-color, #63512d);
}

.anelli-appt-modal button,
.anelli-info-modal button {
    color: inherit;
    -webkit-text-fill-color: currentColor;
}

.anelli-appt-option span,
.anelli-appt-option__name,
.anelli-appt-option__label {
    color: inherit;
    -webkit-text-fill-color: inherit;
}

.anelli-appt-option__label {
    display: inline-flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.anelli-appt-option__name {
    font-size: inherit;
    line-height: 1.3;
}

.anelli-appt-option:hover,
.anelli-appt-option.is-selected {
    border-color: var(--gray-dark, #1a1a1a);
}

.anelli-appt-option__badge {
    display: inline-block;
    padding: 4px 8px;
    background: #fcc35d;
    color: #1a1a1a;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.04em;
    line-height: 1.2;
    text-transform: uppercase;
    white-space: nowrap;
}

.anelli-appt-location-card {
    border: 1px solid #ddd;
    padding: 18px;
}

.anelli-appt-location-card.is-expanded {
    border-color: var(--gray-dark, #1a1a1a);
}

.anelli-appt-location-card__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    border: 0;
    background: none;
    padding: 0;
    color: #1a1a1a;
    -webkit-text-fill-color: #1a1a1a;
    text-align: left;
    cursor: pointer;
    font-family: inherit;
    -webkit-appearance: none;
    appearance: none;
}

.anelli-appt-location-card__name {
    font-size: 20px;
    font-weight: 500;
}

.anelli-appt-location-card__address {
    margin: 8px 0 0;
    font-size: 14px;
    color: #666;
}

.anelli-appt-location-card__body {
    margin-top: 16px;
}

.anelli-appt-notice {
    margin: 16px 0;
    padding: 14px 16px;
    background: #faf8f3;
    border: 1px solid #e8dfc8;
    font-size: 14px;
    line-height: 1.6;
    color: #444;
}

.anelli-appt-service-item {
    border-bottom: 1px solid #eee;
}

.anelli-appt-service-item__head {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 16px 0;
    border: 0;
    background: none;
    color: #1a1a1a;
    -webkit-text-fill-color: #1a1a1a;
    text-align: left;
    cursor: pointer;
    font-size: 15px;
    font-family: inherit;
    -webkit-appearance: none;
    appearance: none;
}

.anelli-appt-service-item__radio {
    width: 18px;
    height: 18px;
    border: 1px solid #bbb;
    border-radius: 50%;
    flex-shrink: 0;
}

.anelli-appt-service-item.is-selected .anelli-appt-service-item__radio {
    border: 5px solid var(--gray-dark, #1a1a1a);
}

.anelli-appt-service-item__panel {
    display: none;
    padding: 0 0 20px 30px;
}

.anelli-appt-service-item.is-selected .anelli-appt-service-item__panel {
    display: block;
}

.anelli-appt-calendar {
    margin-bottom: 20px;
}

.anelli-appt-calendar__nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 16px;
}

.anelli-appt-calendar__month {
    flex: 1;
    text-align: center;
    font-size: 16px;
    font-weight: 500;
    line-height: 1.3;
    text-transform: capitalize;
    color: var(--gray-dark, #1a1a1a);
}

.anelli-appt-calendar__nav-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    padding: 0;
    border: 1px solid #ddd;
    border-radius: 50%;
    background: #fff;
    color: var(--gray-dark, #1a1a1a);
    font-family: inherit;
    font-size: 22px;
    font-weight: 300;
    line-height: 1;
    cursor: pointer;
    transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease;
    appearance: none;
    -webkit-appearance: none;
    box-shadow: none;
    flex-shrink: 0;
}

.anelli-appt-calendar__nav-btn span {
    display: block;
    margin-top: -2px;
}

.anelli-appt-calendar__nav-btn:hover {
    border-color: var(--gray-dark, #1a1a1a);
    background: #fafafa;
}

.anelli-appt-calendar__nav-btn:focus-visible {
    outline: 2px solid var(--theme-color, #63512d);
    outline-offset: 2px;
}

.anelli-appt-modal button {
    box-shadow: none;
}

.anelli-appt-calendar__grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
}

.anelli-appt-calendar__dow,
.anelli-appt-calendar__day {
    text-align: center;
    padding: 8px 4px;
    font-size: 13px;
}

.anelli-appt-calendar__dow {
    color: #888;
    font-size: 11px;
}

.anelli-appt-calendar__day {
    border: 0;
    background: none;
    cursor: pointer;
}

.anelli-appt-calendar__day.is-available:hover {
    background: #f5f5f5;
}

.anelli-appt-calendar__day.is-selected {
    background: var(--theme-color, #63512d);
    color: #fff;
}

.anelli-appt-calendar__day.is-disabled {
    color: #ccc;
    cursor: default;
}

.anelli-appt-slots {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}

.anelli-appt-slot {
    padding: 10px 8px;
    border: 1px solid #ddd;
    background: #fff;
    cursor: pointer;
    font-size: 14px;
}

.anelli-appt-slot.is-selected {
    border-color: var(--gray-dark, #1a1a1a);
    background: var(--gray-dark, #1a1a1a);
    color: #fff;
}

.anelli-appt-slot:disabled {
    opacity: 0.35;
    cursor: not-allowed;
}

.anelli-appt-form .anelli-appt-field {
    margin-bottom: 14px;
}

.anelli-appt-form label {
    display: block;
    margin-bottom: 6px;
    font-size: 13px;
    color: #555;
}

.anelli-appt-form input[type="text"],
.anelli-appt-form input[type="email"],
.anelli-appt-form input[type="tel"] {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #ddd;
    font-size: 15px;
}

.anelli-appt-slots-wrap {
    margin-bottom: 8px;
}

.anelli-appt-datetime-actions {
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.anelli-appt-submit {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 52px;
    padding: 16px 24px;
    border: 1px solid var(--gray-dark, #1a1a1a);
    background: var(--gray-dark, #1a1a1a);
    color: #fff;
    font-family: inherit;
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 0.1em;
    line-height: 1.2;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.25s ease, border-color 0.25s ease, opacity 0.25s ease;
    appearance: none;
    -webkit-appearance: none;
}

.anelli-appt-submit:hover:not(:disabled) {
    background: var(--theme-color, #63512d);
    border-color: var(--theme-color, #63512d);
    color: #fff;
}

.anelli-appt-submit:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    background: #b8b8b8;
    border-color: #b8b8b8;
    color: #fff;
}

.anelli-appt-form .anelli-appt-submit {
    margin-top: 16px;
}

.anelli-appt-privacy {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    font-size: 12px;
    line-height: 1.5;
    color: #666;
}

.anelli-appt-success {
    padding: 20px 0;
    font-size: 15px;
    line-height: 1.7;
}

.anelli-appt-footer-bar {
    text-align: center;
    padding: 16px 0 0;
}

/* Popup richiesta informazioni */
.anelli-info-topbar {
    display: inline-flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}

.anelli-info-help-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: inherit;
    text-decoration: none;
}

.anelli-info-help-link:hover,
.anelli-info-help-link:focus {
    color: var(--theme-color, #63512d);
    text-decoration: none;
}

.anelli-info-topbar .anelli-appt-trigger.anelli-appt-btn--header {
    width: auto;
    margin: 0;
    padding: 0;
    border: 0;
    background: none;
    color: inherit;
    font-family: inherit;
    font-size: inherit;
    font-weight: 700;
    letter-spacing: 0.02em;
    line-height: 1.3;
    text-decoration: underline;
    text-underline-offset: 3px;
    text-transform: none;
}

.anelli-info-topbar .anelli-appt-trigger.anelli-appt-btn--header:hover,
.anelli-info-topbar .anelli-appt-trigger.anelli-appt-btn--header:focus {
    background: none;
    border-color: transparent;
    color: var(--theme-color, #63512d);
}

.anelli-appt-footer-wrap {
    margin-top: 4px;
}

.anelli-appt-footer-wrap .anelli-appt-trigger.anelli-appt-btn--footer {
    width: auto;
    margin-top: 10px;
    padding: 6px 12px;
    border: 1px solid rgba(255, 255, 255, 0.45);
    border-radius: 0;
    background: transparent;
    color: #fff;
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-decoration: none;
}

.anelli-appt-footer-wrap .anelli-appt-trigger.anelli-appt-btn--footer:hover,
.anelli-appt-footer-wrap .anelli-appt-trigger.anelli-appt-btn--footer:focus {
    background: rgba(255, 255, 255, 0.08);
    border-color: #fff;
    color: #fff;
}

.anelli-info-modal {
    position: fixed;
    inset: 0;
    z-index: 999998;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.anelli-info-modal.is-open {
    display: flex;
}

.anelli-info-modal__overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
}

.anelli-info-modal__panel {
    position: relative;
    z-index: 2;
    width: min(520px, 100%);
    max-height: min(92vh, 900px);
    overflow: auto;
    background: #fff;
    padding: 28px 24px 32px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
}

.anelli-info-modal__close {
    position: absolute;
    top: 12px;
    right: 14px;
    border: 0;
    background: none;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    color: #666;
}

.anelli-info-modal__title {
    margin: 0 0 20px;
    font-size: 22px;
    font-weight: 500;
    letter-spacing: 0.02em;
    color: var(--gray-dark, #1a1a1a);
}

body.anelli-info-modal-open {
    overflow: hidden;
}

@media (max-width: 767px) {
    .anelli-info-topbar {
        gap: 8px;
    }

    .anelli-info-modal__panel {
        padding: 24px 18px 28px;
    }
}

@media (max-width: 767px) {
    .anelli-appt-modal__panel {
        padding: 24px 18px 28px;
    }

    .anelli-appt-slots {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Richiesta informazioni prodotto */
.anelli-product-info {
    margin: 24px 0 0;
    padding-top: 20px;
    border-top: 1px solid #eee;
    clear: both;
}

.anelli-product-info--after-read-more {
    margin: 0;
    padding-top: 0;
    border-top: 0;
}

.anelli-product-info--after-summary {
    margin: 24px 0 0;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.anelli-product-info__toggle {
    display: block;
    width: 100%;
    padding: 14px 18px;
    border: 1px solid var(--gray-dark, #1a1a1a);
    background: transparent;
    color: var(--gray-dark, #1a1a1a);
    font-family: inherit;
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.08em;
    line-height: 1.4;
    text-align: center;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease;
    appearance: none;
    -webkit-appearance: none;
}

.anelli-product-info__toggle:hover,
.anelli-product-info__toggle[aria-expanded="true"] {
    background: var(--theme-color, #63512d);
    border-color: var(--theme-color, #63512d);
    color: #fff;
}

.anelli-product-info__panel {
    margin-top: 16px;
    padding: 20px 18px;
    background: #faf8f4;
    border: 1px solid #eee7dc;
}

.anelli-product-info__panel[hidden] {
    display: none !important;
}

.anelli-product-info__intro {
    margin-bottom: 18px;
    padding-bottom: 16px;
    border-bottom: 1px solid #ece6dc;
}

.anelli-product-info__intro-text {
    margin: 0 0 12px;
    font-size: 14px;
    line-height: 1.6;
    color: #444;
}

.anelli-product-info__intro-links {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.anelli-product-info__intro-links a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--gray-dark, #1a1a1a);
    font-size: 13px;
    line-height: 1.4;
    text-decoration: none;
    transition: color 0.2s ease;
}

.anelli-product-info__intro-links a:hover,
.anelli-product-info__intro-links a:focus {
    color: var(--theme-color, #63512d);
}

.anelli-product-info__intro-icon {
    flex-shrink: 0;
    color: var(--theme-color, #63512d);
}

.anelli-info-modal__body .anelli-product-info__intro {
    margin-bottom: 20px;
}

.anelli-product-info__field {
    margin-bottom: 14px;
}

.anelli-product-info__field label {
    display: block;
    margin-bottom: 6px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #666;
}

.anelli-product-info__field input[type="text"],
.anelli-product-info__field input[type="email"],
.anelli-product-info__field input[type="tel"],
.anelli-product-info__field textarea {
    width: 100%;
    padding: 11px 12px;
    border: 1px solid #ddd;
    background: #fff;
    font-family: inherit;
    font-size: 14px;
    line-height: 1.4;
    color: #1a1a1a;
    box-sizing: border-box;
}

.anelli-product-info__field textarea {
    min-height: 110px;
    resize: vertical;
}

.anelli-product-info__field input:focus,
.anelli-product-info__field textarea:focus {
    outline: none;
    border-color: var(--theme-color, #63512d);
}

.anelli-product-info__privacy {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    margin: 16px 0 18px;
    font-size: 12px;
    line-height: 1.5;
    color: #666;
    cursor: pointer;
}

.anelli-product-info__privacy input {
    margin-top: 3px;
    flex-shrink: 0;
}

.anelli-product-info__submit {
    display: block;
    width: 100%;
    min-height: 48px;
    padding: 14px 20px;
    border: 1px solid var(--gray-dark, #1a1a1a);
    background: var(--gray-dark, #1a1a1a);
    color: #fff;
    font-family: inherit;
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.25s ease, border-color 0.25s ease, opacity 0.25s ease;
    appearance: none;
    -webkit-appearance: none;
}

.anelli-product-info__submit:hover:not(:disabled) {
    background: var(--theme-color, #63512d);
    border-color: var(--theme-color, #63512d);
}

.anelli-product-info__submit:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.anelli-product-info__message {
    margin: 14px 0 0;
    font-size: 13px;
    line-height: 1.5;
}

.anelli-product-info__message--success {
    color: #2e7d32;
}

.anelli-product-info__message--error {
    color: #c62828;
}

.anelli-product-info__success {
    padding: 8px 4px 4px;
    text-align: center;
}

.anelli-product-info__success-title {
    margin: 0 0 10px;
    font-size: 16px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #2e7d32;
}

.anelli-product-info__success-text {
    margin: 0;
    font-size: 14px;
    line-height: 1.7;
    color: #444;
}

.anelli-product-info--sent .anelli-product-info__panel {
    margin-top: 0;
}

.anelli-product-info--sent .anelli-product-info__intro {
    display: none;
}

.anelli-product-info--sent .anelli-product-info__panel[hidden] {
    display: block !important;
}

