@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=Inter:wght@300;400;500;600&display=swap');

:root {
    /* Dark Mode - The Brutalist (Default) */
    --bg-main: #000000;
    --bg-surface: #111111;
    --text-primary: #FFFFFF;
    --text-secondary: #A3A3A3;
    --accent: #D1D5DB;
    --border-color: #333333;
    --invert-filter: invert(1);
    --cursor-url: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' width='28' height='28' viewBox='0 0 100 100'><rect width='100' height='100' rx='24' fill='%23121215' stroke='%23ffffff' stroke-width='4'/><text x='50%' y='54%' dominant-baseline='central' text-anchor='middle' font-size='56' font-family='system-ui, -apple-system, sans-serif' font-weight='800' fill='%23ffffff'>D.</text></svg>");
}

[data-theme="light"] {
    /* Light Mode - Nền Be nhạt (#F5F5F0) & Xanh Rêu thẫm (#1F2922) */
    --bg-main: #F5F5F0;
    --bg-surface: #EAEAE3;
    --text-primary: #1F2922;
    --text-secondary: #48564C;
    --accent: #1F2922;
    --border-color: #D5D5CA;
    --invert-filter: invert(0);
    --cursor-url: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' width='28' height='28' viewBox='0 0 100 100'><rect width='100' height='100' rx='24' fill='%231F2922' stroke='%23F5F5F0' stroke-width='4'/><text x='50%' y='54%' dominant-baseline='central' text-anchor='middle' font-size='56' font-family='system-ui, -apple-system, sans-serif' font-weight='800' fill='%23F5F5F0'>D.</text></svg>");
}

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

html,
body,
a,
button,
input,
textarea,
select,
label,
.btn,
.tech-item,
.work-card,
.service-card,
.bento-card {
    cursor: var(--cursor-url) 14 14, auto;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-main);
    color: var(--text-primary);
    transition: background-color 0.4s ease, color 0.4s ease;
    line-height: 1.6;
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6,
.brand-font {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
}

a {
    color: inherit;
    text-decoration: none;
    transition: opacity 0.3s ease;
}

a:hover {
    opacity: 0.8;
}

ul {
    list-style: none;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
}

/* --- Typography --- */
.text-accent {
    color: var(--accent);
}

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

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border-radius: 99px;
    font-family: 'Outfit', sans-serif;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    gap: 8px;
    font-size: 1rem;
}

.btn-primary {
    background-color: var(--text-primary);
    color: var(--bg-main);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 255, 255, 0.1);
}

[data-theme="light"] .btn-primary:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--text-primary);
    color: var(--text-primary);
}

.btn-outline:hover {
    background-color: var(--text-primary);
    color: var(--bg-main);
}

/* --- Sticky Navigation --- */
header {
    position: sticky;
    top: 0;
    z-index: 50;
    background-color: rgba(var(--bg-main-rgb), 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.nav-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.logo {
    font-size: 1.5rem;
    letter-spacing: -0.5px;
    display: flex;
    align-items: center;
    gap: 8px;
}

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

.nav-links a {
    font-weight: 500;
    font-size: 0.95rem;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0%;
    height: 2px;
    background-color: var(--accent);
    transition: width 0.3s ease;
}

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

.nav-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.lang-switch {
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
}

.theme-toggle {
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--bg-surface);
    transition: all 0.3s ease;
}

.theme-toggle:hover {
    background-color: var(--border-color);
}

.theme-toggle .moon-icon {
    display: none;
}

[data-theme="light"] .theme-toggle .sun-icon {
    display: none;
}

[data-theme="light"] .theme-toggle .moon-icon {
    display: block;
}

/* --- Hero Section (Bento Box) --- */
.hero {
    padding: 40px 0;
}

.bento-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 0.35fr;
    grid-template-rows: 230px 310px;
    gap: 16px;
    height: 556px;
}

