* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    min-height: 100vh;
    padding: 10px 20px 20px 20px;
    overflow-y: auto;
    font-size: 15px;
}

.page-wrapper {
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
}

.restaurant-logo {
    width: 180px;
    height: 180px;
    margin: 0 auto 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.restaurant-logo img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.restaurant-name {
    text-align: center;
    font-size: 22px;
    font-weight: bold;
    color: #333;
    margin-bottom: 24px;
    letter-spacing: -0.5px;
}

.container {
    background: white;
    border-radius: 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    padding: 40px 30px;
    width: 100%;
    max-width: 600px;
    margin-bottom: 20px;
}

h1 {
    text-align: center;
    color: #333;
    margin-bottom: 30px;
    font-size: 29px;
}

.booking-summary-header {
    padding: 0 20px;
    margin-bottom: 24px;
    display: none;
    text-align: center;
    color: #666;
    font-weight: normal;
    font-size: 17px;
}

.booking-summary-header.show {
    display: block;
}

.progress-container {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
    position: relative;
}

.progress-container::before {
    content: '';
    position: absolute;
    top: 20px;
    left: 0;
    right: 0;
    height: 2px;
    background: #e0e0e0;
    z-index: 0;
}

.progress-line {
    position: absolute;
    top: 20px;
    left: 0;
    height: 2px;
    background: #4caf50;
    z-index: 1;
    transition: width 0.3s ease;
}

.step {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 2;
    flex: 1;
}

.step-circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: white;
    border: 2px solid #e0e0e0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: #999;
    transition: all 0.3s ease;
    margin-bottom: 8px;
}

.step.active .step-circle {
    border-color: #FF1D76;
    background: #FF1D76;
    color: white;
}

.step.completed .step-circle {
    border-color: #4caf50;
    background: #4caf50;
    color: white;
}

.step-label {
    font-size: 13px;
    color: #666;
    text-align: center;
}

.step.active .step-label {
    color: #FF1D76;
    font-weight: 600;
}

.form-section {
    display: none;
}

.form-section.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

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

.form-group {
    margin-bottom: 24px;
}

label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: 500;
}

/* Prevent auto-zoom on mobile devices */
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
textarea,
select {
    font-size: 16px !important;
}

textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-family: inherit;
    resize: vertical;
    min-height: 100px;
    transition: border-color 0.3s ease;
}

textarea:focus {
    outline: none;
    border-color: #FF1D76;
}

.allergies-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-top: 16px;
}

.allergy-option {
    padding: 12px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
    text-align: center;
    font-size: 15px;
}

.allergy-option:hover {
    border-color: #FF1D76;
}

.allergy-option:focus {
    outline: none;
}

.allergy-option:focus:not(:hover):not(.selected) {
    border-color: #e0e0e0;
}

.allergy-option:focus-visible:not(:hover):not(.selected) {
    border-color: #e0e0e0;
}

.allergy-option.selected {
    background: #FF1D76;
    border-color: #FF1D76;
    color: white;
}

select, input, textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 17px;
    transition: border-color 0.3s ease;
}

select:focus, input:focus, textarea:focus {
    outline: none;
    border-color: #FF1D76;
}

.guest-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(60px, 60px));
    gap: 10px;
    margin-top: 16px;
    justify-content: start;
}

.guest-option {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #e0e0e0;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
    font-size: 16px;
    font-weight: 600;
    color: #333;
}

.guest-option:hover {
    border-color: #FF1D76;
    transform: scale(1.05);
}

/* Only show hover effects after mouse movement is detected */
body:not(.mouse-user) .guest-option:hover,
body:not(.mouse-user) .calendar-day:hover,
body:not(.mouse-user) .time-slot:hover,
body:not(.mouse-user) .allergy-option:hover {
    border-color: #e0e0e0;
    transform: none;
}

.guest-option:focus {
    outline: none;
}

.guest-option:focus:not(:hover):not(.selected) {
    border-color: #e0e0e0;
    transform: none;
}

.guest-option:focus-visible:not(:hover):not(.selected) {
    border-color: #e0e0e0;
    transform: none;
}

.guest-option.selected {
    background: #FF1D76;
    border-color: #FF1D76;
    color: white;
}

