/* CSS Variablen für erdige Grüntöne */
.wp-block-nms-gutenberg-blocks-gridfilter {
    --primary-green: #4a7c59;
    --green-light: #e8f0e8;
    --green-darker: #3a5f48;
    --accent-green: #6ba68a;
    --shadow-green: rgba(74, 124, 89, 0.15);
    --border-color: #d1e3d4;
    --text-muted: #6b8a7a;
    --gap: 1.5rem;
    --radius: 12px;
    --shadow: 0 4px 12px var(--shadow-green);
    --shadow-hover: 0 8px 24px var(--shadow-green);
}

.nms-gridfilter-form {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--gap);
    align-items: flex-end;
    padding: 1.5rem;
    background: rgba(232, 240, 232, 1);
    border-radius: var(--radius);
    border: 1px solid var(--border-color);
}

.nms-gridfilter-input-group {
    display: flex;
    gap: 1rem;
    justify-content: center;
    width: 100%;
    max-width: 660px;
}

.nms-gridfilter-textsearch,
.nms-gridfilter-category {
    max-width: 320px;
    flex: 1 1 320px;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.nms-gridfilter-textsearch label,
.nms-gridfilter-category label {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

/* Einheitliche Input/Select Styling */
.nms-gridfilter-textsearch input,
.nms-gridfilter-category select {
    width: auto;
    padding: 0.875rem 1rem;
    border: 2px solid var(--border-color);
    border-radius: var(--radius);
    font-size: 1rem;
    font-family: inherit;
    background: #fff;
    color: var(--primary-green);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    appearance: none;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b8a7a' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");
    background-position: right 0.75rem center;
    background-repeat: no-repeat;
    background-size: 1rem;
    padding-right: 2.5rem;
}

.nms-gridfilter-textsearch input:focus,
.nms-gridfilter-category select:focus {
    outline: none;
    border-color: var(--primary-green);
    box-shadow: 0 0 0 3px rgba(74, 124, 89, 0.1);
    transform: translateY(-1px);
}

.nms-gridfilter-textsearch input:hover,
.nms-gridfilter-category select:hover {
    border-color: var(--accent-green);
}

/* Button Styling - einheitlich modern */
.nms-gridfilter-submit {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.nms-submit-label {
    visibility: hidden;
    height: 0;
    margin: 0;
    padding: 0;
}

.nms-gridfilter-submit .wp-block-button__link.wp-element-button,
.nms-gridfilter-buttons .nms-gridfilter-button {
    padding: 0.875rem 1.5rem;
    border: 2px solid var(--primary-green);
    border-radius: var(--radius);
    font-size: 1rem;
    font-weight: 600;
    background: linear-gradient(135deg, var(--primary-green) 0%, var(--accent-green) 100%);
    color: white;
    text-decoration: none;
    text-transform: none;
    letter-spacing: 0.025em;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    min-height: 52px;
    box-shadow: var(--shadow);
    flex-shrink: 0;
}

.nms-gridfilter-submit .wp-block-button__link.wp-element-button:hover,
.nms-gridfilter-buttons .nms-gridfilter-button:hover {
    background: linear-gradient(135deg, var(--green-darker) 0%, var(--primary-green) 100%);
    box-shadow: var(--shadow-hover);
    transform: translateY(-2px);
}

.nms-gridfilter-submit .wp-block-button__link.wp-element-button:active,
.nms-gridfilter-buttons .nms-gridfilter-button:active {
    transform: translateY(0);
}

.nms-gridfilter-buttons {
    margin-top: 1.5rem;
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

/* Filter Buttons - dezenter Hintergrund */
.nms-gridfilter-buttons .nms-gridfilter-button {
    background: linear-gradient(135deg, var(--green-light) 0%, #f5fbf5 100%);
    color: var(--primary-green);
    border-color: var(--border-color);
    box-shadow: 0 2px 8px var(--shadow-green);
}

.nms-gridfilter-buttons .nms-gridfilter-button:hover {
    background: linear-gradient(135deg, var(--accent-green) 0%, var(--primary-green) 100%);
    color: white;
    box-shadow: var(--shadow-hover);
}

.nms-gridfilter-buttons .nms-gridfilter-button:after {
    content: "x";
    display: block;
    position: absolute;
    top: 5px;
    right: 10px;
    font-weight: 800;
    font-size: 85%;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nms-gridfilter-input-group {
        flex-direction: column;
        max-width: 100%;
    }
    
    .nms-gridfilter-textsearch,
    .nms-gridfilter-category {
        max-width: 100%;
    }
    
    .nms-gridfilter-form {
        padding: 1rem;
    }
	
	.nms-gridfilter-textsearch,
	.nms-gridfilter-category {
		flex: 1;
	}
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    .nms-gridfilter-textsearch input,
    .nms-gridfilter-category select {
        background: #2a3a32;
        color: #e8f0e8;
        border-color: #4a5f48;
    }
}