/**
 * Internship Listings Premium Stylesheet - Wireframe Aligned
 */

:root {
    --primary-color: #04a5c7; /* Parent theme link blue */
    --text-color: #2c3d49;    /* Parent theme base text */
    --text-dark: #112337;     /* Parent theme heading/dark text */
    --text-muted: #686e77;    /* Parent theme secondary text */
    --border-grey: #cccccc;
    --border-light: #e2e8f0;
    --bg-grey-light: #f3f4f6;
    --bg-grey-medium: #e9ecef;
    --card-bg: #ffffff;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-pill: 30px;
    --shadow-card: 0 4px 12px rgba(0, 0, 0, 0.05);
    --font-stack: inherit;    /* Inherit Figtree / theme fonts */
}

/* Container */
.internships-container {
    display: grid;
    grid-template-columns: clamp(300px, calc(28.125rem + ((1vw - 19.2px) * 16.7411)), 450px) 1fr;
    gap: 35px;
    margin: 40px auto;
    max-width: 90%;
    padding: 0 20px;
    font-family: var(--font-stack);
    color: var(--text-color);
}

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

/* --- SIDEBAR FILTERS --- */
.internships-sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-self: start;
}

/* Search Box */
.filter-group-search {
    width: 100%;
}

.filter-group-search .search-wrapper {
    position: relative;
}

.filter-group-search .search-input {
    width: 100%;
    padding: 12px 60px 12px 16px;
    border: 1px solid var(--border-grey);
    border-radius: var(--radius-pill);
    font-size: 14px;
    outline: none;
    background: #ffffff;
}

.filter-group-search .search-icon {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 100px;
}

/* Bordered Filter Box (Population, Stipend, Housing) */
.filter-box {
    border: 1px solid var(--border-grey);
    border-radius: var(--radius-md);
    padding: 20px;
    background: #ffffff;
}

.filter-box-title {
    margin: 0 0 15px 0;
    font-size: 16px;
    font-weight: 700;
    color: var(--primary-color);
}

/* Dropdown Filters */
.filter-select-group {
    width: 100%;
}

.filter-select-group .filter-select {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border-grey);
    border-radius: var(--radius-pill);
    font-size: 14px;
    font-weight: 500;
    background-color: #F1F9FB;
    color: #4e4e4e;
    outline: none;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%234a4a4a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 15px center;
    background-size: 16px;
}

/* Checkbox Items */
.checkbox-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-color);
    cursor: pointer;
}

.checkbox-label input {
    width: 18px;
    height: 18px;
    border: 1px solid var(--border-grey);
    border-radius: 4px;
    accent-color: var(--primary-color);
    flex: 18px 0 0;
    cursor: pointer;
}

.clear-filters-btn {
    display: block;
    width: 100%;
    text-align: center;
    padding: 12px;
    /*background: #fef2f2;*/
    color: #dc2626;
    /*border: 2px solid #fecaca;*/
    border-radius: var(--radius-pill);
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
}

.clear-filters-btn.disabled {
    margin-bottom: 20px;
}

/*.clear-filters-btn:hover {
    background: #fee2e2;
}*/


/* --- LISTINGS CONTENT AREA --- */
.internships-content {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

/* Listings Grid */
.listings-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
}

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

/* Listing Card */
.listing-card {
    background: var(--card-bg);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    overflow: hidden;
    padding: 0 0 25px 0;
    display: flex;
    flex-direction: column;
    gap: 15px;
    box-shadow: var(--shadow-card);
    transition: transform 0.2s, box-shadow 0.2s;
}

.listing-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

/* Top Large Logo Container */
.card-logo-container {
    width: 100%;
    height: 200px;
    background: var(--bg-grey-light);
    display: flex;
    align-items: center;
    justify-content: center;
    /*border-bottom: 2px solid var(--border-light);*/
    overflow: hidden;
}

/*.card-logo-container img {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
}*/

.logo-fallback-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    background: var(--bg-grey-medium);
}

.logo-placeholder {
    font-size: 40px;
    font-weight: 800;
    color: #a0aec0;
}

/* Metadata tags row */
.card-metadata-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    /*padding: 0 24px;*/
}

.meta-tag {
    font-size: 12px;
    font-weight: 700;
    color: var(--text-muted);
}

.meta-tag::before {
    content: "★ ";
    color: var(--text-muted);
}

/* Employer Title Section */
/*.card-title-section {
    padding: 0 24px;
}*/

.employer-name {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0 0 8px 0;
}

.card-line {
    border: none;
    border-bottom: 2px solid var(--border-light);
    margin: 8px 0 0 0;
    width: 100%;
}

/* Address Block */
.card-address-section {
    /*padding: 0 24px;*/
    /*font-size: 14px;*/
    color: var(--text-color);
    line-height: 1.5;
}

/*.card-address-section p {
    margin: 0;
}*/

/* Button Wrapper */
/*.card-button-wrapper {
    padding: 10px 24px 0 24px;
    display: flex;
    justify-content: center;
}*/

