/* ??????? */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #3b82f6;
    --primary-dark: #2563eb;
    --primary-glow: rgba(59, 130, 246, 0.5);
    --secondary-color: #10b981;
    --accent-color: #8b5cf6;
    --text-dark: #1f2937;
    --text-light: #9ca3af;
    --text-white: #ffffff;
    --bg-dark: #0a0e27;
    --bg-darker: #050714;
    --bg-card: #111827;
    --bg-card-hover: #1f2937;
    --border-color: rgba(59, 130, 246, 0.3);
    --border-glow: rgba(59, 130, 246, 0.6);
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3), 0 2px 4px -1px rgba(0, 0, 0, 0.2);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.4), 0 4px 6px -2px rgba(0, 0, 0, 0.3);
    --glow: 0 0 20px var(--primary-glow);
}

body {
    font-size: calc(1rem + 5px);
    font-family: 'Noto Sans TC', sans-serif;
    line-height: 1.6;
    color: var(--text-white);
    overflow-x: hidden;
    background: var(--bg-dark);
    position: relative;
}

/* ??????? */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(59, 130, 246, 0.1) 1px, transparent 1px),
        linear-gradient(90deg, rgba(59, 130, 246, 0.1) 1px, transparent 1px);
    background-size: 50px 50px;
    pointer-events: none;
    z-index: 0;
    animation: gridMove 20s linear infinite;
}

@keyframes gridMove {
    0% {
        transform: translate(0, 0);
    }
    100% {
        transform: translate(50px, 50px);
    }
}

/* ???????? */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 50%, rgba(59, 130, 246, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(139, 92, 246, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 20%, rgba(16, 185, 129, 0.05) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
    animation: pulse 15s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 0.5;
    }
    50% {
        opacity: 1;
    }
}

/* ???? */
.particles {
    position: fixed;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
    z-index: 0;
}

.particle {
    position: absolute;
    width: 2px;
    height: 2px;
    background: #00d4ff;
    border-radius: 50%;
    opacity: 0;
    box-shadow: 0 0 6px rgba(0, 212, 255, 0.8);
    animation: particle-rise linear infinite;
}

@keyframes particle-rise {
    0% {
        transform: translateY(100vh) translateX(0);
        opacity: 0;
    }
    10% {
        opacity: 0.8;
    }
    90% {
        opacity: 0.4;
    }
    100% {
        transform: translateY(-10vh) translateX(40px);
        opacity: 0;
    }
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
    z-index: 1;
}

/* ??? */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(10, 14, 39, 0.8);
    backdrop-filter: blur(20px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5), 0 0 20px rgba(59, 130, 246, 0.2);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    transition: all 0.3s ease;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 20px;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.nav-brand h1 {
    font-size: calc(1.5rem + 5px);
    color: var(--primary-color);
    font-weight: 700;
    margin: 0;
}

.nav-logo {
    height: 32px;
    width: auto;
    object-fit: contain;
    filter: drop-shadow(0 0 8px rgba(59, 130, 246, 0.4));
    transition: all 0.3s ease;
}

.nav-brand:hover .nav-logo {
    filter: drop-shadow(0 0 12px rgba(59, 130, 246, 0.6));
    transform: scale(1.05);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-link {
    text-decoration: none;
    color: var(--text-white);
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
}

.nav-link:hover {
    color: var(--primary-color);
    text-shadow: 0 0 10px var(--primary-glow);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    box-shadow: 0 0 10px var(--primary-glow);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 5px;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--text-white);
    transition: all 0.3s ease;
    box-shadow: 0 0 5px rgba(59, 130, 246, 0.5);
}

/* ??? */
.hero {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
    overflow: hidden;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 30% 50%, rgba(59, 130, 246, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 70% 50%, rgba(139, 92, 246, 0.3) 0%, transparent 50%),
        linear-gradient(135deg, var(--bg-darker) 0%, var(--bg-dark) 100%);
    z-index: -1;
    animation: gradientShift 10s ease infinite;
}

@keyframes gradientShift {
    0%, 100% {
        filter: hue-rotate(0deg);
    }
    50% {
        filter: hue-rotate(20deg);
    }
}

