/**
 * Field deep-dive pages (single-field.php): subfield selector tabs, application cards grid, page header/bullet lists.
 */

/* SubField Page Header & Bullet Lists */
.subfield-hero-banner {
    position: relative;
    padding: 5rem 2rem;
    background: linear-gradient(135deg, rgba(15, 44, 76, 0.92), rgba(15, 99, 161, 0.85)), url('hero-main.png') center/cover no-repeat;
    color: #FFFFFF;
    text-align: center;
    border-bottom: 1px solid #D1E4F5;
}

.subfield-hero-title {
    font-family: var(--vosges-font-display);
    font-size: 2.6rem;
    margin-bottom: 0.8rem;
    color: #FFFFFF;
}

.subfield-hero-desc {
    font-size: 1.1rem;
    max-width: 750px;
    margin: 0 auto;
    color: #E6F2FC;
    line-height: 1.6;
}

.subfield-apply-box {
    margin-top: 1.2rem;
    padding-top: 1rem;
    border-top: 1px solid #E6F2FC;
}

.subfield-apply-heading {
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--rect-blue-4);
    margin-bottom: 0.8rem;
    display: flex;
    align-items: center;
    gap: 6px;
}

.subfield-bullet-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.subfield-bullet-item {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 14px;
    color: #33597D;
    line-height: 1.45;
}

.subfield-bullet-item::before {
    content: "•";
    color: var(--rect-blue-3);
    font-weight: 800;
    font-size: 16px;
    line-height: 1;
}

/* ==========================================================================
   Subfield Cover Hero & Real-World Application Cards System
   ========================================================================== */
.subfield-cover-hero {
    position: relative;
    width: 100%;
    min-height: 420px;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    padding: 120px 5% 60px 5%;
    box-sizing: border-box;
    transition: background-image 0.5s ease-in-out;
}

.subfield-cover-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(1, 10, 20, 0.92) 0%, rgba(10, 37, 64, 0.8) 100%);
    z-index: 1;
}

.subfield-cover-content {
    position: relative;
    z-index: 2;
    max-width: 1280px;
    margin: 0 auto;
    width: 100%;
}

.subfield-cover-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 1rem;
    background: rgba(0, 229, 255, 0.12);
    border: 1px solid rgba(0, 229, 255, 0.35);
    border-radius: 50px;
    color: #00E5FF;
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    margin-bottom: 1.2rem;
}

.subfield-cover-title {
    font-size: 3.2rem;
    font-weight: 800;
    color: #FFFFFF;
    line-height: 1.12;
    letter-spacing: -0.02em;
    margin: 0 0 1rem 0;
}

.subfield-cover-desc {
    font-size: 1.15rem;
    color: #CBD5E1;
    line-height: 1.6;
    max-width: 720px;
    margin: 0 0 2rem 0;
}

/* Subfield Selector Tabs */
.subfield-tabs-bar {
    background: #031325;
    border-bottom: 1px solid rgba(45, 153, 235, 0.2);
    padding: 1rem 5%;
    position: sticky;
    top: var(--header-h);
    z-index: 100;
}

.subfield-tabs-container {
    max-width: 1280px;
    margin: 0 auto;
    display: flex;
    gap: 0.8rem;
    overflow-x: auto;
    padding-bottom: 0.4rem;
    scrollbar-width: thin;
}

.subfield-tab-btn {
    padding: 0.7rem 1.3rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    color: #94A3B8;
    font-family: inherit;
    font-size: 0.92rem;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.25s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.subfield-tab-btn:hover {
    background: rgba(45, 153, 235, 0.15);
    color: #FFFFFF;
    border-color: rgba(45, 153, 235, 0.35);
}

.subfield-tab-btn.active {
    background: #0F63A1;
    color: #FFFFFF;
    border-color: #2D99EB;
    box-shadow: 0 4px 15px rgba(15, 99, 161, 0.35);
}

/* Application Cards Grid */
.subfield-app-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    margin-top: 2.5rem;
}

.app-card {
    background: #FFFFFF;
    border: 1px solid #E2E8F0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(15, 44, 76, 0.06);
    transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    flex-direction: column;
}

.app-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 45px rgba(15, 99, 161, 0.16);
    border-color: #0F63A1;
}