.bento-card {
    background-color: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    padding: 32px;
    overflow: hidden;
    position: relative;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.bento-card:hover {
    border-color: var(--accent);
}

.bento-main {
    grid-column: 1 / span 2;
    grid-row: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 32px 40px;
    height: 100%;
}

.bento-main h1 {
    font-size: 3.2rem;
    line-height: 1.1;
    letter-spacing: -1.5px;
    margin-bottom: 10px;
}

.bento-main p {
    font-size: 1.05rem;
    color: var(--text-secondary);
    line-height: 1.5;
    max-width: 750px;
}

/* Khối Visual (Video Showcase) */
.bento-visual {
    grid-column: 1;
    grid-row: 2;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    background: var(--bg-main);
    overflow: hidden;
}

.video-container {
    position: relative;
    width: 100%;
    height: 100%;
}

.video-container video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    filter: brightness(0.85);
}

.video-overlay {
    position: absolute;
    bottom: 16px;
    left: 16px;
    z-index: 2;
}

.video-badge {
    background: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(8px);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 6px 14px;
    border-radius: 99px;
    font-size: 0.75rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    letter-spacing: 0.5px;
}

/* Khối Starter Package Nổi Bật */
.bento-bait {
    grid-column: 2;
    grid-row: 2;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 24px 28px;
    height: 100%;
}

.highlight-bait {
    border: 1.5px solid var(--text-primary);
    background: linear-gradient(135deg, var(--bg-surface), rgba(255, 255, 255, 0.04));
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.bait-badge {
    background-color: var(--text-primary);
    color: var(--bg-main);
    font-size: 0.7rem;
    font-weight: 800;
    padding: 4px 12px;
    border-radius: 99px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    letter-spacing: 0.5px;
    margin-bottom: 12px;
    width: fit-content;
}

.bait-header h3 {
    font-size: 1.4rem;
    margin-bottom: 4px;
}

.bait-header p {
    font-size: 0.88rem;
}

.bait-middle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin: 12px 0;
}

.price-box .price-prefix {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.price-box .price {
    font-size: 2.4rem;
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    line-height: 1;
    color: var(--accent);
}

.price-box .currency {
    font-size: 0.95rem;
    font-weight: 600;
}

.bait-features {
    display: flex;
    flex-direction: column;
    gap: 5px;
    font-size: 0.85rem;
    color: var(--text-primary);
    font-weight: 500;
}

.bait-features li {
    display: flex;
    align-items: center;
    gap: 8px;
}

.bait-features li i {
    width: 15px;
    height: 15px;
    stroke-width: 2.5;
    color: var(--accent);
}

.btn-cta {
    width: 100%;
    padding: 12px 20px;
    font-size: 0.95rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.bento-marquee-vertical {
    grid-column: 3;
    grid-row: 1 / span 2;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    height: 100%;
    max-height: 100%;
    position: relative;
    background: linear-gradient(145deg, #E6E6EB, #D0D0D8, #F0F0F5);
    color: #121215;
    border: 1px solid rgba(255, 255, 255, 0.4);
    box-shadow: inset 0 0 20px rgba(255, 255, 255, 0.6), 0 10px 30px rgba(0, 0, 0, 0.2);
    padding: 0;
}

[data-theme="light"] .bento-marquee-vertical {
    background: linear-gradient(145deg, #EBEBE5, #DCDCD4, #F5F5EF);
    color: #1F2922;
    border: 1px solid #D2D2C7;
    box-shadow: inset 0 0 20px rgba(255, 255, 255, 0.7), 0 8px 20px rgba(0, 0, 0, 0.08);
}

.marquee-vertical-track {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    will-change: transform;
}

.marquee-vertical-track span {
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 2rem;
    line-height: 1.2;
    text-transform: uppercase;
    text-align: center;
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    padding: 24px 0;
    white-space: normal;
}

@keyframes marquee-vertical-loop {
    0% {
        transform: translateY(0%);
    }

    100% {
        transform: translateY(-50%);
    }
}

@keyframes marquee-vertical-loop-reverse {
    0% {
        transform: translateY(-50%);
    }

    100% {
        transform: translateY(0%);
    }
}

/* --- Services & Pricing --- */
.services {
    padding: 100px 0;
}

.section-header {
    margin-bottom: 64px;
}

.section-header h2 {
    font-size: 3rem;
    letter-spacing: -1px;
    margin-bottom: 16px;
}

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

.service-card {
    background-color: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    padding: 40px 32px;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.service-card:hover {
    transform: translateY(-8px);
    border-color: var(--accent);
}

.service-card.highlight {
    background: linear-gradient(135deg, var(--bg-surface), var(--bg-main));
    border-color: var(--accent);
}

.service-tag {
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-secondary);
    margin-bottom: 16px;
}

.service-card h3 {
    font-size: 1.75rem;
    margin-bottom: 16px;
}

.service-price {
    font-size: 2.5rem;
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border-color);
}

.service-features {
    flex-grow: 1;
    margin-bottom: 32px;
}

.service-features li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 12px;
    color: var(--text-secondary);
}

.service-features li svg {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    color: var(--accent);
    margin-top: 2px;
}

/* --- Selected Works --- */
.works {
    padding: 100px 0;
}

.works-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 32px;
}

.work-card {
    position: relative;
    border-radius: 24px;
    overflow: hidden;
    background-color: var(--bg-surface);
    aspect-ratio: 4/3;
    display: block;
}

.work-img-wrapper {
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.work-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1);
}

