/* =============================================
   UTILITY CLASSES
   Reusable classes for common styling patterns
============================================= */

/* ===== DISPLAY & VISIBILITY ===== */
.display-none {
    display: none !important;
}

.display-block {
    display: block !important;
}

.display-inline-block {
    display: inline-block !important;
}

.display-inline-flex {
    display: inline-flex !important;
}

.display-flex {
    display: flex !important;
}

.display-grid {
    display: grid !important;
}

/* ===== MARGIN UTILITIES ===== */
.margin-0 {
    margin: 0 !important;
}

.margin-top-0 {
    margin-top: 0 !important;
}

.margin-top-8 {
    margin-top: 8px !important;
}

.margin-top-15 {
    margin-top: 15px !important;
}

.margin-top-20 {
    margin-top: 20px !important;
}

.margin-top-24 {
    margin-top: 24px !important;
}

.margin-top-28 {
    margin-top: 28px !important;
}

.margin-top-40 {
    margin-top: 40px !important;
}

.margin-top-56 {
    margin-top: 56px !important;
}

.margin-top-60 {
    margin-top: 60px !important;
}

.margin-24-0-0 {
    margin: 24px 0 0 !important;
}

.margin-40-0 {
    margin: 40px 0 !important;
}

.margin-bottom-0 {
    margin-bottom: 0 !important;
}

.margin-bottom-8 {
    margin-bottom: 8px !important;
}

.margin-bottom-12 {
    margin-bottom: 12px !important;
}

.margin-bottom-16 {
    margin-bottom: 16px !important;
}

.margin-bottom-20 {
    margin-bottom: 20px !important;
}

.margin-bottom-24 {
    margin-bottom: 24px !important;
}

.margin-bottom-28 {
    margin-bottom: 28px !important;
}

/* ===== PADDING UTILITIES ===== */
.padding-top-40 {
    padding-top: 40px !important;
}

/* ===== TEXT ALIGNMENT ===== */
.text-left {
    text-align: left !important;
}

.text-center {
    text-align: center !important;
}

.text-right {
    text-align: right !important;
}

.text-center-padded {
    text-align: center;
    padding: 32px;
    margin: 32px 0;
}

.text-right-mt20 {
    margin-top: 20px;
    text-align: right;
}

/* ===== TEXT STYLING ===== */
.link-inherit {
    color: inherit !important;
    text-decoration: underline !important;
}

.link-inherit::before {
    display: none !important;
}

.gold-text-small {
    color: var(--color-gold);
    font-size: 13px;
    margin-top: 15px;
}

.small-gray-text {
    margin-top: 16px;
    font-size: 0.85rem;
    color: var(--color-text-gray);
}

.text-sm-lh16 {
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 0;
}

.text-sm-lh16-pl20 {
    font-size: 14px;
    line-height: 1.6;
    margin: 0;
    padding-left: 20px;
}

.text-sm-lineheight {
    margin-bottom: 12px;
    font-size: 14px;
    line-height: 1.5;
}

.heading-uppercase-16 {
    margin-top: 0;
    font-size: 16px;
    text-transform: uppercase;
}

/* ===== BORDER UTILITIES ===== */
.border-left-accent {
    border-left: 6px solid var(--color-accent) !important;
}

.border-left-accent-mb0 {
    border-left: 6px solid var(--color-accent);
    margin-bottom: 0;
}

.border-left-blue {
    border-left-color: #003366 !important;
}

.border-left-green {
    border-left-color: #10B981 !important;
}

.border-left-purple {
    border-left-color: #7C3AED !important;
}

/* ===== BACKGROUND UTILITIES ===== */
.bg-white {
    background: white !important;
}