.gradient-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        linear-gradient(180deg, rgba(10, 14, 39, 0.7) 0%, rgba(10, 14, 39, 0.9) 100%),
        repeating-linear-gradient(
            0deg,
            transparent,
            transparent 2px,
            rgba(59, 130, 246, 0.03) 2px,
            rgba(59, 130, 246, 0.03) 4px
        );
}

/* ??????? */
.tech-decoration {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.tech-circle {
    position: absolute;
    border: 2px solid rgba(59, 130, 246, 0.3);
    border-radius: 50%;
    animation: pulseCircle 4s ease-in-out infinite;
}

.circle-1 {
    width: 300px;
    height: 300px;
    top: 10%;
    right: 10%;
    box-shadow: 0 0 30px rgba(59, 130, 246, 0.3);
}

.circle-2 {
    width: 200px;
    height: 200px;
    bottom: 20%;
    left: 15%;
    border-color: rgba(139, 92, 246, 0.3);
    box-shadow: 0 0 30px rgba(139, 92, 246, 0.3);
    animation-delay: 1s;
}

.circle-3 {
    width: 150px;
    height: 150px;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    border-color: rgba(16, 185, 129, 0.3);
    box-shadow: 0 0 30px rgba(16, 185, 129, 0.3);
    animation-delay: 2s;
}

@keyframes pulseCircle {
    0%, 100% {
        opacity: 0.3;
        transform: scale(1);
    }
    50% {
        opacity: 0.6;
        transform: scale(1.1);
    }
}

.tech-line {
    position: absolute;
    background: linear-gradient(90deg, transparent, rgba(59, 130, 246, 0.5), transparent);
    animation: lineMove 8s linear infinite;
}

.line-1 {
    width: 200px;
    height: 1px;
    top: 30%;
    left: 5%;
    transform: rotate(45deg);
    animation-delay: 0s;
}

.line-2 {
    width: 150px;
    height: 1px;
    bottom: 30%;
    right: 10%;
    transform: rotate(-45deg);
    animation-delay: 2s;
}

.line-3 {
    width: 180px;
    height: 1px;
    top: 60%;
    left: 20%;
    transform: rotate(30deg);
    animation-delay: 4s;
}

@keyframes lineMove {
    0% {
        opacity: 0;
        transform: translateX(-50px) rotate(45deg);
    }
    50% {
        opacity: 1;
    }
    100% {
        opacity: 0;
        transform: translateX(50px) rotate(45deg);
    }
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    padding: 0 20px;
    animation: fadeInUp 1s ease;
}

.hero-title {
    font-size: calc(3.5rem + 5px);
    font-weight: 700;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #ffffff 0%, var(--primary-color) 50%, var(--accent-color) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 30px rgba(59, 130, 246, 0.5);
    filter: drop-shadow(0 0 20px rgba(59, 130, 246, 0.3));
    animation: titleGlow 3s ease-in-out infinite;
}

@keyframes titleGlow {
    0%, 100% {
        filter: drop-shadow(0 0 20px rgba(59, 130, 246, 0.3));
    }
    50% {
        filter: drop-shadow(0 0 30px rgba(59, 130, 246, 0.6));
    }
}

.hero-subtitle {
    font-size: calc(1.25rem + 5px);
    margin-bottom: 2rem;
    opacity: 0.95;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* ???? */
.btn {
    display: inline-block;
    padding: 0.75rem 2rem;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: calc(1rem + 5px);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-color) 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.4);
    position: relative;
    overflow: hidden;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s;
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(59, 130, 246, 0.6), 0 0 30px rgba(59, 130, 246, 0.4);
}

.btn-secondary {
    background: transparent;
    color: white;
    border: 2px solid var(--primary-color);
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.3);
}

.btn-secondary:hover {
    background: rgba(59, 130, 246, 0.1);
    border-color: var(--accent-color);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 0 25px rgba(59, 130, 246, 0.6);
}

/* ???? */
.section-title {
    font-size: calc(2.5rem + 5px);
    font-weight: 700;
    text-align: center;
    margin-bottom: 1rem;
    color: var(--text-white);
    position: relative;
    display: inline-block;
    width: 100%;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--primary-color), transparent);
    box-shadow: 0 0 10px var(--primary-glow);
}

