/* 
overrides.css - Custom CSS overrides for CyberOptics portfolio site
Intentionally minimal.
   Use this file only for small, controlled overrides.
   Keep your Webflow CSS untouched to preserve exact visuals. */


/* Ensure body background color is black */

body,
.body {
    background-color: #000 !important;
    font-family: 'neue-haas-grotesk-display', sans-serif;
    font-family: 'Montserrat', sans-serif;
}

.error-message {
    display: none;
    /* Hide the error message by default */
}


/* Background Image Container */

.background-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    overflow: hidden;
    z-index: -1;
}

.background-container img {
    position: absolute;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 2s ease-in-out;
}

.background-container img.active {
    opacity: 1;
}


/* Grid Container */

.grid-container {
    height: calc(100vh - 80px);
}


/* Vertical Text - Left (Name) */

.vertical-text-left {
    animation: slideInVertical 1.5s ease-in-out forwards;
    font-family: 'Montserrat', sans-serif;
}


/* Main Title */

.main-title {
    animation: slideInHorizontal 1.5s ease-in-out forwards;
    font-family: 'Montserrat', sans-serif;
}

.impact-text {
    position: absolute;
    top: 125px;
    left: 110px;
    background: rgba(0, 13, 38, 0.5);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 24px 20px;
    max-height: 234px;
    max-width: 500px;
    z-index: 999;
    text-align: left;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
    opacity: 0;
    transform: translateY(10px);
    animation: fadeSlideIn 1.2s ease-out forwards;
    animation-delay: 0.7s;
    font-family: 'Montserrat', sans-serif;
}

.login-btn {
    transition: transform 0.3s ease, background-color 0.3s ease;
}

.login-btn:hover {
    transform: scale(1.06);
    box-shadow: 0 4px 20px rgba(156, 120, 240, 0.3);
}

@keyframes fadeSlideIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.impact-text:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 36px rgba(0, 0, 0, 0.28);
}

.impact-heading {
    font-family: 'Montserrat', sans-serif;
    font-weight: 900;
    font-size: 1.4rem;
    color: #FE40FE;
    line-height: 1.4;
    margin-bottom: 12px;
    font-family: 'Montserrat', sans-serif;
}

.impact-subheading {
    font-family: 'Montserrat', sans-serif;
    font-weight: 400;
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.5;
    margin: 0;
}


/* General Styles for Social Links */

.social-links-area {
    display: flex;
    gap: 20px;
}

.fab {
    font-size: 60px;
}

a.social-link {
    height: 100%
}

.social-link,
.resume {
    opacity: 0;
    /* Start hidden */
    transform: translateY(20px);
    /* Start slightly below */
    transition: opacity 0.5s ease, transform 0.5s ease;
    /* Smooth animations */
}

.social-link:hover .fab,
.resume:hover .fab {
    color: #7e6cf3;
    /* Hover effect for icons */
}

.resume {
    height: 54px;
    font-family: Montserrat, sans-serif !important;
    font-weight: 700 !important;
    margin-top: 3px;
}

.password-container {
    position: relative;
}

#password-input {
    width: 100%;
    padding-left: 40px;
}

#toggle-password {
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
}

#password-input {
    width: 100%;
    padding-left: 40px;
    background-color: rgb(58, 56, 129);
    /* Purple background */
    color: white;
    /* White text */
    outline: none;
    /* Remove default browser outline */
    border-radius: 8px;
    /* Smooth edges */
    font-size: 16px;
    /* Comfortable font size */
    transition: background-color 0.3s ease, border-color 0.3s ease;
    /* Smooth transition */
}

#password-input:focus {
    background-color: rgba(75, 72, 144, 1);
    /* Slightly lighter purple when focused */
    border-color: rgba(255, 255, 255, 0.6);
    /* Add a light border on focus */
    box-shadow: 0 0 5px rgba(58, 56, 129, 0.6);
    /* Subtle glow */
}

#toggle-password {
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: white;
    /* Match icon color with text */
    font-size: 18px;
}

#toggle-password:hover {
    color: rgba(255, 255, 255, 0.8);
    /* Slight hover effect for better UI feedback */
}

.impact-chat-trigger {
    appearance: none;
    width: 100%;
    max-width: 500px;
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.impact-chat-trigger .impact-kicker {
    display: inline-block;
    margin-bottom: 10px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.74);
}

.impact-chat-trigger .impact-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-top: 18px;
    padding: 10px 14px;
    border-radius: 999px;
    background: linear-gradient(135deg, #7e2cde, #3325a3);
    color: #fff;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.8rem;
    font-weight: 700;
    line-height: 1;
}

.portfolio-chat-shell {
    position: fixed;
    inset: 0;
    z-index: 5000;
    display: flex;
    justify-content: center;
    align-items: stretch;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.42s cubic-bezier(0.22, 1, 0.36, 1), visibility 0.42s linear;
}

.portfolio-chat-shell.is-open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.portfolio-chat-backdrop {
    position: absolute;
    inset: 0;
background:
    radial-gradient(circle at 20% 20%, rgba(126, 44, 222, 0.14), transparent 28%),
    radial-gradient(circle at 80% 30%, rgba(80, 120, 255, 0.10), transparent 26%),
    rgba(2, 6, 18, 0.78);
backdrop-filter: blur(14px) saturate(125%);
-webkit-backdrop-filter: blur(14px) saturate(125%);
}

