/* ForumX premium responsive footer */
html { scroll-behavior: smooth; }

body .site-footer.fx-footer {
    position: relative;
    margin-top: 64px;
    padding: 0 0 calc(104px + env(safe-area-inset-bottom));
    border-top: 4px solid var(--accent);
    background:
        radial-gradient(circle at 12% 0%, color-mix(in srgb, var(--accent) 9%, transparent), transparent 34%),
        linear-gradient(180deg, color-mix(in srgb, var(--card) 42%, #06101b), color-mix(in srgb, var(--bg) 78%, #050b13));
    color: var(--text);
    overflow: hidden;
}

body .site-footer.fx-footer::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(120deg, rgba(255,255,255,.018), transparent 35%, transparent 70%, rgba(255,255,255,.012));
}

body .fx-footer-shell {
    position: relative;
    z-index: 1;
    padding-top: 32px;
    padding-bottom: 26px;
}

body .fx-footer-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 24px;
}

body .fx-footer-brand {
    min-width: 0;
    display: inline-flex;
    align-items: center;
    gap: 14px;
    color: var(--text);
    text-decoration: none;
}

body .fx-footer-brand .brand-mark {
    flex: 0 0 58px;
    width: 58px;
    height: 58px;
    display: grid;
    place-items: center;
    border-radius: 15px;
    color: #fff;
    font-weight: 850;
    font-size: 1.05rem;
    background: linear-gradient(145deg, color-mix(in srgb, var(--accent) 92%, #fff), color-mix(in srgb, var(--accent) 74%, #1d4ed8));
    border: 1px solid color-mix(in srgb, var(--accent) 55%, rgba(255,255,255,.26));
    box-shadow: 0 14px 32px color-mix(in srgb, var(--accent) 24%, transparent), inset 0 1px 0 rgba(255,255,255,.2);
}

body .fx-footer-brand-copy {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

body .fx-footer-brand-copy strong {
    color: var(--text);
    font-size: 1.14rem;
    line-height: 1.15;
}

body .fx-footer-brand-copy small {
    max-width: 360px;
    color: var(--muted);
    font-size: .86rem;
    line-height: 1.45;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

body .fx-footer-social {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
}

body .fx-footer-social > a,
body .fx-footer-social > span {
    width: 46px;
    height: 46px;
    display: inline-grid;
    place-items: center;
    border-radius: 13px;
    color: color-mix(in srgb, var(--text) 78%, var(--muted));
    text-decoration: none;
    background: color-mix(in srgb, var(--card-2) 68%, transparent);
    border: 1px solid color-mix(in srgb, var(--line) 86%, transparent);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.035), 0 9px 22px rgba(2,8,23,.12);
    transition: color .18s ease, border-color .18s ease, background .18s ease, transform .18s ease;
}

body .fx-footer-social > a:hover,
body .fx-footer-social > a:focus-visible {
    color: #fff;
    border-color: color-mix(in srgb, var(--accent) 52%, var(--line));
    background: color-mix(in srgb, var(--accent) 20%, var(--card-2));
    transform: translateY(-2px);
}

body .fx-footer-social > span.is-disabled {
    opacity: .55;
    cursor: not-allowed;
}

body .fx-footer-social .forumx-icon {
    width: 21px;
    height: 21px;
}

body .fx-footer-social b {
    font-size: 1.25rem;
    line-height: 1;
}

body .fx-footer-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

body .fx-footer-card,
body .fx-footer-quick,
body .fx-footer-bottom {
    border: 1px solid color-mix(in srgb, var(--line) 88%, transparent);
    background: color-mix(in srgb, var(--card) 76%, transparent);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.025), 0 12px 30px rgba(2,8,23,.10);
}

body .fx-footer-card {
    min-width: 0;
    padding: 16px;
    border-radius: 16px;
}

body .fx-footer-card h2,
body .fx-footer-quick h2 {
    margin: 0 0 13px;
    display: flex;
    align-items: center;
    gap: 9px;
    color: var(--text);
    font-size: 1rem;
    line-height: 1.2;
}

body .fx-footer-card h2 > .forumx-icon,
body .fx-footer-quick h2 > .forumx-icon {
    width: 22px;
    height: 22px;
    color: var(--accent);
}

body .fx-footer-card nav {
    display: grid;
    gap: 2px;
}

body .fx-footer-card nav > a {
    min-height: 48px;
    display: grid;
    grid-template-columns: 28px minmax(0, 1fr) 18px;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border-radius: 11px;
    color: color-mix(in srgb, var(--text) 78%, var(--muted));
    text-decoration: none;
    border: 1px solid color-mix(in srgb, var(--line) 76%, transparent);
    background: color-mix(in srgb, var(--card-2) 42%, transparent);
    transition: color .17s ease, border-color .17s ease, background .17s ease, transform .17s ease;
}

body .fx-footer-card nav > a:hover,
body .fx-footer-card nav > a:focus-visible {
    color: var(--text);
    border-color: color-mix(in srgb, var(--accent) 38%, var(--line));
    background: color-mix(in srgb, var(--accent) 8%, var(--card-2));
    transform: translateX(2px);
}

body .fx-footer-card nav > a > .forumx-icon:last-child {
    width: 16px;
    height: 16px;
    color: var(--muted);
}

body .fx-footer-link-icon {
    width: 28px;
    height: 28px;
    display: inline-grid;
    place-items: center;
    color: color-mix(in srgb, var(--accent) 70%, var(--muted));
}

body .fx-footer-link-icon .forumx-icon {
    width: 18px;
    height: 18px;
}

body .fx-footer-quick {
    margin-top: 14px;
    padding: 16px;
    border-radius: 16px;
}

body .fx-footer-quick nav {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
}

body .fx-footer-quick nav > a {
    min-width: 0;
    min-height: 46px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 9px 12px;
    border-radius: 11px;
    color: color-mix(in srgb, var(--text) 78%, var(--muted));
    text-decoration: none;
    border: 1px solid color-mix(in srgb, var(--line) 78%, transparent);
    background: color-mix(in srgb, var(--card-2) 42%, transparent);
    transition: color .17s ease, border-color .17s ease, background .17s ease, transform .17s ease;
}

body .fx-footer-quick nav > a:hover,
body .fx-footer-quick nav > a:focus-visible {
    color: var(--text);
    border-color: color-mix(in srgb, var(--accent) 38%, var(--line));
    background: color-mix(in srgb, var(--accent) 8%, var(--card-2));
    transform: translateY(-1px);
}

body .fx-footer-quick nav .forumx-icon {
    flex: 0 0 18px;
    width: 18px;
    height: 18px;
}

body .fx-footer-bottom {
    margin-top: 14px;
    min-height: 74px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 15px 16px;
    border-radius: 16px;
}

body .fx-footer-bottom > div {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
    color: var(--muted);
    font-size: .78rem;
}

body .fx-footer-bottom .footer-version {
    display: inline-flex;
    align-items: center;
    gap: 7px;
}

body .fx-footer-bottom .footer-version i {
    width: 9px;
    height: 9px;
    display: inline-block;
    border-radius: 50%;
    background: #22c55e;
    box-shadow: 0 0 0 5px rgba(34,197,94,.10), 0 0 16px rgba(34,197,94,.38);
}

body .fx-footer-top {
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    color: var(--text);
    text-decoration: none;
    border: 1px solid color-mix(in srgb, var(--line) 82%, transparent);
    background: color-mix(in srgb, var(--card-2) 68%, transparent);
    transition: border-color .17s ease, background .17s ease, transform .17s ease;
}

body .fx-footer-top:hover,
body .fx-footer-top:focus-visible {
    border-color: color-mix(in srgb, var(--accent) 42%, var(--line));
    background: color-mix(in srgb, var(--accent) 10%, var(--card-2));
    transform: translateY(-2px);
}

body .fx-footer-top .forumx-icon {
    width: 19px;
    height: 19px;
    transform: rotate(-90deg);
}

@media (max-width: 780px) {
    body .site-footer.fx-footer {
        margin-top: 44px;
    }

    body .fx-footer-shell {
        padding-top: 25px;
    }

    body .fx-footer-head {
        gap: 14px;
        margin-bottom: 18px;
    }

    body .fx-footer-brand .brand-mark {
        flex-basis: 50px;
        width: 50px;
        height: 50px;
        border-radius: 13px;
    }

    body .fx-footer-social > a,
    body .fx-footer-social > span {
        width: 42px;
        height: 42px;
        border-radius: 12px;
    }

    body .fx-footer-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    body .fx-footer-card,
    body .fx-footer-quick {
        padding: 14px;
        border-radius: 14px;
    }

    body .fx-footer-quick nav {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
    }

    body .fx-footer-bottom {
        border-radius: 14px;
    }
}

@media (max-width: 480px) {
    body .site-footer.fx-footer {
        padding-bottom: calc(94px + env(safe-area-inset-bottom));
    }

    body .fx-footer-head {
        align-items: flex-start;
    }

    body .fx-footer-brand {
        gap: 11px;
    }

    body .fx-footer-brand .brand-mark {
        flex-basis: 46px;
        width: 46px;
        height: 46px;
        font-size: .9rem;
    }

    body .fx-footer-brand-copy strong {
        font-size: 1rem;
    }

    body .fx-footer-brand-copy small {
        max-width: 175px;
        font-size: .76rem;
    }

    body .fx-footer-social {
        gap: 7px;
    }

    body .fx-footer-social > a,
    body .fx-footer-social > span {
        width: 38px;
        height: 38px;
        border-radius: 11px;
    }

    body .fx-footer-social .forumx-icon {
        width: 18px;
        height: 18px;
    }

    body .fx-footer-card nav > a {
        min-height: 45px;
        padding: 7px 8px;
        font-size: .87rem;
    }

    body .fx-footer-quick nav > a {
        min-height: 43px;
        padding: 8px;
        font-size: .82rem;
    }

    body .fx-footer-bottom {
        min-height: 68px;
        padding: 13px;
    }

    body .fx-footer-bottom > div {
        font-size: .7rem;
    }

    body .fx-footer-top {
        flex-basis: 40px;
        width: 40px;
        height: 40px;
    }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    body .fx-footer-social > a,
    body .fx-footer-card nav > a,
    body .fx-footer-quick nav > a,
    body .fx-footer-top { transition: none; }
}

/* Footer manager + extended social buttons */
body .fx-footer-social {
    flex-wrap: wrap;
    max-width: min(100%, 460px);
}

body .fx-footer-social-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.2em;
    font-size: .86rem;
    font-weight: 800;
    letter-spacing: -.02em;
    line-height: 1;
}

body .fx-footer-social-x { font-size: 1.22rem; }
body .fx-footer-social-facebook { font-size: 1.2rem; font-family: Arial, sans-serif; }
body .fx-footer-social-instagram { font-size: 1.3rem; }
body .fx-footer-social-youtube,
body .fx-footer-social-telegram { font-size: 1.05rem; }
body .fx-footer-social-linkedin { font-size: .78rem; text-transform: lowercase; }

.fx-footer-admin-form {
    display: grid;
    gap: 16px;
}

.fx-footer-admin-row {
    display: grid;
    gap: 12px;
    padding: 15px 0;
    border-top: 1px solid color-mix(in srgb, var(--line) 78%, transparent);
}

.fx-footer-admin-row:first-of-type {
    border-top: 0;
    padding-top: 4px;
}

.fx-footer-admin-row > strong {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    color: var(--text);
}

.fx-footer-admin-social-row .fx-footer-social-mark,
.fx-footer-admin-social-row .forumx-icon {
    width: 26px;
    height: 26px;
    display: inline-grid;
    place-items: center;
    border-radius: 8px;
    color: var(--accent);
    background: color-mix(in srgb, var(--accent) 10%, transparent);
}

@media (max-width: 720px) {
    body .fx-footer-social {
        max-width: 100%;
        justify-content: flex-start;
    }

    .fx-footer-admin-row .form-grid {
        grid-template-columns: 1fr;
    }
}

/* ForumX footer unified cards + rich page editor v2 */
body .fx-footer-head {
    justify-content: flex-start;
}

body .fx-footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
}

