/*
Theme Name: The Fieldnote
Theme URI: https://example.com/fieldnote
Author: Praveenkumar
Author URI: https://example.com
Description: An editorial journal-style blog theme — paper, ink and gold. Fully dynamic: featured cover story, latest notes grid, archive section, single article layout, category archives and Customizer-editable masthead, pull quote, subscribe box and footer.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: fieldnote
Tags: blog, editorial, magazine, one-column, custom-menu, featured-images
*/

:root {
    --paper: #F6F1E7;
    --paper-deep: #EFE8D8;
    --ink: #1C1A17;
    --ink-soft: #524B41;
    --gold: #A8763A;
    --gold-soft: #C9A76C;
    --terracotta: #A5432B;
    --line: #D8CFBC;
    --white: #FFFDF8;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    background: var(--paper);
    color: var(--ink);
    font-family: 'Poppins', sans-serif !important;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'Montserrat', sans-serif;
}

a {
    color: inherit;
    text-decoration: none !important;
}

img {
    max-width: 100%;
    height: auto;
}

.progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 2px;
    width: 0%;
    background: var(--gold);
    z-index: 999;
    transition: width .1s linear;
}

/* Admin bar offset */
body.admin-bar .progress {
    top: 32px;
}

/* ===== MASTHEAD ===== */
.masthead {
    position: relative;
    padding: 22px 6vw 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--line);
}

.masthead-left {

    font-size: 11px;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--ink-soft);
}

.masthead-title {

    font-weight: 450;
    font-size: clamp(28px, 4vw, 46px);
    letter-spacing: -.01em;
    text-align: center;
}

.masthead-title a {
    color: inherit;
}

.masthead-title em {
    font-style: italic;
    color: var(--terracotta);
    font-weight: 300;
}

.masthead-right {

    font-size: 11px;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--ink-soft);
    text-align: right;
}

@media(max-width:720px) {
    .masthead {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }

    .masthead-right {
        text-align: center;
    }
}

a {
    text-decoration: none;
}

.spine {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    width: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 50;
    pointer-events: none;
}

.logo-trigger img {
    width: 200px;
}

.mfp-content {
    width: 70% !important;
    margin: auto;
    background: white;
    padding: 35px;
    border-radius: 10px;
    position: relative;
}

.spine span {
    writing-mode: vertical-rl;
    transform: rotate(180deg);

    font-size: 10px;
    letter-spacing: .22em;
    text-transform: uppercase;
    color: var(--ink-soft);
    opacity: .55;
}

@media(max-width:900px) {
    .spine {
        display: none;
    }
}

/* ===== NAV STRIP ===== */
.navstrip {
    display: flex;
    gap: 28px;
    justify-content: center;
    padding: 14px 6vw;

    font-size: 12px;
    letter-spacing: .08em;
    text-transform: uppercase;
    border-bottom: 1px solid var(--line);
    flex-wrap: wrap;
}

.navstrip ul {
    display: contents;
    list-style: none;
}

.navstrip li {
    display: inline-flex;
}

.navstrip a {
    color: var(--ink-soft);
    position: relative;
    padding-bottom: 3px;
}

.navstrip a.active,
.navstrip .current-menu-item>a,
.navstrip .current-cat>a {
    color: var(--ink);
}

.navstrip a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0;
    height: 1px;
    background: var(--gold);
    transition: width .3s ease;
}

.navstrip a:hover::after,
.navstrip a.active::after,
.navstrip .current-menu-item>a::after,
.navstrip .current-cat>a::after {
    width: 100%;
}

/* ===== FEATURED ===== */
.featured {
    max-width: 1180px;
    margin: 0 auto;
    padding: 64px 6vw 40px;
    display: grid;
    grid-template-columns: 1.1fr .9fr;
    gap: 56px;
    align-items: center;
}

