:root {
    --bg-dark: #08090c;
    --bg-card: rgba(15, 18, 28, 0.6);
    --bg-card-hover: rgba(22, 27, 42, 0.85);
    --text-primary: #fcfbf8;
    --text-secondary: #9aa0a6;
    --accent-coral: #ff8e63;
    --accent-pink: #ff7eb0;
    --accent-blue: #4b73ff;
    --accent-gradient: linear-gradient(135deg, var(--accent-coral) 0%, var(--accent-pink) 50%, var(--accent-blue) 100%);
    --glass-border: rgba(255, 255, 255, 0.07);
    --font-main: 'Plus Jakarta Sans', 'Outfit', sans-serif;
    --transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-primary);
    font-family: var(--font-main);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    position: relative;
}

/* Subtle background grid pattern representing code systems */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: radial-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 24px 24px;
    z-index: -3;
    pointer-events: none;
}



/* Animated Gradient Blobs (Lovable-inspired fluid mesh backdrop) */
.blob-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -3;
    overflow: hidden;
    pointer-events: none;
}
.blob-container::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(8, 9, 12, 0.35); /* very light dark tint */
    backdrop-filter: blur(80px);
    -webkit-backdrop-filter: blur(80px);
    z-index: 2;
}

.blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    opacity: 0.65; /* more vibrant */
    z-index: 1;
    animation: floatBlob 25s infinite alternate ease-in-out;
}

.blob-1 {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--accent-coral) 0%, rgba(255, 142, 99, 0) 70%);
    top: -10%;
    right: -10%;
    animation-duration: 20s;
}

.blob-2 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, var(--accent-pink) 0%, rgba(255, 126, 176, 0) 70%);
    bottom: -10%;
    left: -10%;
    animation-duration: 26s;
    animation-delay: -5s;
}

.blob-3 {
    width: 550px;
    height: 550px;
    background: radial-gradient(circle, var(--accent-blue) 0%, rgba(75, 115, 255, 0) 70%);
    top: 35%;
    left: 15%;
    animation-duration: 32s;
    animation-delay: -10s;
}

@keyframes floatBlob {
    0% {
        transform: translate(0, 0) scale(1) rotate(0deg);
    }
    33% {
        transform: translate(80px, 60px) scale(1.1) rotate(120deg);
    }
    66% {
        transform: translate(-40px, 40px) scale(0.95) rotate(240deg);
    }
    100% {
        transform: translate(0, 0) scale(1) rotate(360deg);
    }
}

/* Header & Navigation */
header {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 32px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 10;
}

.logo-link {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.main-logo {
    height: 40px;
    width: auto;
    filter: brightness(0) invert(1) drop-shadow(0 2px 6px rgba(255, 255, 255, 0.1));
}

.nav-links {
    display: flex;
    gap: 32px;
    list-style: none;
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: var(--transition);
    position: relative;
    padding: 6px 0;
}

.nav-links a:hover {
    color: var(--text-primary);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-gradient);
    transition: var(--transition);
}

.nav-links a:hover::after {
    width: 100%;
}

/* Container */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 24px 100px;
    flex-grow: 1;
}

/* Hero Section */
.hero {
    text-align: center;
    margin-bottom: 120px;
}

.tagline {
    display: inline-block;
    padding: 6px 18px;
    border-radius: 100px;
    background: rgba(255, 142, 99, 0.08);
    border: 1px solid rgba(255, 142, 99, 0.18);
    color: #ff9d7d;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 28px;
}

.main-title {
    font-size: 4rem;
    font-weight: 900;
    line-height: 1.15;
    letter-spacing: -0.03em;
    margin-bottom: 28px;
    color: #ffffff;
}

.gradient-text {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.subtitle {
    font-size: 1.3rem;
    color: var(--text-secondary);
    max-width: 720px;
    margin: 0 auto 36px;
    line-height: 1.7;
}

/* Portfolio Section */
.section-title {
    font-size: 2.2rem;
    font-weight: 900;
    margin-bottom: 60px;
    text-align: center;
    letter-spacing: -0.02em;
}

.section-title::after {
    content: '';
    display: block;
    width: 50px;
    height: 4px;
    background: var(--accent-gradient);
    border-radius: 2px;
    margin: 16px auto 0;
}

.portfolio-grid {
    display: flex;
    flex-direction: column;
    gap: 56px;
    margin-bottom: 100px;
}

.portfolio-card {
    background: var(--bg-card);
    border: 1px solid var(--glass-border);
    border-radius: 32px;
    padding: 56px;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: 48px;
    align-items: center;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

/* Pair72 Card Styling */
.pair72-card:hover {
    border-color: rgba(255, 126, 176, 0.35);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.5), 0 0 50px rgba(255, 126, 176, 0.08);
    transform: translateY(-4px);
}

/* Halter Card Styling */
.halter-card:hover {
    border-color: rgba(75, 115, 255, 0.35);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.5), 0 0 50px rgba(75, 115, 255, 0.08);
    transform: translateY(-4px);
}

