/* 
    Thomas Portfolio - CSS Stylesheet
    Inspired by Mr. Robot Hacker Theme
*/

/* ---------- Base Styles ---------- */
:root {
    --hacker-bg: #0a0a0a;
    --hacker-text: #e6e6e6;
    --hacker-accent: #1EAEDB;
    --hacker-muted: #333333;
    --hacker-dark: #000000;
    --hacker-light: #f0f0f0;
    --hacker-error: #ff3e3e;
    --hacker-success: #00b894;
    --hacker-card: #111111;
    --hacker-hover: #1A1A1A;
    --hover-transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    border-color: var(--hacker-muted);
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--hacker-bg);
    color: var(--hacker-text);
    line-height: 1.6;
    overflow-x: hidden;
}

::-webkit-scrollbar {
    width: 8px;
    background-color: #111;
}

::-webkit-scrollbar-thumb {
    background-color: var(--hacker-accent);
    border-radius: 4px;
}

::selection {
    background-color: rgba(30, 174, 219, 0.3);
    color: #fff;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

section {
    padding: 100px 0;
}

a {
    color: var(--hacker-text);
    text-decoration: none;
    transition: var(--hover-transition);
}

a:hover {
    color: var(--hacker-accent);
}

/* ---------- Typography ---------- */
h1, h2, h3, h4, h5, h6 {
    margin-bottom: 1rem;
    line-height: 1.2;
}

h1 {
    font-size: 3rem;
}

h2 {
    font-size: 2.5rem;
}

h3 {
    font-size: 1.5rem;
}

p {
    margin-bottom: 1rem;
}

.accent {
    color: var(--hacker-accent);
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border-radius: 4px;
    font-weight: 500;
    text-align: center;
    cursor: pointer;
    transition: var(--hover-transition);
}

.btn-primary {
    background-color: var(--hacker-accent);
    color: var(--hacker-light);
}

.btn-primary:hover {
    box-shadow: 0 0 15px rgba(30, 174, 219, 0.7);
    transform: translateY(-2px);
    color: var(--hacker-light);
}

.btn-secondary {
    background-color: transparent;
    border: 1px solid var(--hacker-muted);
    color: var(--hacker-text);
}

.btn-secondary:hover {
    border-color: var(--hacker-accent);
    color: var(--hacker-accent);
}

.btn-full {
    width: 100%;
}

.btn i {
    margin-left: 8px;
}

/* ---------- Navigation ---------- */
#navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 20px 0;
    transition: var(--hover-transition);
}

#navbar.scrolled {
    padding: 10px 0;
    background-color: rgba(10, 10, 10, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

#navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: 'Courier Prime', monospace;
    font-size: 1.5rem;
    font-weight: 700;
}

.logo span:first-child {
    color: var(--hacker-text);
}

.nav-links {
    display: flex;
    gap: 30px;
}

.nav-links a {
    font-family: 'Courier Prime', monospace;
    font-size: 0.9rem;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 100%;
    transform: scaleX(0);
    height: 1px;
    bottom: -4px;
    left: 0;
    background-color: var(--hacker-accent);
    transform-origin: bottom right;
    transition: transform 0.3s ease-out;
}

.nav-links a:hover::after {
    transform: scaleX(1);
    transform-origin: bottom left;
}

.menu-toggle {
    display: none;
    cursor: pointer;
    font-size: 1.5rem;
}

.menu-toggle .fa-times {
    display: none;
}

.mobile-menu {
    display: none;
    position: fixed;
    top: 70px;
    left: 0;
    width: 100%;
    background-color: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(10px);
    padding: 20px;
    z-index: 999;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transform: translateY(-100%);
    transition: transform 0.3s ease;
}

.mobile-menu.active {
    transform: translateY(0);
}

.mobile-link {
    display: block;
    padding: 15px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    font-family: 'Courier Prime', monospace;
    font-size: 1rem;
}

/* ---------- Hero Section ---------- */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.bg-effects {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: -1;
}

.bg-effect-1 {
    position: absolute;
    top: 25%;
    left: 25%;
    width: 500px;
    height: 500px;
    background-color: rgba(30, 174, 219, 0.05);
    border-radius: 50%;
    filter: blur(80px);
}

