.post-form-page .post-form-shell {
    width: min(820px, calc(100% - 48px));
    margin: 34px auto 56px;
}

.post-form-page .form-page-heading {
    margin-bottom: 18px;
}

.post-form-page .form-page-heading h2 {
    margin: 0;
    color: #203747;
    font-size: 27px;
    line-height: 1.25;
}

.post-form-page .form-error {
    margin: 0 0 16px;
    padding: 12px 14px;
    border: 1px solid #edc7c2;
    border-radius: 8px;
    background: #fff3f1;
    color: #963d34;
    line-height: 1.5;
}

.post-form-page .post-editor {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 19px 20px;
    padding: 25px;
    border: 1px solid #e1e7eb;
    border-radius: 11px;
    background: #fff;
    box-shadow: 0 4px 14px rgb(29 52 68 / 5%);
}

.post-form-page .form-field {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 7px;
}

.post-form-page .form-field--wide {
    grid-column: 1 / -1;
}

.post-form-page .form-field > label,
.post-form-page .form-field-label {
    color: #344b5a;
    font-size: 14px;
    font-weight: 700;
}

.post-form-page .form-field input[type="text"],
.post-form-page .form-field input[type="password"],
.post-form-page .form-field select,
.post-form-page .form-field textarea {
    width: 100%;
    min-height: 46px;
    padding: 10px 12px;
    border: 1px solid #d7e0e5;
    border-radius: 7px;
    background: #fff;
    color: #263746;
    font: inherit;
    font-size: 15px;
}

.post-form-page .form-field textarea {
    min-height: 190px;
    resize: vertical;
    line-height: 1.6;
}

.post-form-page .form-display-value {
    display: flex;
    min-height: 46px;
    align-items: center;
    padding: 10px 12px;
    border: 1px solid #d7e0e5;
    border-radius: 7px;
    background: #f2f5f6;
    color: #344b5a;
    font-size: 15px;
}

.post-form-page .form-field input[type="text"]:focus,
.post-form-page .form-field input[type="password"]:focus,
.post-form-page .form-field select:focus,
.post-form-page .form-field textarea:focus {
    border-color: #e77d32;
    outline: 3px solid rgb(231 125 50 / 17%);
}

.post-form-page .form-field input[name="title"],
.post-form-page .form-field textarea[name="body"] {
    font-size: 0.8em;
}

.post-form-page .form-checkbox {
    display: flex;
    min-height: 46px;
    flex-direction: row;
    align-items: center;
    gap: 10px;
    padding: 0 12px;
    border: 1px solid #e1e7eb;
    border-radius: 7px;
    background: #f8fafb;
}

.post-form-page .form-checkbox input {
    width: 17px;
    height: 17px;
    margin: 0;
    accent-color: #e77d32;
}