body .visit-website-btn, body .search-read-more-btn {
    display: inline-block;
    padding: 15px 30px;
    background: #04A5C7;
    color: #fff;
    border-radius: 100px;
    font-size: 16px;
    line-height: 1.7em !important;
    font-weight: 500;
    text-decoration: none;
    text-align: center;
    border: none;
    transition: all 300ms ease 0ms;
}

body .visit-website-btn:hover, body .search-read-more-btn:hover {
    background-color: #6A207F;
    transition: all 300ms ease 0ms;
}

/* Load More Button Container */
.load-more-container {
    display: flex;
    justify-content: center;
    margin: 30px 0 0 0;
}

.load-more-btn {
    display: inline-block;
    padding: 15px 30px;
    background: #04A5C7;
    color: #fff;
    border-radius: 100px;
    font-size: 16px;
    line-height: 1.7em !important;
    font-weight: 500;
    text-decoration: none;
    text-align: center;
    border: none;
    transition: all 300ms ease 0ms;
}

.load-more-btn:hover {
    background-color: #6A207F;
    transition: all 300ms ease 0ms;
}

/* No results state */
.no-results {
    text-align: center;
    padding: 50px;
    background: #ffffff;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    color: var(--text-muted);
}

.no-results i {
    font-size: 40px;
    margin-bottom: 15px;
}

/* Loader Spinner */
.internships-loader {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 30px 0;
    width: 100%;
}

.internships-loader .spinner {
    width: 40px;
    height: 40px;
    border: 4px solid var(--border-light);
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* --- SINGLE PAGE STYLES --- */
.single-internship-wrapper {
    background: #f8fafc;
    padding: 40px 0;
    font-family: var(--font-stack);
}

.internship-single-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 180px 20px 0 20px;
}

.back-link-wrapper {
    margin-bottom: 20px;
}

.back-to-listings-link {
    font-size: 14px;
    font-weight: 700;
    color: var(--primary-color);
    text-decoration: none;
    transition: opacity 0.2s;
}

.back-to-listings-link:hover {
    opacity: 0.8;
}

/* Single Two-Column Grid */
.single-layout-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 0;
    margin-bottom: 40px;
}

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

/* Left Column: Info Box */
.single-main-column {
    background: #ffffff;
    border: 1px solid var(--border-grey);
    border-radius: var(--radius-md);
    padding: 30px;
    box-shadow: var(--shadow-card);
}

.single-post-title {
    font-size: 32px;
    font-weight: 800;
    color: var(--text-dark);
    margin: 0 0 30px 0;
}

.details-list-box {
    display: flex;
    flex-direction: column;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 0;
    border-bottom: 1px dashed var(--border-grey);
}

.detail-row:last-child {
    border-bottom: none;
}

.detail-label {
    font-size: 16px;
    font-weight: 700;
    color: #3C4551;
}

.detail-value {
    font-size: 15px;
    color: var(--text-color);
    text-align: right;
}

/* Right Column: Sidebar Cards */
.single-sidebar-column {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 30px;
    gap: 0;
    border-radius: 0 8px 0 0;
    box-shadow: none;
    border-bottom: 1px solid #d6d6d6;
    background-color: #fff;
}

.sidebar-logo-card {
    background: #ffffff;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    padding: 30px;
    text-align: center;
    box-shadow: var(--shadow-card);
}

.single-logo {
    max-width: 100%;
    max-height: 150px;
    object-fit: contain;
    margin-bottom: 20px;
}

.single-logo-placeholder {
    font-size: 60px;
    color: #a0aec0;
    margin-bottom: 20px;
}

.sidebar-employer-name {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0;
}

.sidebar-contact-card {
    background: #ffffff;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    padding: 30px;
    box-shadow: var(--shadow-card);
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.contact-item {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    font-size: 14px;
    color: var(--text-color);
    line-height: 1.5;
}

.contact-icon {
    font-size: 16px;
    flex-shrink: 0;
}

.contact-text a {
    color: var(--primary-color);
    text-decoration: none;
}

.contact-text a:hover {
    text-decoration: underline;
}

/* Bottom Content Rows */
.single-bottom-content {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.content-section {
    background: #ffffff;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    padding: 35px;
    box-shadow: var(--shadow-card);
}

.content-section h3 {
    margin: 0 0 20px 0;
    font-size: 22px;
    font-weight: 700;
    color: var(--primary-color);
    border-left: 4px solid var(--primary-color);
    padding-left: 15px;
    padding-bottom: 0;
}

.section-content {
    font-size: 15px;
    color: var(--text-color);
    line-height: 1.7;
}

.section-content p {
    margin: 0 0 15px 0;
}

.section-content p:last-child {
    margin-bottom: 0;
}

.section-content ul {
    margin: 10px 0;
    padding-left: 20px;
}

.section-content li {
    margin-bottom: 8px;
}


@media (max-width: 1024px) {
    .internships-container {
        grid-template-columns: 1fr;
    }
}
@media screen and (max-width: 980px) {
    .internship-single-container {
        padding: 20px 20px 0 20px;
    }
}