body .fx-footer-card {
    height: 100%;
}

body .fx-footer-card nav:empty::after {
    content: "Bu bölüm için etkin bağlantı yok.";
    display: block;
    padding: 12px;
    border: 1px dashed color-mix(in srgb, var(--line) 82%, transparent);
    border-radius: 11px;
    color: var(--muted);
    font-size: .82rem;
}

body .fx-footer-social-link-icon {
    border-radius: 8px;
    background: color-mix(in srgb, var(--accent) 10%, transparent);
}

body .fx-footer-social-link-icon .fx-footer-social-mark,
body .fx-footer-social-link-icon .forumx-icon {
    width: 20px;
    height: 20px;
    display: inline-grid;
    place-items: center;
    color: color-mix(in srgb, var(--accent) 78%, var(--text));
}

body .fx-footer-bottom {
    margin-top: 14px;
}

/* Footer-linked content pages */
.footer-content-page .main-content,
.footer-content-page main.container {
    min-width: 0;
}

.fx-footer-page-shell {
    width: min(100%, 980px);
    margin: 0 auto;
    display: grid;
    gap: 16px;
}

.fx-footer-page-hero {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px;
}

.fx-footer-page-hero > div {
    min-width: 0;
}

.fx-footer-page-hero h1 {
    margin: 3px 0 6px;
    font-size: clamp(1.55rem, 4vw, 2.35rem);
}

