@import url('https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap');

:root {

    --btn-color: #fdfdfd;
    /* button color*/
    --btn-bg: #0d0d0d;
    /* button bg color*/

    --primary-text-color: #000;
    --header-link-hover: #dddcdccf;
    --footer-link-hover: #6dbb00;
    --input-focus-bd-color: #0d0d0d;
}


html {
    scroll-behavior: smooth;
    font-family: "Iowan Old Style", "Apple Garamond", Baskerville, "Times New Roman", "Droid Serif", Times, "Source Serif Pro", serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
    line-height: 1.75;
    font-size: 1.0625rem;
    color: #2c2c2c;
    overflow-x: hidden;
    max-width: 100vw;
    scroll-padding-top: 150px;
}

body {
    overflow-x: hidden;
    max-width: 100vw;
}

/* Apply serif fonts to common text elements */
p,
li,
blockquote,
dd,
dt {
    font-family: "Iowan Old Style", "Apple Garamond", Baskerville, "Times New Roman", "Droid Serif", Times, "Source Serif Pro", serif;
    line-height: 1.75;
}

/* Ensure descriptions and abstracts use serif */
.tw-text-gray-600,
.tw-text-gray-700 {
    font-family: "Iowan Old Style", "Apple Garamond", Baskerville, "Times New Roman", "Droid Serif", Times, "Source Serif Pro", serif;
}

/* Ensure italic text uses serif */
.tw-italic {
    font-family: "Iowan Old Style", "Apple Garamond", Baskerville, "Times New Roman", "Droid Serif", Times, "Source Serif Pro", serif;
}

/* Ensure metadata text (dates, authors, venue) uses serif */
p.tw-mt-4 {
    font-family: "Iowan Old Style", "Apple Garamond", Baskerville, "Times New Roman", "Droid Serif", Times, "Source Serif Pro", serif;
}

header {
    /* background-color: #fff;
    color: #000; */
}


header>.collapsible-header {
    display: flex;
    gap: 1rem;
    width: 100%;
    background-color: inherit;
    place-content: flex-end;
    overflow: hidden;
    transition: width 0.3s ease;
}

.outline-effect {
    color: black;
    -webkit-text-fill-color: transparent;
    /* Will override color (regardless of order) */
    -webkit-text-stroke: 2px black;
}

.animated-collapse {
    transition: width 0.3s ease;
}

.header-links {
    display: flex;
    align-items: center;
    min-width: fit-content;
    /*    border-radius: 25px;*/
    padding: 5px 15px;
    border-color: transparent;
    border-width: 2px;
    border-style: solid;
    transition: all 0.2s;
}

.header-links:hover {
    /*    background-color: var(--header-link-hover);*/
    background-color: #f3f3f3b4;
    border-color: rgb(75 85 99);
    /* gray 600 */
}

.person-page-links {
    display: inline-block;
    color: black;
    padding: 6px 8px;
    border: 1px solid rgb(209 213 219);
    /* gray 300 */
    transition: all 0.2s;
    cursor: pointer;
    font-size: 0.9rem;
}

.person-page-links:hover {
    border-color: rgb(75 85 99);
    /* gray 600 */
    background-color: #f3f3f3b4;
}

.material-icons.md-40 {
    font-size: 40px;
}

.primary-text-color {
    color: var(--primary-text-color);
}

.opacity-0 {
    opacity: 0 !important;
}

.opacity-100 {
    opacity: 100 !important;
}

.btn {
    padding: 10px 15px;
    width: max-content;
    border-radius: 25px;
    color: var(--btn-color);
    background-color: var(--btn-bg);
    justify-content: center;
    align-items: center;
    display: flex;
    cursor: pointer;
}

.btn:hover {}

.btn:disabled {
    cursor: default;
}

.input {
    padding: 10px;
    background-color: transparent;
    border-radius: 25px;
    /* outline: none; */
    min-width: 100px;
    border: 2px solid #818080;
    transition: border 0.3s;
}

.input:active,
.input:focus,
.input:focus-within {
    border: 2px solid var(--input-focus-bd-color);
}

.input-error {
    border-bottom: 3px solid #ff1e1e;
}

.input-error:focus-within {
    border-bottom: 3px solid #fd0101;
}


/* Navigation dots styling */
.dots-container {
    text-align: center;
    margin-top: 20px;
}

.footer-link {
    color: #0d0d0d;
    transition: color 0.3s;
}

.footer-link:hover {
    color: var(--footer-link-hover);
}


.review-container {
    position: relative;
    max-width: 600px;
    margin: auto;
}

.review-card {
    box-shadow: 0px 2px 4px #757474a0;
    border-radius: 15px;
    /* width: 200px; */
    /* height: 550px; */
    padding: 10px;
}

/* --------- collapsible div ---------- */
.collapsible {
    background-color: #f3f0f0;
    color: #2b2929;
    /* cursor: pointer; */
    padding: 5px;
    width: 100%;
    border: none;
    text-align: left;
    outline: none;
    font-size: 16px;
    transition: 0.4s;
}