.featured-eyebrow {

    font-size: 11px;
    letter-spacing: .18em;
    text-transform: uppercase;
    color: var(--terracotta);
    margin-bottom: 18px;
}

.featured h1 {
    font-weight: 450;
    font-size: 30px;
    /* line-height: 1.05; */
    /* letter-spacing: -.015em; */
    margin-bottom: 22px;
}

.featured h1 a {
    color: inherit;
}

.featured h1 a:hover {
    color: var(--terracotta);
}

.featured-dek {
    font-size: 18px;
    line-height: 1.65;
    color: var(--ink-soft);
    max-width: 46ch;
    margin-bottom: 28px;
}

.featured-meta {

    font-size: 12px;
    color: var(--ink-soft);
    display: flex;
    gap: 18px;
    align-items: center;
    letter-spacing: .02em;
}

.featured-meta .dot {
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: var(--ink-soft);
}

.featured-media {
    position: relative;
    /* aspect-ratio: 4/5; */
    border-radius: 2px;
    overflow: hidden;
    background: linear-gradient(160deg, #2b2620, #4a4034);
}

.featured-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 1.2s cubic-bezier(.16, 1, .3, 1);
}

.featured-media:hover img {
    transform: scale(1.05);
}

.featured-folio {
    position: absolute;
    bottom: 16px;
    right: 16px;

    font-size: 11px;
    letter-spacing: .1em;
    color: #F6F1E7;
    background: rgba(28, 26, 23, .55);
    padding: 6px 10px;
    backdrop-filter: blur(4px);
}

@media(max-width:860px) {
    .featured {
        grid-template-columns: 1fr;
        padding-top: 44px;
    }
}

/* ===== SECTION LABEL ===== */
.section-label {
    max-width: 1180px;
    margin: 70px auto 30px;
    padding: 0 6vw;
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 20px;
}

.section-label h2,
.section-label h1 {

    font-weight: 450;
    font-size: 26px;
    letter-spacing: -.01em;
}

.section-label .rule {
    flex: 1;
    height: 1px;
    background: var(--line);
}

.section-label .count {

    font-size: 12px;
    color: var(--ink-soft);
    letter-spacing: .06em;
}

/* ===== ARTICLE GRID ===== */
.grid {
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 6vw 30px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
    /* border-top: 1px solid var(--line); */
}

.grid-inner {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-column: 1 / -1;
}

.card {
    padding: 36px 28px;
    border-right: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    display: flex;
    flex-direction: column;
    gap: 14px;
    cursor: pointer;
    transition: background .3s ease;
    position: relative;
}

.card:nth-child(3n) {
    border-right: none;
}

.card:hover {
    background: var(--paper-deep);
}

.card-link {
    position: absolute;
    inset: 0;
    z-index: 1;
}

.card-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.card-tag {

    font-size: 10.5px;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--gold);
    position: relative;
    z-index: 2;
}

.card-folio {

    font-size: 11px;
    color: var(--ink-soft);
    opacity: .6;
}

.card h3 {

    font-weight: 450;
    font-size: 22px;
    line-height: 1.2;
    letter-spacing: -.01em;
}

.card h3 .u {
    background-image: linear-gradient(var(--gold), var(--gold));
    background-repeat: no-repeat;
    background-position: 0 100%;
    background-size: 0% 1px;
    transition: background-size .4s ease;
}

.card:hover h3 .u {
    background-size: 100% 1px;
}

.card p {
    font-size: 14.5px;
    line-height: 1.65;
    color: var(--ink-soft);
}

.card-foot {

    font-size: 11px;
    color: var(--ink-soft);
    display: flex;
    gap: 10px;
    margin-top: auto;
    padding-top: 6px;
}

@media(max-width:900px) {
    .grid {
        grid-template-columns: 1fr;
    }

    .card {
        border-right: none;
    }
}

/* ===== PULL QUOTE BREAK ===== */
.pullquote {
    max-width: 900px;
    margin: 70px auto;
    padding: 0 6vw;
    text-align: center;
}