.portfolio-chat-panel {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    width: min(920px, calc(100vw - 56px));
    height: calc(100vh - 56px);
    margin: 28px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 22px;
    background:
        radial-gradient(circle at top left, rgba(126, 44, 222, 0.12), transparent 24%),
        radial-gradient(circle at top right, rgba(70, 110, 255, 0.07), transparent 22%),
        linear-gradient(180deg, rgba(8, 12, 28, 0.965), rgba(6, 10, 22, 0.985));
    box-shadow:
        0 22px 70px rgba(0, 0, 0, 0.34),
        inset 0 1px 0 rgba(255, 255, 255, 0.04);
    overflow: hidden;
    transform: translateY(34px) scale(0.965);
    transition: transform 0.48s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.48s cubic-bezier(0.22, 1, 0.36, 1);
}
.portfolio-chat-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
    padding: 24px 24px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.portfolio-chat-eyebrow {
    margin: 0 0 8px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.11em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.52);
}

.portfolio-chat-title {
    margin: 0 0 10px;
    font-family: 'Montserrat', sans-serif;
    font-size: clamp(1.2rem, 1.6vw, 1.65rem);
    font-weight: 700;
    line-height: 1.16;
    color: rgba(255, 255, 255, 0.96);
}

.portfolio-chat-intro {
    margin: 0;
    max-width: 700px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.9rem;
    line-height: 1.55;
    color: rgba(255, 255, 255, 0.72);
}
.portfolio-chat-body {
    opacity: 0;
    transform: translateY(18px);
    transition:
        opacity 0.38s cubic-bezier(0.22, 1, 0.36, 1),
        transform 0.38s cubic-bezier(0.22, 1, 0.36, 1);
}

.portfolio-chat-shell.is-open .portfolio-chat-header {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.12s;
}

.portfolio-chat-shell.is-open .portfolio-chat-body {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.18s;
}
.portfolio-chat-shell.is-open .portfolio-chat-panel {
    transform: translateY(0) scale(1);
}

.portfolio-chat-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 24px;
    padding: 28px 28px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.portfolio-chat-header-copy {
    max-width: 720px;
}

.portfolio-chat-eyebrow {
    margin: 0 0 10px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.66);
}

.portfolio-chat-title {
    margin: 0 0 12px;
    font-family: 'Montserrat', sans-serif;
    font-size: clamp(1.4rem, 2vw, 2rem);
    font-weight: 800;
    line-height: 1.15;
    color: #fff;
}

.portfolio-chat-intro {
    margin: 0;
    max-width: 760px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.98rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.88);
}

.portfolio-chat-close {
    flex: 0 0 auto;
    width: 40px;
    height: 40px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04);
    color: rgba(255, 255, 255, 0.82);
    font-size: 1.45rem;
    line-height: 1;
    transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.portfolio-chat-close:hover {
    background: rgba(255, 255, 255, 0.07);
    border-color: rgba(255, 255, 255, 0.08);
    transform: translateY(-1px);
}

.portfolio-chat-body {
    display: flex;
    flex-direction: column;
    min-height: 0;
    flex: 1;
}

.portfolio-chat-jd-strip {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    margin: 0 24px;
    padding: 14px 16px;
    border: 1px solid rgba(148, 88, 255, 0.18);
    border-radius: 18px;
    background:
        radial-gradient(circle at top left, rgba(194, 96, 255, 0.08), transparent 34%),
        linear-gradient(180deg, rgba(24, 8, 54, 0.94), rgba(17, 7, 44, 0.96));
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.03),
        0 10px 24px rgba(0, 0, 0, 0.14);
}

.portfolio-chat-jd-strip-label {
    margin: 0 0 6px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.56);
}

.portfolio-chat-jd-strip-title {
    margin: 0 0 6px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.95rem;
    font-weight: 700;
    line-height: 1.4;
    color: rgba(255, 255, 255, 0.96);
}

.portfolio-chat-jd-strip-meta {
    margin: 0;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.82rem;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.78);
}

.portfolio-chat-jd-strip-actions {
    display: flex;
    gap: 8px;
    flex: 0 0 auto;
}

.portfolio-chat-jd-strip-button {
    appearance: none;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 999px;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.04);
    color: #fff;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
}

.portfolio-chat-edit-modal {
    margin: 14px 24px 0;
}

.portfolio-chat-edit-card {
    border: 1px solid rgba(148, 88, 255, 0.18);
    border-radius: 18px;
    padding: 16px;
    background:
        radial-gradient(circle at top left, rgba(194, 96, 255, 0.08), transparent 34%),
        linear-gradient(180deg, rgba(24, 8, 54, 0.94), rgba(17, 7, 44, 0.96));
}

.portfolio-chat-edit-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
}

.portfolio-chat-edit-title {
    margin: 0;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.95rem;
    font-weight: 700;
    color: #fff;
}

.portfolio-chat-edit-close {
    width: 32px;
    height: 32px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04);
    color: rgba(255, 255, 255, 0.8);
    cursor: pointer;
}

.portfolio-chat-edit-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.portfolio-chat-edit-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.75rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.8);
}

.portfolio-chat-edit-input {
    width: 100%;
    min-height: 44px;
    padding: 10px 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.04);
    color: #fff;
    font-family: 'Montserrat', sans-serif;
}

.portfolio-chat-edit-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 14px;
}

@media (max-width: 768px) {
    .portfolio-chat-jd-strip {
        margin-left: 18px;
        margin-right: 18px;
        flex-direction: column;
    }

    .portfolio-chat-edit-modal {
        margin-left: 18px;
        margin-right: 18px;
    }

    .portfolio-chat-edit-grid {
        grid-template-columns: 1fr;
    }
}

.portfolio-chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 22px 24px 120px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    scrollbar-width: none;
}