/* Style for the collapsible content */
.content {
    padding: 0 18px;
    /* display: none; */
    height: 0px;
    overflow: hidden;
    background-color: transparent;
    transition: height 0.5s;
    text-align: justify;
    margin-top: 10px;
}

.collapsible .active,
.collapsible:hover {
    /* background-color: #dedddd; */
}

/* Header navigation uses 1024px breakpoint (let Tailwind lg: handle it) */
@media not all and (min-width: 1024px) {
    header .collapsible-header {
        position: fixed;
        right: 0px;
        flex-direction: column;
        opacity: 0;
        height: 100vh;
        min-height: 100vh;
        height: 100dvh;
        width: 0vw;
        justify-content: flex-start;
        padding: 8px;
        padding-top: 70px;
        padding-bottom: 20px;
        place-items: end;
        background-color: #ffffff;
        color: #000000;
        overflow-y: auto;
        overflow-x: hidden;
        box-shadow: 2px 0px 3px #000;
        pointer-events: none;
    }

    .header-links {
        color: black;
        padding: 6px 10px;
        font-size: 15px;
    }

    /* Enable pointer events when menu is opened */
    header .collapsible-header.opacity-100 {
        pointer-events: auto;
    }

}

/*    top: 50%;
    left: 38%;
    transform: translate(-50%, -50%);*/
.image-container {
    position: relative;
    width: 100%;
    /* Adjust width as needed */
    height: 500px;
    /*    height: max(80%, 450px);*/
    overflow: hidden;
    /*    max-width: 600px; Adjust max-width to control the image size */
}

.image-container img {
    width: 100%;
    /* Ensures the image fits the container */
    height: 100%;
    object-fit: cover;
    object-position: left;
}

.text-overlay {
    position: absolute;
    top: 50%;
    left: 40px;
    transform: translate(0%, -50%);
    /*    display: flex;
    align-items: center;
    height: 100vh;
    */
    /*    position: absolute;*/
    color: white;
    /* Text color */
    /*    top: 100px;*/
    /*    left: 40px;*/
    width: 60%;
    /* Ensures the image fits the container */
    /*    font-size: 24px; Adjust font size */
    /*    font-weight: bold;*/
    /*    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7); Optional text shadow for readability */
}

/* Responsive adjustments for text overlay on small screens */
@media (max-width: 767px) {
    .text-overlay {
        left: 5%;
        right: 5%;
        width: 90%;
        top: auto;
        bottom: 20px;
        transform: none;
    }

    /* Reduce line height for large heading on tablets */
    .text-overlay .tw-leading-\[85px\] {
        line-height: 1.3 !important;
    }

    .image-container {
        height: 420px;
    }
}

@media (max-width: 480px) {
    .text-overlay {
        left: 4%;
        right: 4%;
        width: 92%;
        top: auto;
        bottom: 15px;
        transform: none;
    }

    /* Reduce line height for large heading on small screens */
    .text-overlay .tw-leading-\[85px\] {
        line-height: 1.2 !important;
    }

    .image-container {
        height: 450px;
    }
}

/* Section container styling */
section {
    display: flex;
    flex-direction: column;
    align-items: left;
    /*margin-top: 20px; Space between header and section */
}

.padding-fix {
    -webkit-padding-start: 0px;
    /* Adjust as needed */
}

/*@media not all and (min-resolution: 0.001dpcm) and (min--moz-device-pixel-ratio: 0) {
    .safari-padding-fix {
        padding-bottom: 0 !important;
    }
}
*/
.safari-padding-fix {
    padding-bottom: 12px;
    /* or any other padding value */
}

/*@supports (-webkit-touch-callout: none) {
    .safari-padding-fix {
        padding-bottom: 0 !important;
    }
}*/

.safari-box-sizing {
    box-sizing: border-box;
}

.bi-bluesky::before {
    content: "";
    /*    background-image: url("../assets/images/icons/bluesky.svg") no-repeat*/
    background-color: currentColor;
    -webkit-mask: url("../assets/images/icons/bluesky.svg") no-repeat 50% 50%;
    mask: url("../assets/images/icons/bluesky.svg") no-repeat 50% 50%;
    -webkit-mask-size: contain;
    mask-size: contain;
    height: 32px;
    width: 24px;
}

/* Search functionality styles */
.tw-line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Search Modal Overlay */
.search-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 9999;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 20px;
    padding-top: 80px;
    opacity: 1;
    transition: opacity 0.2s ease-in-out;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.search-modal-overlay.search-hidden {
    display: none;
    opacity: 0;
}

.search-modal-overlay.search-visible {
    display: flex;
    opacity: 1;
}

/* Search Modal Content */
.search-modal-content {
    background: white;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    width: 100%;
    max-width: 700px;
    max-height: calc(100vh - 100px);
    display: flex;
    flex-direction: column;
    transform: translateY(0);
    transition: transform 0.2s ease-in-out;
    border: 2px solid #d1d5db;
}

.search-hidden .search-modal-content {
    transform: translateY(-20px);
}

/* Search Header */
.search-header {
    padding: 12px 16px;
    border-bottom: 1px solid #e5e7eb;
}

.search-input-container {
    display: flex;
    align-items: center;
    gap: 10px;
}

