.tips-page,
.tip-detail,
.tips-admin-page,
.tips-editor-page {
    display:grid;
    gap:22px;
}

.tips-hero {
    display:grid;
    grid-template-columns:minmax(0,1.3fr) minmax(300px,.7fr);
    gap:28px;
    align-items:end;
    padding:30px;
    border:1px solid var(--line);
    border-radius:20px;
    background:
        radial-gradient(circle at top right, rgba(29,78,216,.13), transparent 36%),
        var(--surface);
    box-shadow:0 12px 32px rgba(15,23,42,.07);
}

.tips-hero h1,
.tip-detail-head h1 {
    margin:.35rem 0 .65rem;
    font-size:clamp(2rem,4vw,3.25rem);
    line-height:1.04;
}

.tips-hero p,
.tip-detail-summary {
    margin:0;
    color:var(--muted);
    font-size:1.08rem;
    line-height:1.7;
}

.tips-eyebrow {
    display:block;
    color:var(--blue);
    font-size:.76rem;
    font-weight:900;
    letter-spacing:.14em;
}

.tips-search {
    display:grid;
    gap:9px;
    padding:18px;
    border:1px solid var(--line);
    border-radius:14px;
    background:rgba(255,255,255,.76);
}

.tips-search-row {
    display:grid;
    grid-template-columns:1fr auto;
    gap:8px;
}

.tips-clear-search,
.tips-read-more,
.tips-back {
    color:var(--blue);
    font-weight:800;
    text-decoration:none;
}

.tips-feed,
.tips-admin-list {
    display:grid;
    gap:16px;
}

.tips-card {
    display:grid;
    grid-template-columns:minmax(0,1fr) 250px;
    min-height:210px;
    overflow:hidden;
    border:1px solid var(--line);
    border-radius:17px;
    background:var(--surface);
    box-shadow:0 4px 16px rgba(15,23,42,.05);
}

.tips-card-copy {
    display:flex;
    flex-direction:column;
    align-items:flex-start;
    padding:24px;
}

.tips-card h2 {
    margin:.45rem 0 .55rem;
    font-size:1.45rem;
}

.tips-card h2 a {
    text-decoration:none;
}

.tips-card h2 a:hover,
.tips-read-more:hover,
.tips-back:hover {
    text-decoration:underline;
}

.tips-summary {
    margin:0 0 16px;
    color:var(--muted);
    line-height:1.65;
}

.tips-meta {
    display:flex;
    gap:10px;
    align-items:center;
    flex-wrap:wrap;
    color:var(--muted);
    font-size:.78rem;
    font-weight:800;
    letter-spacing:.04em;
    text-transform:uppercase;
}

.tips-meta > * + *::before {
    content:"•";
    margin-right:10px;
    color:#94a3b8;
}

.tips-tags {
    display:flex;
    gap:7px;
    flex-wrap:wrap;
    margin:0 0 18px;
}

.tips-tags span {
    padding:5px 9px;
    border-radius:999px;
    background:#eef2ff;
    color:#3730a3;
    font-size:.76rem;
    font-weight:800;
}

.tips-read-more {
    margin-top:auto;
}

.tips-card-image {
    display:block;
    min-height:210px;
    background:#e2e8f0;
}

.tips-card-image img,
.tip-detail-image img {
    width:100%;
    height:100%;
    object-fit:cover;
    display:block;
}

.tips-empty {
    text-align:center;
    padding:36px;
}

.tip-detail {
    max-width:900px;
    margin:0 auto;
}

.tip-detail-head {
    display:grid;
    gap:12px;
    padding-top:6px;
}

.tip-detail-image {
    overflow:hidden;
    max-height:480px;
    border-radius:18px;
    border:1px solid var(--line);
    background:#e2e8f0;
}

.tip-detail-image img {
    max-height:480px;
}

.tip-body-copy {
    padding:26px;
    border:1px solid var(--line);
    border-radius:16px;
    background:var(--surface);
    white-space:pre-line;
    font-size:1.03rem;
    line-height:1.78;
}

.tip-source {
    display:grid;
    gap:10px;
}

.tip-source p {
    margin:0;
    color:var(--muted);
}

.tip-source .primary {
    justify-self:start;
}

.tips-admin-note {
    display:flex;
    gap:8px 12px;
    flex-wrap:wrap;
    align-items:center;
}

.tips-admin-note span {
    color:var(--muted);
}

.tips-admin-row {
    display:grid;
    grid-template-columns:minmax(0,1fr) 120px auto;
    gap:18px;
    align-items:center;
}

.tips-admin-row h2 {
    margin:.4rem 0;
}

.tips-admin-row p {
    margin:.35rem 0 .6rem;
    color:var(--muted);
}

.tips-admin-thumb {
    width:120px;
    height:86px;
    object-fit:cover;
    border-radius:10px;
    border:1px solid var(--line);
}

.tips-admin-actions {
    display:flex;
    align-items:center;
    justify-content:flex-end;
    gap:8px;
    flex-wrap:wrap;
}

.tips-admin-actions form {
    margin:0;
}

.tips-status {
    padding:4px 8px;
    border-radius:999px;
}

.tips-status.is-published {
    background:#dcfce7;
    color:#166534;
}

.tips-status.is-draft {
    background:#f1f5f9;
    color:#475569;
}

.tips-delete {
    color:#991b1b;
    background:#fee2e2;
}

.tips-editor {
    display:grid;
    gap:20px;
}

.tips-editor textarea {
    resize:vertical;
}

.tips-editor-grid {
    align-items:start;
}

.tips-editor-preview {
    display:grid;
    gap:8px;
    max-width:360px;
}

.tips-editor-preview img {
    width:100%;
    max-height:220px;
    object-fit:cover;
    border-radius:12px;
    border:1px solid var(--line);
}

.tips-publish-check {
    display:flex;
    align-items:flex-start;
    gap:11px;
    padding:14px;
    border:1px solid var(--line);
    border-radius:12px;
    background:#f8fafc;
}

.tips-publish-check input {
    width:auto;
    margin-top:4px;
}

.tips-publish-check span {
    display:grid;
    gap:3px;
}

.tips-publish-check small {
    color:var(--muted);
    font-weight:500;
}

.tips-editor-actions {
    display:flex;
    gap:10px;
    flex-wrap:wrap;
}

[data-theme="dark"] .tips-search,
[data-theme="dark"] .tips-publish-check {
    background:rgba(15,23,42,.45);
}

[data-theme="dark"] .tips-tags span {
    background:#312e81;
    color:#e0e7ff;
}

@media (max-width:850px) {
    .tips-hero,
    .tips-card,
    .tips-admin-row {
        grid-template-columns:1fr;
    }

    .tips-card-image {
        min-height:190px;
        order:-1;
    }

    .tips-admin-thumb {
        width:100%;
        height:170px;
    }

    .tips-admin-actions {
        justify-content:flex-start;
    }
}

@media (max-width:560px) {
    .tips-hero {
        padding:20px;
    }

    .tips-search-row {
        grid-template-columns:1fr;
    }

    .tips-card-copy,
    .tip-body-copy {
        padding:20px;
    }
}
