:root {
    --solar-green: #0f5132;
    --solar-green-dark: #093b25;
    --solar-lime: #a9db4f;
    --solar-yellow: #ffc107;
    --solar-bg: #f4f7f5;
}

html { scroll-behavior: smooth; }
body { background: var(--solar-bg); color: #17211b; min-height: 100vh; }
.solar-navbar { background: linear-gradient(110deg, var(--solar-green-dark), var(--solar-green)); }
.brand-mark { display: inline-grid; place-items: center; width: 2rem; height: 2rem; color: var(--solar-yellow); font-size: 1.5rem; }
.hero-solar { background: radial-gradient(circle at 90% 10%, rgba(255,193,7,.35), transparent 35%), linear-gradient(135deg, #093b25, #14633f); color: white; }
.hero-solar::after { content: ''; position: absolute; width: 300px; height: 300px; border: 1px solid rgba(255,255,255,.12); border-radius: 50%; right: -120px; bottom: -180px; }
.glass-card { background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.18); border-radius: 1rem; backdrop-filter: blur(8px); }
.stat-number { font-size: 1.6rem; font-weight: 800; }
.forum-list { background: white; }
.forum-row { padding: 1.15rem; border-bottom: 1px solid #e8ece9; transition: background .15s ease, transform .15s ease; }
.forum-row:last-child { border-bottom: 0; }
.forum-row:hover { background: #f8fbf9; transform: translateX(2px); }
.forum-icon { flex: 0 0 auto; width: 2.75rem; height: 2.75rem; border-radius: .85rem; display: grid; place-items: center; background: #e7f4eb; color: var(--solar-green); font-size: 1.35rem; }
.min-w-0 { min-width: 0; }
.recent-card { top: 5.5rem; }
.last-no-border:last-child { border-bottom: 0 !important; padding-bottom: 0 !important; }
.auth-shell { max-width: 560px; }
.auth-icon { width: 4rem; height: 4rem; display: grid; place-items: center; margin: auto; border-radius: 1.25rem; background: #e7f4eb; color: var(--solar-green); font-size: 2rem; }
.btn-solar { --bs-btn-color: #fff; --bs-btn-bg: var(--solar-green); --bs-btn-border-color: var(--solar-green); --bs-btn-hover-color: #fff; --bs-btn-hover-bg: var(--solar-green-dark); --bs-btn-hover-border-color: var(--solar-green-dark); }
.topic-state { width: 2rem; text-align: center; }
.post-author { background: #f8faf8; border-right: 1px solid #edf0ee; }
.avatar-circle, .profile-avatar { display: grid; place-items: center; border-radius: 50%; background: linear-gradient(135deg, var(--solar-green), #1c8154); color: white; font-weight: 800; }
.avatar-circle { width: 3.25rem; height: 3.25rem; font-size: 1.35rem; }
.profile-avatar { width: 6rem; height: 6rem; font-size: 2.4rem; }
.post-header { background: #fbfcfb; border-bottom: 1px solid #edf0ee; }
.post-body { min-height: 120px; line-height: 1.75; overflow-wrap: anywhere; }
.post-signature { border-top: 1px dashed #dfe5e1; background: #fbfcfb; }
.editor { line-height: 1.6; resize: vertical; }
.admin-action { transition: transform .15s ease, box-shadow .15s ease; }
.admin-action:hover { transform: translateY(-2px); }
.site-footer { background: #0b2d1e; color: rgba(255,255,255,.72); }
.table > :not(caption) > * > * { padding: 1rem; }

@media (max-width: 767.98px) {
    .post-author { border-right: 0; border-bottom: 1px solid #edf0ee; }
    .hero-solar { padding: 1.5rem !important; }
}

/* v0.2 Community */
.post-card { scroll-margin-top: 5.5rem; transition: box-shadow .35s ease, background-color .35s ease, transform .35s ease; }
.post-card.post-highlight { background-color: rgba(255, 193, 7, .10); box-shadow: 0 0 0 .18rem rgba(255,193,7,.32), 0 .75rem 1.75rem rgba(0,0,0,.12) !important; }
.post-card.post-highlight .post-author,
.post-card.post-highlight .post-meta,
.post-card.post-highlight .post-content { background-color: rgba(255, 248, 224, .72); transition: background-color .35s ease; }
@media (prefers-reduced-motion: reduce) {
    .post-card,
    .post-card.post-highlight .post-author,
    .post-card.post-highlight .post-meta,
    .post-card.post-highlight .post-content { transition: none; }
}
.post-author { background: linear-gradient(180deg, rgba(15,81,50,.08), rgba(15,81,50,.02)); border-right: 1px solid rgba(0,0,0,.06); }
.avatar-circle { width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; background: #0f5132; color: #fff; font-size: 1.25rem; font-weight: 800; box-shadow: inset 0 0 0 3px rgba(255,255,255,.18); }
.avatar-large { width: 90px; height: 90px; font-size: 2rem; }
.post-body { line-height: 1.75; overflow-wrap: anywhere; }
.post-signature { opacity: .85; }
.attachments-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: .75rem; }
.attachment-image { display: block; border-radius: .75rem; overflow: hidden; border: 1px solid rgba(0,0,0,.1); background: #f5f5f5; }
.attachment-image img { display: block; width: 100%; height: 180px; object-fit: cover; transition: transform .2s ease; }
.attachment-image:hover img { transform: scale(1.02); }
.attachment-file { display: flex; align-items: center; gap: .75rem; padding: .9rem 1rem; border: 1px solid rgba(0,0,0,.1); border-radius: .75rem; text-decoration: none; color: inherit; background: var(--bs-tertiary-bg); }
.attachment-file small { display: block; color: var(--bs-secondary-color); }
.report-details { position: relative; }
.report-details summary { list-style: none; }
.report-details summary::-webkit-details-marker { display: none; }
.report-popover { position: absolute; z-index: 20; right: 0; bottom: 2.25rem; width: min(320px, 82vw); padding: 1rem; border-radius: .75rem; background: var(--bs-body-bg); border: 1px solid rgba(0,0,0,.12); }
.notification-unread { background: rgba(255,193,7,.08); }
.notification-dot { width: .65rem; height: .65rem; border-radius: 50%; background: #ffc107; flex: 0 0 auto; }
.notification-unread .notification-dot { box-shadow: 0 0 0 .25rem rgba(255,193,7,.18); }
.profile-stat { padding: .75rem .35rem; border-radius: .75rem; background: var(--bs-tertiary-bg); }
.profile-stat strong, .profile-stat small { display: block; }
.profile-stat strong { font-size: 1.2rem; }
.report-open { border-left: .3rem solid #dc3545 !important; }
.admin-action { color: inherit; transition: transform .2s ease, box-shadow .2s ease; }
.admin-action:hover { transform: translateY(-2px); box-shadow: 0 .75rem 1.5rem rgba(0,0,0,.12) !important; }
.page-link { color: #0f5132; }
.active > .page-link { background-color: #0f5132; border-color: #0f5132; }

@media (max-width: 767.98px) {
    .post-author { border-right: 0; border-bottom: 1px solid rgba(0,0,0,.06); }
    .report-popover { position: fixed; left: 1rem; right: 1rem; bottom: 1rem; width: auto; }
}
.likers-details { position: relative; }
.likers-details summary { list-style: none; }
.likers-details summary::-webkit-details-marker { display: none; }
.likers-popover { position: absolute; z-index: 15; left: 0; bottom: 2.25rem; min-width: 180px; max-width: 280px; padding: .75rem; border-radius: .75rem; background: var(--bs-body-bg); border: 1px solid rgba(0,0,0,.12); display: flex; flex-direction: column; gap: .35rem; }
.likers-popover a { text-decoration: none; font-size: .875rem; }

/* v0.3 Search, SEO and profiles */
.nav-search { width: min(230px, 100%); }
.search-hero { background: radial-gradient(circle at 95% 0, rgba(255,193,7,.22), transparent 36%), var(--bs-body-bg); }
.search-result { transition: transform .18s ease, box-shadow .18s ease; }
.search-result:hover { transform: translateY(-2px); box-shadow: 0 .8rem 1.8rem rgba(0,0,0,.1) !important; }
.search-result .small a { position: relative; z-index: 2; }
.profile-avatar-image { width: 90px; height: 90px; border-radius: 50%; object-fit: cover; border: 3px solid rgba(15,81,50,.16); box-shadow: 0 .35rem 1rem rgba(0,0,0,.12); display: block; }
.post-avatar-image { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; border: 2px solid rgba(255,255,255,.8); box-shadow: 0 .25rem .75rem rgba(0,0,0,.12); display: block; }
.breadcrumb { --bs-breadcrumb-divider-color: rgba(0,0,0,.35); }

@media (max-width: 991.98px) {
    .nav-search { width: 100%; }
}

/* v0.4 Accounts, discussion and moderation */
.bbcode-toolbar { flex-wrap: wrap; }
.forum-quote { margin: 1rem 0; padding: .85rem 1rem; border-left: .3rem solid var(--solar-green); background: rgba(15,81,50,.06); border-radius: 0 .75rem .75rem 0; }
.forum-quote-author { font-weight: 700; margin-bottom: .5rem; color: var(--solar-green); }
.forum-code { padding: 1rem; border-radius: .75rem; background: #111827; color: #e5e7eb; overflow-x: auto; white-space: pre-wrap; }
.mention { font-weight: 700; text-decoration: none; color: var(--solar-green); }
.post-deleted { border: 1px dashed rgba(220,53,69,.45) !important; opacity: .92; }
.post-deleted .post-author { filter: grayscale(.4); }

/* v0.5 Alpha 3 — messages and relationships */
.message-unread { background: rgba(13, 202, 240, .08); border-left: .3rem solid #0dcaf0 !important; }
.private-message { max-width: 88%; }
.private-message-mine { margin-left: auto; border-left: .3rem solid var(--solar-green) !important; background: rgba(15, 81, 50, .035); }
.message-avatar { width: 42px; height: 42px; border-radius: 50%; object-fit: cover; }
.avatar-small { width: 42px; height: 42px; font-size: 1rem; }
.min-w-0 { min-width: 0; }
@media (max-width: 767.98px) {
    .private-message { max-width: 100%; }
}


/* Alpha 6 — reactions, polls και community identity */
.reaction-picker,.reaction-summary{position:relative}.reaction-picker>summary,.reaction-summary>summary{list-style:none;cursor:pointer}.reaction-picker>summary::-webkit-details-marker,.reaction-summary>summary::-webkit-details-marker{display:none}.reaction-menu,.reaction-users{position:absolute;z-index:30;left:0;bottom:calc(100% + .45rem);min-width:210px;background:var(--bs-body-bg);border:1px solid var(--bs-border-color);border-radius:.8rem;padding:.55rem}.reaction-menu form+form{margin-top:.25rem}.reaction-users{display:flex;flex-direction:column;gap:.25rem;min-width:180px}.reaction-users a{text-decoration:none}.reaction-badge{font-size:.82rem}.poll-option{cursor:pointer;transition:border-color .15s ease,background-color .15s ease}.poll-option:hover{border-color:var(--bs-primary)!important;background:var(--bs-tertiary-bg)}.progress{height:.5rem}.professional-review-form{min-width:min(100%,320px)}


/* Alpha 7 — Theme engine & operations */
.theme-switcher { min-width: 132px; border-color: rgba(255,255,255,.35); }
[data-bs-theme="dark"] {
    --solar-bg: #101713;
    --solar-green-dark: #071f15;
    --bs-body-bg: #101713;
    --bs-body-color: #e4ebe6;
    --bs-tertiary-bg: #18231c;
    --bs-secondary-bg: #162019;
    --bs-border-color: #314039;
}
[data-bs-theme="dark"] body { background: #101713; color: #e4ebe6; }
[data-bs-theme="dark"] .forum-list,
[data-bs-theme="dark"] .forum-row,
[data-bs-theme="dark"] .post-header,
[data-bs-theme="dark"] .post-signature,
[data-bs-theme="dark"] .post-author { background-color: var(--bs-body-bg); color: var(--bs-body-color); }
[data-bs-theme="dark"] .forum-row:hover { background: #17231b; }
[data-bs-theme="dark"] .post-author { background: linear-gradient(180deg, rgba(63,177,111,.1), rgba(15,81,50,.02)); }
[data-bs-theme="dark"] .search-hero { background: radial-gradient(circle at 95% 0, rgba(255,193,7,.12), transparent 36%), var(--bs-body-bg); }
.health-score-ring { width: 9rem; height: 9rem; border-radius: 50%; display: grid; place-items: center; background: conic-gradient(var(--solar-green) calc(var(--score) * 1%), var(--bs-secondary-bg) 0); position: relative; }
.health-score-ring::after { content: ''; position: absolute; inset: .8rem; border-radius: 50%; background: var(--bs-body-bg); }
.health-score-ring > div { position: relative; z-index: 1; }
.job-error { max-width: 420px; white-space: normal; overflow-wrap: anywhere; }
.settings-nav { position: sticky; top: 5.5rem; }
.backup-checksum { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .72rem; overflow-wrap: anywhere; }

/* Alpha 8 — Enhanced editor, media library and mobile UX */
.editor-toolbox { position: sticky; top: 5.25rem; z-index: 20; padding: .65rem; border: 1px solid var(--bs-border-color); border-radius: .9rem; background: var(--bs-tertiary-bg); background: color-mix(in srgb, var(--bs-tertiary-bg) 94%, transparent); box-shadow: 0 .35rem 1rem rgba(0,0,0,.055); backdrop-filter: blur(12px); }
.editor-toolbar .btn { min-height: 2.25rem; }
.editor-toolbar .btn-group .btn { min-width: 2.35rem; }
.editor-more-menu { min-width: 210px; }
.editor-template-menu { min-width: 260px; }
.editor-emoji-menu { min-width: 220px; }
.editor-emoji-grid { grid-template-columns: repeat(4, 1fr); gap: .35rem; }
.editor-emoji-grid .btn { font-size: 1.15rem; padding: .35rem; }
.editor-counter { white-space: nowrap; font-variant-numeric: tabular-nums; }
.editor-help { column-gap: 1rem; }
.editor-toolbox + textarea[name="body"] { min-height: 260px; border-radius: .9rem; padding: 1rem; line-height: 1.65; box-shadow: inset 0 1px 2px rgba(0,0,0,.025); }
.visual-editor-source {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
    opacity: 0 !important;
}
.visual-editor-surface {
    min-height: 280px;
    max-height: 720px;
    overflow-y: auto;
    border-radius: .9rem;
    padding: 1rem;
    line-height: 1.6;
    white-space: normal;
    overflow-wrap: anywhere;
    box-shadow: inset 0 1px 2px rgba(0,0,0,.025);
}
.visual-editor-surface:focus {
    border-color: rgba(25, 135, 84, .7);
    box-shadow: 0 0 0 .2rem rgba(25, 135, 84, .12), inset 0 1px 2px rgba(0,0,0,.025);
    outline: 0;
}
.visual-editor-surface:empty::before {
    content: attr(data-placeholder);
    color: var(--bs-secondary-color);
    pointer-events: none;
}
.visual-editor-surface strong { font-weight: 700; }
.visual-editor-surface blockquote {
    margin: .6rem 0;
    padding: .55rem .8rem;
    border-left: 4px solid var(--solar-green);
    background: var(--bs-tertiary-bg);
    border-radius: .35rem;
}
.visual-editor-surface blockquote[data-visual-quote-label]::before {
    content: attr(data-visual-quote-label);
    display: block;
    margin-bottom: .25rem;
    font-size: .78rem;
    font-weight: 700;
    color: var(--bs-secondary-color);
}
.visual-editor-surface ul,
.visual-editor-surface ol { margin: .45rem 0; padding-left: 1.5rem; }
.visual-editor-surface hr { margin: .7rem 0; opacity: .35; }
.visual-editor-block {
    display: block;
    margin: .6rem 0;
    padding: .65rem .8rem;
    border: 1px solid var(--bs-border-color);
    border-radius: .65rem;
    background: var(--bs-tertiary-bg);
}
.visual-editor-block-label { display: block; font-size: .78rem; font-weight: 700; color: var(--bs-secondary-color); }
.visual-editor-block pre { margin: .45rem 0 0; white-space: pre-wrap; }
.visual-editor-image { display: block; max-width: min(100%, 560px); max-height: 320px; margin-top: .5rem; border-radius: .55rem; object-fit: contain; }
.editor-toolbox + textarea[name="body"]:focus { border-color: rgba(15,81,50,.55); box-shadow: 0 0 0 .22rem rgba(15,81,50,.12); }
.editor-drop-active { outline: 3px dashed var(--solar-green); outline-offset: 3px; background: rgba(15,81,50,.06); }
.editor-upload-preview { width: 66px; height: 54px; overflow: hidden; }
.editor-upload-preview img { width: 100%; height: 100%; object-fit: cover; display: block; }
.forum-inline-image-link { display: block; margin: 1rem 0; max-width: 100%; }
.forum-inline-image { display: block; max-width: min(100%, 980px); max-height: 760px; width: auto; height: auto; border-radius: .85rem; border: 1px solid var(--bs-border-color); box-shadow: 0 .5rem 1.4rem rgba(0,0,0,.1); cursor: zoom-in; }
.forum-spoiler { margin: 1rem 0; border: 1px solid var(--bs-border-color); border-radius: .75rem; overflow: hidden; }
.forum-spoiler summary { padding: .75rem 1rem; cursor: pointer; font-weight: 700; background: var(--bs-tertiary-bg); }
.forum-spoiler-body { padding: 1rem; }
.forum-list-bbcode { margin: 1rem 0; padding-left: 1.5rem; }
.forum-bbcode-table { min-width: 420px; margin-bottom: 0; }
.forum-bbcode-table th { background: var(--bs-tertiary-bg); }
.forum-bbcode-rule { margin: .75rem 0; border-color: var(--bs-border-color); opacity: 1; }
.forum-code-wrap { margin: 1rem 0; border-radius: .8rem; overflow: hidden; background: #111827; }
.forum-code-toolbar { display: flex; justify-content: space-between; align-items: center; padding: .45rem .7rem; background: #1f2937; color: #d1d5db; font-size: .78rem; font-weight: 700; }
.forum-code-wrap .forum-code { margin: 0; border-radius: 0; }
.media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 1rem; }
.media-card { min-width: 0; }
.media-thumb { display: block; width: 100%; height: 180px; overflow: hidden; cursor: zoom-in; }
.media-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .2s ease; }
.media-thumb:hover img { transform: scale(1.03); }
.media-picker-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: .75rem; }
.media-picker-item { border: 1px solid var(--bs-border-color); border-radius: .75rem; overflow: hidden; padding: 0; background: var(--bs-body-bg); color: var(--bs-body-color); text-align: left; }
.media-picker-item img { width: 100%; height: 125px; object-fit: cover; display: block; }
.media-picker-item span { display: block; padding: .45rem .6rem; font-size: .75rem; color: var(--bs-secondary-color); }
.image-lightbox { position: fixed; inset: 0; z-index: 1090; display: none; place-items: center; padding: 2rem; background: rgba(0,0,0,.88); }
.image-lightbox.show { display: grid; }
.image-lightbox img { max-width: 96vw; max-height: 92vh; object-fit: contain; border-radius: .75rem; }
.image-lightbox-close { position: fixed; top: 1rem; right: 1.25rem; width: 3rem; height: 3rem; border: 0; border-radius: 50%; background: rgba(255,255,255,.18); color: #fff; font-size: 2rem; line-height: 1; }
.profile-cover { height: 155px; background-position: center; background-size: cover; }
.profile-cover-placeholder { background: radial-gradient(circle at 80% 20%, rgba(255,193,7,.55), transparent 28%), linear-gradient(135deg, var(--solar-green), #198754); }
.profile-card-body { position: relative; }
.profile-card .profile-avatar-image, .profile-card .avatar-large { margin-top: -72px; background: var(--bs-body-bg); }
.profile-cover-preview { display: block; width: 100%; height: 180px; object-fit: cover; border-radius: .85rem; border: 1px solid var(--bs-border-color); background-position: center; background-size: cover; }
.avatar-cropper canvas { width: min(100%, 320px); height: auto; border-radius: 50%; border: 3px solid var(--solar-green); cursor: grab; touch-action: none; background: var(--bs-tertiary-bg); }
.avatar-cropper canvas:active { cursor: grabbing; }
.mobile-reply-button { display: none; position: fixed; right: 1rem; bottom: 1rem; z-index: 1040; border-radius: 999px; box-shadow: 0 .8rem 2rem rgba(0,0,0,.25); }

@media (max-width: 767.98px) {
    .editor-toolbox { position: static; margin-left: -.25rem; margin-right: -.25rem; padding: .55rem; }
    .editor-toolbar { gap: .4rem !important; }
    .editor-toolbar .btn { padding-left: .55rem; padding-right: .55rem; }
    .editor-counter { width: 100%; margin-top: .15rem; text-align: right; }
    .forum-inline-image { width: 100%; max-height: 520px; object-fit: contain; }
    .media-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .65rem; }
    .media-thumb { height: 135px; }
    .mobile-reply-button { display: inline-flex; align-items: center; gap: .4rem; }
    body:has(#reply-form) { padding-bottom: 4.5rem; }
    .post-actions { gap: .35rem !important; }
    .post-actions .btn { padding: .35rem .55rem; }
}

.post-anchor-legacy,
.post-card {
    scroll-margin-top: 6.5rem;
}
.mention-menu {
    position: absolute;
    z-index: 1080;
    left: 0;
    right: 0;
    top: calc(100% + .25rem);
    max-height: 15rem;
    overflow-y: auto;
}
