/* style.css */
/* Reset CSS */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: #FFFFFF;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background: linear-gradient(135deg, #1E2A63, #141B41);
}

.header-buttons {
    width: 90%;
    max-width: 700px;
    display: flex;
    justify-content: flex-start;
    margin-bottom: 20px;
    z-index: 2;
}

.header-button {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px 15px;
    font-size: 16px;
    font-weight: 600;
    color: #FFFFFF;
    background: linear-gradient(135deg, #4CAF50, #388E3C);
    border: none;
    border-radius: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    text-align: center;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
    margin-right: 10px; /* Spazio tra i pulsanti header */
}

.header-button i {
    font-size: 20px;
    margin-right: 8px;
}

.header-button:hover {
    background: linear-gradient(135deg, #388E3C, #2E7D32);
    transform: translateY(-2px);
    box-shadow: 0 6px 10px rgba(0, 0, 0, 0.3);
}

.header-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.2);
    transition: all 0.4s ease;
    transform: skewX(-45deg);
}

.header-button:hover::before {
    left: 100%;
}

.container {
    width: 90%;
    max-width: 700px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
    padding: 40px 20px;
    text-align: center;
    z-index: 1;
    margin-bottom: 20px;
}

.page-heading {
    font-size: 32px;
    font-weight: bold;
    margin-bottom: 30px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #FFD700;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.courier-selection {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 20px;
}

.courier-button {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 15px;
    font-size: 16px;
    font-weight: 600;
    color: #FFFFFF;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid transparent;
    border-radius: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    width: 120px;
}

.courier-button i {
    font-size: 30px;
    margin-bottom: 10px;
}

.courier-button:hover {
    border-color: #007bff;
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
    box-shadow: 0 6px 10px rgba(0, 0, 0, 0.2);
}

.courier-button.selected {
    border-color: #FFD700;
    background: rgba(255, 255, 255, 0.15);
}

.form-container {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    margin-bottom: 20px;
    text-align: left;
}

label {
    font-weight: bold;
    margin-bottom: 8px;
    color: #FFFFFF;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

input[type="text"] {
    padding: 12px 15px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    background: rgba(255, 255, 255, 0.2);
    color: #FFFFFF;
    transition: background 0.3s ease;
}

input[type="text"]:focus {
    background: rgba(255, 255, 255, 0.3);
    outline: none;
}

input[type="text"]::placeholder {
    color: #CCCCCC;
    opacity: 1;
}

input[type="text"]:-ms-input-placeholder {
    color: #CCCCCC;
}

input[type="text"]::-ms-input-placeholder {
    color: #CCCCCC;
}

button {
    padding: 15px 25px;
    font-size: 18px;
    font-weight: 600;
    color: #FFFFFF;
    background: linear-gradient(135deg, #007bff, #0056b3);
    border: none;
    border-radius: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 6px 10px rgba(0, 0, 0, 0.2);
    width: 100%;
}

button:hover {
    background: linear-gradient(135deg, #0056b3, #004085);
    transform: translateY(-2px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.3);
}

.result-container {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    padding: 30px;
    margin-top: 30px;
    text-align: left;
}

.result-title {
    font-size: 24px;
    font-weight: bold;
    color: #FFD700;
    margin-bottom: 20px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.result-item {
    color: #EEEEEE;
    margin-bottom: 10px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    gap: 10px;
}

.result-item strong {
    color: #FFFFFF;
    font-weight: bold;
}

.result-link {
    color: #007bff;
    text-decoration: none;
    transition: color 0.3s ease;
    flex-grow: 1;
}

.result-link:hover {
    color: #00b8ff;
    text-decoration: underline;
}

.save-link-icon {
    color: #FFD700;
    cursor: pointer;
    font-size: 1.2em;
}

.save-link-icon:hover {
    color: #FFFF00;
}

.footer {
    width: 90%;
    max-width: 700px;
    margin-top: 30px;
    padding: 20px;
    font-size: 14px;
    color: #CCCCCC;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    text-align: center;
    z-index: 1;
}

.footer a {
    color: #FFD700;
    text-decoration: none;
}

.footer a:hover {
    text-decoration: underline;
}

/* Responsive Design */
@media (max-width: 600px) {
    .container {
        padding: 30px 15px;
    }

    .page-heading {
        font-size: 28px;
        margin-bottom: 20px;
    }

    .courier-selection {
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }

    .courier-button {
        width: 100%;
    }

    .form-container,
    .result-container {
        padding: 20px;
    }

    button {
        font-size: 16px;
        padding: 12px 20px;
    }

    .result-title {
        font-size: 20px;
    }

    .header-buttons {
        justify-content: center;
        margin-bottom: 15px;
    }

    .header-button {
        font-size: 14px;
        padding: 8px 12px;
        margin-right: 5px;
    }

    .header-button i {
        font-size: 18px;
        margin-right: 5px;
    }

    .footer {
        padding: 15px;
        font-size: 12px;
    }

    .result-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }

    .save-link-icon {
        margin-left: 0;
    }
}

/* Sezione Ricerche Recenti */
.recent-searches {
    width: 90%;
    max-width: 700px;
    margin-top: 25px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 15px;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.2);
    text-align: left;
}

.recent-searches h2 {
    font-size: 20px;
    font-weight: bold;
    color: #FFD700;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

#search-list {
    list-style-type: none;
    padding-left: 0;
}

#search-list li {
    padding: 12px 15px;
    margin-bottom: 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    color: #e0e0e0;
    transition: background 0.3s ease;
}

#search-list li:hover {
    background: rgba(255, 255, 255, 0.1);
}

#search-list strong {
    color: #FFFFFF;
    font-weight: bold;
}

#search-list em {
    color: #AAAAAA;
    font-style: italic;
}

#search-list small {
    color: #CCCCCC;
    float: right;
}

#search-list a {
    display: inline-block;
    margin-top: 6px;
    color: #00bfff;
    text-decoration: none;
    font-size: 14px;
}

#search-list a:hover {
    text-decoration: underline;
    color: #00ffff;
}