
.hrf-faq-list {
	margin-bottom: 2em;
}

.hrf-faq-list article:last-of-type {
	display: none !important;
	visibility: hidden;
}

    /* ============================================
   BUTTON: Button colors for FS, CC, NSF, and ERF
   ============================================ */

a.button-fancy {
    display: block !important;
    width: fit-content !important;
    margin: 0 auto !important;
    padding: 12px 24px !important;
    background-color: #e6783a !important;
    color: black !important;
    text-decoration: none !important;
    border-radius: 50px !important;
    font-weight: bold !important;
    text-align: center !important;
    cursor: pointer !important;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1) !important;
    transition: all 0.3s ease !important;
}

a.button-fancy:hover {
    background-color: #c86933 !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 8px rgba(0, 0, 0, 0.15) !important;
}

a.button-fancy-cc {
    display: block !important;
    width: fit-content !important;
    margin: 0 auto !important;
    padding: 12px 24px !important;
    background-color: #b5d334 !important;
    color: black !important;
    text-decoration: none !important;
    border-radius: 50px !important;
    font-weight: bold !important;
    text-align: center !important;
    cursor: pointer !important;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1) !important;
    transition: all 0.3s ease !important;
}

a.button-fancy-cc:hover {
    background-color: #859a29 !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 8px rgba(0, 0, 0, 0.15) !important;
}

a.button-fancy-nsf {
    display: block !important;
    width: fit-content !important;
    margin: 0 auto !important;
    padding: 12px 24px !important;
    background-color: #00b3d0 !important;
    color: black !important;
    text-decoration: none !important;
    border-radius: 50px !important;
    font-weight: bold !important;
    text-align: center !important;
    cursor: pointer !important;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1) !important;
    transition: all 0.3s ease !important;
}

a.button-fancy-nsf:hover {
    background-color: #048fa5 !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 8px rgba(0, 0, 0, 0.15) !important;
}

a.button-fancy-erf {
    display: block !important;
    width: fit-content !important;
    margin: 0 auto !important;
    padding: 12px 24px !important;
    background-color: #f5524f !important;
    color: black !important;
    text-decoration: none !important;
    border-radius: 50px !important;
    font-weight: bold !important;
    text-align: center !important;
    cursor: pointer !important;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1) !important;
    transition: all 0.3s ease !important;
}

a.button-fancy-erf:hover {
    background-color: #d00400 !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 8px rgba(0, 0, 0, 0.15) !important;
}
     /* ============================================
   TABLE CLASS: .nice (Application Deadline Table)
   ============================================ */

.nice {
    border-collapse: collapse !important;
    width: 100% !important;
    max-width: 800px !important;
    margin: 20px auto !important;
    table-layout: auto !important;
    border: 3px double #000 !important;
    font-size: 14px !important;
}

.nice td {
    padding: 8px 12px !important;
    border: 1px solid #000 !important;
    vertical-align: top !important;
    text-align: center !important;
}

/* Style the header row */
.nice tr:first-child td {
    color: #e6783a !important;
    font-weight: bold !important;
}

/* Mobile responsiveness */
@media screen and (max-width: 768px) {
    .nice {
        font-size: 12px !important;
        margin: 10px !important;
        width: calc(100% - 20px) !important;
    }
    
    .nice td {
        padding: 6px 8px !important;
        word-wrap: break-word !important;
        hyphens: auto !important;
    }
}

@media screen and (max-width: 480px) {
    /* Completely reset table structure for mobile */
    .nice, .nice tbody, .nice tr, .nice td {
        display: block !important;
        width: 100% !important;
    }
    
    .nice {
        border: none !important;
        margin: 10px 0 !important;
        font-size: 14px !important;
    }
    
    /* Hide original header */
    .nice thead,
    .nice tr:first-child {
        display: none !important;
    }
    
    /* Style each row as a card */
    .nice tr {
        border: 2px solid #000 !important;
        border-radius: 8px !important;
        margin-bottom: 20px !important;
        padding: 15px !important;
        background: #fff !important;
        box-shadow: 0 2px 8px rgba(0,0,0,0.1) !important;
    }
    
    /* Style each cell */
    .nice td {
        border: none !important;
        border-bottom: 1px solid #e0e0e0 !important;
        padding: 10px 0 !important;
        text-align: left !important;
        position: relative !important;
        padding-left: 0 !important;
        margin: 0 !important;
    }
    
    .nice td:last-child {
        border-bottom: none !important;
    }
    
    /* Add field labels */
    .nice td:before {
        content: attr(data-label) !important;
        font-weight: bold !important;
        color: #e6783a !important;
        display: block !important;
        margin-bottom: 5px !important;
        font-size: 13px !important;
        text-transform: uppercase !important;
        letter-spacing: 0.5px !important;
    }
    
    .nice td strong {
        color: #000 !important;
        font-weight: bold !important;
    }
}