.bg-effect-2 {
    position: absolute;
    bottom: 25%;
    right: 25%;
    width: 300px;
    height: 300px;
    background-color: rgba(30, 174, 219, 0.03);
    border-radius: 50%;
    filter: blur(60px);
}

.hero-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 40px;
}

.hero-text {
    flex: 1;
    animation: fadeIn 1s ease-out forwards;
}

.typing-animation {
    display: inline-block;
    overflow: hidden;
    white-space: nowrap;
    margin: 0 auto;
    font-family: 'Courier Prime', monospace;
    color: rgba(230, 230, 230, 0.8);
    border-right: 3px solid var(--hacker-accent);
    animation: typing 3.5s steps(30, end), blink 0.75s step-end infinite;
}

.cta-buttons {
    display: flex;
    gap: 15px;
    margin-top: 30px;
}

.terminal-container {
    flex: 1;
    animation: fadeInDelay 1s ease-out forwards;
}

.terminal {
    background-color: #111;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid var(--hacker-muted);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.terminal-header {
    background-color: var(--hacker-muted);
    padding: 8px;
    display: flex;
    align-items: center;
}

.terminal-button {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin-right: 8px;
}

.terminal-button.red {
    background-color: #ff5f56;
}

.terminal-button.yellow {
    background-color: #ffbd2e;
}

.terminal-button.green {
    background-color: #27c93f;
}

.terminal-body {
    padding: 16px;
    font-family: 'Courier Prime', monospace;
    font-size: 0.9rem;
}

.terminal-line {
    display: flex;
    margin-bottom: 8px;
}

.terminal-prompt {
    color: var(--hacker-accent);
    margin-right: 8px;
}

.terminal-cursor {
    display: inline-block;
    width: 8px;
    height: 16px;
    background-color: var(--hacker-accent);
    animation: blink 1s step-end infinite;
    vertical-align: middle;
    margin-left: 2px;
}

.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    opacity: 0;
    animation: fadeIn 1s ease-out 2s forwards;
}

.scroll-indicator span {
    font-size: 0.8rem;
    font-family: 'Courier Prime', monospace;
    margin-bottom: 8px;
    color: rgba(230, 230, 230, 0.5);
}

.scroll-indicator i {
    color: var(--hacker-accent);
    animation: bounce 2s infinite;
}

/* ---------- About Section ---------- */
.about {
    background-color: var(--hacker-dark);
}

.section-header {
    margin-bottom: 60px;
    text-align: center;
}

.section-subtitle {
    color: var(--hacker-accent);
    font-family: 'Courier Prime', monospace;
    font-size: 0.9rem;
    margin-bottom: 12px;
}

.section-title {
    margin-bottom: 20px;
}

.accent-line {
    width: 60px;
    height: 4px;
    background-color: var(--hacker-accent);
    margin: 0 auto 30px;
}

.section-description {
    max-width: 700px;
    margin: 0 auto;
    color: rgba(230, 230, 230, 0.7);
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
}

.about-text p {
    color: rgba(230, 230, 230, 0.8);
    line-height: 1.8;
}

.about-features {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 30px;
}

.feature {
    display: flex;
    align-items: center;
    gap: 10px;
}

.feature i {
    color: var(--hacker-accent);
}

.skills-box {
    background-color: rgba(17, 17, 17, 0.5);
    backdrop-filter: blur(10px);
    border: 1px solid var(--hacker-muted);
    border-radius: 8px;
    padding: 30px;
}

.skills-title {
    font-family: 'Courier Prime', monospace;
    color: var(--hacker-accent);
    margin-bottom: 20px;
}

.skills {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.skill-pill {
    display: inline-block;
    padding: 6px 12px;
    background-color: var(--hacker-muted);
    border-radius: 20px;
    font-size: 0.8rem;
    transition: var(--hover-transition);
}

.skill-pill:hover {
    background-color: var(--hacker-accent);
    transform: translateY(-2px);
}

.experience {
    margin-top: 20px;
}

.experience-item {
    position: relative;
    padding-left: 15px;
    margin-bottom: 15px;
    border-left: 2px solid var(--hacker-muted);
    padding: 8px 0 8px 15px;
}

.experience-item.active {
    border-left: 2px solid var(--hacker-accent);
}

.experience-title {
    font-weight: 500;
    margin-bottom: 4px;
}

.experience-period {
    font-size: 0.8rem;
    color: rgba(230, 230, 230, 0.6);
}

/* ---------- Projects Section ---------- */
.projects {
    background: linear-gradient(to bottom, var(--hacker-bg), var(--hacker-dark));
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
}

.project-card {
    background-color: var(--hacker-card);
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid var(--hacker-muted);
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2), 0 0 15px rgba(30, 174, 219, 0.1);
    border-color: rgba(30, 174, 219, 0.3);
}

