/* Section Styles */
.section {
    max-width: 1250px;
    margin: 0 auto;
    width: 95%;
    padding: 50px 100px;
    padding-top: 30px;
    display: flex;
    flex-direction: column;
    gap: 25px;
    position: relative;
    margin-top: calc(45vh * -0.15);
    background: white;
    z-index: 10;
}

.section-title,
.section h2 {
    font-weight: 700;
    font-size: 32px;
    color: #1a1a1a;
    /* Very dark grey, almost black */
    margin-bottom: 12px;
    position: relative;
    display: inline-block;
    /* Essential to make the underline match the text */
    text-transform: none;
    hyphens: auto;
    word-wrap: break-word;
    overflow-wrap: break-word;
    /* Reference image uses sentence case */
}

.section-title::after,
.section h2::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -8px;
    /* Gap between text and line */
    width: 60px;
    /* The short length seen in your image */
    height: 3px;
    /* The thickness of the blue line */
    background-color: #8A244B;
    /* The specific Cambridge-style blue */
}

.subsection-title,
.section h3 {
    font-family: "Source Sans 3", sans-serif;
    font-weight: 600;
    font-size: 22px;
    color: #333333;
    margin-top: 20px;
    margin-bottom: 10px;
    position: relative;
    display: block;
    hyphens: auto;
    word-wrap: break-word;
    overflow-wrap: break-word;
    /* Subheadings usually take full width */
}

/* Subtle accent for subheadings */
.subsection-title::after,
.section h3::after {
    content: "";
    display: block;
    width: 30px;
    height: 2px;
    background-color: #208b3a;
    /* Your brand green */
    margin-top: 5px;
}

.section-paragraph,
.section p {
    font-weight: 400;
    font-size: 18px;
    line-height: 1.7em;
    word-spacing: 0.5;
    color: #000000;
    width: 100%;
    text-align: left;
    hyphens: auto;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.button-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: fit-content;
    padding: 10px 20px;
    font-size: 16px;
    font-weight: 500;
    letter-spacing: 0.3px;
    color: #FFFFFF;
    text-decoration: none;
    background-color: #544bad;
    border: 1px solid transparent;
    border-radius: 6px;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(84, 75, 173, 0.2);
    transition: background-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.button-primary:hover {
    background-color: #423b8f;
    box-shadow: 0 4px 8px rgba(84, 75, 173, 0.3);
    transform: translateY(-1px);
}

.button-primary:active {
    background-color: #393382;
    box-shadow: 0 1px 2px rgba(84, 75, 173, 0.2);
    transform: translateY(0);
}

.button-primary:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px rgba(84, 75, 173, 0.4);
}