.portfolio-chat-messages::-webkit-scrollbar {
    display: none;
}

.portfolio-chat-message {
    max-width: 680px;
    padding: 13px 15px;
    border-radius: 16px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.9rem;
    line-height: 1.58;
}

.portfolio-chat-message-assistant {
    align-self: flex-start;
    background:
        linear-gradient(180deg, rgba(23, 8, 52, 0.9), rgba(16, 7, 42, 0.9));
    color: rgba(255, 255, 255, 0.92);
    border: 1px solid rgba(147, 90, 255, 0.16);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.portfolio-chat-message-user {
    align-self: flex-end;
    background:
        linear-gradient(135deg, rgba(126, 44, 222, 0.92), rgba(68, 133, 255, 0.84));
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.06);
    box-shadow: 0 10px 24px rgba(50, 32, 142, 0.22);
}

.portfolio-chat-thinking {
    min-width: 78px;
    max-width: 78px;
    padding: 14px 16px;
}

.portfolio-chat-thinking-dots {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.portfolio-chat-thinking-dots span {
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.78);
    animation: portfolioChatThinkingPulse 1.1s infinite ease-in-out;
}

.portfolio-chat-thinking-dots span:nth-child(2) {
    animation-delay: 0.14s;
}

.portfolio-chat-thinking-dots span:nth-child(3) {
    animation-delay: 0.28s;
}

@keyframes portfolioChatThinkingPulse {
    0%, 80%, 100% {
        opacity: 0.35;
        transform: translateY(0);
    }
    40% {
        opacity: 1;
        transform: translateY(-2px);
    }
}

.portfolio-chat-inputbar {
    position: sticky;
    bottom: 0;
    z-index: 8;
    display: flex;
    align-items: flex-end;
    gap: 12px;
    padding: 18px 24px 22px;
    background: linear-gradient(180deg, rgba(6, 10, 38, 0), rgba(6, 10, 38, 0.92) 28%, rgba(6, 10, 38, 0.98));
    border-top: 1px solid rgba(255, 255, 255, 0.04);
}

.portfolio-chat-input {
   
    min-height: 54px;
    max-height: 54px;
    padding: 15px 16px;
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.04);
    color: #fff;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.9rem;
    line-height: 1.5;
    overflow: scroll;
    scrollbar-width: none;
    transition: border-color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
    min-width: calc(100% - 100px);
}
.portfolio-chat-input:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.055);
    border-color: rgba(165, 147, 255, 0.22);
    box-shadow: 0 0 0 3px rgba(165, 147, 255, 0.06);
}

.portfolio-chat-input::placeholder {
    color: rgba(255, 255, 255, 0.42);
}

.portfolio-chat-input::-webkit-scrollbar {
    display: none;
}

.portfolio-chat-send {
    align-self: end;
    min-width: 98px;
    height: 54px;
    padding: 0 18px;
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.05);
    color: rgba(255, 255, 255, 0.92);
    font-family: 'Montserrat', sans-serif;
    font-size: 0.88rem;
    font-weight: 700;
    transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.portfolio-chat-send:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.11);
    transform: translateY(-1px);
}

.portfolio-chat-send.is-busy,
.portfolio-chat-card-button.is-busy,
.portfolio-chat-chip.is-busy {
    opacity: 0.65;
    pointer-events: none;
}

.portfolio-chat-status {
    padding: 0 24px 12px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.8rem;
    line-height: 1.45;
    color: rgba(255, 255, 255, 0.62);
}

.portfolio-chat-status.is-error {
    color: rgba(255, 180, 180, 0.92);
}

.portfolio-chat-status.is-success {
    color: rgba(190, 255, 210, 0.92);
}

.portfolio-chat-message-intro {
    max-width: 760px;
}

.portfolio-chat-message-label {
    margin: 0 0 8px;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.52);
}

.portfolio-chat-response-cards {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.portfolio-chat-quick-actions {
    display: flex;
    flex-wrap: nowrap;
    gap: 12px;
    margin: 2px 0 16px;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
}

.portfolio-chat-quick-actions::-webkit-scrollbar {
    display: none;
}

.portfolio-chat-secondary-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 4px 0 14px;
}

.portfolio-chat-chip-primary {
    background: linear-gradient(135deg, rgba(126, 44, 222, 0.94), rgba(95, 120, 255, 0.88));
    box-shadow: 0 10px 22px rgba(50, 32, 142, 0.18);
}

.portfolio-chat-edit-grid-jd {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.portfolio-chat-edit-consent {
    display: grid;
    grid-template-columns: 18px 1fr;
    gap: 10px;
    align-items: start;
    margin-top: 14px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.74rem;
    line-height: 1.5;
    color: rgba(255,255,255,0.78);
}

.portfolio-chat-edit-checkbox {
    margin-top: 2px;
}

.portfolio-chat-edit-field-wide {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 12px;
}

.portfolio-chat-edit-textarea {
    min-height: 180px;
    resize: vertical;
    overflow-y: auto;
    scrollbar-width: none;
}

.portfolio-chat-edit-textarea::-webkit-scrollbar {
    display: none;
}

.portfolio-chat-chip {
margin-top:1px;
    appearance: none;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.04);
    color: rgba(255, 255, 255, 0.92);
    border-radius: 999px;
    padding: 11px 15px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.8rem;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.portfolio-chat-chip:hover,
.portfolio-chat-chip:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(165, 147, 255, 0.22);
    transform: translateY(-1px);
}
#portfolioChatPasteJdChip.is-jd-saved {
    background: #1f8f5f;
    border-color: #1f8f5f;
    color: #fff;
}