.search-input-container i.bi-search {
    color: #9ca3af;
    font-size: 18px;
    flex-shrink: 0;
}

.search-input-container input {
    flex: 1;
    border: none;
    outline: none;
    font-size: 16px;
    color: #111827;
    background: transparent;
}

.search-input-container input::placeholder {
    color: #9ca3af;
}

.search-close-btn {
    background: transparent;
    border: none;
    color: #9ca3af;
    cursor: pointer;
    padding: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: background-color 0.2s, color 0.2s;
    flex-shrink: 0;
}

.search-close-btn:hover {
    background-color: #f3f4f6;
    color: #4b5563;
}

/* Search Results Container */
.search-results {
    flex: 1;
    overflow-y: auto;
    padding: 12px 16px;
    -webkit-overflow-scrolling: touch;
}

/* Empty State */
.search-empty-state {
    color: #9ca3af;
    text-align: center;
    padding: 60px 20px;
    font-size: 16px;
}

/* Search Result Item */
.search-result-item {
    display: block;
    padding: 12px;
    background-color: #f3f3f3b4;
    border: 2px solid transparent;
    margin-bottom: 10px;
    transition: border-color 0.15s;
    text-decoration: none;
    color: inherit;
}

.search-result-item:hover {
    border-color: #4b5563;
}

.search-result-content {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

/* Search Result Thumbnail */
.search-result-thumbnail {
    width: 80px;
    height: 80px;
    flex-shrink: 0;
    overflow: hidden;
    position: relative;
}

.search-result-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Search Badge */
.search-badge {
    padding: 4px 8px;
    font-size: 10px;
    font-weight: 500;
    white-space: nowrap;
    width: fit-content;
    border: 1px solid;
}

/* Badge Overlay on Thumbnail */
.search-badge-overlay {
    position: absolute;
    top: 0;
    left: 0;
    padding: 3px 6px;
    font-size: 9px;
    opacity: 0.85;
    line-height: 1.2;
    max-width: 80px;
    word-wrap: break-word;
}

.search-badge-paper {
    background-color: #dbeafe;
    color: #1e40af;
    border-color: #1e40af;
}

.search-badge-person {
    background-color: #d1fae5;
    color: #065f46;
    border-color: #065f46;
}

.search-badge-area {
    background-color: #e9d5ff;
    color: #6b21a8;
    border-color: #6b21a8;
}

/* Search Result Text */
.search-result-text {
    flex: 1;
    min-width: 0;
}

.search-result-title {
    font-weight: 500;
    color: #111827;
    margin-bottom: 4px;
    line-height: 1.4;
}

.search-result-subtitle {
    font-size: 14px;
    color: #6b7280;
    line-height: 1.4;
    margin-top: 4px;
    font-family: "Iowan Old Style", "Apple Garamond", Baskerville, "Times New Roman", "Droid Serif", Times, "Source Serif Pro", serif;
}

/* Search Result Arrow */
.search-result-arrow {
    color: #9ca3af;
    font-size: 16px;
    flex-shrink: 0;
    align-self: center;
}


/* Add blue underline to h2 section titles h3::after {
    content: '';
    display: block;
    width: 40px;
    height: 5px;
    background-color: #3b82f6;
    margin-top: 0.5rem;
    margin-bottom: 0.75rem;
} */

/* Section underline styling - thicker, shorter, less space above */
.section-underline {
    display: block;
    background-color: #3b82f6 !important;
    height: 6px !important;
    width: 45px !important;
    margin-top: 0.5rem !important;
    margin-bottom: 0.75rem !important;
    min-height: 6px;
    content: '';
}

@media (max-width: 768px) {
    .section-underline {
        height: 4px !important;
        width: 30px !important;
        min-height: 4px;
    }
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .search-modal-overlay {
        padding: 10px;
        padding-top: 60px;
        align-items: flex-start;
    }

    .search-modal-content {
        max-height: calc(100vh - 70px);
    }

    .search-result-thumbnail {
        width: 60px;
        height: 60px;
    }

    .search-badge-overlay {
        top: 0;
        left: 0;
        padding: 2px 5px;
        font-size: 8px;
        max-width: 60px;
    }

    .search-header {
        padding: 16px;
    }

    .search-input-container input {
        font-size: 16px;
    }

    .search-results {
        padding: 12px 16px;
    }

    .search-result-item {
        padding: 12px;
    }

    .search-result-content {
        gap: 10px;
    }

    .search-result-title {
        font-size: 15px;
    }

    .search-result-subtitle {
        font-size: 13px;
    }

    .search-empty-state {
        padding: 40px 20px;
        font-size: 15px;
    }
}

/* Extra small screens */
@media (max-width: 480px) {
    .search-modal-overlay {
        padding: 5px;
        padding-top: 50px;
    }

    .search-modal-content {
        max-height: calc(100vh - 60px);
    }

    .search-result-thumbnail {
        width: 50px;
        height: 50px;
    }

    .search-badge-overlay {
        top: 0;
        left: 0;
        padding: 2px 4px;
        font-size: 7px;
        max-width: 50px;
    }
}