/* =================================
   Custom overrides for Hitesh's portfolio
   Extends HTML5 UP's "Dimension"
   ================================= */

/* Wider Projects panel */
#main article.wide {
    width: 64rem;
}

/* Accent color */
:root {
    --accent: #64d6ff;
    --accent-soft: rgba(100, 214, 255, 0.12);
}

.accent { color: var(--accent); }
em { color: var(--accent); font-style: italic; }
strong { color: #ffffff; }

.muted {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.85em;
}

.lead {
    font-size: 1.15em;
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.85);
}

/* Brain icon — tint the logo */
#header .logo .icon.fa-brain::before {
    color: #fff;
}

/* =================================
   Education
   ================================= */
.edu-item {
    padding: 0.8rem 0 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 0.6rem;
}
.edu-item:last-of-type { border-bottom: 0; }
.edu-head {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 0.2rem;
}
.edu-head strong { font-size: 1.05rem; }
.edu-date {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.55);
    font-family: 'Source Code Pro', monospace;
}
.edu-sub {
    margin: 0 !important;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
}

/* =================================
   Chips
   ================================= */
ul.chips {
    list-style: none;
    padding: 0;
    margin: 0 0 1.5rem 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}
ul.chips li {
    padding: 0.35rem 0.8rem;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 999px;
    font-size: 0.82rem;
    color: rgba(255, 255, 255, 0.82);
    transition: all 0.2s ease;
}
ul.chips li:hover {
    background: var(--accent-soft);
    border-color: var(--accent);
    color: #fff;
    transform: translateY(-2px);
}
ul.chips.small li {
    font-size: 0.72rem;
    padding: 0.25rem 0.6rem;
}

/* =================================
   Experience
   ================================= */
.exp-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}
.exp-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 1rem;
    padding-bottom: 0.8rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.exp-head h3 {
    margin: 0 0 0.25rem 0;
    font-size: 1.3rem;
    border: 0;
    padding: 0;
}
.exp-company {
    color: var(--accent);
    font-size: 0.92rem;
    margin: 0 !important;
}
.exp-date {
    font-size: 0.78rem;
    padding: 0.3rem 0.7rem;
    background: var(--accent-soft);
    color: var(--accent);
    border-radius: 999px;
    white-space: nowrap;
}

/* =================================
   Projects grid
   ================================= */
.projects {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.25rem;
    margin: 1.5rem 0;
}
.project {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
    position: relative;
}
.project:hover {
    border-color: var(--accent);
    background: rgba(100, 214, 255, 0.04);
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}
.project-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}
.project-tag {
    font-size: 0.7rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--accent);
    font-family: 'Source Code Pro', monospace;
}
.project-gh {
    width: 30px; height: 30px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.14);
    transition: all 0.2s ease;
    text-decoration: none !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.14) !important;
}
.project-gh:hover {
    color: #fff;
    background: var(--accent);
    border-color: var(--accent);
    transform: rotate(8deg) scale(1.05);
}
.project-gh .icon { font-size: 0.9rem; }
.project-gh .icon::before { color: inherit; }

.project h3 {
    font-size: 1.05rem;
    margin: 0 0 0.5rem 0 !important;
    padding: 0;
    border: 0;
    line-height: 1.3;
    color: #fff;
}
.project p {
    font-size: 0.88rem;
    line-height: 1.55;
    color: rgba(255, 255, 255, 0.7);
    margin: 0 0 0.8rem 0 !important;
}
.project .metric {
    font-size: 0.82rem;
    padding: 0.4rem 0.7rem;
    background: var(--accent-soft);
    border-left: 2px solid var(--accent);
    border-radius: 2px;
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 0.8rem !important;
}
.project ul.chips { margin-top: auto; margin-bottom: 0 !important; }

/* =================================
   Timeline for achievements
   ================================= */