#portfolioChatPasteJdChip.is-jd-saved:hover,
#portfolioChatPasteJdChip.is-jd-saved:focus {
    background: #18724c;
    border-color: #18724c;
    color: #fff;
}

#portfolioChatPasteJdChip.is-jd-attention {
    box-shadow: 0 0 0 3px rgba(31, 143, 95, 0.22);
}
#portfolioChatPasteJdChip.is-jd-saved {
    font-weight: 700;
}
.portfolio-chat-card {
    position: relative;
    border: 1px solid rgba(148, 88, 255, 0.2);
    background:
        radial-gradient(circle at top left, rgba(214, 88, 255, 0.07), transparent 30%),
        linear-gradient(180deg, rgba(24, 8, 54, 0.94), rgba(17, 7, 44, 0.96));
    border-radius: 22px;
    padding: 18px 18px 16px;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.03),
        0 16px 34px rgba(0, 0, 0, 0.16);
}

.portfolio-chat-card-eyebrow {
    margin: 0 0 8px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.66rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.5);
}

.portfolio-chat-card-title {
    margin: 0 0 8px;
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.35;
    color: rgba(255, 255, 255, 0.96);
}

.portfolio-chat-card-copy {
    margin: 0;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.88rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.78);
}

.portfolio-chat-card-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 14px;
}

.portfolio-chat-card-button {
    appearance: none;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(126, 44, 222, 0.14);
    color: #fff;
    border-radius: 999px;
    padding: 10px 14px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.78rem;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.portfolio-chat-card-button:hover,
.portfolio-chat-card-button:focus {
    outline: none;
    background: rgba(126, 44, 222, 0.24);
    border-color: rgba(165, 147, 255, 0.24);
    transform: translateY(-1px);
}

.portfolio-chat-footer-note {
    padding: 0 24px 14px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.76rem;
    line-height: 1.45;
    color: rgba(255, 255, 255, 0.48);
}
.portfolio-chat-message-user-compact {
    max-width: 760px;
    width: 100%;
    padding: 0;
    background: transparent;
    border: 0;
}

.portfolio-chat-jd-card {
    border: 1px solid rgba(152, 94, 255, 0.26);
    border-radius: 22px;
    background:
        radial-gradient(circle at top left, rgba(255, 117, 179, 0.12), transparent 32%),
        linear-gradient(135deg, rgba(54, 16, 118, 0.95), rgba(29, 12, 87, 0.96));
    color: #fff;
    overflow: hidden;
    box-shadow:
        0 18px 42px rgba(0, 0, 0, 0.24),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.portfolio-chat-jd-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    padding: 16px 18px 14px;
}

.portfolio-chat-jd-card-copy {
    min-width: 0;
}

.portfolio-chat-jd-card-label {
    margin: 0 0 7px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.72);
}

.portfolio-chat-jd-card-title {
    margin: 0;
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.35;
    color: #fff;
}

.portfolio-chat-jd-card-meta {
    margin: 8px 0 0;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.82rem;
    line-height: 1.45;
    color: rgba(255, 255, 255, 0.82);
}

.portfolio-chat-jd-toggle {
    appearance: none;
    flex: 0 0 auto;
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    border-radius: 999px;
    padding: 10px 12px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.74rem;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.portfolio-chat-jd-toggle:hover,
.portfolio-chat-jd-toggle:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.14);
    transform: translateY(-1px);
}

.portfolio-chat-jd-card-body {
    display: none;
    padding: 0 18px 18px;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.portfolio-chat-jd-card.is-expanded .portfolio-chat-jd-card-body {
    display: block;
}

.portfolio-chat-jd-fulltext {
    margin: 14px 0 0;
    white-space: pre-wrap;
    word-break: break-word;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.85rem;
    line-height: 1.62;
    color: rgba(255, 255, 255, 0.96);
}

.portfolio-chat-fit-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.portfolio-chat-fit-box {
    position: relative;
    border: 1px solid rgba(164, 92, 255, 0.22);
    border-radius: 22px;
    background:
        radial-gradient(circle at top left, rgba(186, 98, 255, 0.08), transparent 34%),
        linear-gradient(180deg, rgba(23, 6, 50, 0.96), rgba(16, 5, 40, 0.94));
    padding: 18px 18px 16px;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.03),
        0 14px 34px rgba(0, 0, 0, 0.18);
    overflow: hidden;
}

.portfolio-chat-fit-box::before {
    content: "";
    display: block;
    width: 42px;
    height: 42px;
    margin-bottom: 14px;
    border-radius: 14px;
    background:
        linear-gradient(135deg, rgba(112, 76, 255, 0.92), rgba(71, 191, 255, 0.92));
    box-shadow:
        0 10px 18px rgba(77, 64, 200, 0.25),
        inset 0 1px 0 rgba(255, 255, 255, 0.18);
}

.portfolio-chat-fit-box-wide {
    grid-column: 1 / -1;
}

.portfolio-chat-fit-label {
    margin: 0 0 8px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.5);
}

.portfolio-chat-fit-title {
    margin: 0;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.98rem;
    font-weight: 700;
    line-height: 1.4;
    color: rgba(255, 255, 255, 0.96);
}

.portfolio-chat-fit-copy {
    margin: 8px 0 0;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.86rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.78);
}

.portfolio-chat-fit-list {
    margin: 10px 0 0;
    padding-left: 18px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.85rem;
    line-height: 1.65;
    color: rgba(255, 255, 255, 0.84);
}

.portfolio-chat-fit-list li + li {
    margin-top: 4px;
}


