/*
   PHASE 1 BENTO GRID
   ------------------------------------------------------------------
   Grey note: legacy about layout is fully removed.
   Grey note: this file now contains only the new grid architecture.
*/

.about-world {
    background-color: #050505;
    /* Grey note: section spacing under the glass navbar */
    padding: 80px 0;
}

/* Grey note: refined ratios — middle column is intentionally wider */
.bento-grid {
    display: grid;
    grid-template-columns: 1.2fr 1.4fr 1fr;
    gap: 20px;
    /* UPDATED LOGIC */
  /* This takes 100vh minus offset, but caps it at 850px (adjust based on your content) */
  height: min(calc(100vh - 140px), 850px);
    min-height: 650px;
}

/* Grey note: middle stack fills full grid height and splits cards equally */
.bento-column-middle {
    display: flex;
    flex-direction: column;
    gap: 20px;
    height: 100%;
}

/* Grey note: tools card takes ~40% height, skills card takes ~60% to fit physics chips */
.bento-column-middle .tools-card {
    flex: 0.40;
    display: flex;
    flex-direction: column;
}

/* TOOLS TRACK LAYOUT
   ------------------------------------------------------------------
   Grey note: Horizontal track for tool icons with grouping for annotations
*/
.tools-viewport {
    position: relative;
    flex: 1; 
    width: 100%;
    overflow: visible; /* Grey note: allows annotations to bleed into card padding */
}

.tools-track {
    display: flex;
    flex-wrap: nowrap; /* Grey note: strictly forces a single horizontal line */
    width: max-content; /* Grey note: allows track to expand way past card edges */
    position: absolute;
    left: 0;
    top: calc(50% - 25px); /* Grey note: Centered vertically with a 15px upward nudge */
    animation: scrollTools 35s linear infinite; 
}

.tools-set {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: 32px;
    padding-right: 300px; /* Grey note: wide gap ensures the de-clutter arrow is clear before repeating */
    flex-shrink: 0; /* Grey note: CRITICAL - prevents the browser from compressing the set */
}

.tool-group {
    display: flex;
    align-items: center;
    gap: 32px;
    position: relative; 
    flex-shrink: 0; /* Grey note: CRITICAL - prevents individual logos from squishing */
}

@keyframes scrollTools {
    0% { transform: translate(0, 0); }
    100% { transform: translate(-50%, 0); } /* Grey note: flawless loop at exactly half the track width */
}

.tool-box {
    width: 56px;
    height: 56px;
    padding: 10px;
    border-radius: 12px;
    border: 1px solid #2E2E2E;
    background-color: transparent;
    box-sizing: border-box;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-shrink: 0;
}

.tool-box img {
    width: 36px;
    height: 36px;
    object-fit: contain;
}

/* Base style for the upcoming handwritten labels */
.tool-label {
    font-family: 'Caveat', cursive;
    font-weight: 700;
    font-size: 22px; 
    color: #6A6A6A; 
    white-space: nowrap;
    pointer-events: none;
    line-height: 1; /* Grey note: tight line height so it sits snug against the SVG lines */
}

/* TOOL ANNOTATIONS (Lines & Labels)
   ------------------------------------------------------------------ */

.annotation {
    position: absolute;
    display: flex;
    flex-direction: column;
    pointer-events: none;
    z-index: 5;
    gap: 4px; /* Space between text and line */
}

.anno-line {
    display: block;
    width: auto;
    height: auto;
    object-fit: contain;
}

/* 1. Design & Prototype (Left side, bracket shape) */
.anno-design {
    right: calc(100% + 16px);
    top: 50%;
    transform: translateY(-50%);
    align-items: flex-end; /* Pushes text to the right side of the flexbox */
}

/* 2. Fellow Researchers (Underneath, spans all 3) */
.anno-ai {
    top: calc(100% + 12px);
    left: 50%;
    transform: translateX(-50%);
    width: 105%; /* Stretches slightly past the edges of the boxes */
    align-items: flex-end; /* Aligns text to the right to match Figma */
}
.anno-ai .anno-line { width: 100%; }

/* 3. Build Tools (Underneath, spans all 3) */
.anno-build {
    top: calc(100% + 12px);
    left: 50%;
    transform: translateX(-50%);
    width: 105%;
    align-items: center; /* Aligns text in the center */
}
.anno-build .anno-line { width: 100%; }

/* 4. Languages (Above, spans all 3) */
.anno-lang {
    bottom: calc(100% + 12px);
    left: 50%;
    transform: translateX(-50%);
    width: 105%;
    flex-direction: column; /* Puts the label ABOVE the line */
    align-items: center;
}
.anno-lang .anno-line { width: 100%; }

/* 5. De-clutter (Right side, swooping arrow) */
.anno-manage {
    left: calc(100% + 16px);
    bottom: 20px; /* Anchors it nicely to the bottom of Jira */
    align-items: flex-start;
    flex-direction: column-reverse; /* Puts text above the swoop */
}