.pullquote blockquote {

    font-style: italic;
    font-weight: 300;
    font-size: clamp(22px, 3vw, 32px);
    line-height: 1.5;
    color: var(--ink);
}

.pullquote cite {
    display: block;
    margin-top: 18px;

    font-size: 12px;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--ink-soft);
    font-style: normal;
}

/* ===== SUBSCRIBE ===== */
.subscribe {
    max-width: 1180px;
    margin: 20px auto 90px;
    padding: 0 6vw;
}

.subscribe-inner {
    border: 1px solid var(--ink);
    padding: 56px 6vw;
    text-align: center;
    position: relative;
    background: var(--white);
}

.subscribe-inner::before,
.subscribe-inner::after {
    content: '';
    position: absolute;
    width: 14px;
    height: 14px;
    border: 1px solid var(--gold);
}

.subscribe-inner::before {
    top: -1px;
    left: -1px;
    border-right: none;
    border-bottom: none;
}

.subscribe-inner::after {
    bottom: -1px;
    right: -1px;
    border-left: none;
    border-top: none;
}

.subscribe h2 {

    font-weight: 450;
    font-size: clamp(26px, 3vw, 36px);
    margin-bottom: 14px;
    letter-spacing: -.01em;
}

.subscribe p {
    color: var(--ink-soft);
    font-size: 15px;
    max-width: 44ch;
    margin: 0 auto 30px;
}

.subscribe-form {
    display: flex;
    max-width: 420px;
    margin: 0 auto;
    border-bottom: 1px solid var(--ink);
}

.subscribe-form input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    padding: 12px 4px;

    font-size: 14px;
    color: var(--ink);
}

.subscribe-form input::placeholder {
    color: var(--ink-soft);
}

.subscribe-form button {
    background: none;
    border: none;

    font-size: 12px;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--gold);
    cursor: pointer;
    padding: 12px 4px;
}

.subscribe-form button:hover {
    color: var(--terracotta);
}

/* ===== FOOTER ===== */
.site-footer {
    border-top: 1px solid var(--line);
    padding: 30px 6vw;
    display: flex;
    justify-content: space-between;
    align-items: center;

    font-size: 11px;
    color: var(--ink-soft);
    letter-spacing: .04em;
    flex-wrap: wrap;
    gap: 10px;
}

.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity .8s ease, transform .8s ease;
}

.reveal.in {
    opacity: 1;
    transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }

    html {
        scroll-behavior: auto;
    }
}

/* ===== PAGINATION ===== */
.pagination-wrap {
    max-width: 1180px;
    margin: 10px auto 40px;
    padding: 0 6vw;
    display: flex;
    justify-content: center;
}

.pagination-wrap .nav-links {
    display: flex;
    gap: 14px;
    align-items: center;

    font-size: 12px;
    letter-spacing: .1em;
    text-transform: uppercase;
}

.pagination-wrap .page-numbers {
    color: var(--ink-soft);
    padding: 6px 10px;
    border: 1px solid transparent;
}

.pagination-wrap .page-numbers.current {
    color: var(--ink);
    border-color: var(--gold);
}

.pagination-wrap .page-numbers:hover:not(.current) {
    color: var(--terracotta);
}

/* ===== SINGLE ARTICLE ===== */
.article-hero {
    max-width: 820px;
    margin: 0 auto;
    padding: 64px 6vw 34px;
    text-align: center;
}

.article-hero .featured-eyebrow {
    margin-bottom: 16px;
}

.article-hero .featured-eyebrow a {
    color: inherit;
}

.article-hero .featured-eyebrow a:hover {
    color: var(--gold);
}

.article-hero h1 {

    font-weight: 450;
    font-size: clamp(32px, 4.4vw, 56px);
    line-height: 1.08;
    letter-spacing: -.015em;
    margin-bottom: 20px;
}