.portfolio-chat-followup-launcher {
    align-self: flex-start;
    width: min(760px, 100%);
    margin-top: 4px;
    margin-bottom: 6px;
}

.portfolio-chat-followup-launcher.is-hidden {
    display: none;
}

.portfolio-chat-followup-launcher-button {
    appearance: none;
    border: 1px solid rgba(148, 88, 255, 0.18);
    border-radius: 999px;
    padding: 10px 16px;
    background: linear-gradient(135deg, rgba(126, 44, 222, 0.94), rgba(95, 120, 255, 0.88));
    color: #fff;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 10px 22px rgba(50, 32, 142, 0.18);
}

.portfolio-chat-inline-panel {
    position: relative;
    align-self: flex-start;
    width: min(760px, 100%);
    margin-top: 2px;
    padding: 16px 18px 16px;
    border: 1px solid rgba(148, 88, 255, 0.18);
    border-radius: 22px;
    background:
        radial-gradient(circle at top left, rgba(192, 97, 255, 0.08), transparent 30%),
        linear-gradient(180deg, rgba(22, 8, 52, 0.94), rgba(15, 7, 40, 0.95));
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.03),
        0 14px 30px rgba(0, 0, 0, 0.14);
}

.portfolio-chat-inline-panel.is-collapsed,
.portfolio-chat-inline-panel.is-dismissed {
    display: none;
}

.portfolio-chat-inline-panel-controls {
    position: absolute;
    top: 10px;
    right: 10px;
    display: flex;
    gap: 8px;
}

.portfolio-chat-inline-panel-close,
.portfolio-chat-inline-panel-toggle {
    width: 32px;
    height: 32px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04);
    color: rgba(255, 255, 255, 0.78);
    font-size: 0.8rem;
    line-height: 1;
    cursor: pointer;
}

.portfolio-chat-inline-panel-row + .portfolio-chat-inline-panel-row {
    margin-top: 14px;
}

.portfolio-chat-inline-panel-label {
    margin: 0 0 8px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.54);
}

.portfolio-chat-inline-panel-copy {
    margin: 0;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.88rem;
    line-height: 1.58;
    color: rgba(255, 255, 255, 0.9);
}

.portfolio-chat-inline-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.portfolio-chat-inline-chip,
.portfolio-chat-inline-question,
.portfolio-chat-inline-cta {
    appearance: none;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 999px;
    padding: 10px 14px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.8rem;
    font-weight: 700;
    line-height: 1.2;
    cursor: pointer;
    color: #fff;
}

.portfolio-chat-inline-chip,
.portfolio-chat-inline-question {
    background: rgba(255, 255, 255, 0.05);
}

.portfolio-chat-inline-cta {
    background: linear-gradient(135deg, rgba(126, 44, 222, 0.94), rgba(70, 120, 255, 0.88));
    box-shadow: 0 10px 22px rgba(50, 32, 142, 0.2);
}
.portfolio-chat-inline-panel-fit {
    width: min(920px, 100%);
}

.portfolio-chat-fit-readout-title {
    margin: 0 0 14px;
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.4;
    color: rgba(255, 255, 255, 0.96);
}

.portfolio-chat-fit-readout-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.portfolio-chat-fit-readout-card {
    border: 1px solid rgba(148, 88, 255, 0.16);
    border-radius: 18px;
    padding: 14px;
    background:
        radial-gradient(circle at top left, rgba(194, 96, 255, 0.06), transparent 34%),
        linear-gradient(180deg, rgba(28, 10, 60, 0.94), rgba(18, 8, 44, 0.96));
}

.portfolio-chat-fit-readout-rank {
    margin: 0 0 8px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.54);
}

.portfolio-chat-fit-readout-card-title {
    margin: 0 0 6px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.94rem;
    font-weight: 700;
    line-height: 1.35;
    color: rgba(255, 255, 255, 0.96);
}

.portfolio-chat-fit-readout-score {
    margin: 0 0 8px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.82rem;
    font-weight: 700;
    color: rgba(133, 217, 255, 0.96);
}

.portfolio-chat-fit-readout-copy {
    margin: 0;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.84rem;
    line-height: 1.58;
    color: rgba(255, 255, 255, 0.84);
}

@media (max-width: 768px) {
    .portfolio-chat-fit-readout-grid {
        grid-template-columns: 1fr;
    }
}
@media (max-width: 768px) {
    .portfolio-chat-fit-grid {
        grid-template-columns: 1fr;
    }

    .portfolio-chat-jd-card-header {
        flex-direction: column;
        align-items: stretch;
    }

    .portfolio-chat-jd-toggle {
        width: 100%;
        text-align: center;
    }
}
@media (max-width: 768px) {
    .portfolio-chat-quick-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .portfolio-chat-chip,
    .portfolio-chat-card-button {
        width: 100%;
        justify-content: center;
        text-align: center;
    }

    .portfolio-chat-footer-note {
        padding-left: 18px;
        padding-right: 18px;
    }
}
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

body.chat-open {
    overflow: hidden;
}

@media (max-width: 768px) {
    .portfolio-chat-panel {
        width: 100vw;
        height: 100vh;
        margin: 0;
        border-radius: 0;
    }

    .portfolio-chat-header,
    .portfolio-chat-messages,
    .portfolio-chat-inputbar {
        padding-left: 18px;
        padding-right: 18px;
    }

    .portfolio-chat-inputbar {
        grid-template-columns: 1fr;
    }

    .portfolio-chat-send {
        width: 100%;
    }
}

/* Responsive Design */