.project-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.7s ease;
}

.project-card:hover .project-image img {
    transform: scale(1.1);
}

.project-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(30, 174, 219, 0.2);
    backdrop-filter: blur(3px);
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.project-card:hover .project-overlay {
    opacity: 1;
}

.project-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: rgba(0, 0, 0, 0.7);
    border-radius: 50%;
    color: var(--hacker-text);
    transition: var(--hover-transition);
}

.project-link:hover {
    background-color: var(--hacker-dark);
    color: var(--hacker-accent);
}

.project-info {
    padding: 25px;
}

.project-title {
    font-size: 1.2rem;
    margin-bottom: 10px;
    transition: var(--hover-transition);
}

.project-card:hover .project-title {
    color: var(--hacker-accent);
}

.project-description {
    color: rgba(230, 230, 230, 0.7);
    font-size: 0.9rem;
    margin-bottom: 15px;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.project-tag {
    font-size: 0.7rem;
    padding: 4px 8px;
    background-color: rgba(51, 51, 51, 0.5);
    border-radius: 4px;
    color: rgba(230, 230, 230, 0.9);
    font-family: 'Courier Prime', monospace;
}

.project-more {
    display: inline-flex;
    align-items: center;
    font-size: 0.9rem;
    font-family: 'Courier Prime', monospace;
    color: var(--hacker-accent);
}

.project-more i {
    margin-left: 5px;
    font-size: 0.8rem;
}

/* ---------- Contact Section ---------- */
.contact {
    background-color: var(--hacker-dark);
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
}

.contact-form-container {
    background-color: rgba(17, 17, 17, 0.5);
    backdrop-filter: blur(10px);
    border: 1px solid var(--hacker-muted);
    border-radius: 8px;
    padding: 30px;
    position: relative;
}

.contact-title {
    font-family: 'Courier Prime', monospace;
    color: var(--hacker-accent);
    margin-bottom: 25px;
}

.contact-form {
    display: grid;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-size: 0.9rem;
    color: rgba(230, 230, 230, 0.7);
}

.form-group input,
.form-group textarea {
    padding: 12px;
    background-color: rgba(51, 51, 51, 0.5);
    border: 1px solid var(--hacker-muted);
    border-radius: 4px;
    color: var(--hacker-text);
    resize: none;
    transition: var(--hover-transition);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--hacker-accent);
    box-shadow: 0 0 0 2px rgba(30, 174, 219, 0.2);
}