.card-content {
    display: flex;
    flex-direction: column;
}

.app-meta {
    display: flex;
    gap: 16px;
    align-items: center;
    margin-bottom: 24px;
}

.app-badge {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    padding: 6px 14px;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 700;
    color: #cbd5e1;
    letter-spacing: 0.02em;
}

.app-icon-wrapper {
    font-size: 2.2rem;
    filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.3));
}

.app-title {
    font-size: 2.4rem;
    font-weight: 900;
    margin-bottom: 16px;
    color: #ffffff;
    letter-spacing: -0.01em;
}

.app-description {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 32px;
    line-height: 1.7;
}

.app-tech-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 32px;
}

.tech-tag {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 600;
    color: #cbd5e1;
    font-family: monospace;
}

.portfolio-card:hover .tech-tag {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
}

.btn-card-visit {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    padding: 12px 24px;
    border-radius: 100px;
    font-weight: 700;
    font-size: 0.95rem;
    width: fit-content;
    transition: var(--transition);
}

.pair72-card .btn-card-visit {
    background: rgba(255, 126, 176, 0.1);
    border: 1px solid rgba(255, 126, 176, 0.25);
    color: #ff9ec4;
}

.pair72-card .btn-card-visit:hover {
    background: rgba(255, 126, 176, 0.2);
    border-color: #ff7eb0;
    transform: translateY(-2px);
}

.halter-card .btn-card-visit {
    background: rgba(75, 115, 255, 0.1);
    border: 1px solid rgba(75, 115, 255, 0.25);
    color: #8fa6ff;
}

.halter-card .btn-card-visit:hover {
    background: rgba(75, 115, 255, 0.2);
    border-color: #4b73ff;
    transform: translateY(-2px);
}

/* Device Gallery Styling */
.card-visual {
    display: flex;
    justify-content: center;
    align-items: center;
    perspective: 1200px;
}

.device-gallery {
    position: relative;
    width: 280px;
    height: 400px;
}

.device-frame {
    position: absolute;
    width: 170px;
    height: 340px;
    border-radius: 28px;
    background: #000;
    border: 7px solid #141724;
    overflow: hidden;
    transition: var(--transition);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6);
}

.device-screenshot {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.frame-main {
    z-index: 3;
    left: 55px;
    top: 30px;
}

.pair72-card .frame-main {
    box-shadow: 0 20px 45px rgba(255, 126, 176, 0.2);
}
.halter-card .frame-main {
    box-shadow: 0 20px 45px rgba(75, 115, 255, 0.2);
}

.frame-back.left {
    z-index: 1;
    left: -20px;
    top: 50px;
    transform: rotateY(25deg) translateZ(-80px) scale(0.85);
    filter: brightness(0.45);
    opacity: 0.75;
}

.frame-back.right {
    z-index: 2;
    left: 130px;
    top: 50px;
    transform: rotateY(-25deg) translateZ(-80px) scale(0.85);
    filter: brightness(0.45);
    opacity: 0.75;
}

/* Hover transitions */
.portfolio-card:hover .frame-main {
    transform: translateY(-12px) scale(1.04);
}

.portfolio-card:hover .frame-back.left {
    transform: rotateY(15deg) translateZ(-30px) translateX(-25px) scale(0.9);
    filter: brightness(0.8);
    opacity: 0.95;
}

.portfolio-card:hover .frame-back.right {
    transform: rotateY(-15deg) translateZ(-30px) translateX(25px) scale(0.9);
    filter: brightness(0.8);
    opacity: 0.95;
}

/* Info Grid Section */
.info-section {
    margin-bottom: 120px;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
}

.info-card {
    background: rgba(15, 18, 28, 0.45);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 40px 32px;
    transition: var(--transition);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.info-card:hover {
    border-color: rgba(255, 126, 176, 0.25);
    background: var(--bg-card-hover);
    transform: translateY(-6px);
}

.info-icon {
    font-size: 2rem;
    margin-bottom: 24px;
    color: #ff9d7d;
}

.info-title {
    font-size: 1.3rem;
    font-weight: 800;
    margin-bottom: 12px;
    color: #ffffff;
    letter-spacing: -0.01em;
}

.info-text {
    font-size: 1rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Contact Section */
.contact-section {
    background: radial-gradient(circle at top, rgba(255, 142, 99, 0.08) 0%, transparent 70%);
    border: 1px solid var(--glass-border);
    border-radius: 36px;
    padding: 70px 40px;
    text-align: center;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.contact-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 250px;
    height: 3px;
    background: var(--accent-gradient);
}

.contact-title {
    font-size: 2.5rem;
    font-weight: 900;
    margin-bottom: 20px;
    letter-spacing: -0.02em;
}

.contact-subtitle {
    color: var(--text-secondary);
    font-size: 1.1rem;
    max-width: 650px;
    margin: 0 auto;
    line-height: 1.7;
}

.subtle-contact-link {
    color: var(--accent-pink);
    text-decoration: underline;
    font-weight: 500;
    transition: var(--transition);
}

.subtle-contact-link:hover {
    color: var(--accent-coral);
}

.contact-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    padding: 16px 36px;
    border-radius: 100px;
    font-weight: 700;
    font-size: 1.05rem;
    transition: var(--transition);
}

.btn-primary {
    background: var(--accent-gradient);
    color: #ffffff;
    box-shadow: 0 10px 25px rgba(255, 126, 176, 0.25);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 35px rgba(255, 126, 176, 0.45);
    filter: brightness(1.1);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #ffffff;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateY(-3px);
    border-color: rgba(255, 255, 255, 0.15);
}

/* Footer Bottom Links */
.footer-bottom-links {
    margin-top: 60px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    font-size: 0.9rem;
}

.footer-bottom-links a {
    color: var(--text-secondary);
    text-decoration: none;
    opacity: 0.7;
    transition: var(--transition);
}

.footer-bottom-links a:hover {
    opacity: 1;
    color: var(--text-primary);
}

.separator {
    color: var(--text-secondary);
    opacity: 0.3;
}

/* Scroll Reveal Animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 1.2s cubic-bezier(0.16, 1, 0.3, 1), transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Accessibility Settings */
.accessibility-trigger {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 48px;
    height: 48px;
    background: transparent;
    color: #ffffff;
    border: 2px solid rgba(255, 255, 255, 0.45);
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.25);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.accessibility-trigger:hover {
    transform: scale(1.1);
    background: rgba(255, 255, 255, 0.08);
    border-color: #ffffff;
}

.accessibility-trigger svg {
    width: 24px;
    height: 24px;
}

.accessibility-menu {
    position: fixed;
    bottom: 84px;
    right: 24px;
    background: #0d0f14;
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 24px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
    display: none;
    flex-direction: column;
    gap: 12px;
    z-index: 1001;
    width: 350px;
    max-height: 80vh;
    overflow-y: auto;
    text-align: left;
    animation: slideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.accessibility-menu.active {
    display: flex;
}

.acc-header {
    font-size: 1.1rem;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 8px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.acc-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    margin-bottom: 8px;
}

.acc-btn {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    padding: 10px 12px;
    border-radius: 10px;
    font-family: inherit;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
    width: 100%;
}

.acc-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--accent-pink);
    color: #ffffff;
}

.acc-btn.reset {
    margin-top: 4px;
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
    border-color: rgba(239, 68, 68, 0.2);
    font-size: 0.88rem;
    padding: 12px;
    justify-content: center;
}

.acc-btn.reset:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: #ef4444;
}