.section-subtitle {
    text-align: center;
    color: var(--text-light);
    font-size: calc(1.1rem + 5px);
    margin-bottom: 3rem;
}

/* ??? */
.services {
    padding: 100px 0;
    background: var(--bg-dark);
    position: relative;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.service-card {
    background: var(--bg-card);
    padding: 2rem;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
    text-align: left;
    position: relative;
    overflow: hidden;
    display: grid;
    grid-template-columns: auto 1fr;
    column-gap: 1rem;
    row-gap: 1rem;
    align-items: center;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(59, 130, 246, 0.1), transparent);
    transition: left 0.5s;
}

.service-card:hover::before {
    left: 100%;
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), 0 0 20px var(--primary-glow);
    border-color: var(--border-glow);
    background: var(--bg-card-hover);
}

.service-icon {
    width: 48px;
    height: 48px;
    margin-bottom: 0;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 1;
    grid-column: 1;
    grid-row: 1;
}

.service-icon svg {
    width: 100%;
    height: 100%;
    transition: transform 0.3s ease, filter 0.3s ease;
}

.service-card:hover .service-icon {
    color: #60a5fa;
}

.service-card:hover .service-icon svg {
    transform: scale(1.08);
    filter: drop-shadow(0 0 8px var(--primary-glow));
}

.service-card h3 {
    font-size: calc(1.75rem + 5px);
    margin-bottom: 0;
    color: var(--text-white);
    position: relative;
    z-index: 1;
    grid-column: 2;
    grid-row: 1;
    align-self: center;
}

.service-card p {
    color: var(--text-light);
    font-size: calc(1.1rem + 5px);
    line-height: 1.8;
    position: relative;
    z-index: 1;
    grid-column: 1 / -1;
    grid-row: 2;
}

/* ????? */
.about {
    padding: 100px 0;
    background: var(--bg-darker);
    position: relative;
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    margin-top: 3rem;
}

.about-text p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
    font-size: calc(1.1rem + 5px);
    line-height: 1.8;
}

.about-text .section-title {
    color: var(--text-white);
}

.stats {
    display: flex;
    gap: 3rem;
    margin-top: 2rem;
}

.stat-item {
    text-align: center;
}

.stat-item h3 {
    font-size: calc(2.5rem + 5px);
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 700;
    margin-bottom: 0.5rem;
    text-shadow: 0 0 20px var(--primary-glow);
}

.stat-item p {
    color: var(--text-light);
    font-size: calc(1rem + 5px);
}

.about-image {
    position: relative;
}

.image-placeholder {
    width: 100%;
    height: 400px;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.2) 0%, rgba(139, 92, 246, 0.2) 100%);
    border-radius: 12px;
    position: relative;
    overflow: hidden;
    border: 1px solid var(--border-color);
    box-shadow: 0 0 30px rgba(59, 130, 246, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    transition: all 0.3s ease;
}

.image-placeholder:hover {
    box-shadow: 0 0 40px rgba(59, 130, 246, 0.5), 0 0 60px rgba(139, 92, 246, 0.3);
    border-color: var(--border-glow);
    transform: scale(1.02);
}

.logo-image {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    filter: drop-shadow(0 0 20px rgba(59, 130, 246, 0.4));
    transition: all 0.3s ease;
}

.image-placeholder:hover .logo-image {
    filter: drop-shadow(0 0 30px rgba(59, 130, 246, 0.6));
    transform: scale(1.05);
}

.tech-pattern {
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(45deg, rgba(59, 130, 246, 0.2) 25%, transparent 25%),
        linear-gradient(-45deg, rgba(59, 130, 246, 0.2) 25%, transparent 25%),
        linear-gradient(45deg, transparent 75%, rgba(139, 92, 246, 0.2) 75%),
        linear-gradient(-45deg, transparent 75%, rgba(139, 92, 246, 0.2) 75%);
    background-size: 30px 30px;
    background-position: 0 0, 0 15px, 15px -15px, -15px 0px;
    animation: patternMove 20s linear infinite;
}

