/* RHW Meldeformular Styles */

.rhw-meldeformular {
    margin-top: 2.5rem;
    width: 100%;
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
    padding: 2rem;
    margin-bottom: 3rem;
    border: 1px solid #dc2626;
    border-radius: 0.75rem;
    text-align: left;
}

.rhw-meldeformular-title {
    text-align: center;
    margin-bottom: 1rem;
}

.rhw-meldeformular-grid {
    display: grid;
    grid-template-columns: 1fr;
    margin-top: 1.25rem;
    gap: 1rem;
}

.rhw-meldeformular-field {
    display: flex;
    flex-direction: column;
}

.rhw-meldeformular-field label {
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.rhw-meldeformular-hint {
    display: block;
    margin-top: 0.25rem;
    font-size: 0.875rem;
    color: #6b7280;
    font-style: italic;
}

.rhw-meldeformular-input,
.rhw-meldeformular-textarea {
    background-color: transparent;
    border: 1px solid #e5e7eb;
    width: 100%;
    border-radius: 0.25rem;
    padding: 0.5rem;
    font-family: inherit;
    font-size: inherit;
    color: #ffffff;
}

.rhw-meldeformular-input::placeholder,
.rhw-meldeformular-textarea::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.rhw-meldeformular-input:focus,
.rhw-meldeformular-textarea:focus,
.rhw-meldeformular-select:focus {
    outline: none;
    border-color: #dc2626;
    box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.1);
    color: #ffffff;
}

.rhw-meldeformular-select {
    background-color: transparent;
    border: 1px solid #e5e7eb;
    width: 100%;
    border-radius: 0.25rem;
    padding: 0.5rem;
    font-family: inherit;
    font-size: inherit;
    cursor: pointer;
    color: #ffffff;
}

.rhw-meldeformular-checkbox-label {
    display: flex;
    align-items: flex-start;
    cursor: pointer;
    font-weight: normal;
}

.rhw-meldeformular-checkbox-label span {
    margin-left: 0.5rem;
    line-height: 1.5;
}

.rhw-meldeformular-checkbox {
    margin-top: 0.25rem;
    width: 1.25rem;
    height: 1.25rem;
    cursor: pointer;
    flex-shrink: 0;
}

.rhw-meldeformular-textarea {
    height: 9rem;
    resize: vertical;
}

.rhw-meldeformular-success {
    margin-top: 1.25rem;
    padding: 1.5rem;
    background-color: #065f46;
    border: 1px solid #10b981;
    border-radius: 0.25rem;
    color: #ffffff;
}

.rhw-meldeformular-success p {
    margin: 0.5rem 0;
}

.rhw-meldeformular-success p:first-child {
    margin-top: 0;
}

.rhw-meldeformular-success p:last-child {
    margin-bottom: 0;
}

.rhw-meldeformular-errors {
    margin-top: 1.25rem;
    padding: 1rem;
    background-color: #7f1d1d;
    border: 1px solid #dc2626;
    border-radius: 0.25rem;
    color: #ffffff;
}

.rhw-meldeformular-error-list {
    list-style-type: disc;
    margin-left: 1.5rem;
    margin-top: 0.5rem;
}

.rhw-meldeformular-error-list li {
    margin-bottom: 0.25rem;
}

.rhw-meldeformular-submit {
    text-align: right;
}

.rhw-meldeformular-button {
    padding: 0.5rem 0.75rem;
    background-color: #dc2626;
    color: white;
    border: none;
    border-radius: 0.75rem;
    cursor: pointer;
    font-size: inherit;
    font-family: inherit;
    transition: background-color 0.2s, transform 0.1s;
}

.rhw-meldeformular-button:hover {
    background-color: #b91c1c;
}

.rhw-meldeformular-button:active {
    transform: scale(0.98);
}

.rhw-meldeformular-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Loading Overlay */
.rhw-meldeformular-loading {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(0, 0, 0, 0.9);
    color: white;
    font-size: 1.875rem;
    z-index: 9999;
}

.rhw-meldeformular-loading span {
    margin-left: 0.75rem;
}

.rhw-meldeformular-spinner {
    animation: spin 1s linear infinite;
    height: 2.5rem;
    width: 2.5rem;
    display: inline-block;
}

.rhw-meldeformular-spinner-circle {
    opacity: 0.25;
}

.rhw-meldeformular-spinner-path {
    opacity: 0.75;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* Responsive Design */
@media (max-width: 1024px) {
    .rhw-meldeformular {
        max-width: 100%;
        padding: 1rem;
    }
}

@media (max-width: 640px) {
    .rhw-meldeformular {
        padding: 1rem;
        margin-top: 1rem;
    }
    
    .rhw-meldeformular-loading {
        font-size: 1.25rem;
    }
    
    .rhw-meldeformular-spinner {
        height: 2rem;
        width: 2rem;
    }
}

/* Turnstile Widget Styling */
.cf-turnstile {
    margin: 0.5rem 0;
}