@media (max-width: 1024px) {
  /*   .main-title {}
    .vertical-text-left {} */
    .fab {
        font-size: 49px;
        /* Smaller icons on tablets */
    }
    .social-links-area {
        gap: 15px;
        /* Reduce spacing */
    }
    .resume {
        height: 50px;
        margin-top: 0;
    }
}
@media (max-width: 768px) {
    .main-title {
        line-height: 3rem;
        font-weight: 200;
    }

    .impact-text {
        top: 80px;
        left: 80px;
        max-width: 60%;
        max-height: 100%;
        padding: 16px;
        display: none;
    }

    .impact-heading {
        font-size: 1.2rem;
    }

    .impact-subheading {
        font-size: 0.8rem;
    }

    .vertical-text-left {
        font-size: 1.5em;
        line-height: 1rem;
        margin-left: 10px;
        font-weight: 200;
    }

    .fab {
        font-size: 49px;
    }

    .social-links-area {
        flex-direction: row;
        align-items: flex-start;
    }

    .login-btn {
        font-size: 1em;
    }
}
@media (max-width: 375px) {
    .impact-text {
        position: absolute;
        top: 100px;
        left: 60px;
        background: rgba(0, 0, 0, 0.5);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        border: 1px solid rgba(255, 255, 255, 0.1);
        border-radius: 14px;
        padding: 24px 20px;
        max-height: 95%;
        max-width: 185px;
        z-index: 999;
        text-align: left;
        box-shadow: 0 4px 30px rgba(0, 0, 0, 0.2);
        transition: transform 0.3s ease;
        opacity: 0;
        transform: translateY(10px);
        animation: fadeSlideIn 1.2s ease-out forwards;
        animation-delay: 0.7s;
        padding: 20px;
    }
    
    .impact-subheading {
        font-family: 'Montserrat', sans-serif;
        font-weight: 400;
        font-size: 0.8rem !important;
        color: rgba(255, 255, 255, 0.9);
        line-height: 1 !important;
        margin: 0;
    }
    
    .background-container>picture {
        position: absolute;
        top: 0;
        left: -50%;
        width: 150%;
        height: 100vh;
        overflow: hidden;
        z-index: -1;
    }
}

/* Animations */
@keyframes slideInVertical {
    0% {
        opacity: 0;
        transform: translateY(50px);
    }
    
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}
@keyframes slideInHorizontal {
    0% {
        opacity: 0;
        transform: translateX(50px);
    }
    
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}
@keyframes fadeInLink {
    0% {
        opacity: 0;
    }
    
    100% {
        opacity: 1;
    }
}
#linkedin {
    animation: fadeInLink 0.5s ease-in-out 1s forwards;
    /* 1s delay */
}
#facebook {
    animation: fadeInLink 0.5s ease-in-out 1.5s forwards;
    /* 1.5s delay */
}
#resume {
    animation: fadeInLink 0.5s ease-in-out 2s forwards;
    /* 2s delay */
}

.portfolio-chat-panel {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.portfolio-chat-body {
    display: flex;
    flex-direction: column;
    min-height: 0;
    flex: 1;
}

.portfolio-chat-messages {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 22px 24px 140px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    scrollbar-width: none;
}

.portfolio-chat-messages::-webkit-scrollbar {
    display: none;
}

.portfolio-chat-inputbar {
    position: sticky;
    bottom: 0;
    z-index: 10;
    display: flex;
    align-items: flex-end;
    gap: 12px;
    padding: 18px 24px 22px;
    background: linear-gradient(180deg, rgba(6, 10, 38, 0), rgba(6, 10, 38, 0.92) 28%, rgba(6, 10, 38, 0.98));
    border-top: 1px solid rgba(255, 255, 255, 0.04);
}
.portfolio-chat-edit-modal {
    display: block;
    width: calc(100% - 48px);
    max-width: none;
    box-sizing: border-box;
    margin: 0 24px 16px;
    align-self: stretch;
    position: relative;
    z-index: 3;
}
.portfolio-chat-edit-card {
    width: 100%;
    max-height: 60vh;
    overflow-y: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
    border: 1px solid rgba(148, 88, 255, 0.18);
    border-radius: 18px;
    padding: 16px;
    background:
        radial-gradient(circle at top left, rgba(194, 96, 255, 0.08), transparent 34%),
        linear-gradient(180deg, rgba(24, 8, 54, 0.96), rgba(17, 7, 44, 0.98));
}
.portfolio-chat-edit-card {
    max-height: calc(100vh - 260px);
    overflow-y: auto;
    padding: 20px 20px 24px;
    box-sizing: border-box;
}
.portfolio-chat-edit-card::-webkit-scrollbar {
    display: none;
}

.portfolio-chat-edit-header {
    position: relative;
    top: auto;
    z-index: auto;
    background: transparent;
    padding-bottom: 10px;
}

.portfolio-chat-edit-actions {
    position: relative;
    bottom: auto;
    z-index: auto;
    display: flex;
    justify-content: flex-end;
    margin-top: 18px;
    padding-top: 12px;
    background: transparent;
}

.portfolio-chat-edit-textarea {
    min-height: 220px;
    resize: vertical;
    overflow-y: auto;
    scrollbar-width: none;
}

.portfolio-chat-edit-textarea::-webkit-scrollbar {
    display: none;
}

.portfolio-chat-edit-consent {
    display: grid;
    grid-template-columns: 18px 1fr;
    gap: 10px;
    align-items: start;
    margin-top: 14px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.74rem;
    line-height: 1.5;
    color: rgba(255,255,255,0.78);
}

.portfolio-chat-edit-checkbox {
    margin-top: 2px;
}

.portfolio-chat-disclaimer {
    margin: 0 0 16px;
    padding: 12px 14px;
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 14px;
    background: rgba(255,255,255,0.04);
}

.portfolio-chat-disclaimer-title {
    margin: 0 0 4px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.72);
}