.work-card:hover .work-img-wrapper img {
    transform: scale(1.05);
}

.work-info {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 32px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
    color: #FFFFFF;
    /* Luôn sáng cho phần hình ảnh */
}

.work-info h3 {
    font-size: 1.5rem;
    margin-bottom: 8px;
}

.work-tags {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.work-tags span {
    font-size: 0.8rem;
    font-family: 'Outfit', monospace;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(4px);
    padding: 4px 12px;
    border-radius: 99px;
}

/* --- Tech Stack Marquee --- */
.tech-stack {
    padding: 60px 0;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    overflow: hidden;
    background-color: var(--bg-surface);
}

.marquee-container {
    display: flex;
    width: 200%;
    animation: marquee-horizontal 20s linear infinite;
}



/* =========================
   TECH STACK
========================= */

.tech-stack {
    padding: 70px 0;
    background: var(--bg-surface);
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    overflow: hidden;
}

.marquee-container {
    display: flex;
    width: max-content;
    animation: marquee-horizontal 32s linear infinite;
}

.marquee-container:hover {
    animation-play-state: paused;
}

.marquee-content {
    display: flex;
    align-items: center;
    gap: 22px;
    padding-right: 22px;
}

.tech-item {
    position: relative;
    width: 82px;
    height: 82px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 20px;
    background: var(--bg-main);
    border: 1px solid var(--border-color);
    transition: .35s;
    flex-shrink: 0;
}

.tech-item:hover {
    transform: translateY(-8px);
    border-color: #555;
    box-shadow:
        0 12px 35px rgba(0, 0, 0, .35);
}

/* Tooltip hiển thị tên đầy đủ khi hover */
.tech-item::after {
    content: attr(data-name);
    position: absolute;
    bottom: calc(100% + 12px);
    left: 50%;
    transform: translateX(-50%) translateY(6px);
    background: rgba(20, 20, 25, 0.95);
    color: #fff;
    padding: 6px 12px;
    font-size: 0.75rem;
    font-weight: 600;
    font-family: 'Inter', sans-serif;
    letter-spacing: 0.3px;
    white-space: nowrap;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(8px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 100;
}

.tech-item::before {
    content: '';
    position: absolute;
    bottom: calc(100% + 4px);
    left: 50%;
    transform: translateX(-50%) translateY(6px);
    border-width: 5px 6px 0 6px;
    border-style: solid;
    border-color: rgba(20, 20, 25, 0.95) transparent transparent transparent;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 100;
}

.tech-item:hover::after,
.tech-item:hover::before {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.tech-item img {

    width: 42px;
    height: 42px;

    transition: .35s;

}

.tech-item:hover img {

    transform: scale(1.15);

}

/* =========================
   BRAND COLORS
========================= */

.html img {
    filter: brightness(0) saturate(100%) invert(49%) sepia(93%) saturate(1800%) hue-rotate(347deg);
}

.css img {
    filter: brightness(0) saturate(100%) invert(36%) sepia(94%) saturate(1850%) hue-rotate(190deg);
}

.js img {
    filter: brightness(0) saturate(100%) invert(89%) sepia(42%) saturate(1150%) hue-rotate(358deg);
}

.php img {
    filter: brightness(0) saturate(100%) invert(46%) sepia(14%) saturate(1160%) hue-rotate(204deg);
}

.dotnet img {
    filter: brightness(0) saturate(100%) invert(23%) sepia(92%) saturate(2400%) hue-rotate(255deg);
}

.react img {
    filter: brightness(0) saturate(100%) invert(79%) sepia(36%) saturate(1450%) hue-rotate(158deg);
}

.next img {
    filter: invert(100%);
}

.node img {
    filter: brightness(0) saturate(100%) invert(50%) sepia(83%) saturate(520%) hue-rotate(78deg);
}

.mysql img {
    filter: brightness(0) saturate(100%) invert(35%) sepia(76%) saturate(620%) hue-rotate(173deg);
}

.postgres img {
    filter: brightness(0) saturate(100%) invert(33%) sepia(85%) saturate(980%) hue-rotate(183deg);
}

.docker img {
    filter: brightness(0) saturate(100%) invert(47%) sepia(93%) saturate(1500%) hue-rotate(180deg);
}

.git img {
    filter: brightness(0) saturate(100%) invert(48%) sepia(90%) saturate(1800%) hue-rotate(345deg);
}

.laravel img {
    filter: brightness(0) saturate(100%) invert(26%) sepia(98%) saturate(3200%) hue-rotate(350deg);
}

.ci img {
    filter: brightness(0) saturate(100%) invert(29%) sepia(96%) saturate(3100%) hue-rotate(352deg);
}

.mongo img {
    filter: brightness(0) saturate(100%) invert(41%) sepia(66%) saturate(700%) hue-rotate(74deg);
}

.vue img {
    filter: brightness(0) saturate(100%) invert(43%) sepia(65%) saturate(730%) hue-rotate(125deg);
}

.wp img {
    filter: brightness(0) saturate(100%) invert(41%) sepia(78%) saturate(900%) hue-rotate(175deg);
}

@keyframes marquee-horizontal {

    from {
        transform: translateX(0);
    }

    to {
        transform: translateX(-50%);
    }

}

@keyframes marquee-horizontal {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

/* --- Footer & Contact --- */
.footer {
    padding: 100px 0 40px;
    background-color: var(--bg-main);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 64px;
    margin-bottom: 64px;
}

.contact-form {
    background-color: var(--bg-surface);
    padding: 40px;
    border-radius: 24px;
    border: 1px solid var(--border-color);
}

.form-group {
    margin-bottom: 24px;
}

.form-control {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px solid var(--border-color);
    padding: 16px 0;
    color: var(--text-primary);
    font-size: 1rem;
    font-family: 'Inter', sans-serif;
    transition: border-color 0.3s ease;
}

.form-control:focus {
    outline: none;
    border-bottom-color: var(--accent);
}

textarea.form-control {
    resize: vertical;
    min-height: 100px;
}

.footer-info {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.footer-brand {
    font-size: 6rem;
    line-height: 1;
    letter-spacing: -3px;
    margin-bottom: 24px;
    color: var(--text-primary);
}

.footer-links {
    margin-bottom: 32px;
}

.footer-links a {
    display: block;
    font-size: 1.5rem;
    font-family: 'Outfit', sans-serif;
    margin-bottom: 12px;
    width: fit-content;
}

.footer-links a:hover {
    color: var(--accent);
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--border-color);
    padding-top: 24px;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* --- Floating Action Buttons (FABs) --- */
.fabs {
    position: fixed;
    bottom: 24px;
    right: 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 100;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s ease;
}

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

.fab {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: var(--bg-surface);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.fab:hover {
    transform: scale(1.1);
}

.fab.zalo:hover {
    background-color: #0068FF;
    color: #FFF;
    border-color: #0068FF;
}

.fab.tele:hover {
    background-color: #2AABEE;
    color: #FFF;
    border-color: #2AABEE;
}

.fab.wa:hover {
    background-color: #25D366;
    color: #FFF;
    border-color: #25D366;
}

.fab.back-to-top {
    background-color: var(--text-primary);
    color: var(--bg-main);
}

.fab.back-to-top:hover {
    opacity: 0.9;
}

/* Responsive */
@media (max-width: 1024px) {
    .bento-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .bento-visual {
        grid-column: span 2;
    }

    .bento-bait {
        grid-column: span 1;
    }

    .bento-marquee-vertical {
        grid-column: span 1;
        min-height: 200px;
    }

    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }

    .bento-main h1 {
        font-size: 3rem;
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    .works-grid {
        grid-template-columns: 1fr;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .footer-brand {
        font-size: 4rem;
    }
}