.button-hightlight {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    align-self: center;
    width: fit-content;
    padding: 14px 26px;
    font-family: 'Allerta', sans-serif;
    font-weight: 600;
    font-size: 16px;
    letter-spacing: 0.5px;
    color: #FFFFFF;
    text-decoration: none;
    background: linear-gradient(135deg, #0056b3 0%, #004494 100%);
    border: none;
    border-radius: 50px;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 86, 179, 0.3);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.button-hightlight:hover {
    background: linear-gradient(135deg, #0069d9 0%, #0056b3 100%);
    box-shadow: 0 6px 16px rgba(0, 86, 179, 0.45);
    transform: translateY(-2px);
}

.button-hightlight:active {
    transform: translateY(1px);
    box-shadow: 0 2px 6px rgba(0, 86, 179, 0.3);
}

.ithc-list,
.section ul {
    font-size: 16px;
    line-height: 1.6em;
    color: #000;
    padding-left: 20px;
    hyphens: auto;
    word-wrap: break-word;
    overflow-wrap: break-word;
}


.ithc-list li,
.section li {
    margin-bottom: 10px;
}

.ithc-list li,
.section li p {
    font-size: 16px !important;
}

.ithc-table,
.section table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 10px;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    text-align: left;
}

.ithc-table th,
.ithc-table td,
.section th,
.section td {
    border: 1px solid #e6e6e6;
    color: #334155;
    padding: 12px;
    font-size: 16px;
    font-weight: 400;
    color: #000;
    hyphens: auto;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.ithc-table th,
.ithc-table td,
.section th p,
.section td p {
    font-size: 16px !important;
    padding: 10px !important;
}

.ithc-table th:first-child,
.ithc-table td:first-child,
.section table th:first-child,
.section table td:first-child {
    width: 1%;
    white-space: nowrap;
    padding-right: 20px;
}

.ithc-table th:nth-child(2),
.ithc-table td:nth-child(2),
.section table th:nth-child(2),
.section table td:nth-child(2) {
    text-align: left;
}

.ithc-table th,
.section th {
    background-color: #f8fafc;
    font-weight: 600;
    text-transform: capitalize;
}

.ithc-table tr:nth-child(even),
.section table tr:nth-child(even) {
    background-color: #f9f9f9;
}

.btn-table-action {
    display: inline-flex;
    align-items: center;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    white-space: nowrap;
    transition: all 0.2s ease-in-out;
}

/* Hover effect: Fills with blue background and adds a soft shadow */
.btn-table-action:hover {
    color: #2b6cb0;
}

/* Smooth transition for the arrow icon */
.btn-table-action .action-icon {
    transition: transform 0.2s ease;
}

/* Container for the pagination */
.pagination-wrapper .pagination {
    display: flex;
    gap: 8px;
    /* Adds space between the numbers */
    list-style: none;
    padding: 0;
    margin: 0;
    align-items: center;
}

/* Base style for the pagination buttons (Numbers, Prev, Next) */
.pagination-wrapper .page-link {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    /* Makes sure single digits are perfect squares */
    height: 36px;
    padding: 0 12px;
    background-color: #ffffff;
    color: #4a5568;
    /* Slate gray text */
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease-in-out;
}

/* Hover state for inactive numbers */
.pagination-wrapper .page-link:hover {
    background-color: #eff6ff;
    /* Soft blue background */
    color: #2b6cb0;
    /* Academic blue text */
    border-color: #2b6cb0;
}

/* Active state (The current page you are on) */
.pagination-wrapper .page-item.active .page-link {
    background-color: #2b6cb0;
    color: #ffffff;
    border-color: #2b6cb0;
    box-shadow: 0 2px 4px rgba(43, 108, 176, 0.2);
    pointer-events: none;
    /* Prevents clicking the active page */
}

/* Disabled state (e.g., the 'Previous' button when you are on Page 1) */
.pagination-wrapper .page-item.disabled .page-link {
    color: #a0aec0;
    background-color: #f8fafc;
    border-color: #e2e8f0;
    pointer-events: none;
    /* Disables clicking */
}

/* Optional: Hide the pesky blue outline that Bootstrap adds on focus */
.pagination-wrapper .page-link:focus {
    box-shadow: 0 0 0 3px rgba(43, 108, 176, 0.2);
    outline: none;
}

/* 1. Shared Layout Containers */
.journal-container,
.membership-container {
    width: 100%;
    max-width: 800px;
    margin: 40px auto;
    padding: 0 15px;
    font-family: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
    color: #2d3748;
}

.form-wrapper,
.membership-form-wrapper {
    background: #ffffff;
    padding: 35px 40px;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.06);
    border: 1px solid #eaeaea;
}

/* 2. Grid & Layout */
.form-row {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}

.form-row .form-group {
    flex: 1;
    min-width: 250px;
    /* Forces stacking on mobile */
}

.form-group {
    margin-bottom: 20px;
}

/* 3. Labels & Inputs */
label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 14px;
    color: #4a5568;
}

.req {
    color: #e53e3e;
    margin-left: 2px;
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="file"],
select,
textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    font-size: 15px;
    background: #fcfcfc;
    transition: all 0.2s ease;
    box-sizing: border-box;
    /* Crucial for layout stability */
}