.portfolio-chat-disclaimer-copy {
    margin: 0;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.78rem;
    line-height: 1.45;
    color: rgba(255,255,255,0.72);
}

@media (max-width: 768px) {
    .portfolio-chat-edit-modal {
        inset: 12px 12px 88px 12px;
    }

    .portfolio-chat-edit-grid-jd {
        grid-template-columns: 1fr;
    }
}
.portfolio-chat-panel,
.portfolio-chat-body {
    min-height: 0;
}

.portfolio-chat-messages {
    flex: 1;
    min-height: 0;
    overflow-y: auto !important;
    overflow-x: hidden;
    padding: 22px 24px 140px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.portfolio-chat-messages::-webkit-scrollbar {
    width: 0;
    height: 0;
    display: none;
}
.portfolio-chat-messages {
    padding-bottom: 140px;
    box-sizing: border-box;
}
.portfolio-chat-inputbar {
    position: sticky;
    bottom: 0;
    z-index: 10;
}
.portfolio-chat-inputbar {
    position: relative;
    z-index: 2;
}

.portfolio-chat-edit-modal {
    position: relative;
    z-index: 3;
}
[hidden] {
    display: none !important;
}

.portfolio-chat-edit-modal[hidden] {
    display: none !important;
}
#portfolioChatQuickActions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 0 0 12px 25px;
    padding: 0;
}

.portfolio-chat-inputbar #portfolioChatQuickActions,
.portfolio-chat-form-wrap #portfolioChatQuickActions,
#portfolioChatForm + #portfolioChatQuickActions {
    margin-bottom: 12px;
}

#portfolioChatQuickActions .portfolio-chat-chip {
    flex: 0 0 auto;
}
#portfolioChatPasteJdChip.is-jd-saved {
    background: #1f8f5f;
    border-color: #1f8f5f;
    color: #fff;
    font-weight: 700;
}

#portfolioChatPasteJdChip.is-jd-attention {
    box-shadow: 0 0 0 3px rgba(31, 143, 95, 0.22);
}

.portfolio-chat-edit-modal {
    display: block;
    width: calc(100% - 48px);
    margin: 0 24px 16px;
    position: relative;
    z-index: 3;
}

.portfolio-chat-edit-card {
    max-height: calc(100vh - 260px);
    overflow-y: auto;
}

.portfolio-chat-messages {
    padding-bottom: 140px;
}
/* ===== Chat form scroll + action visibility fix ===== */

.portfolio-chat-panel,
.portfolio-chat-body {
    min-height: 0;
}

.portfolio-chat-body {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
}

.portfolio-chat-messages {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 22px 24px 190px;
    box-sizing: border-box;
}

.portfolio-chat-inputbar {
    position: sticky;
    bottom: 0;
    z-index: 2;
}

.portfolio-chat-edit-modal {
    display: block;
    width: calc(100% - 48px);
    max-width: none;
    margin: 0 24px 16px;
    box-sizing: border-box;
    position: relative;
    z-index: 6;
    flex: 0 0 auto;
    align-self: stretch;
}

.portfolio-chat-edit-card {
    width: 100%;
    max-height: calc(100vh - 220px);
    overflow-y: auto;
    overflow-x: hidden;
    box-sizing: border-box;
    padding: 20px 20px 28px;
    border: 1px solid rgba(148, 88, 255, 0.18);
    border-radius: 18px;
    background:
        radial-gradient(circle at top left, rgba(194, 96, 255, 0.08), transparent 34%),
        linear-gradient(180deg, rgba(24, 8, 54, 0.96), rgba(17, 7, 44, 0.98));
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.portfolio-chat-edit-card::-webkit-scrollbar {
    display: none;
}

.portfolio-chat-edit-header {
    position: sticky;
    top: 0;
    z-index: 1;
    background:
        linear-gradient(180deg, rgba(24, 8, 54, 0.98), rgba(24, 8, 54, 0.9));
    padding-bottom: 10px;
}

.portfolio-chat-edit-actions {
    position: sticky;
    bottom: 0;
    z-index: 1;
    display: flex;
    justify-content: flex-end;
    margin-top: 18px;
    padding-top: 12px;
    padding-bottom: 4px;
    background:
        linear-gradient(180deg, rgba(17, 7, 44, 0), rgba(17, 7, 44, 0.98) 28%);
}

.portfolio-chat-edit-textarea {
    min-height: 220px;
    max-height: 40vh;
    resize: vertical;
    overflow-y: auto;
}

@media (max-width: 768px) {
    .portfolio-chat-edit-modal {
        width: calc(100% - 24px);
        margin: 0 12px 12px;
    }

    .portfolio-chat-edit-card {
        max-height: calc(100vh - 180px);
    }
}
/* keep pills visible above the input bar */
#portfolioChatQuickActions {
    position: relative;
    z-index: 9;
    display: flex !important;
    flex-wrap: wrap;
    gap: 10px;
    margin: 0 24px 12px;
    padding: 0;
}

.portfolio-chat-body #portfolioChatQuickActions {
    flex: 0 0 auto;
}

.portfolio-chat-edit-modal + #portfolioChatQuickActions,
.portfolio-chat-messages + #portfolioChatQuickActions {
    display: flex !important;
}