.article-hero .article-dek {
    font-size: 18px;
    line-height: 1.65;
    color: var(--ink-soft);
    max-width: 52ch;
    margin: 0 auto 26px;
}

.article-hero .featured-meta {
    justify-content: center;
}

.article-figure {
    max-width: 1080px;
    margin: 14px auto 0;
    padding: 0 6vw;
}

.article-figure img {
    width: 100%;
    aspect-ratio: 16/9;
    object-fit: contain;
    border-radius: 2px;
    display: block;
}

.article-figure figcaption {

    font-size: 11px;
    letter-spacing: .06em;
    color: var(--ink-soft);
    margin-top: 10px;
    text-align: right;
}

.article-body {
    max-width: 90%;
    margin: 48px auto 0;
    padding: 0 6vw;
    font-size: 18px;
    line-height: 1.8;
    color: var(--ink);
}

.article-body>p {
    margin-bottom: 26px;
}

.article-body>p:first-child::first-letter {

    font-weight: 450;
    font-size: 66px;
    line-height: .9;
    float: left;
    padding: 8px 12px 0 0;
    color: var(--terracotta);
}

.article-body h2,
.article-body h3 {

    font-weight: 450;
    letter-spacing: -.01em;
    margin: 44px 0 16px;
    line-height: 1.2;
}

.article-body h2 {
    font-size: 30px;
}

.article-body h3 {
    font-size: 24px;
}

.article-body a {
    color: var(--terracotta);
    background-image: linear-gradient(var(--gold-soft), var(--gold-soft));
    background-repeat: no-repeat;
    background-position: 0 100%;
    background-size: 100% 1px;
}

.article-body blockquote {
    margin: 40px 0;
    padding: 0 0 0 26px;
    border-left: 2px solid var(--gold);

    font-style: italic;
    font-weight: 300;
    font-size: 22px;
    line-height: 1.55;
    color: var(--ink);
}

.article-body ul,
.article-body ol {
    margin: 0 0 26px 22px;
}

.article-body li {
    margin-bottom: 10px;
}

.article-body img {
    border-radius: 2px;
    margin: 10px 0;
}

.article-body figure {
    margin: 34px 0;
}

.article-body figcaption {

    font-size: 11px;
    letter-spacing: .06em;
    color: var(--ink-soft);
    margin-top: 8px;
}

.article-body pre {
    background: var(--paper-deep);
    border: 1px solid var(--line);
    padding: 18px;
    overflow-x: auto;
    font-size: 14px;
    margin-bottom: 26px;
}

.article-body .wp-block-quote cite {
    display: block;
    margin-top: 12px;

    font-size: 12px;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--ink-soft);
    font-style: normal;
}

.article-tags {
    max-width: 700px;
    margin: 40px auto 0;
    padding: 0 6vw;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.article-tags a {

    font-size: 10.5px;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--gold);
    border: 1px solid var(--line);
    padding: 6px 12px;
    transition: all .3s ease;
}

.article-tags a:hover {
    border-color: var(--gold);
    color: var(--terracotta);
}

.article-end {
    max-width: 1160px;
    margin: 46px auto 0;
    padding: 0 6vw;
    text-align: center;
    border-bottom: 1px solid;
    width: 100%;
    padding-bottom: 30px;
    font-size: 12px;
    letter-spacing: .3em;
    color: var(--gold);
}

/* prev / next */
.article-nav {
    max-width: 1080px;
    margin: 70px auto 0;
    padding: 0 6vw;
    display: grid;
    grid-template-columns: 1fr 1fr;
    border-top: 1px solid var(--line);
}

.article-nav a {
    padding: 30px 24px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    transition: background .3s ease;
}

.article-nav a:hover {
    background: var(--paper-deep);
}

.article-nav .nav-label {

    font-size: 10.5px;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: var(--gold);
}

.article-nav .nav-title {

    font-weight: 450;
    font-size: 19px;
    line-height: 1.25;
}