textarea {
    min-height: 120px;
    resize: vertical;
}

/* 4. Interaction States */
input:focus,
select:focus,
textarea:focus {
    border-color: #3182ce;
    background: #ffffff;
    outline: none;
    box-shadow: 0 0 0 4px rgba(49, 130, 206, 0.1);
}

.is-invalid {
    border-color: #e53e3e !important;
    background-color: #fff5f5 !important;
}

.error-msg {
    display: block;
    color: #e53e3e;
    font-size: 13px;
    margin-top: 6px;
    font-weight: 500;
}

/* 5. Shared Button Base */
.submit-btn {
    width: 100%;
    padding: 14px 24px;
    border: none;
    background-color: #3b70b1;
    color: #ffffff;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.1s active;
}

.submit-btn:hover {
    background-color: #2c5282;
}

.notification-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 10px;
    pointer-events: none;
    /* Allows clicking through the container space */
}

.toast-notification {
    pointer-events: auto;
    /* Re-enables clicking for the toast itself */
    min-width: 300px;
    max-width: 400px;
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    display: flex;
    align-items: center;
    padding: 16px;
    border-left: 6px solid #ccc;
    animation: slideIn 0.3s ease-out;
}

/* Success & Error Colors */
.toast-success {
    border-left-color: #48bb78;
}

.toast-error {
    border-left-color: #e53e3e;
}

.toast-notification .icon {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
    font-weight: bold;
    flex-shrink: 0;
}


.toast-success .icon {
    background: #f0fff4;
    color: #48bb78;
}

.toast-error .icon {
    background: #fff5f5;
    color: #e53e3e;
}

.toast-notification .content {
    flex-grow: 1;
}

.toast-notification .content strong {
    display: block;
    font-size: 14px;
    color: #1a202c;
}

.toast-notification .content span {
    font-size: 13px;
    color: #4a5568;
}

.toast-notification .close-btn {
    background: transparent;
    border: none;
    font-size: 20px;
    color: #a0aec0;
    cursor: pointer;
    padding-left: 10px;
}

.toast-notification {
    position: relative;
    /* Needed for the progress bar positioning */
    overflow: hidden;
}

/* The Progress Bar */
.toast-notification::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    width: 100%;
    background: rgba(0, 0, 0, 0.1);
    animation: progress 10s linear forwards;
}

.toast-success::after {
    background: #48bb78;
}

.toast-error::after {
    background: #e53e3e;
}

@keyframes progress {
    from {
        width: 100%;
    }

    to {
        width: 0%;
    }
}

/* Animations */
@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes fadeOut {
    from {
        opacity: 1;
    }

    to {
        opacity: 0;
    }
}

/*Hompage*/

.section h1 {
    position: relative;
    text-align: center;
    font-size: 36px;
    /* Increased slightly for impact */
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: 2px;
    color: #1a1a1a;
    text-transform: uppercase;
    margin-top: 10px;
    padding-bottom: 20px;
}

/* The "Special" Underline (Cambridge Style) */
.section h1::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background-color: #0070c0;
    /* Deep Journal Blue */
    border-radius: 2px;
}

/* The Decorative Background Letter (Optional but very 'Special') */
.section h1::before {
    content: attr(data-title-start);
    /* Pulls a letter from HTML */
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 120px;
    color: rgba(0, 0, 0, 0.03);
    /* Extremely faint */
    z-index: -1;
    pointer-events: none;
}

.about-section .section-paragraph {
    font-weight: 400;
    font-size: 20px;
    line-height: 1.5em;
}

.conference-grid {
    width: 100%;
    max-width: 1200px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 25px;
    margin: 0px auto;
    margin-bottom: 50px;
}

