.lpwr-management-section {
    margin: 1rem 0;
    border: 1px solid #dfe3e7;
    border-radius: 8px;
    background: #fff;
}

.lpwr-closure-panel {
    margin: 0 0 1.25rem;
    padding: 1rem;
    border: 2px solid #b42318;
    border-radius: 8px;
    background: #fff5f4;
}

.lpwr-closure-panel h3 { margin-top: 0; }

.lpwr-closure-action,
.lpwr-reopen-action {
    display: inline-block;
    padding: 0.85rem 1.15rem;
    border: 0;
    border-radius: 5px;
    background: #b42318;
    color: #fff;
    font: inherit;
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.25;
    cursor: pointer;
}

.lpwr-closure-action:hover,
.lpwr-closure-action:focus { background: #8f1c13; color: #fff; }

.lpwr-reopen-action { background: #177a42; }
.lpwr-reopen-action:hover,
.lpwr-reopen-action:focus { background: #0f5d31; color: #fff; }

.lpwr-closure-disclosure > summary,
.lpwr-reopen-disclosure > summary { list-style: none; }
.lpwr-closure-disclosure > summary::-webkit-details-marker,
.lpwr-reopen-disclosure > summary::-webkit-details-marker { display: none; }
.lpwr-closure-disclosure[open] > summary,
.lpwr-reopen-disclosure[open] > summary { display: none; }

.lpwr-closure-form {
    display: grid;
    gap: 1rem;
    margin-top: 1rem;
}

.lpwr-closure-form label > span,
.lpwr-closure-form small { display: block; }
.lpwr-closure-form label > span { margin-bottom: 0.35rem; font-weight: 700; }
.lpwr-closure-form small { margin-top: 0.35rem; }
.lpwr-closure-form textarea,
.lpwr-closure-form input {
    box-sizing: border-box;
    width: 100%;
    min-height: 46px !important;
    padding: 11px 14px !important;
    border: 1px solid #9ca3af;
    border-radius: 8px;
    background: #fff;
    color: inherit;
    font-family: inherit;
    font-size: 16px !important;
    font-weight: 400;
    line-height: 1.35;
}
.lpwr-closure-form textarea { min-height: 7rem; resize: vertical; }
.lpwr-closure-form input::placeholder,
.lpwr-closure-form textarea::placeholder { color: #6b7280; opacity: 0.72; }
.lpwr-closure-form input:focus,
.lpwr-closure-form textarea:focus {
    border-color: #177a42;
    outline: 3px solid rgb(23 122 66 / 18%);
    outline-offset: 1px;
    box-shadow: none;
}
.lpwr-closure-confirm {
    justify-self: start;
}
.lpwr-reopen-confirm { justify-self: start; }
.lpwr-closure-form .lpwr-reopen-confirmation {
    display: flex;
    gap: 0.55rem;
    align-items: flex-start;
}
.lpwr-closure-form .lpwr-reopen-confirmation input {
    width: auto;
    margin-top: 0.25rem;
}
.lpwr-closure-form .lpwr-reopen-confirmation span {
    margin: 0;
    font-weight: 700;
}
.lpwr-closure-state { color: #b42318; font-size: 1.15rem; font-weight: 700; }
.lpwr-closure-success,
.lpwr-closure-error { margin-bottom: 1rem; padding: 0.75rem; }
.lpwr-closure-success { border-left: 4px solid #177a42; background: #effaf3; }
.lpwr-closure-error { border-left: 4px solid #b42318; background: #fff; color: #7a1b13; }

.lpwr-management-required-note {
    margin: 0 0 0.5rem;
    color: #4b5563;
}

.lpwr-required,
.lpwr-management-required-note > span {
    color: #b42318;
    font-weight: 700;
}

.lpwr-management-section > summary {
    padding: 0.9rem 1rem;
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
}

.lpwr-management-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
    padding: 0 1rem 1rem;
}

.lpwr-management-grid label > span,
.lpwr-management-grid legend {
    display: block;
    margin-bottom: 0.35rem;
    font-weight: 700;
}

.lpwr-management-grid input:not([type="checkbox"]),
.lpwr-management-grid select,
.lpwr-management-grid textarea {
    box-sizing: border-box;
    width: 100%;
    min-height: 46px !important;
    padding: 11px 14px !important;
    border: 1px solid #9ca3af;
    border-radius: 8px;
    background: #fff;
    color: inherit;
    font-family: inherit;
    font-size: 16px !important;
    font-weight: 400;
    line-height: 1.35;
}

.lpwr-management-grid select { padding-right: 36px !important; }

.lpwr-management-grid textarea {
    min-height: 7rem;
    resize: vertical;
}

.lpwr-management-grid input::placeholder,
.lpwr-management-grid textarea::placeholder {
    color: #8c949e;
    opacity: 0.72;
}

.lpwr-management-grid input:focus,
.lpwr-management-grid select:focus,
.lpwr-management-grid textarea:focus {
    border-color: #177a42;
    outline: 3px solid rgb(23 122 66 / 18%);
    outline-offset: 1px;
    box-shadow: none;
}

.lpwr-management-grid fieldset {
    min-width: 0;
    margin: 0;
    padding: 0;
    border: 0;
}

.lpwr-coordinate-group {
    padding: 0.75rem !important;
    border: 1px solid #dfe3e7 !important;
    border-radius: 6px;
}

.lpwr-coordinate-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
}

.lpwr-management-wide,
.lpwr-management-help {
    grid-column: 1 / -1;
}

.lpwr-management-checks {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
    gap: 0.5rem 1rem;
}

.lpwr-management-checks label {
    display: flex;
    gap: 0.45rem;
    align-items: flex-start;
}

.lpwr-management-help {
    margin: 0;
    padding: 0.75rem;
    border-left: 4px solid #b7791f;
    background: #fff8e6;
}

@media (max-width: 680px) {
    .lpwr-management-grid {
        grid-template-columns: 1fr;
    }

    .lpwr-coordinate-grid {
        grid-template-columns: 1fr;
    }
}