/* ===== IMAGE UTILITIES ===== */
.img-bordered {
    max-width: 100%;
    height: auto;
    border: 3px solid var(--color-border);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

/* ===== GRID UTILITIES ===== */
.grid-auto-280 {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    margin: 32px 0;
}

.grid-auto-300 {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    margin: 24px 0;
}

/* ===== BUTTON UTILITIES ===== */
.card-btn-link {
    display: inline-block;
    margin-top: 15px;
    font-family: var(--font-legal);
    font-weight: 700;
    color: var(--color-stamp-red);
    text-decoration: none;
    border: 3px solid var(--color-stamp-red);
    padding: 10px 20px;
    transition: all 0.2s;
}

.card-btn-link:hover {
    background: var(--color-stamp-red);
    color: white;
}

.btn-dark-rounded {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    background-color: #111827;
    color: #ffffff;
    text-decoration: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    transition: background-color 0.2s ease;
}

.btn-dark-rounded:hover {
    background-color: #1f2937;
}

.btn-submit-full {
    margin-top: 20px;
    padding: 12px 24px;
    border: 2px solid #000;
    background: #000;
    color: #fff;
    font-family: 'JetBrains Mono', monospace;
    text-transform: uppercase;
    font-weight: bold;
    cursor: pointer;
    width: 100%;
    box-sizing: border-box;
}

.btn-submit-full:hover {
    background: #333;
}

/* ===== SECTION UTILITIES ===== */
.footer-section {
    border-top: 4px solid #000;
    padding: 20px;
    margin-top: 40px;
    text-align: center;
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
}

.cta-box-bordered {
    margin-top: 40px;
    text-align: center;
    border: 4px solid #000;
    padding: 20px;
}

.margin-bottom-8-fs14 {
    margin-bottom: 8px;
    font-size: 14px;
    line-height: 1.6;
}

/* ===== STATIC HTML CONTENT ===== */
.static-html-container {
    padding: 80px 10% !important;
}

.static-content {
    /* Preserve original HTML styling */
}

/* Ensure WordPress editor doesn't interfere with static HTML */
.static-content * {
    box-sizing: border-box;
}

/* ===== HIGHLIGHTED LINKS ===== */
/* Apply highlighter effect to all content links */
main a:not(.btn):not(.next-folder-card):not(.card-button):not(.platform-button):not(.prompt-pill):not(.tool-tab) {
    color: var(--color-stamp-red);
    text-decoration: none;
    font-weight: 700;
    position: relative;
    z-index: 0;
    padding: 0 0.08em 0.02em;
    transition: color 0.18s ease;
}

main a:not(.btn):not(.next-folder-card):not(.card-button):not(.platform-button):not(.prompt-pill):not(.tool-tab)::before {
    content: '';
    position: absolute;
    left: -0.08em;
    right: -0.1em;
    bottom: 0.12em;
    height: 0.72em;
    background: rgba(255, 235, 59, 0.5);
    border-radius: 7px 2px 6px 3px;
    transform: rotate(-1.2deg);
    z-index: -1;
    transition: background 0.18s ease, transform 0.18s ease;
}

main a:not(.btn):not(.next-folder-card):not(.card-button):not(.platform-button):not(.prompt-pill):not(.tool-tab):hover {
    color: var(--color-text-ink);
}

main a:not(.btn):not(.next-folder-card):not(.card-button):not(.platform-button):not(.prompt-pill):not(.tool-tab):hover::before {
    background: rgba(255, 235, 59, 0.7);
    transform: rotate(-1.8deg);
}

/* Also apply to entry content and article content */
.entry-content a:not(.btn):not(.next-folder-card):not(.card-button):not(.platform-button):not(.prompt-pill):not(.tool-tab),
article a:not(.btn):not(.next-folder-card):not(.card-button):not(.platform-button):not(.prompt-pill):not(.tool-tab) {
    color: var(--color-stamp-red);
    text-decoration: none;
    font-weight: 700;
    position: relative;
    z-index: 0;
    padding: 0 0.08em 0.02em;
    transition: color 0.18s ease;
}

.entry-content a:not(.btn):not(.next-folder-card):not(.card-button):not(.platform-button):not(.prompt-pill):not(.tool-tab)::before,
article a:not(.btn):not(.next-folder-card):not(.card-button):not(.platform-button):not(.prompt-pill):not(.tool-tab)::before {
    content: '';
    position: absolute;
    left: -0.08em;
    right: -0.1em;
    bottom: 0.12em;
    height: 0.72em;
    background: rgba(255, 235, 59, 0.5);
    border-radius: 7px 2px 6px 3px;
    transform: rotate(-1.2deg);
    z-index: -1;
    transition: background 0.18s ease, transform 0.18s ease;
}

.entry-content a:not(.btn):not(.next-folder-card):not(.card-button):not(.platform-button):not(.prompt-pill):not(.tool-tab):hover,
article a:not(.btn):not(.next-folder-card):not(.card-button):not(.platform-button):not(.prompt-pill):not(.tool-tab):hover {
    color: var(--color-text-ink);
}

.entry-content a:not(.btn):not(.next-folder-card):not(.card-button):not(.platform-button):not(.prompt-pill):not(.tool-tab):hover::before,
article a:not(.btn):not(.next-folder-card):not(.card-button):not(.platform-button):not(.prompt-pill):not(.tool-tab):hover::before {
    background: rgba(255, 235, 59, 0.7);
    transform: rotate(-1.8deg);
}

/* ===== BUTTON OVERRIDES ===== */
/* Ensure all button-like elements don't get highlight effect and have proper contrast */
.btn,
.btn-cta,
.btn-secondary,
.btn-dark-rounded,
.btn-submit-full,
.btn-send,
.expand-cta,
.card-btn-link,
.platform-button,
.prompt-pill,
.tool-tab,
.card-button,
.next-folder-card,
a.btn,
a.btn-cta,
a.btn-secondary,
a.expand-cta,
a.card-btn-link {
    position: relative;
    color: inherit !important;
}

.btn::before,
.btn-cta::before,
.btn-secondary::before,
.btn-dark-rounded::before,
.btn-submit-full::before,
.btn-send::before,
.expand-cta::before,
.card-btn-link::before,
.platform-button::before,
.prompt-pill::before,
.tool-tab::before,
.card-button::before,
.next-folder-card::before,
a.btn::before,
a.btn-cta::before,
a.btn-secondary::before,
a.expand-cta::before,
a.card-btn-link::before {
    display: none !important;
    content: none !important;
}

/* Ensure button text colors are always visible */
.btn {
    color: white !important;
}

.btn:hover {
    color: var(--color-accent) !important;
    background: white !important;
}

.btn-cta,
a.btn-cta,
a.btn-cta:link,
a.btn-cta:visited {
    color: white !important;
}

.btn-cta:hover {
    color: var(--color-stamp-red) !important;
    background: white !important;
}

.btn-secondary {
    color: var(--color-accent) !important;
}

.btn-secondary:hover {
    color: white !important;
    background: var(--color-accent) !important;
}

.expand-cta {
    color: #FFFFFF !important;
}

.expand-cta:hover {
    color: var(--color-accent) !important;
}