/* Base Card with Cambridge Border */
.conference-card {
    width: 100%;
    max-width: 400px;
    background: #fff;
    border: 1px solid #E6E6E6;
    padding: 20px;
    border-top: 4px solid #0070c0;
    hyphens: auto;
    word-wrap: break-word;
    overflow-wrap: break-word;
    transition: 0.3s;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.conference-card:hover {
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
}

.conference-card-title {
    font-weight: 600;
    font-size: 18px;
    line-height: 1.5em;
    color: #000000;
    margin: 0;
}

.conference-detail {
    display: flex;
    width: 100%;
}

.detail-row {
    display: flex;
    flex-direction: column;
    gap: 2px;
    width: 100%;
}

.detail-label {
    font-weight: 600;
    font-size: 16px;
    line-height: 1.5em;
    color: #000000;
}

.detail-label-small {
    font-weight: 500;
    font-size: 16px;
    line-height: 1.5em;
    color: #000000;
}

.detail-value {
    font-weight: 500;
    font-size: 16px;
    line-height: 1.5em;
    color: #828282;
}


/* Status Badge */
.status-badge {
    color: #208b3a;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 10px;
}


/* Archive Style (More Muted) */
.archive-card {
    border-top: 1px solid #eee;
    background: #fcfcfc;
}

.card-title-sm {
    font-size: 16px;
    color: #333;
}

.link-secondary {
    font-size: 13px;
    color: #0070c0;
    text-decoration: none;
    font-weight: 600;
}

.conference-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 25px;
}

.conference-img {
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
}

.conference-img img {
    width: 100%
}


/* Journals Section */

.journal-nav-bar {
    background-color: #ffffff;
    border-bottom: 2px solid #eee;
    padding: 15px 0;
}

.nav-container {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
}

.nav-btn {
    text-decoration: none;
    color: #333;
    padding: 8px 16px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.nav-btn:hover {
    background-color: #f0f0f0;
    color: #0056b3;
    /* Change to your brand color */
    border-color: #0056b3;
}


/* Highlight the Submit button */
.nav-btn.highlight-btn {
    background-color: #0056b3;
    color: white;
    border-color: #0056b3;
}

.nav-btn.highlight-btn:hover {
    background-color: #004494;
}

#about,
#board,
#guideandpolicy,
#submission, #object, #exe_commee, #advi_board, #n_exe_mem, #stra_act_commee, #n_inter_mem {
    scroll-margin-top: 110px;
}


/*Archive Page*/
.volume-img {
    width: 100%;
    max-width: 260px;
}

.volume-img img {
    width: 100%
}

.journal-card:hover {
    background-color: rgba(0, 0, 0, 0.2);
}

.journal-card-title {
    font-weight: 500;
    font-size: 18px;
    line-height: 1.5em;
    color: #000000;
    margin: 0;
}

.previous-issues-title {
    margin-top: 25px;
}


/* About Page */

.committee-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.committee-card {
    background-color: #f4f4f4;
    border: 1px solid #E6E6E6;
    padding: 20px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.12);
    transition: transform 0.2s ease;
    text-align: center;
    max-width: 300px;
    width: 100%;
    margin: 0px auto;
}

.committee-card img {
    width: 175px;
    height: 175px;
    object-fit: cover;
    border-radius: 50%;
    margin-bottom: 10px;
    border: 3px solid #e6e6e6;
}

.committee-card h3 {
    margin: 8px 0 5px;
    font-size: 18px;
}

.position {
    font-weight: 600 !important;
    font-size: 18px !important;
    color: #0046FF !important;
    text-align: center !important;
}

.details {
    font-size: 16px !important;
    color: #555 !important;
    margin: 5px 0 !important;
    text-align: center !important;
}

/* Contact Section */
.contact-section {
    background-color: #e9f3f6;
    padding: 50px 10%;
}

.contact-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 50px;
}

.contact-info,
.contact-form {
    flex: 1 1 45%;
}

.contact-info h2,
.contact-form h2 {
    font-size: 1.8rem;
    margin-bottom: 20px;
    color: #1c1c1c;
}