.fx-footer-page-hero p {
    margin: 0;
    color: var(--muted);
}

.fx-footer-page-icon {
    flex: 0 0 54px;
    width: 54px;
    height: 54px;
    display: grid;
    place-items: center;
    border-radius: 15px;
    color: #fff;
    background: linear-gradient(145deg, color-mix(in srgb, var(--accent) 88%, #fff), color-mix(in srgb, var(--accent) 72%, #1d4ed8));
    border: 1px solid color-mix(in srgb, var(--accent) 58%, rgba(255,255,255,.26));
    box-shadow: 0 14px 30px color-mix(in srgb, var(--accent) 20%, transparent);
}

.fx-footer-page-icon .forumx-icon {
    width: 26px;
    height: 26px;
}

.fx-footer-page-card {
    max-width: none;
    margin: 0;
    padding: clamp(18px, 4vw, 34px);
}

.fx-footer-page-card .post-body {
    font-size: 1rem;
    line-height: 1.8;
}

/* Unified footer administration */
.fx-footer-admin-form,
.fx-footer-admin-page-list {
    width: 100%;
    max-width: none;
    min-width: 0;
    display: grid;
    justify-items: stretch;
    align-items: stretch;
    gap: 18px;
}

.fx-footer-admin-section,
.fx-footer-admin-page-card,
.fx-footer-admin-pages-intro,
.fx-footer-admin-savebar {
    width: 100%;
    max-width: none;
    min-width: 0;
    margin-inline: 0;
    justify-self: stretch;
}

.fx-footer-admin-section,
.fx-footer-admin-page-card,
.fx-footer-admin-pages-intro {
    overflow: hidden;
}

.fx-footer-admin-card-head,
.fx-footer-admin-item-head {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.fx-footer-admin-card-head {
    margin-bottom: 16px;
}

.fx-footer-admin-card-head > div,
.fx-footer-admin-item-head > div {
    min-width: 0;
    flex: 1 1 auto;
}

.fx-footer-admin-card-head small,
.fx-footer-admin-item-head small {
    display: block;
    margin-bottom: 3px;
    color: var(--muted);
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.fx-footer-admin-card-head h2,
.fx-footer-admin-card-head p,
.fx-footer-admin-item-head strong {
    margin: 0;
}

.fx-footer-admin-card-head h2 {
    font-size: 1.08rem;
}

.fx-footer-admin-card-head p {
    margin-top: 5px;
    color: var(--muted);
    font-size: .86rem;
    line-height: 1.5;
}

.fx-footer-admin-card-icon,
.fx-footer-admin-item-icon {
    flex: 0 0 auto;
    display: inline-grid;
    place-items: center;
    color: var(--accent);
    background: color-mix(in srgb, var(--accent) 11%, transparent);
    border: 1px solid color-mix(in srgb, var(--accent) 26%, var(--line));
}

.fx-footer-admin-card-icon {
    width: 44px;
    height: 44px;
    border-radius: 13px;
}

.fx-footer-admin-item-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
}

.fx-footer-admin-card-icon .forumx-icon {
    width: 22px;
    height: 22px;
}

.fx-footer-admin-item-icon .forumx-icon {
    width: 19px;
    height: 19px;
}

.fx-footer-admin-item-icon .fx-footer-social-mark {
    min-width: 20px;
    color: var(--accent);
}

.fx-footer-admin-items {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.fx-footer-admin-item {
    min-width: 0;
    display: grid;
    align-content: start;
    gap: 13px;
    padding: 15px;
    border-radius: 14px;
    border: 1px solid color-mix(in srgb, var(--line) 88%, transparent);
    background: color-mix(in srgb, var(--card-2) 54%, transparent);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.025);
}

.fx-footer-admin-item .form-grid {
    grid-template-columns: 1fr;
    gap: 10px;
}

.fx-footer-admin-item textarea {
    min-height: 92px;
    resize: vertical;
}

.fx-footer-admin-item-options {
    margin-top: auto;
    padding-top: 2px;
}

.fx-footer-admin-toggle {
    margin-top: 14px;
    padding: 13px 14px;
    border-radius: 12px;
    border: 1px solid color-mix(in srgb, var(--line) 84%, transparent);
    background: color-mix(in srgb, var(--card-2) 48%, transparent);
}

.fx-footer-admin-savebar {
    position: sticky;
    bottom: 12px;
    z-index: 6;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 14px 16px;
    border-color: color-mix(in srgb, var(--accent) 34%, var(--line));
    background: color-mix(in srgb, var(--card) 94%, #081421);
    box-shadow: 0 18px 45px rgba(2,8,23,.28), inset 0 1px 0 rgba(255,255,255,.04);
    backdrop-filter: blur(14px);
}

.fx-footer-admin-savebar > div {
    min-width: 0;
    display: grid;
    gap: 3px;
}

.fx-footer-admin-savebar span {
    color: var(--muted);
    font-size: .8rem;
}

.fx-footer-admin-page-card.is-new {
    border-color: color-mix(in srgb, var(--accent) 30%, var(--line));
}

.fx-footer-page-editor {
    display: grid;
    gap: 8px;
    margin-top: 14px;
}

.fx-footer-page-editor > textarea[data-editor] {
    min-height: 220px;
}

.fx-footer-page-editor .forumx-quill-shell {
    min-width: 0;
    width: 100%;
}

.fx-footer-page-editor .forumx-quill-frame .ql-editor {
    min-height: 240px;
}

.fx-footer-admin-page-card .button-row {
    margin-top: 14px;
}

@media (max-width: 760px) {
    .fx-footer-admin-items {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 780px) {
    body .fx-footer-grid {
        grid-template-columns: 1fr;
    }

    .fx-footer-page-hero {
        align-items: flex-start;
        padding: 17px;
    }

    .fx-footer-admin-savebar {
        position: static;
        align-items: stretch;
        flex-direction: column;
    }

    .fx-footer-admin-savebar .button {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 520px) {
    .fx-footer-page-hero {
        gap: 12px;
    }

    .fx-footer-page-icon {
        flex-basis: 46px;
        width: 46px;
        height: 46px;
        border-radius: 13px;
    }

    .fx-footer-page-icon .forumx-icon {
        width: 22px;
        height: 22px;
    }

    .fx-footer-admin-card-head,
    .fx-footer-admin-item-head {
        align-items: flex-start;
    }

    .fx-footer-admin-card-head .status-chip,
    .fx-footer-admin-item-head .status-chip {
        margin-left: auto;
    }

    .fx-footer-admin-item {
        padding: 13px;
        border-radius: 12px;
    }

    .fx-footer-page-editor .forumx-quill-frame .ql-editor {
        min-height: 210px;
    }
}