.portfolio-chat-inputbar {
    position: sticky;
    bottom: 0;
    z-index: 8;
}

.portfolio-chat-edit-modal {
    z-index: 7;
}
.portfolio-chat-shell.is-open #portfolioChatQuickActions {
    display: flex !important;
}
#portfolioChatQuickActions {
    position: sticky;
    bottom: 86px;
    z-index: 9;
    background: transparent;
}
/* ===== JD form pinned to top + scrollable ===== */

.portfolio-chat-body {
    position: relative;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.portfolio-chat-messages {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 18px 24px 180px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: stretch;
}

.portfolio-chat-edit-modal {
    order: -100;
    position: sticky;
    top: 0;
    z-index: 20;
    width: calc(100% - 48px);
    margin: 0 24px 16px;
    align-self: stretch;
    flex: 0 0 auto;
    display: block;
}

.portfolio-chat-edit-card {
    width: 100%;
    max-height: calc(100vh - 180px);
    overflow-y: auto;
    overflow-x: hidden;
    box-sizing: border-box;
    padding: 18px 18px 28px;
    border-radius: 18px;
    scrollbar-width: thin;
}

.portfolio-chat-edit-header {
    position: sticky;
    top: 0;
    z-index: 2;
    padding-bottom: 10px;
}

.portfolio-chat-edit-actions {
    position: sticky;
    bottom: 0;
    z-index: 2;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding-top: 12px;
    padding-bottom: 6px;
}

.portfolio-chat-inputbar {
    position: sticky;
    bottom: 0;
    z-index: 10;
}

@media (max-width: 768px) {
    .portfolio-chat-edit-modal {
        width: calc(100% - 24px);
        margin: 0 12px 12px;
    }

    .portfolio-chat-edit-card {
        max-height: calc(100vh - 140px);
    }
}
/* ===== Dashboard gallery row layout ===== */

.work-gallery {
    width: 100%;
}

.work-gallery:after {
    content: "";
    display: block;
    clear: both;
}

.work-gallery .thumby {
    width: 33.3333%;
    float: left;
    padding: 0 12px 24px;
    box-sizing: border-box;
}

.work-gallery .thumby.bundle-hidden,
.work-gallery .thumby.bundle-extra-hidden {
    display: none !important;
}

@media (max-width: 991px) {
    .work-gallery .thumby {
        width: 50%;
    }
}

@media (max-width: 640px) {
    .work-gallery .thumby {
        width: 100%;
    }
}
/* ===== Dashboard case-study layout fix ===== */

/* Let isotope/bootstrap work on the cards instead of forcing 100% flex-basis */
#work .work-gallery .thumby {
    display: block !important;
    flex: 0 0 auto !important;
    flex-basis: auto !important;
    width: 33.3333% !important;
    max-width: 33.3333% !important;
    float: left !important;
    padding: 0 12px 24px !important;
    box-sizing: border-box;
}

/* Keep hidden curated cards truly hidden */
#work .work-gallery .thumby.bundle-hidden,
#work .work-gallery .thumby.bundle-extra-hidden {
    display: none !important;
}

/* Make each card fill its own column properly */
#work .work-gallery .thumby .image,
#work .work-gallery .thumby .headline_container {
    width: 100%;
}

/* Make thumbnail images behave consistently */
#work .work-gallery .thumby .img-fluid {
    display: block;
    width: 100% !important;
    height: auto !important;
}

/* Clear floats */
#work .work-gallery::after {
    content: "";
    display: block;
    clear: both;
}

@media (max-width: 991px) {
    #work .work-gallery .thumby {
        width: 50% !important;
        max-width: 50% !important;
    }
}

@media (max-width: 640px) {
    #work .work-gallery .thumby {
        width: 100% !important;
        max-width: 100% !important;
    }
}
body.tailored-dashboard #work .work-gallery {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
    width: 100%;
}

body.tailored-dashboard #work .work-gallery .thumby {
    display: block !important;
    width: auto !important;
    max-width: none !important;
    float: none !important;
    flex: none !important;
    flex-basis: auto !important;
    margin: 0 !important;
    padding: 0 !important;
}

body.tailored-dashboard #work .work-gallery .thumby.bundle-hidden,
body.tailored-dashboard #work .work-gallery .thumby.bundle-extra-hidden {
    display: none !important;
}

@media (max-width: 991px) {
    body.tailored-dashboard #work .work-gallery {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    body.tailored-dashboard #work .work-gallery {
        grid-template-columns: 1fr;
    }
}
body.tailored-dashboard #work .work-gallery {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
    width: 100%;
    margin: 0;
    padding: 0;
}

body.tailored-dashboard #work .work-gallery .thumby {
    display: block !important;
    width: auto !important;
    max-width: none !important;
    float: none !important;
    flex: none !important;
    flex-basis: auto !important;
    margin: 0 !important;
    padding: 0 !important;
}

body.tailored-dashboard #work .work-gallery .thumby.bundle-hidden,
body.tailored-dashboard #work .work-gallery .thumby.bundle-extra-hidden {
    display: none !important;
}

body.tailored-dashboard #work .work-gallery .thumby .image,
body.tailored-dashboard #work .work-gallery .thumby .headline_container,
body.tailored-dashboard #work .work-gallery .thumby .img-fluid {
    width: 100%;
}

body.tailored-dashboard #work .work-gallery .thumby .img-fluid {
    display: block;
    height: auto !important;
}

@media (max-width: 991px) {
    body.tailored-dashboard #work .work-gallery {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    body.tailored-dashboard #work .work-gallery {
        grid-template-columns: 1fr;
    }
}