.contact-info p {
    font-size: 16px;
    line-height: 1.6;
    color: #222;
}

.contact-info a {
    color: #2e7d32;
    text-decoration: none;
    font-weight: bold;
}

.contact-info a:hover {
    text-decoration: underline;
}

/* Form Styling */
.contact-form form {
    display: flex;
    flex-direction: column;
}

.contact-form label {
    font-weight: bold;
    margin-top: 15px;
    color: #1a1a1a;
}

.contact-form span {
    font-weight: normal;
    color: #666;
    font-size: 0.9rem;
}

.contact-form input,
.contact-form textarea,
.contact-form select {
    padding: 10px;
    border: 1px solid #ccc;
    margin-top: 5px;
    font-size: 1rem;
    border-radius: 4px;
    background-color: #fff;
}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: #2e7d32;
    outline: none;
}

.contact-form button {
    background-color: #1c1c1c;
    color: #fff;
    border: none;
    padding: 12px 0;
    font-size: 1rem;
    border-radius: 4px;
    margin-top: 20px;
    cursor: pointer;
    transition: 0.3s;
}

.contact-form button:hover {
    background-color: #333;
}

/* Responsive Design */
@media screen and (max-width: 1440px) {
    .section {
        padding-left: 25px;
        padding-right: 25px;
    }
}

@media screen and (max-width: 1024px) {
    .journal-cards-previous {
        flex-wrap: wrap;
    }
}

@media screen and (max-width: 768px) {

    .section {
        padding: 30px 20px;
        padding-top: 15px;
    }

    .section h1 {
        text-align: center;
        font-size: 28px;
        font-weight: 700;
    }

    .section-title,
    .section h2 {
        font-size: 26px;
        line-height: 1.3em;
    }

    .subsection-title,
    .section h3 {
        font-size: 18px;
        line-height: 1.3em;
    }

    .about-section .section-paragraph,
    .section p {
        font-size: 16px;
    }

    .conference-cards {
        flex-direction: column;
    }

    .conference-card {
        padding: 10px;
    }

    .section-paragraph,
    .journal-card-title,
    .conference-card-title {
        font-size: 14px;
    }

    .detail-label,
    .detail-value {
        font-size: 14px;
    }

    .ithc-list,
    .section ul {
        font-size: 14px;
    }

    .ithc-list li,
    .section li p {
        font-size: 14px !important;
    }

    .ithc-table th,
    .ithc-table td,
    .section th,
    .section td {
        font-size: 16px;
        padding: 10px;
    }

    .ithc-table th,
    .ithc-table td,
    .section th p,
    .section td p {
        font-size: 14px !important;
        padding: 15px !important;
    }

    .ithc-table,
    .section table {
        width: 100%;
        border-collapse: collapse;
        margin-top: 10px;
        overflow-x: auto;
        display: block;
        -webkit-overflow-scrolling: touch;
    }

    .ithc-table th,
    .ithc-table td,
    .section th,
    .section td {
        white-space: nowrap;
    }

    .committee-card {
        padding: 15px;
    }

    .committee-card img {
        width: 150px;
        height: 150px;
    }

    .committee-card h3 {
        font-size: 16px;
    }

    .position {
        font-size: 16px !important;
    }

    .details {
        font-size: 14px !important;
    }

    .contact-container {
        flex-direction: column;
    }

    .contact-info,
    .contact-form {
        flex: 1 1 100%;
    }

}

@media screen and (max-width: 468px) {

    .section {
        padding-left: 15px;
        padding-right: 15px;
    }

    .button-primary {
        font-size: 14px;
    }

    .button-hightlight {
        font-size: 14px;
    }

    .nav-btn {
        font-size: 14px;
        padding: 6px 12px;
    }

    .journal-form .form-row {
        flex-direction: column;
        gap: 0;
    }

    .form-wrapper {
        padding: 20px;
    }
}