ul.timeline {
    list-style: none;
    padding: 0;
    margin: 0;
    position: relative;
}
ul.timeline::before {
    content: '';
    position: absolute;
    left: 3.5rem;
    top: 0.6rem;
    bottom: 0.6rem;
    width: 1px;
    background: linear-gradient(180deg, var(--accent), transparent);
}
ul.timeline li {
    display: flex;
    gap: 1.5rem;
    padding: 1rem 0;
    position: relative;
}
ul.timeline li::before {
    content: '';
    position: absolute;
    left: calc(3.5rem - 5px);
    top: 1.5rem;
    width: 11px;
    height: 11px;
    border-radius: 50%;
    background: #1b1f22;
    border: 2px solid var(--accent);
    box-shadow: 0 0 12px rgba(100, 214, 255, 0.5);
}
ul.timeline li > .year {
    flex: 0 0 3rem;
    font-family: 'Source Code Pro', monospace;
    font-size: 0.9rem;
    color: var(--accent);
    padding-top: 0.2rem;
}
ul.timeline li > div {
    padding-left: 1.5rem;
    flex: 1;
}
ul.timeline h4 {
    margin: 0 0 0.3rem 0 !important;
    font-size: 1rem;
    color: #fff;
    padding: 0;
    border: 0;
}
ul.timeline p {
    margin: 0 !important;
    color: rgba(255, 255, 255, 0.65);
    font-size: 0.88rem;
}

/* =================================
   Skill bars
   ================================= */
.bars {
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
    margin-top: 0.5rem;
}
.bar {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}
.bar > span {
    font-size: 0.82rem;
    color: rgba(255, 255, 255, 0.8);
}
.bar .track {
    height: 4px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 2px;
    overflow: hidden;
}
.bar .track i {
    display: block;
    height: 100%;
    width: 0;
    background: linear-gradient(90deg, var(--accent), #a855f7);
    border-radius: 2px;
    animation: fill 1.6s cubic-bezier(.2,.7,.2,1) 0.3s forwards;
}
@keyframes fill { to { width: var(--w); } }

/* =================================
   Contact list
   ================================= */
.contact-list { margin-top: 1rem !important; }
.contact-list li {
    padding: 0.5rem 0 !important;
    display: flex !important;
    align-items: center;
    gap: 0.8rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}
.contact-list li .icon {
    color: var(--accent);
    width: 20px;
    text-align: center;
}
.contact-list li a { border-bottom-color: rgba(100, 214, 255, 0.3); }
.contact-list li a:hover { border-bottom-color: var(--accent); color: var(--accent); }

/* =================================
   Header tweaks — name larger, accent on the name
   ================================= */
#header h1 {
    letter-spacing: -0.02em;
    font-weight: 600;
}

/* Make the logo pulse subtly */
#header .logo {
    transition: transform 0.3s ease;
}
#header .logo:hover { transform: rotate(10deg) scale(1.05); }

/* BG: blend toward deeper tone so accents pop */
#bg {
    filter: saturate(1.1) contrast(1.05);
}

/* =================================
   Responsive
   ================================= */
@media screen and (max-width: 980px) {
    #main article.wide { width: auto; }
    .projects { grid-template-columns: 1fr; }
    ul.timeline::before { left: 1rem; }
    ul.timeline li::before { left: calc(1rem - 5px); }
    ul.timeline li > .year { flex-basis: auto; padding-left: 2rem; }
    ul.timeline li > div { padding-left: 2rem; }
    ul.timeline li { flex-direction: column; gap: 0.4rem; }
}

@media screen and (max-width: 480px) {
    .exp-head, .edu-head { flex-direction: column; align-items: flex-start; }
    .exp-date { font-size: 0.7rem; }
}

/* =================================
   Respect reduced motion
   ================================= */
@media (prefers-reduced-motion: reduce) {
    .bar .track i { animation: none; width: var(--w); }
    .project:hover { transform: none; }
    #header .logo:hover { transform: none; }
}