.article-nav .nav-next {
    text-align: right;
    border-left: 1px solid var(--line);
    align-items: flex-end;
}

@media(max-width:720px) {
    .article-nav {
        grid-template-columns: 1fr;
    }

    .article-nav .nav-next {
        border-left: none;
        border-top: 1px solid var(--line);
    }
}

/* ===== COMMENTS (minimal, matching) ===== */
.comments-area {
    max-width: 700px;
    margin: 60px auto 0;
    padding: 0 6vw;
}

.comments-area .comments-title,
.comments-area .comment-reply-title {

    font-weight: 450;
    font-size: 24px;
    margin-bottom: 24px;
}

.comment-list {
    list-style: none;
}

.comment-list .comment {
    border-top: 1px solid var(--line);
    padding: 22px 0;
}

.comment-list .comment-author {

    font-size: 13px;
    font-weight: 600;
}

.comment-list .comment-metadata {

    font-size: 11px;
    color: var(--ink-soft);
    margin: 4px 0 10px;
}

.comment-list .comment-content {
    font-size: 15.5px;
    line-height: 1.7;
}

.comment-list .avatar {
    border-radius: 50%;
    margin-right: 10px;
    vertical-align: middle;
}

.comment-form label {
    display: block;

    font-size: 11px;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--ink-soft);
    margin-bottom: 6px;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
    width: 100%;
    background: var(--white);
    border: 1px solid var(--line);
    padding: 12px;

    font-size: 15px;
    color: var(--ink);
    margin-bottom: 18px;
}

.comment-form input:focus,
.comment-form textarea:focus {
    outline: none;
    border-color: var(--gold);
}

.comment-form .submit {
    background: var(--ink);
    color: var(--paper);
    border: none;

    font-size: 12px;
    letter-spacing: .12em;
    text-transform: uppercase;
    padding: 14px 28px;
    cursor: pointer;
    transition: background .3s ease;
}

.comment-form .submit:hover {
    background: var(--terracotta);
}

/* ===== ARCHIVE / SEARCH / 404 helpers ===== */
.page-intro {
    max-width: 1180px;
    margin: 56px auto 0;
    padding: 0 6vw;
}

.page-intro .featured-eyebrow {
    margin-bottom: 12px;
}

.page-intro h1 {

    font-weight: 450;
    font-size: clamp(30px, 4vw, 48px);
    letter-spacing: -.015em;
    line-height: 1.1;
}

.page-intro .archive-description {
    margin-top: 14px;
    color: var(--ink-soft);
    font-size: 16px;
    max-width: 60ch;
    line-height: 1.65;
}

.no-results {
    max-width: 700px;
    margin: 60px auto 90px;
    padding: 0 6vw;
    text-align: center;
}

.no-results p {
    color: var(--ink-soft);
    margin-bottom: 24px;
}

.search-form-inline {
    display: flex;
    max-width: 420px;
    margin: 0 auto;
    border-bottom: 1px solid var(--ink);
}

.search-form-inline input[type="search"] {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    padding: 12px 4px;

    font-size: 14px;
    color: var(--ink);
}

.search-form-inline button {
    background: none;
    border: none;

    font-size: 12px;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--gold);
    cursor: pointer;
    padding: 12px 4px;
}

/* WP core alignment helpers */
.alignwide {
    max-width: 1080px;
    margin-left: auto;
    margin-right: auto;
}

.alignfull {
    max-width: none;
    width: 100vw;
    margin-left: calc(50% - 50vw);
}

.aligncenter {
    display: block;
    margin-left: auto;
    margin-right: auto;
}

.alignleft {
    float: left;
    margin: 6px 24px 12px 0;
}

.alignright {
    float: right;
    margin: 6px 0 12px 24px;
}

.screen-reader-text {
    border: 0;
    clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px;
    width: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    word-wrap: normal !important;
}