/* ============================================
   TABLE CLASS: .nice2 (Grant Programs Table)
   ============================================ */

.nice2 {
    border-collapse: collapse !important;
    width: 100% !important;
    max-width: 900px !important;
    margin: 20px auto !important;
    table-layout: auto !important;
    border: 3px double #000 !important;
    font-size: 14px !important;
}

.nice2 td {
    padding: 8px 12px !important;
    border: 1px solid #000 !important;
    vertical-align: top !important;
    text-align: center !important;
}

/* Style the header row */
.nice2 tr:first-child td {
    color: #e6783a !important;
    font-weight: bold !important;
}

/* Link styling */
.nice2 a {
    color: #568ecb !important;
    text-decoration: underline !important;
}

.nice2 a:hover {
    color: #1fa8c9 !important;
}

/* Mobile responsiveness */
@media screen and (max-width: 768px) {
    .nice2 {
        font-size: 12px !important;
        margin: 10px !important;
        width: calc(100% - 20px) !important;
    }
    
    .nice2 td {
        padding: 6px 8px !important;
        word-wrap: break-word !important;
        hyphens: auto !important;
    }
}

@media screen and (max-width: 600px) {
    /* Completely reset table structure for mobile */
    .nice2, .nice2 tbody, .nice2 tr, .nice2 td {
        display: block !important;
        width: 100% !important;
    }
    
    .nice2 {
        border: none !important;
        margin: 10px 0 !important;
        font-size: 14px !important;
    }
    
    /* Hide original header */
    .nice2 thead,
    .nice2 tr:first-child {
        display: none !important;
    }
    
    /* Style each row as a card */
    .nice2 tr {
        border: 2px solid #000 !important;
        border-radius: 8px !important;
        margin-bottom: 20px !important;
        padding: 15px !important;
        background: #fff !important;
        box-shadow: 0 2px 8px rgba(0,0,0,0.1) !important;
    }
    
    /* Style each cell */
    .nice2 td {
        border: none !important;
        border-bottom: 1px solid #e0e0e0 !important;
        padding: 10px 0 !important;
        text-align: left !important;
        position: relative !important;
        padding-left: 0 !important;
        margin: 0 !important;
    }
    
    .nice2 td:last-child {
        border-bottom: none !important;
    }
    
    /* Add field labels */
    .nice2 td:before {
        content: attr(data-label) !important;
        font-weight: bold !important;
        color: #e6783a !important;
        display: block !important;
        margin-bottom: 5px !important;
        font-size: 13px !important;
        text-transform: uppercase !important;
        letter-spacing: 0.5px !important;
    }
    
    .nice2 td strong {
        color: #000 !important;
        font-weight: bold !important;
    }

    /* Mobile link styling */
    .nice2 a {
        color: #568ecb !important;
        font-weight: 500 !important;
    }
}

/* ============================================
   CONTAINER CLASSES
   ============================================ */

.nice-table-responsive-container {
    display: flex !important;
    justify-content: center !important;
    overflow-x: auto !important;
    padding: 0 10px !important;
}

/* Ensure container works on mobile for .nice tables */
@media screen and (max-width: 480px) {
    .nice-table-responsive-container {
        display: block !important;
        overflow-x: visible !important;
        padding: 0 !important;
    }
}

/* Ensure container works on mobile for .nice2 tables */
@media screen and (max-width: 600px) {
    .nice-table-responsive-container {
        display: block !important;
        overflow-x: visible !important;
        padding: 0 !important;
    }
}

/* ============================================
   ADDITIONAL STYLING (for grant programs header)
   ============================================ */

.grant-header {
    text-align: center !important;
    margin-bottom: 20px !important;
}

.grant-header a {
    color: #568ecb;
    text-decoration: underline !important;
}

.grant-header a:hover {
    color: #1fa8c9 !important;
}