/* Grey note: tools card takes ~60% height, tools card takes ~40% to fit physics chips */
.bento-column-middle .skills-card {
    flex: 0.60;
    display: flex;
    flex-direction: column;
}

/* Grey note: shared card shell across all three columns */

.bento-card {
    padding: 32px;
    position: relative;
    overflow: hidden;
    border-radius: 24px;
    box-sizing: border-box;
    background-color: #070707;
    border: 1px solid #242424;
}

/* Grey note: fluid single-line heading scale */
.bento-title {
    position: relative;
    font-family: 'Gotham Ultra', sans-serif;
    font-size: clamp(22px, 1.8vw, 24px);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin: 0 0 32px 0;
    color: #FFFFFF;
    z-index: 10;
    pointer-events: none; /* Ensures mouse drags pass through the title to grab chips underneath */
}

.bento-title .bracket {
    color: #4945d1;
}


/* Grey note: story text rhythm is fixed for readability */
.bento-card--story p {
    font-family: 'Albert Sans', sans-serif;
    font-size: 14px;
    color: #9A9A9B;
    line-height: 1.6;
    margin-bottom: 20px;
}

.bento-card--story p:last-child {
    margin-bottom: 0;
}

/* Grey note: dotted fill used only for tools/skills cards */
.dotted-bg {
    background-color: #050505;
    background-image: radial-gradient(#0E0E0F 1.5px, transparent 1.5px);
    background-size: 14px 14px;
}

/* Grey note: photo card is full-bleed with absolute overlay title */
.photo-card {
    padding: 0;
    position: relative;
    overflow: hidden;
    border: none;
}

.photo-card .bento-title {
    position: absolute;
    top: 32px;
    left: 32px;
    z-index: 10;
    color: #000000;
}

.photo-card img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 1;
}

/* 
   SKILLS SCATTER LAYOUT
   ------------------------------------------------------------------
   Grey note: organic positioned chips with subtle rotations
*/

.skills-scatter {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    z-index: 1; /* Sits behind the title */
}

.skill-chip {
    position: absolute;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    padding: 12px 28px;
    background: #070707;
    border: 1px solid #222222;
    box-sizing: border-box;
    white-space: nowrap;
    border-radius: 30px;
    top: 0;
    left: 0;
    margin: 0;
    
    /* Grey note: typography matches Figma spec */
    color: #CDCDCD;
    font-family: 'Albert Sans', sans-serif;
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
    white-space: nowrap;
    letter-spacing: 0.02em;
    
    
    /* Grey note: interaction ready for future drag behavior */
    user-select: none;
    cursor: grab;
    
}



    /* about.css - MOBILE STACKING & DOWNSIZING */
/* about.css - MOBILE READABILITY REFINEMENT */

@media screen and (max-width: 768px) {
    /* 1. THE GRID: Maintain the stack but increase vertical gap */

    .about-world, 
    .about-world .container-lock,
    .bento-grid {
    height: auto !important;      /* [FIX] Removes desktop height restrictions */
    min-height: 100vh !important;
    overflow: visible !important;  /* [FIX] Prevents clipping of the 4th card */
}

    .bento-grid {
        display: flex !important;
        flex-direction: column !important;
        gap: 24px !important; 
    }

    /* 2. THE STORY CARD: Maximizing Readability */
    .bento-card--story {
        width: 100% !important;
    padding: 50px 24px !important;
    height: 400px !important;   /* [ADD] Sets a fixed height for mobile */
    min-height: 400px !important; /* [ADD] Ensures it doesn't shrink below this height */
    overflow-y: auto !important; /* [ADD] Enables internal scrolling for text */
    }

    /* 3. TOOLS & SKILLS CARDS: Giving icons and chips room to breathe */
    .tools-card, 
    .skills-card {
        padding: 40px 24px !important;
        min-height: 300px !important; /* Increased height for visual weight */
    }

    /* 4. THE PHOTO CARD: Immersive full-screen feel */
    .photo-card {
        display: block !important; /* [FIX] Forces rendering */
        width: 100% !important;
        height: 550px !important;  /* [FIX] Substantial height for the portrait */
        padding: 0 !important;
        overflow: hidden !important;
    }

    .photo-card img {
        width: 100% !important;
        height: 100% !important;
        object-fit: cover !important; /* Full edge-to-edge coverage */
    }

    /* 5. TYPOGRAPHY: Keeping it readable on small screens */
    .bento-title {
        font-size: 20px !important; /* Slightly larger for emphasis */
        margin-bottom: 30px !important;
    }

    .bento-card p {
        font-size: 16px !important; /* Optimal readability for mobile body text */
        line-height: 1.6 !important; /* Increased leading to prevent eye strain */
    }
}