/**
 * Gemensam CSS för event-formulär
 * Används av både add_event.php och edit_events.php
 */

/* Datum- och tidsfält */
.dynamic-list {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    overflow: hidden;
}

.date-time-group {
    display: flex;
    gap: 10px;
    align-items: flex-end;
    flex-wrap: wrap;
    width: 100%;
    max-width: 100%;
    padding: 5px 12px 8px 12px;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 5px;
    margin: 0;
    box-sizing: border-box;
}

.date-field,
.time-field {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.date-field label,
.time-field label {
    font-size: 12px;
    color: #666;
    font-weight: normal;
}

.time-selects {
    display: flex;
    align-items: center;
    gap: 5px;
}

.time-selects select {
    width: 70px;
}

.remove-btn {
    background-color: #d32f2f;
    color: white;
    border: none;
    padding: 8px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
    margin-left: auto;
}

.remove-btn:hover {
    background-color: #b71c1c;
}

.add-btn {
    background-color: #2E7D32;
    color: white;
    padding: 8px 15px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    margin-top: 5px;
}

.add-btn:hover {
    background-color: #1B5E20;
}

/* Sektioner */
.section {
    background-color: #f9f9f9;
    padding: 15px;
    margin: 20px 0;
    border-radius: 5px;
    border: 1px solid #ddd;
}

.section h3 {
    margin-top: 0;
    color: #333;
}

/* Bildsektion */
.image-section {
    margin: 20px 0;
}

/* Mobilanpassning */
@media (max-width: 768px) {
    .date-time-group {
        flex-direction: column !important;
        align-items: stretch !important;
        padding: 10px !important;
    }
    
    .date-field {
        width: 100% !important;
    }
    
    .time-field {
        width: 100% !important;
        flex-direction: row !important;
        align-items: center !important;
        gap: 8px !important;
        margin-top: 5px !important;
    }
    
    .time-field label {
        margin: 0 !important;
        min-width: 30px;
    }
    
    .time-selects {
        flex: 1;
    }
    
    .time-selects select {
        flex: 1;
        min-width: 60px;
    }
    
    .remove-btn {
        width: 100% !important;
        margin-left: 0 !important;
        margin-top: 8px !important;
    }
    
    /* Knappar */
    input[type="text"],
    input[type="email"],
    input[type="url"],
    input[type="date"],
    input[type="number"],
    textarea,
    select {
        font-size: 16px !important;
        padding: 12px !important;
    }
    
    button,
    .button {
        font-size: 16px !important;
        padding: 12px 20px !important;
        min-height: 44px;
    }
}