/* Accessibility Settings Actions */
.acc-contrast {
    filter: contrast(1.3) saturate(0.6);
}

.acc-contrast .portfolio-card,
.acc-contrast .info-card,
.acc-contrast .contact-section {
    background: #000 !important;
    border: 2px solid #fff !important;
    box-shadow: none !important;
}

.acc-contrast * {
    color: #fff !important;
    border-color: rgba(255, 255, 255, 0.4) !important;
}

.acc-grayscale {
    filter: grayscale(1) !important;
}

.acc-big-fonts {
    font-size: 1.15em;
}

.acc-small-fonts {
    font-size: 0.85em;
}

.acc-readable-font,
.acc-readable-font * {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif !important;
}

.acc-highlight-links a {
    text-decoration: underline !important;
    outline: 2px dashed var(--accent-pink) !important;
    outline-offset: 2px;
}

.acc-highlight-headers h1,
.acc-highlight-headers h2,
.acc-highlight-headers h3 {
    outline: 2px dashed var(--accent-blue) !important;
    outline-offset: 4px;
}

.acc-big-cursor,
.acc-big-cursor * {
    cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' viewBox='0 0 24 24' fill='white' stroke='black' stroke-width='2'%3E%3Cpath d='M4.5 3v15.25l3.95-3.8 2.3 4.8 2.55-1.2-2.3-4.8 4.65-.05z'/%3E%3C/svg%3E"), auto !important;
}

.acc-stop-animations .blob {
    animation: none !important;
}

/* Animations */
@keyframes slideUp {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Responsive Grid Rules */
@media (max-width: 960px) {
    .portfolio-card {
        grid-template-columns: 1fr;
        padding: 36px;
        gap: 40px;
    }
    
    .device-gallery {
        width: 260px;
        height: 380px;
    }
    
    .device-frame {
        width: 150px;
        height: 300px;
    }
    
    .frame-main {
        left: 55px;
        top: 25px;
    }
    
    .frame-back.left {
        left: -15px;
        top: 40px;
    }
    
    .frame-back.right {
        left: 125px;
        top: 40px;
    }
    
    .info-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

@media (max-width: 640px) {
    .container {
        padding: 40px 16px 80px;
    }
    .main-title {
        font-size: 2.8rem;
    }
    .subtitle {
        font-size: 1.1rem;
    }
    header {
        flex-direction: column;
        gap: 16px;
        padding: 24px 16px;
    }
    .nav-links {
        gap: 24px;
    }
}