.app-card-img-wrapper {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.app-card-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.app-card:hover .app-card-img-wrapper img {
    transform: scale(1.06);
}

.app-card-tag {
    position: absolute;
    top: 1rem;
    inset-inline-end: 1rem;
    padding: 0.35rem 0.8rem;
    background: rgba(1, 10, 20, 0.82);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50px;
    color: #00E5FF;
    font-size: 0.78rem;
    font-weight: 700;
    backdrop-filter: blur(8px);
}

.app-card-body {
    padding: 1.8rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.app-card-title {
    font-size: 1.35rem;
    font-weight: 800;
    color: #0F2C4C;
    margin: 0 0 0.8rem 0;
}

.app-bullets-list {
    list-style: none;
    padding: 0;
    margin: 0 0 1.5rem 0;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    flex: 1;
}

.app-bullet-item {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    font-size: 0.92rem;
    color: #475569;
    line-height: 1.5;
}

.app-bullet-icon {
    width: 16px;
    height: 16px;
    color: #0F63A1;
    flex-shrink: 0;
    margin-top: 2px;
}

.app-applied-tech {
    background: #F8FAFC;
    border: 1px solid #E2E8F0;
    border-radius: 8px;
    padding: 0.8rem 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.app-applied-label {
    font-size: 0.78rem;
    font-weight: 700;
    color: #64748B;
    text-transform: uppercase;
}

.app-applied-value {
    font-size: 0.88rem;
    font-weight: 800;
    color: #0F63A1;
}

@media (max-width: 768px) {
    .subfield-cover-title {
        font-size: 2.2rem !important;
    }
    .subfield-cover-hero {
        min-height: 360px;
        padding: 90px 1rem 40px 1rem;
    }
}

/* ==================== Field Deep-Dive Page (single-field.php) ====================
   Ported from agriculture.html's page-local inline styles. .btn-sharp-primary isn't
   redeclared here — it's shared with the homepage's product showcase CTAs. */

.field-hero-section {
    position: relative;
    width: 100%;
    min-height: 320px;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    padding: 100px 5% 50px 5%;
    box-sizing: border-box;
}

.field-hero-overlay {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 90% 70% at 50% 45%, rgba(0, 0, 0, 0.15) 0%, rgba(0, 0, 0, 0.50) 100%),
        linear-gradient(180deg, rgba(0, 0, 0, 0.45) 0%, rgba(0, 0, 0, 0.25) 45%, rgba(0, 0, 0, 0.65) 100%);
    pointer-events: none;
    z-index: 1;
}

.field-hero-container {
    position: relative;
    z-index: 2;
    max-width: 1280px;
    margin: 0 auto;
    width: 100%;
    text-align: center;
}

.field-hero-title {
    font-family: var(--vosges-font-display);
    font-size: 2.8rem;
    font-weight: 700;
    line-height: 1.2;
    color: #FFFFFF;
    margin: 0 0 0.8rem 0;
}

.field-hero-desc {
    font-family: var(--vosges-font-body);
    font-size: 1.1rem;
    color: #E6F2FC;
    line-height: 1.6;
    max-width: 760px;
    margin: 0 auto 1.5rem auto;
}

.field-apps-section {
    padding: 54px 1rem 80px 1rem;
    background-color: #F5F9FD;
}

.field-apps-container {
    max-width: 1280px;
    margin: 0 auto;
}

.field-apps-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

@media (max-width: 1023px) {
    .field-apps-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 767px) {
    .field-apps-grid {
        grid-template-columns: 1fr;
    }
}

.field-apps-card {
    background: #FFFFFF;
    border: 1px solid #D1E4F5;
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(15, 44, 76, 0.04);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
}

.field-apps-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 28px rgba(15, 99, 161, 0.12);
    border-color: #2D99EB;
}

.field-apps-card:hover .btn-sharp-primary {
    background: #0F63A1;
    box-shadow: 0 4px 12px rgba(15, 99, 161, 0.2);
}

.field-apps-card-img {
    width: 100%;
    height: 210px;
    object-fit: cover;
}

.field-apps-card-body {
    padding: 1.8rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.field-apps-card-title {
    font-family: var(--vosges-font-display);
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0 0 1rem 0;
    color: #0F2C4C;
}

.field-apps-bullet-list {
    list-style: none;
    padding: 0;
    margin: 0 0 1.5rem 0;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    flex: 1;
}

.field-apps-bullet-item {
    display: flex;
    align-items: flex-start;
    gap: 0.65rem;
    font-size: 0.93rem;
    color: #4A6A8A;
    line-height: 1.55;
}

.field-apps-bullet-icon {
    width: 18px;
    height: 18px;
    color: #0D9488;
    flex-shrink: 0;
    margin-top: 2px;
}

.field-apps-card-action {
    margin-top: auto;
    padding-top: 1rem;
    border-top: 1px solid #D1E4F5;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

@media (max-width: 768px) {
    .field-hero-title {
        font-size: 2.1rem;
    }

    .field-hero-section {
        min-height: 270px;
        padding: 85px 1rem 35px 1rem;
    }
}

/* ==================== CSS-only icons for Gutenberg-block content ====================
   A raw <svg> inside RichText/anchor content causes "invalid content" block-validation
   errors (see the homepage's products-showcase/about-distributor blocks). These
   ::before/::after mask-image icons keep the actual block content plain text + a class. */

.icon-arrow-after::after {
    content: "";
    display: inline-block;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    background-color: currentColor;
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.5'%3E%3Cpath d='M5 12h14M12 5l7 7-7 7'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.5'%3E%3Cpath d='M5 12h14M12 5l7 7-7 7'/%3E%3C/svg%3E");
    -webkit-mask-size: contain;
    mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
}

.related-text-link.icon-arrow-after::after {
    width: 14px;
    height: 14px;
}