@keyframes patternMove {
    0% {
        background-position: 0 0, 0 15px, 15px -15px, -15px 0px;
    }
    100% {
        background-position: 30px 30px, 30px 45px, 45px 15px, 15px 30px;
    }
}

/* ??? */
.team {
    padding: 100px 0;
    background: var(--bg-dark);
    position: relative;
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.team-card {
    background: var(--bg-card);
    padding: 2rem;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow);
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.team-card::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.1) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.team-card:hover::after {
    opacity: 1;
}

.team-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), 0 0 20px var(--primary-glow);
    border-color: var(--border-glow);
}

.team-avatar {
    width: 100px;
    height: 100px;
    border-radius: 50%;  /* ?????? */
    object-fit: cover;   /* ???????????? */
    display: block;      /* ???????????????? */
    margin: 0 auto 10px auto; /* ???????? */
}

.test-avatar {
    width: 100px;
    height: 100px;
    object-fit: cover; 
    background-color: white; /* ???? */
    border-radius: 50%;
}


.team-card h3 {
    font-size: calc(1.5rem + 5px);
    margin-bottom: 0.5rem;
    color: var(--text-white);
    position: relative;
    z-index: 1;
}

.team-role {
    color: var(--primary-color);
    font-weight: 500;
    margin-bottom: 1rem;
    position: relative;
    z-index: 1;
    text-shadow: 0 0 10px var(--primary-glow);
}

.team-bio {
    color: var(--text-light);
    line-height: 1.8;
    position: relative;
    z-index: 1;
}

/* ????? */
.contact {
    padding: 100px 0;
    background: var(--bg-darker);
    position: relative;
}

.contact-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 3rem;
    max-width: 640px;
    margin-left: auto;
    margin-right: auto;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    width: 100%;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group input,
.form-group textarea {
    padding: 1rem;
    background: var(--bg-card);
    color: var(--text-white);
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-family: 'Noto Sans TC', sans-serif;
    font-size: calc(1rem + 5px);
    transition: all 0.3s ease;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-light);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 15px var(--primary-glow);
    background: var(--bg-card-hover);
}

.form-group textarea {
    resize: vertical;
}

/* ?? */
.footer {
    background: var(--text-dark);
    color: white;
    padding: 3rem 0 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: 1.3fr 0.9fr 1.2fr 1.1fr;
    gap: 2.5rem;
    margin-bottom: 2rem;
    align-items: start;
}

.footer-section h3,
.footer-section h4 {
    margin-bottom: 1rem;
}

.footer-section p {
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.8;
}

.footer-tagline {
    white-space: nowrap;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-services {
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: 1.25rem;
    row-gap: 0.5rem;
}

.footer-services li {
    margin-bottom: 0;
}

.footer-contact ul li {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.footer-contact-label {
    color: rgba(255, 255, 255, 0.45);
    font-size: 0.9rem;
}

.footer-contact a {
    color: var(--primary-color);
    word-break: break-all;
}

.footer-section.footer-contact a:hover {
    color: #60a5fa;
}

.footer-section a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: white;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.7);
}

/* ?? */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ????? */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background: var(--bg-card);
        border: 1px solid var(--border-color);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: var(--shadow);
        padding: 2rem 0;
    }

    .nav-menu.active {
        left: 0;
    }

    .hero-title {
        font-size: calc(2.5rem + 5px);
    }

    .hero-subtitle {
        font-size: calc(1rem + 5px);
    }

    .section-title {
        font-size: calc(2rem + 5px);
    }

    .about-content {
        grid-template-columns: 1fr;
    }

    .stats {
        flex-direction: column;
        gap: 2rem;
    }

    .services-grid,
    .team-grid {
        grid-template-columns: 1fr;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .footer-tagline {
        white-space: normal;
    }

    .footer-services {
        grid-template-columns: 1fr 1fr;
        max-width: 320px;
    }

    .hero-buttons {
        flex-direction: column;
    }

    .btn {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: calc(2rem + 5px);
    }

    .container {
        padding: 0 15px;
    }

    .services,
    .about,
    .team,
    .contact {
        padding: 60px 0;
    }
}