.form-success {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(17, 17, 17, 0.95);
    backdrop-filter: blur(5px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 30px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    border-radius: 8px;
}

.form-success.active {
    opacity: 1;
    pointer-events: auto;
}

.success-icon {
    width: 60px;
    height: 60px;
    background-color: rgba(0, 184, 148, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.success-icon i {
    color: var(--hacker-success);
    font-size: 1.5rem;
}

.form-success h4 {
    font-size: 1.2rem;
    margin-bottom: 10px;
}

.form-success p {
    text-align: center;
    color: rgba(230, 230, 230, 0.7);
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    gap: 15px;
}

.contact-icon {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    background-color: rgba(51, 51, 51, 0.5);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.contact-icon i {
    color: var(--hacker-accent);
}

.contact-text h4 {
    font-size: 0.9rem;
    color: rgba(230, 230, 230, 0.7);
    margin-bottom: 5px;
}

.contact-text a {
    color: var(--hacker-text);
}

.contact-text a:hover {
    color: var(--hacker-accent);
}

.connect-box {
    background-color: rgba(17, 17, 17, 0.5);
    backdrop-filter: blur(10px);
    border: 1px solid var(--hacker-muted);
    border-radius: 8px;
    padding: 30px;
}

.availability {
    font-family: 'Courier Prime', monospace;
    font-size: 0.9rem;
    color: rgba(230, 230, 230, 0.6);
    margin-top: 20px;
}

.command {
    color: var(--hacker-accent);
}

.status-indicator {
    color: var(--hacker-success);
    margin-left: 20px;
    margin-right: 10px;
}

/* ---------- Footer ---------- */
.footer {
    background-color: var(--hacker-dark);
    border-top: 1px solid var(--hacker-muted);
    padding: 40px 0 20px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.footer-copyright {
    font-size: 0.9rem;
    color: rgba(230, 230, 230, 0.7);
    font-family: 'Courier Prime', monospace;
}

.footer-social {
    display: flex;
    gap: 20px;
}

.social-link {
    color: rgba(230, 230, 230, 0.7);
    transition: var(--hover-transition);
}

.social-link:hover {
    color: var(--hacker-accent);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.footer-bottom p {
    font-size: 0.8rem;
    color: rgba(230, 230, 230, 0.5);
    font-family: 'Courier Prime', monospace;
}

/* ---------- Custom Cursor ---------- */
.custom-cursor {
    position: fixed;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background-color: rgba(30, 174, 219, 0.5);
    pointer-events: none;
    z-index: 9999;
    mix-blend-mode: difference;
    transform: translate(-50%, -50%);
    transition: transform 0.2s ease-out, opacity 0.2s ease-out;
    display: none;
}

.cursor-trail {
    position: fixed;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background-color: var(--hacker-accent);
    pointer-events: none;
    z-index: 9998;
    opacity: 0.8;
    transform: translate(-50%, -50%);
    transition: opacity 0.2s ease-out;
    display: none;
}

/* ---------- Glitch Effect ---------- */
.glitch {
    position: relative;
    display: inline-block;
}

.glitch:hover::before,
.glitch:hover::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.glitch:hover::before {
    left: 2px;
    text-shadow: -1px 0 var(--hacker-accent);
    clip: rect(44px, 450px, 56px, 0);
    animation: glitch 0.3s infinite;
}

.glitch:hover::after {
    left: -2px;
    text-shadow: -1px 0 var(--hacker-error);
    clip: rect(44px, 450px, 56px, 0);
    animation: glitch 0.3s infinite;
}

/* ---------- Animations ---------- */
@keyframes fadeIn {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInDelay {
    0%, 50% {
        opacity: 0;
        transform: translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes typing {
    from { width: 0 }
    to { width: 100% }
}

@keyframes blink {
    0%, 100% { border-color: transparent }
    50% { border-color: var(--hacker-accent) }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

@keyframes glitch {
    0% {
        clip: rect(31px, 9999px, 94px, 0);
    }
    20% {
        clip: rect(62px, 9999px, 61px, 0);
    }
    40% {
        clip: rect(71px, 9999px, 37px, 0);
    }
    60% {
        clip: rect(13px, 9999px, 82px, 0);
    }
    80% {
        clip: rect(41px, 9999px, 70px, 0);
    }
    100% {
        clip: rect(56px, 9999px, 57px, 0);
    }
}

/* ---------- Media Queries ---------- */
@media (min-width: 1024px) {
    .custom-cursor,
    .cursor-trail {
        display: block;
    }
}

@media (max-width: 991px) {
    h1 {
        font-size: 2.5rem;
    }
    
    h2 {
        font-size: 2rem;
    }
    
    .hero-content {
        flex-direction: column;
    }
    
    .about-content,
    .contact-content {
        grid-template-columns: 1fr;
    }
    
    .projects-grid {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    }
}

@media (max-width: 768px) {
    section {
        padding: 80px 0;
    }
    
    .nav-links {
        display: none;
    }
    
    .menu-toggle {
        display: block;
    }
    
    .mobile-menu {
        display: block;
    }
    
    h1 {
        font-size: 2.2rem;
    }
    
    h2 {
        font-size: 1.8rem;
    }
    
    .hero-content {
        text-align: center;
    }
    
    .cta-buttons {
        justify-content: center;
    }
    
    .about-features {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 576px) {
    .projects-grid {
        grid-template-columns: 1fr;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.6rem;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 20px;
    }
}