.post-form-page .form-checkbox label {
    color: #344b5a;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

.post-form-page .form-actions {
    display: flex;
    grid-column: 1 / -1;
    align-items: center;
    gap: 10px;
    margin-top: 2px;
    padding-top: 18px;
    border-top: 1px solid #e8edef;
}

.post-form-page .form-actions .post-button {
    min-width: 112px;
    margin: 0;
    text-align: center;
}

.post-form-page .form-actions .primary-action {
    border-color: #e77d32;
    background: #e77d32;
    color: #fff;
}

.post-form-page .form-actions .primary-action:hover {
    border-color: #c96320;
    background: #c96320;
}

.post-form-page .form-actions .cancel-action {
    color: #4f6370;
}

/* New / edit post form (mockup slide 4) */
.post-form-page .visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

.post-form-page .post-editor--post {
    grid-template-columns: minmax(0, 1fr);
}

.post-form-page .post-editor--post .form-field--wide {
    gap: 4px;
}

.post-form-page .post-editor--post textarea[name="body"] {
    min-height: 150px;
}

.post-form-page .post-form-row {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px 16px;
}

.post-form-page .form-field--inline {
    flex-direction: row;
    align-items: center;
    gap: 8px;
}

.post-form-page .form-field--inline > label {
    flex: 0 0 auto;
}

.post-form-page .form-field--inline select,
.post-form-page .form-field--inline .form-display-value {
    flex: 1 1 auto;
    min-width: 0;
}

/* Town find box beside a location select (common.js initLocationFilters) */
.post-form-page .location-picker {
    display: flex;
    flex: 1 1 auto;
    min-width: 0;
    gap: 6px;
}

.post-form-page .form-field .location-picker .location-filter {
    flex: 0 0 6.5em;
    width: 6.5em;
}

.post-form-page .location-picker select {
    flex: 1 1 auto;
    min-width: 0;
}

/* input element in the selector so it outranks the :focus border while typing */
.post-form-page .form-field input.location-filter.location-filter--none {
    border-color: #c0392b;
    outline: 3px solid rgb(192 57 43 / 15%);
}

.post-form-page .category-preview {
    display: inline-flex;
    flex: none;
}

.post-form-page .category-preview .icon,
.post-form-page .category-display .icon {
    width: 24px;
    height: 24px;
}

.post-form-page .category-display {
    gap: 8px;
}

.post-form-page .form-field--inline input[type="checkbox"] {
    width: 22px;
    height: 22px;
    margin: 0;
    accent-color: #e77d32;
}

.post-form-page .form-display-value--number {
    justify-content: flex-end;
}

.post-form-page .form-message {
    margin: 0;
    padding: 10px 12px;
    border: 1px solid #d7e0e5;
    border-radius: 7px;
    background: #f2f5f6;
    color: #6e7d88;
    font-size: 14px;
    font-style: italic;
    line-height: 1.5;
}

.post-form-page .form-message--error {
    border-color: #edc7c2;
    background: #fff3f1;
    color: #963d34;
    font-style: normal;
}

.post-form-page .form-actions--icons {
    justify-content: center;
    gap: 64px;
}

.post-form-page .icon-action {
    display: grid;
    width: 52px;
    height: 52px;
    place-items: center;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: transparent;
    cursor: pointer;
}

.post-form-page .icon-action svg {
    width: 40px;
    height: 40px;
    fill: none;
    stroke-width: 3;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.post-form-page .icon-action--save svg {
    stroke: #1f9d55;
}

.post-form-page .icon-action--cancel svg {
    stroke: #d93025;
}

.post-form-page .icon-action:hover {
    background: #f2f5f6;
}

.post-form-page .icon-action:focus-visible {
    outline: 2px solid #e77d32;
    outline-offset: 2px;
}

.post-form-page .login-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 20px;
    margin: 16px 4px;
}

.post-form-page .login-links a {
    color: #476273;
    font-size: 14px;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.registration-page .username-feedback {
    min-height: 1.4em;
    color: #6e7d88;
    font-size: 13px;
    line-height: 1.4;
}

.registration-page .password-input-wrap {
    position: relative;
}

.registration-page .password-input-wrap input {
    padding-right: 46px;
}

.registration-page .password-visibility-toggle {
    position: absolute;
    top: 50%;
    right: 7px;
    display: grid;
    width: 34px;
    height: 34px;
    place-items: center;
    transform: translateY(-50%);
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: #536b79;
    font: inherit;
    font-size: 19px;
    line-height: 1;
    cursor: pointer;
}

.registration-page .password-visibility-toggle:hover {
    background: #edf2f4;
}

.registration-page .password-visibility-toggle:focus-visible {
    outline: 2px solid #e77d32;
    outline-offset: 1px;
}

.registration-page .registration-password-guidance {
    grid-column: 1 / -1;
    padding: 15px 16px;
    border: 1px solid #e5eaed;
    border-radius: 8px;
    background: #f8fafb;
}

.registration-page .registration-password-guidance > p {
    margin: 0 0 10px;
    color: #435968;
    font-size: 14px;
}

.registration-page .registration-password-guidance ul {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 7px 18px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.registration-page .password-check {
    margin: 0;
    font-size: 13px;
    line-height: 1.5;
}

.registration-page .check-fail,
.registration-page .strength-very-weak {
    color: #a4433b;
}

.registration-page .check-pass,
.registration-page .strength-very-strong {
    color: #28724b;
}

.registration-page #strength-text {
    font-weight: 700;
}

.registration-page .strength-weak {
    color: #a85758;
}

.registration-page .strength-fair {
    color: #a46418;
}

.registration-page .strength-strong {
    color: #3b6c3e;
}

.registration-page .registration-guidance-space {
    grid-column: 1 / -1;
    min-height: 96px;
}

.recovery-page .recovery-intro {
    margin: 0 0 16px;
    color: #5f707b;
    font-size: 14px;
    line-height: 1.6;
}

.recovery-page .recovery-display-field {
    display: flex;
    min-height: 46px;
    align-items: center;
    padding: 10px 12px;
    border: 1px solid #d7e0e5;
    border-radius: 7px;
    background: #f2f5f6;
    color: #344b5a;
    font-size: 15px;
    line-height: 1.5;
}

.recovery-page .recovery-password-guidance {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px 16px;
    padding: 15px 16px;
    border: 1px solid #e5eaed;
    border-radius: 8px;
    background: #f8fafb;
}

.recovery-page .recovery-password-guidance p {
    margin: 0;
    color: #435968;
    font-size: 13px;
    line-height: 1.5;
}

.recovery-page .recovery-strength {
    margin: 0;
    color: #435968;
    font-size: 14px;
}

@media (max-width: 650px) {
    .post-form-page .post-form-shell {
        width: calc(100% - 28px);
        margin-top: 24px;
    }

    .post-form-page .form-page-heading h2 {
        font-size: 23px;
    }

    .post-form-page .post-editor {
        grid-template-columns: minmax(0, 1fr);
        gap: 16px;
        padding: 18px;
    }

    .post-form-page .form-field--wide,
    .post-form-page .form-actions {
        grid-column: auto;
    }

    .post-form-page .form-actions {
        flex-wrap: wrap;
    }

    .registration-page .registration-password-guidance ul {
        grid-template-columns: minmax(0, 1fr);
    }

    .post-form-page .post-form-row--selects {
        grid-template-columns: minmax(0, 1fr);
    }

    .post-form-page .post-form-row--selects .form-field--inline > label {
        min-width: 72px;
    }

    .post-form-page .form-actions--icons {
        flex-wrap: nowrap;
    }

    .registration-page .registration-guidance-space {
        min-height: 72px;
    }

    .recovery-page .recovery-password-guidance {
        grid-template-columns: minmax(0, 1fr);
    }
}
/* ----- Post image (slide 4) ----- */

.post-form-page .image-box {
    display: grid;
    min-height: 140px;
    place-items: center;
    padding: 10px;
    border: 2px dashed #b9c6ce;
    border-radius: 12px;
    background: #fff;
}

.post-form-page .image-preview {
    display: block;
    max-width: 100%;
    max-height: 360px;
    border-radius: 6px;
    object-fit: contain;
}

.post-form-page .image-placeholder {
    color: #6e7d88;
    font-size: 14px;
}

.post-form-page .image-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 2px 16px 0;
}

.post-form-page .image-action {
    display: inline-grid;
    width: 44px;
    height: 44px;
    place-items: center;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #263746;
    cursor: pointer;
}

.post-form-page .image-action:hover {
    background: #f2f5f6;
}

.post-form-page .image-action:focus-within,
.post-form-page .image-action:focus-visible {
    outline: 2px solid #e77d32;
    outline-offset: 2px;
}

.post-form-page .image-action .icon {
    width: 28px;
    height: 28px;
}

.post-form-page .image-action--danger {
    color: #d93025;
}

.post-form-page .image-message {
    color: #d93025;
    font-size: 13px;
}

/* ----- Rich-text description (Quill, static/vendor/quill-2.0.3) ----- */

.post-form-page .ql-toolbar.ql-snow {
    border: 1px solid #d7e0e5;
    border-radius: 7px 7px 0 0;
    background: #f8fafb;
    font-family: inherit;
}

.post-form-page .ql-container.ql-snow {
    border: 1px solid #d7e0e5;
    border-top: 0;
    border-radius: 0 0 7px 7px;
    background: #fff;
    font-family: inherit;
    font-size: 0.8em;
}

.post-form-page .ql-editor {
    min-height: 150px;
    color: #263746;
    line-height: 1.45;
}

.post-form-page .ql-editor.ql-blank::before {
    color: #8a98a2;
    font-style: normal;
}

.post-form-page .rich-text-editor:focus-within {
    outline: 3px solid rgb(231 125 50 / 17%);
}

/* ----- AI suggestions (brain buttons) ----- */

.post-form-page .field-tools {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
}

.post-form-page .field-tools .ai-button {
    width: 36px;
    height: 36px;
}

.post-form-page .field-tools .ai-button .icon {
    width: 24px;
    height: 24px;
}

.post-form-page .ai-button[aria-busy="true"] {
    opacity: 0.5;
}

.post-form-page .ai-suggestion {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 12px;
    border: 1px solid #f0b184;
    border-radius: 7px;
    background: #fff5ed;
}

.post-form-page .ai-suggestion-text {
    flex: 1;
    margin: 0;
    color: #263746;
    font-size: 14px;
    white-space: pre-line;
}

.post-form-page .ai-suggestion-actions {
    display: flex;
    gap: 4px;
}

/* Sign in with Google (login.html): Google's light button style, own logo file. */
.post-form-page .signin-note {
    margin: 0 0 12px;
    color: #344b5a;
    font-size: 14px;
    line-height: 1.5;
}

.post-form-page .google-signin-button {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-height: 40px;
    padding: 0 16px;
    border: 1px solid #747775;
    border-radius: 20px;
    background: #ffffff;
    color: #1f1f1f;
    font: inherit;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

.post-form-page .google-signin-button:hover,
.post-form-page .google-signin-button:focus-visible {
    background: #f2f2f2;
}
