/*!
 * Lakulah Staff Portal Theme – Main Stylesheet
 * Minimal, clean aesthetic inspired by Twenty Twenty-Five.
 * @package Lakulah_Theme
 * @version 1.2.1
 */

/* ── Reset & tokens ───────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --lkt-green:      #379237;
    --lkt-green-dark: #2a7029;
    --lkt-green-bg:   #f0f7f0;
    --lkt-white:      #ffffff;
    --lkt-bg:         #fafafa;
    --lkt-border:     #e2e6ea;
    --lkt-text:       #1a1a2e;
    --lkt-muted:      #6b7280;
    --lkt-radius:     10px;
    --lkt-font:       'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --lkt-font-serif: 'Playfair Display', Georgia, serif;
    --lkt-header-h:   64px;
}

html { font-size: 16px; }

body {
    font-family: var(--lkt-font);
    background: var(--lkt-bg);
    color: var(--lkt-text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a { color: var(--lkt-green); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; display: block; }

/* ── Header ───────────────────────────────────────────── */
.lkt-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--lkt-white);
    border-bottom: 1px solid var(--lkt-border);
    height: var(--lkt-header-h);
    box-shadow: 0 1px 4px rgba(0,0,0,.05);
}
.lkt-header-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
}
.lkt-logo-link { display: flex; align-items: center; flex-shrink: 0; }
.lkt-logo-img  { height: 40px; width: auto; object-fit: contain; }

.lkt-header-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}
.lkt-header-user {
    font-size: .85rem;
    font-weight: 500;
    color: var(--lkt-muted);
}
.lkt-btn-logout {
    display: inline-flex;
    align-items: center;
    padding: .45rem 1.1rem;
    border: 1px solid var(--lkt-border);
    border-radius: 6px;
    font-size: .82rem;
    font-weight: 600;
    color: var(--lkt-muted);
    background: var(--lkt-white);
    transition: border-color .15s, color .15s, background .15s;
    text-decoration: none;
}
.lkt-btn-logout:hover {
    border-color: #dc2626;
    color: #dc2626;
    background: #fff5f5;
    text-decoration: none;
}
.lkt-btn-signin {
    display: inline-flex;
    align-items: center;
    padding: .45rem 1.1rem;
    background: var(--lkt-green);
    color: var(--lkt-white);
    border-radius: 6px;
    font-size: .82rem;
    font-weight: 600;
    transition: background .15s;
    text-decoration: none;
}
.lkt-btn-signin:hover { background: var(--lkt-green-dark); text-decoration: none; }

/* ── Main content area ────────────────────────────────── */
.lkt-main {
    min-height: calc(100vh - var(--lkt-header-h) - 56px);
    padding: 2.5rem 0;
}
.lkt-content-wrap {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Override WP's default .entry-title / .wp-block-post-title injected by theme */
.lkt-main h1.entry-title,
.lkt-main h1.wp-block-post-title,
.lkt-main .page-title {
    display: none;
}

/* ── Footer ───────────────────────────────────────────── */
.lkt-footer {
    border-top: 1px solid var(--lkt-border);
    background: var(--lkt-white);
    height: 56px;
}
.lkt-footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.lkt-footer-copy    { font-size: .78rem; color: var(--lkt-muted); }
.lkt-footer-version { font-size: .72rem; color: #b0b7bf; font-family: 'Courier New', monospace; }

/* ── Full-screen login page ───────────────────────────── */
body.lkt-login-screen {
    background: var(--lkt-green-bg);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}
.lkt-login-outer {
    width: 100%;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
}

/* Expand the plugin's gateway card to fill this properly */
.lkt-login-screen .lk-gateway-wrap {
    width: 100%;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
}
.lkt-login-screen .lk-gateway-card {
    max-width: 640px;
    box-shadow: 0 8px 40px rgba(55,146,55,.12), 0 2px 12px rgba(0,0,0,.06);
    border-color: rgba(55,146,55,.15);
}
.lkt-login-screen .lk-gateway-logo { height: 130px; }

/* ── Articles (index fallback) ────────────────────────── */
.lkt-article { margin-bottom: 2rem; }
.lkt-article-title {
    font-family: var(--lkt-font-serif);
    font-size: 2rem;
    font-weight: 700;
    color: var(--lkt-text);
    margin-bottom: 1rem;
    line-height: 1.2;
}
.lkt-article-body { font-size: .975rem; line-height: 1.75; color: var(--lkt-text); }
.lkt-no-content   { color: var(--lkt-muted); font-size: .9rem; }

/* ── 404 ──────────────────────────────────────────────── */
.lkt-404-wrap { text-align: center; padding: 5rem 2rem; }
.lkt-404-title {
    font-family: var(--lkt-font-serif);
    font-size: 6rem;
    font-weight: 700;
    color: var(--lkt-green);
    line-height: 1;
    margin-bottom: .5rem;
}
.lkt-404-sub { font-size: 1.1rem; color: var(--lkt-muted); margin-bottom: 2rem; }
.lkt-btn-primary {
    display: inline-flex;
    align-items: center;
    padding: .65rem 1.5rem;
    background: var(--lkt-green);
    color: var(--lkt-white);
    border-radius: 8px;
    font-size: .9rem;
    font-weight: 600;
    transition: background .15s;
    text-decoration: none;
}
.lkt-btn-primary:hover { background: var(--lkt-green-dark); text-decoration: none; }

/* ── Suppress Twenty Twenty-Five leftovers (safety net) ─ */
.wp-site-blocks,
.wp-block-template-part { all: unset; display: block; }
body > .wp-site-blocks > header,
body > .wp-site-blocks > footer { display: none; }

/* ── Responsive ───────────────────────────────────────── */
@media (max-width: 640px) {
    .lkt-header-inner { padding: 0 1rem; }
    .lkt-content-wrap  { padding: 0 1rem; }
    .lkt-header-user   { display: none; }
}