.calendar {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 8px;
    margin-top: 16px;
    transition: opacity 0.2s ease;
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.calendar-header h3 {
    font-size: 19px;
    color: #333;
}

.calendar-nav {
    display: flex;
    gap: 8px;
}

.calendar-nav button {
    padding: 8px 12px;
    background: #f5f5f5;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 19px;
    transition: background 0.3s ease;
}

.calendar-nav button:hover {
    background: #e0e0e0;
}

.calendar-day-name {
    text-align: center;
    font-size: 13px;
    font-weight: 600;
    color: #666;
    padding: 8px 0;
}

.calendar-day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
    font-size: 15px;
}

.calendar-day:hover:not(.disabled):not(.other-month) {
    border-color: #FF1D76;
    transform: scale(1.05);
}

.calendar-day:focus {
    outline: none;
}

.calendar-day:focus:not(:hover):not(.selected) {
    border-color: #e0e0e0;
    transform: none;
}

.calendar-day:focus-visible:not(:hover):not(.selected) {
    border-color: #e0e0e0;
    transform: none;
}

.calendar-day.selected {
    background: #FF1D76;
    border-color: #FF1D76;
    color: white;
}

.calendar-day.disabled {
    background: #f5f5f5;
    color: #ccc;
    cursor: not-allowed;
    border-color: #f5f5f5;
}

.calendar-day.other-month {
    color: #ccc;
    border-color: #f5f5f5;
}

.calendar-day.today {
    border-color: #ffa726;
    font-weight: bold;
}

.time-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    transition: opacity 0.15s ease;
}

.time-slot {
    padding: 12px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
}

.time-slot:hover {
    border-color: #FF1D76;
}

.time-slot:focus {
    outline: none;
}

.time-slot:focus:not(:hover):not(.selected) {
    border-color: #e0e0e0;
}

.time-slot:focus-visible:not(:hover):not(.selected) {
    border-color: #e0e0e0;
}

.time-slot.selected {
    background: #FF1D76;
    border-color: #FF1D76;
    color: white;
}

.loading {
    text-align: center;
    padding: 40px 20px;
    color: #666;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #FF1D76;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 16px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.btn-group {
    display: flex;
    gap: 12px;
    margin-top: 30px;
}

button {
    flex: 1;
    padding: 14px 24px;
    border: none;
    border-radius: 8px;
    font-size: 17px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-primary {
    background: #4caf50;
    color: white;
}

.btn-primary:hover {
    background: #45a049;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(76, 175, 80, 0.4);
}

.btn-secondary {
    background: #e0e0e0;
    color: #333;
}

.btn-secondary:hover {
    background: #d0d0d0;
}

.summary {
    background: #f5f5f5;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.summary-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid #e0e0e0;
}

.summary-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.summary-label {
    color: #666;
}

.summary-value {
    font-weight: 600;
    color: #333;
}

.success-message {
    text-align: center;
    padding: 40px 20px;
}

.success-icon {
    width: 80px;
    height: 80px;
    background: #4caf50;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 40px;
    color: white;
}

.error-message {
    background: #fee;
    color: #c33;
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 16px;
    font-size: 15px;
    display: none;
}

.error-message.show {
    display: block;
    animation: shake 0.3s ease;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-10px); }
    75% { transform: translateX(10px); }
}

.btn-add-children {
    background: transparent;
    border: 2px solid #ccc;
    color: #999;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 24px;
    display: inline-block;
}

.btn-add-children:hover {
    background: #f0f0f0;
    border-color: #bbb;
    color: #666;
    transform: none;
    box-shadow: none;
}

.btn-add-children.active {
    background: #f0f0f0;
    border-color: #bbb;
    color: #666;
}

@media (max-width: 480px) {
    .container {
        padding: 30px 20px;
    }

    h1 {
        font-size: 25px;
    }

    .restaurant-logo {
        width: 150px;
        height: 150px;
        margin-bottom: 12px;
    }

    .guest-grid {
        grid-template-columns: repeat(4, 1fr);
    }

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

    .step-label {
        font-size: 12px;
    }

    .step-circle {
        width: 36px;
        height: 36px;
        font-size: 15px;
    }
}