:root {
    --primary-color: #050816;
    --secondary-color: #8B5CF6;
    --text-color: #FFFFFF;
    --card-bg: #151030;
    --section-padding: 80px 0;
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--primary-color);
    background-image: url('data:image/svg+xml,...'); /* 添加波浪线背景 */
}

.navbar {
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    background: linear-gradient(90deg, 
        rgba(5, 8, 22, 0.95) 0%,
        rgba(21, 16, 48, 0.95) 51%, 
        rgba(13, 13, 37, 0.95) 100%
    );
    backdrop-filter: blur(8px);
    padding: 1rem 0;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.3);
}

.nav-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 1rem;
}

.logo {
    color: var(--secondary-color);
    font-size: 1.5rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    display: flex;
    align-items: center;
    gap: 0.8rem;
    margin-left: -10rem;  /* 向左偏移，使其比内容区更靠左 */
}

.logo i {
    font-size: 2.5rem;
    color: var(--secondary-color);
}

.nav-links {
    display: flex;
    gap: 4rem;
    margin: 0;
    padding: 0;
    list-style: none;
    align-items: center;
}

.nav-links li a {
    color: var(--secondary-color);
    text-decoration: none;
    font-weight: 500;
    font-size: 1.5rem;
    transition: all 0.3s ease;
    position: relative;
    font-family: 'M PLUS Rounded 1c', sans-serif;
}

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

.nav-links li a:hover {
    color: #9F75FF;
}

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

.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 120px 10% 0;
    background: var(--primary-color);
}

.hero-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    gap: 2rem;
}

.hero-text {
    flex: 1;
    max-width: 55%;
    padding-right: 2rem;
    position: relative;
}

.hero-text::before {
    content: '';
    position: absolute;
    left: -2rem;
    top: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(180deg, 
        var(--secondary-color) 0%,
        rgba(139, 92, 246, 0.5) 100%
    );
    border-radius: 4px;
}

.hero-text .title {
    font-size: 3.5rem;
    font-weight: 400;
    margin-bottom: 3rem;
    line-height: 1.4;
    font-family: 'Italianno', cursive;
    background: linear-gradient(45deg, #8B5CF6, #EC4899);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-text .subtitle {
    font-size: 4.9rem;
    margin-bottom: 1.5rem;
    font-family: 'M PLUS Rounded 1c', sans-serif;
    font-weight: 800;
    white-space: nowrap;
    line-height: 1.1;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.hero-text .subtitle .intro {
    color: var(--text-color);
    font-size: 4.2rem;
    font-weight: 500;
    font-family: 'M PLUS Rounded 1c', sans-serif;
    text-transform: none;
}

.hero-text .subtitle .name {
    color: var(--secondary-color);
    font-size: 4.9rem;
    font-weight: 800;
}

.hero-text .description {
    font-size: 2.2rem;
    line-height: 1.5;
    color: var(--text-color);
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    margin-bottom: 2rem;
}

.hero-image {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    max-width: 45%;
}

.hero-image img {
    max-width: 100%;
    height: auto;
    border-radius: 20px;
}

.section {
    padding: var(--section-padding);
    position: relative;
    overflow: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.section-subtitle {
    color: var(--secondary-color);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: 1rem;
    font-family: 'Space Mono', monospace;
}

.section-title {
    font-size: 5rem;
    font-weight: 800;
    color: var(--text-color);
    margin-bottom: 2rem;
    position: relative;
}

.overview-text {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.3rem;
    line-height: 2;
    max-width: 800px;
    margin-bottom: 3rem;
    font-family: 'Space Mono', monospace;
    letter-spacing: 0.5px;
}

.highlight-text {
    background: linear-gradient(120deg, 
        #FF6B6B 1%,
        #3d4040 25%,
        #45B7D1 50%,
        #96E6 75%
    );
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 700;
    animation: gradient 8s ease infinite;
    background-size: 300% 300%;
}

@keyframes gradient {
    0% { background-position: 0% 50% }
    50% { background-position: 100% 50% }
    100% { background-position: 0% 50% }
}

.tech-stack {
    display: flex;
    gap: 3rem;
    justify-content: flex-start;
    margin: 2rem 0 4rem;
    flex-wrap: wrap;
    padding: 1.8rem 3rem;
    background: rgba(21, 16, 48, 0.15);
    border-radius: 16px;
    backdrop-filter: blur(8px);
    border: 1px solid rgba(139, 92, 246, 0.1);
}

.tech-icon {
    font-size: 2.8rem;
    transition: all 0.3s ease;
    cursor: pointer;
    opacity: 0.85;
}

.tech-icon:hover {
    opacity: 1;
    transform: translateY(-6px);
    filter: drop-shadow(0 0 12px currentColor);
}


/* 为每个图标设置特定颜色和微光效果 */
.fa-database { 
    color: #336791; 
    filter: drop-shadow(0 0 8px rgba(51, 103, 145, 0.3));
}

.fa-database.mysql { 
    color: #00758F;
    filter: drop-shadow(0 0 8px rgba(0, 117, 143, 0.3));
}

.fa-chart-bar { 
    color: #F2C811;
    filter: drop-shadow(0 0 8px rgba(242, 200, 17, 0.3));
}

.fa-html5 { 
    color: #E44D26;
    filter: drop-shadow(0 0 8px rgba(228, 77, 38, 0.3));
}

.fa-css3-alt { 
    color: #264DE4;
    filter: drop-shadow(0 0 8px rgba(38, 77, 228, 0.3));
}

.fa-js { 
    color: #F7DF1E;
    filter: drop-shadow(0 0 8px rgba(247, 223, 30, 0.3));
}

.fa-python { 
    color: #3776AB;
    filter: drop-shadow(0 0 8px rgba(55, 118, 171, 0.3));
}

.fa-linux { 
    color: #FCC624;
    filter: drop-shadow(0 0 8px rgba(252, 198, 36, 0.3));
}

.fa-git-alt { 
    color: #F05032;
    filter: drop-shadow(0 0 8px rgba(240, 80, 50, 0.3));
}


.skills-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    padding: 1rem 0;
}

.skill-card {
    background: rgba(21, 16, 48, 0.2);
    border-radius: 16px;
    padding: 2rem 1.5rem;
    text-align: center;
    border: 1px solid rgba(139, 92, 246, 0.1);
    transition: all 0.3s ease;
    backdrop-filter: blur(6px);
    min-height: 200px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.skill-card:hover {
    transform: translateY(-8px);
    border-color: rgba(139, 92, 246, 0.3);
    box-shadow: 0 0 25px rgba(139, 92, 246, 0.15);
}

.skill-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    transition: all 0.3s ease;
}

.skill-card h3 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-top: 1rem;
    opacity: 0.9;
}

.skill-card:hover h3 {
    opacity: 1;
}

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

/* 移动端适配 */
@media (max-width: 768px) {
  /* 导航栏适配 */
  .nav-content {
    padding: 0 1rem;
  }
  
  .logo {
    margin-left: 0;
    font-size: 1.2rem;
  }
  
  .logo i {
    font-size: 1.8rem;
  }
  
  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 70%;
    height: 100vh;
    background: rgba(5, 8, 22, 0.95);
    flex-direction: column;
    justify-content: center;
    gap: 2rem;
    transition: 0.5s;
    z-index: 1001;
    padding: 2rem;
  }
  
  .nav-links.active {
    right: 0;
  }
  
  .menu-toggle {
    display: block;
    z-index: 1002;
    cursor: pointer;
  }
  
  .menu-toggle span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--secondary-color);
    margin: 5px 0;
    transition: 0.3s;
  }
  
  /* Hero区域适配 */
  .hero-content {
    flex-direction: column-reverse;
    text-align: center;
    padding-top: 2rem;
  }
  
  .hero-text {
    max-width: 100%;
    padding-right: 0;
  }
  
  .hero-text::before {
    display: none;
  }
  
  .hero-text .subtitle {
    font-size: 2.8rem;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
  }
  
  .hero-text .subtitle .intro {
    font-size: 2.2rem;
  }
  
  .hero-text .subtitle .name {
    font-size: 2.8rem;
  }
  
  .hero-text .description {
    font-size: 1.4rem;
  }
  
  .hero-text .title {
    font-size: 2rem;
  }
  
  .hero-image {
    max-width: 80%;
    margin-bottom: 2rem;
  }
  
  /* 技能区域适配 */
  .section-title {
    font-size: 2.5rem;
  }
  
  .overview-text {
    font-size: 1rem;
  }
  
  .tech-stack {
    gap: 1.5rem;
    padding: 1rem;
    justify-content: center;
  }
  
  .tech-icon {
    font-size: 2rem;
  }
  
  /* 时间线适配 - 修复版 */
  .timeline::before {
    left: 30px;
  }
  
  .timeline-item {
    width: 100%;
    padding-left: 80px !important; /* 强制所有项目使用相同的左内边距 */
    padding-right: 0 !important; /* 移除右内边距 */
    left: 0 !important; /* 确保所有项目都从左侧开始 */
    margin-bottom: 3rem; /* 增加项目间距 */
  }
  
  .timeline-dot {
    left: 30px !important; /* 强制所有点位于左侧 */
    transform: translateX(-50%);
  }
  
  .timeline-content {
    max-width: 100%;
    margin: 0;
  }
  
  .timeline-header h3 {
    font-size: 1.2rem;
  }
  
  .timeline-details li {
    font-size: 0.9rem;
  }
  
  /* 项目区域适配 */
  .projects-grid {
    grid-template-columns: 1fr;
  }
  
  .project-content h3 {
    font-size: 1.5rem;
  }
  
  /* 联系表单适配 */
  .contact-form {
    padding: 1.5rem;
  }
  
  .submit-btn {
    width: 100%;
  }
  
  /* 页脚适配 */
  .footer-content {
    flex-direction: column;
    text-align: center;
    gap: 1.5rem;
  }
  
  .social-icons {
    justify-content: center;
  }
  
  .contact-info {
    margin: 1.5rem 0;
  }
  
  .qr-code {
    justify-content: center;
  }
  
  .qr-code img {
    width: 100px;
    height: 100px;
  }
}

/* iPhone特定适配 */
@media (max-width: 480px) {
  .hero-text .subtitle {
    font-size: 2.4rem;
  }
  
  .hero-text .subtitle .intro {
    font-size: 1.8rem;
  }
  
  .hero-text .subtitle .name {
    font-size: 2.4rem;
  }
  
  .hero-text .description {
    font-size: 1.2rem;
  }
  
  .section {
    padding: 40px 0;
  }
  
  .container {
    padding: 0 1rem;
  }
  
  .skills-grid {
    gap: 1rem;
  }
  
  .skill-card {
    min-height: 160px;
    padding: 1.5rem 1rem;
  }
  
  .skill-icon {
    width: 60px;
    height: 60px;
    margin-bottom: 1rem;
  }
  
  .skill-card h3 {
    font-size: 1rem;
  }
}
.projects-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-top: 3rem;
}

.project-card {
    background: rgba(21, 16, 48, 0.3);
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid rgba(139, 92, 246, 0.1);
    backdrop-filter: blur(6px);
    transition: transform 0.3s ease;
}

.project-card:hover {
    transform: translateY(-8px);
}

.project-image {
    width: 100%;
    height: 250px;
    overflow: hidden;
    position: relative;
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.project-content {
    padding: 2rem;
}

.project-content h3 {
    font-size: 2rem;
    color: var(--text-color);
    margin-bottom: 1rem;
    font-weight: 700;
}

.project-content p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.project-tags {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 1.5rem;
}

.project-tags span {
    color: var(--secondary-color);
    font-size: 0.9rem;
    font-family: 'Space Mono', monospace;
}

.project-tags span::before {
    content: '#';
    opacity: 0.7;
}

.github-icon {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: rgba(21, 16, 48, 0.8);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-color);
    text-decoration: none;
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.github-icon:hover {
    transform: translateY(-3px);
    border-color: var(--secondary-color);
}

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

@media (max-width: 768px) {
    .projects-grid {
        grid-template-columns: 1fr;
    }
}

.footer {
    background: rgba(21, 16, 48, 0.3);
    backdrop-filter: blur(10px);
    padding: 2rem 0;
    border-top: 1px solid rgba(139, 92, 246, 0.1);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
}

.footer-left, .footer-center, .footer-right {
    flex: 1;
}

.social-icons {
    display: flex;
    gap: 1.5rem;
}

.social-icon {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(21, 16, 48, 0.5);
    border-radius: 8px;
    border: 1px solid rgba(139, 92, 246, 0.2);
    transition: all 0.3s ease;
}

.social-icon:hover {
    transform: translateY(-3px);
    border-color: var(--secondary-color);
    background: rgba(21, 16, 48, 0.8);
}

.social-icon i {
    font-size: 1.5rem;
    color: var(--text-color);
}

.social-icon .fa-github {
    color: #f0f6fc;
}

.social-icon .fa-q {
    color: #55C500;
    font-weight: bold;
}

.social-icon .fa-n {
    color: #ffffff;
}

.social-icon img {
    width: 24px;
    height: 24px;
    filter: brightness(0.8);
    transition: filter 0.3s ease;
}

.social-icon:hover img {
    filter: brightness(1);
}

/* 为 Qiita 图标添加特定样式 */
.social-icon img[alt="Qiita"] {
    fill: #55C500;  /* Qiita 的品牌绿色 */
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.contact-item {
    display: flex;
    align-items: center;
}

.contact-item .label {
    width: 100px;  /* 固定宽度确保对齐 */
    text-align: left;
    color: #9F75FF;  /* 紫色标签 */
}

.contact-item .value {
    color: var(--text-color);
    margin-bottom: 0.8rem;
    font-size: 0.9rem;
}

.qr-code {
    display: flex;
    justify-content: flex-end;
}

.qr-code img {
    width: 120px;
    height: 120px;
    border-radius: 8px;
    border: 1px solid rgba(139, 92, 246, 0.2);
}

@media (max-width: 768px) {
    .footer-content {
        flex-direction: column;
        text-align: center;
    }

    .social-icons {
        justify-content: center;
        margin-bottom: 1.5rem;
    }

    .contact-info {
        margin-bottom: 1.5rem;
    }

    .qr-code {
        justify-content: center;
    }
}

.contact-form {
    max-width: 800px;
    margin: 3rem auto;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 16px;
    backdrop-filter: blur(10px);
}

.form-group {
    margin-bottom: 2rem;
}

.form-group h3 {
    font-size: 1.2rem;
    color: var(--text-color);
    margin-bottom: 1rem;
    font-weight: 500;
}

.form-input {
    width: 100%;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: var(--text-color);
    font-size: 1rem;
    transition: all 0.3s ease;
}

textarea.form-input {
    min-height: 150px;
    resize: vertical;
}

.form-input:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 2px rgba(139, 92, 246, 0.2);
}

.form-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.submit-btn {
    display: block;
    margin-left: auto;
    padding: 0.8rem 2rem;
    background: rgba(139, 92, 246, 0.1);
    color: var(--text-color);
    border: 1px solid var(--secondary-color);
    border-radius: 8px;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.submit-btn:hover {
    background: var(--secondary-color);
    transform: translateY(-2px);
}

@media (max-width: 768px) {
    .contact-form {
        padding: 1.5rem;
    }
    
    .submit-btn {
        width: 100%;
    }
}

.shooting-stars {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
    overflow: hidden;
}

.shooting-star {
    position: absolute;
    width: 200px;
    height: 2px;
    background: linear-gradient(90deg, #fff, #fff);
    animation: shooting 6s linear infinite;
    opacity: 0;
}

.shooting-star:nth-child(1) {
    top: 10%;
    left: 100%;
    animation-delay: 0s;
}

.shooting-star:nth-child(2) {
    top: 25%;
    left: 100%;
    animation-delay: 2.4s;
}

.shooting-star:nth-child(3) {
    top: 40%;
    left: 100%;
    animation-delay: 4.8s;
}

.shooting-star:nth-child(4) {
    top: 55%;
    left: 100%;
    animation-delay: 7.2s;
}

.shooting-star:nth-child(5) {
    top: 70%;
    left: 100%;
    animation-delay: 9.6s;
}

@keyframes shooting {
    0% {
        transform: translateX(0) translateY(0) rotate(-45deg);
        opacity: 1;
    }
    
    100% {
        transform: translateX(-3000px) translateY(3000px) rotate(-45deg);
        opacity: 1;
    }
}

.timeline {
    position: relative;
    max-width: 1000px;
    margin: 4rem auto;
    padding: 2rem 0;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    width: 2px;
    height: 100%;
    background: linear-gradient(180deg, 
        var(--secondary-color) 0%,
        rgba(139, 92, 246, 0.3) 100%
    );
}

.timeline-item {
    position: relative;
    margin-bottom: 4rem;
    width: 50%;
}

.timeline-item:nth-child(1),
.timeline-item:nth-child(2),
.timeline-item:nth-child(4) {
    left: 0;
    padding-right: 6rem;
}

.timeline-item:nth-child(3),
.timeline-item:nth-child(5) {
    left: 50%;
    padding-left: 6rem;
}

.timeline-content {
    background: rgba(21, 16, 48, 0.3);
    padding: 2rem;
    border-radius: 16px;
    border: 1px solid rgba(139, 92, 246, 0.3);
    backdrop-filter: blur(6px);
    max-width: 450px;
    position: relative;
    box-shadow: 
        0 0 0 1px rgba(139, 92, 246, 0.2),
        0 4px 20px rgba(139, 92, 246, 0.1);
    transition: all 0.3s ease;
}

.timeline-content:hover {
    border-color: rgba(139, 92, 246, 0.5);
    box-shadow: 
        0 0 0 1px rgba(139, 92, 246, 0.3),
        0 8px 25px rgba(139, 92, 246, 0.15);
}

.timeline-dot {
    position: absolute;
    width: 48px;
    height: 48px;
    background: rgba(21, 16, 48, 0.8);
    border-radius: 50%;
    top: 0;
    border: 2px solid var(--secondary-color);
    box-shadow: 0 0 15px rgba(139, 92, 246, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(4px);
    transform: translateX(-50%);
}

.timeline-item:nth-child(1) .timeline-dot,
.timeline-item:nth-child(2) .timeline-dot,
.timeline-item:nth-child(4) .timeline-dot {
    left: 100%;
}

.timeline-item:nth-child(3) .timeline-dot,
.timeline-item:nth-child(5) .timeline-dot {
    left: 0;
}

@media (max-width: 768px) {
    .timeline::before {
        left: 30px;
    }
    
    .timeline-item {
        width: 100%;
        padding-left: 80px;
        padding-right: 0;
    }
    
    .timeline-item:nth-child(odd),
    .timeline-item:nth-child(even) {
        left: 0;
    }
    
    .timeline-content {
        max-width: 100%;
        margin: 0;
    }
}

/* ==================== MY STORY SECTION ==================== */

/* Interests Section */
.interests-section {
    margin-bottom: 4rem;
}

.interests-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    margin-top: 2rem;
}

.interest-card {
    background: linear-gradient(135deg, rgba(21, 16, 48, 0.4) 0%, rgba(139, 92, 246, 0.08) 100%);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(139, 92, 246, 0.25);
    border-radius: 16px;
    padding: 1.5rem 1.2rem;
    min-height: 180px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    animation: float 5s ease-in-out infinite;
    position: relative;
    overflow: hidden;
}

/* Gradient border effect */
.interest-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 16px;
    padding: 1px;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.5), rgba(236, 72, 153, 0.3), rgba(139, 92, 246, 0.2));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.4s ease;
}

/* Shimmer effect */
.interest-card::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        45deg,
        transparent 40%,
        rgba(139, 92, 246, 0.1) 50%,
        transparent 60%
    );
    transform: rotate(45deg) translateX(-100%);
    transition: transform 0.6s ease;
}

.interest-card:hover {
    transform: translateY(-10px) scale(1.03);
    border-color: transparent;
    box-shadow: 
        0 0 25px rgba(139, 92, 246, 0.4),
        0 15px 35px rgba(0, 0, 0, 0.3),
        inset 0 0 20px rgba(139, 92, 246, 0.05);
}

.interest-card:hover::before {
    opacity: 1;
}

.interest-card:hover::after {
    transform: rotate(45deg) translateX(100%);
}

.interest-icon {
    width: 55px;
    height: 55px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
    position: relative;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.2) 0%, rgba(236, 72, 153, 0.1) 100%);
    border-radius: 12px;
    transition: all 0.4s ease;
}

.interest-icon i {
    font-size: 1.8rem;
    background: linear-gradient(135deg, #8B5CF6 0%, #EC4899 50%, #8B5CF6 100%);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 8px rgba(139, 92, 246, 0.4));
    animation: iconPulse 3s ease-in-out infinite, iconGradient 4s ease infinite;
}

@keyframes iconGradient {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.interest-card:hover .interest-icon {
    transform: scale(1.1) rotate(5deg);
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.3) 0%, rgba(236, 72, 153, 0.2) 100%);
}

.interest-card:hover .interest-icon i {
    filter: drop-shadow(0 0 15px rgba(139, 92, 246, 0.7));
}

.interest-title {
    font-size: 1.1rem;
    font-weight: 700;
    background: linear-gradient(135deg, #FFFFFF 0%, #E0D4FF 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 0.6rem;
    font-family: 'M PLUS Rounded 1c', sans-serif;
    letter-spacing: 0.5px;
}

.interest-description {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.65);
    line-height: 1.5;
    font-family: 'Inter', sans-serif;
    transition: color 0.3s ease;
}

.interest-card:hover .interest-description {
    color: rgba(255, 255, 255, 0.85);
}


/* Travel Journey Section */
.travel-journey {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    margin-top: 3rem;
}

.country-card {
    background: linear-gradient(145deg, rgba(21, 16, 48, 0.35) 0%, rgba(139, 92, 246, 0.05) 100%);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(139, 92, 246, 0.2);
    border-radius: 20px;
    padding: 2rem;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
}

/* Animated gradient border */
.country-card::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, #8B5CF6, #EC4899, #06B6D4, #8B5CF6);
    background-size: 400% 400%;
    border-radius: 22px;
    z-index: -1;
    opacity: 0;
    animation: gradientBorder 3s ease infinite;
    transition: opacity 0.4s ease;
}

@keyframes gradientBorder {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

/* Inner glow effect */
.country-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(ellipse at 50% 0%, rgba(139, 92, 246, 0.15) 0%, transparent 60%);
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.country-card:hover {
    border-color: transparent;
    box-shadow: 
        0 0 35px rgba(139, 92, 246, 0.35),
        0 20px 40px rgba(0, 0, 0, 0.25),
        inset 0 0 30px rgba(139, 92, 246, 0.05);
    transform: translateY(-8px) scale(1.02);
}

.country-card:hover::before {
    opacity: 0.6;
}

.country-card:hover::after {
    opacity: 1;
}

.country-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
    margin-bottom: 1.5rem;
}

.country-flag {
    font-size: 2.2rem;
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.3));
    animation: flagWave 2s ease-in-out infinite;
}

@keyframes flagWave {
    0%, 100% { transform: rotate(-3deg); }
    50% { transform: rotate(3deg); }
}

.country-name {
    font-size: 1.4rem;
    font-weight: 700;
    background: linear-gradient(135deg, #FFFFFF 0%, #C4B5FD 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: 3px;
    font-family: 'M PLUS Rounded 1c', sans-serif;
}

.city-counter-wrapper {
    margin: 1.5rem 0;
    position: relative;
}

.city-counter {
    font-size: 3.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, #8B5CF6 0%, #EC4899 50%, #06B6D4 100%);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    display: block;
    line-height: 1;
    filter: drop-shadow(0 0 20px rgba(139, 92, 246, 0.4));
    font-family: 'M PLUS Rounded 1c', sans-serif;
    animation: counterGradient 3s ease infinite;
}

@keyframes counterGradient {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.city-label {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-top: 0.4rem;
    display: block;
    font-family: 'Space Mono', monospace;
}

.city-highlights {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.8rem;
    margin-top: 1.5rem;
}

.city-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.15) 0%, rgba(236, 72, 153, 0.08) 100%);
    border: 1px solid rgba(139, 92, 246, 0.3);
    border-radius: 16px;
    padding: 0.5rem 1rem;
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.85rem;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: default;
    font-family: 'Inter', sans-serif;
    position: relative;
    overflow: hidden;
}

.city-tag::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s ease;
}

.city-tag i {
    background: linear-gradient(135deg, #8B5CF6 0%, #EC4899 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    font-size: 0.75rem;
}

.city-tag:hover {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.25) 0%, rgba(236, 72, 153, 0.15) 100%);
    border-color: rgba(139, 92, 246, 0.6);
    box-shadow: 
        0 0 20px rgba(139, 92, 246, 0.35),
        0 5px 15px rgba(0, 0, 0, 0.2);
    transform: translateY(-4px) scale(1.05);
}

.city-tag:hover::before {
    left: 100%;
}


/* ==================== STORY SECTION ANIMATIONS ==================== */

/* Floating Animation for Interest Cards */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-10px);
    }
}

/* Icon Glow Pulse */
@keyframes iconPulse {
    0%, 100% {
        filter: drop-shadow(0 0 8px rgba(139, 92, 246, 0.5));
    }
    50% {
        filter: drop-shadow(0 0 20px rgba(139, 92, 246, 0.8));
    }
}

/* Fade In Up Animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Counter Glow Animation */
@keyframes counterGlow {
    0%, 100% {
        text-shadow: 0 0 30px rgba(139, 92, 246, 0.5);
    }
    50% {
        text-shadow: 0 0 50px rgba(139, 92, 246, 0.8), 0 0 80px rgba(139, 92, 246, 0.4);
    }
}

/* Apply animations */
.interest-card {
    opacity: 0;
    animation: fadeInUp 0.8s ease forwards, float 4s ease-in-out infinite;
    animation-delay: var(--delay, 0s), calc(var(--delay, 0s) + 0.8s);
}

.interest-card:nth-child(1) { --delay: 0.1s; }
.interest-card:nth-child(2) { --delay: 0.2s; }
.interest-card:nth-child(3) { --delay: 0.3s; }
.interest-card:nth-child(4) { --delay: 0.4s; }

.country-card {
    opacity: 0;
    animation: fadeInUp 0.8s ease forwards;
}

.country-card:nth-child(1) { animation-delay: 0.5s; }
.country-card:nth-child(2) { animation-delay: 0.7s; }

.city-counter.animated {
    animation: counterGlow 2s ease-in-out infinite;
}

/* Sparkle effect for story section */
.story-sparkle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--secondary-color);
    border-radius: 50%;
    pointer-events: none;
    animation: sparkle 2s ease-in-out infinite;
}

@keyframes sparkle {
    0%, 100% {
        opacity: 0;
        transform: scale(0);
    }
    50% {
        opacity: 1;
        transform: scale(1);
    }
}

/* Reduced motion for accessibility */
@media (prefers-reduced-motion: reduce) {
    .interest-card,
    .country-card,
    .interest-icon i,
    .city-counter {
        animation: none !important;
        opacity: 1;
        transform: none;
    }
    
    .country-card::before {
        animation: none;
    }
}


/* ==================== STORY SECTION RESPONSIVE STYLES ==================== */

/* Tablet (max-width: 1024px) */
@media (max-width: 1024px) {
    .interests-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.2rem;
    }
    
    .interest-card {
        min-height: 160px;
        padding: 1.3rem 1rem;
    }
    
    .interest-icon {
        width: 45px;
        height: 45px;
    }
    
    .interest-icon i {
        font-size: 1.5rem;
    }
    
    .interest-title {
        font-size: 1rem;
    }
    
    .interest-description {
        font-size: 0.8rem;
    }
    
    .travel-journey {
        gap: 1.5rem;
    }
    
    .country-card {
        padding: 1.8rem;
    }
    
    .city-counter {
        font-size: 3rem;
    }
    
    .city-label {
        font-size: 0.8rem;
    }
}

/* Mobile (max-width: 768px) */
@media (max-width: 768px) {
    .interests-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
    
    .interest-card {
        min-height: 140px;
        padding: 1.2rem 1rem;
        animation: fadeInUp 0.6s ease forwards;
    }
    
    .interest-card:nth-child(1) { animation-delay: 0.1s; }
    .interest-card:nth-child(2) { animation-delay: 0.15s; }
    .interest-card:nth-child(3) { animation-delay: 0.2s; }
    .interest-card:nth-child(4) { animation-delay: 0.25s; }
    
    .interest-icon {
        width: 40px;
        height: 40px;
        margin-bottom: 0.8rem;
    }
    
    .interest-icon i {
        font-size: 1.3rem;
    }
    
    .interest-title {
        font-size: 0.95rem;
        margin-bottom: 0.4rem;
    }
    
    .interest-description {
        font-size: 0.75rem;
        line-height: 1.4;
    }
    
    .travel-journey {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        margin-top: 2.5rem;
    }
    
    .country-card {
        padding: 1.5rem;
    }
    
    .country-header {
        margin-bottom: 1rem;
    }
    
    .country-flag {
        font-size: 1.8rem;
    }
    
    .country-name {
        font-size: 1.2rem;
        letter-spacing: 2px;
    }
    
    .city-counter {
        font-size: 2.8rem;
    }
    
    .city-label {
        font-size: 0.75rem;
        letter-spacing: 1px;
    }
    
    .city-highlights {
        gap: 0.6rem;
        margin-top: 1rem;
    }
    
    .city-tag {
        padding: 0.4rem 0.8rem;
        font-size: 0.75rem;
    }
}

/* Small Mobile (max-width: 480px) */
@media (max-width: 480px) {
    .interests-section {
        margin-bottom: 2rem;
    }
    
    .interests-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.8rem;
    }
    
    .interest-card {
        min-height: 120px;
        padding: 1rem 0.8rem;
    }
    
    .interest-icon {
        width: 35px;
        height: 35px;
        margin-bottom: 0.6rem;
    }
    
    .interest-icon i {
        font-size: 1.1rem;
    }
    
    .interest-title {
        font-size: 0.85rem;
    }
    
    .interest-description {
        font-size: 0.7rem;
        line-height: 1.5;
    }
    
    .travel-journey {
        gap: 1rem;
    }
    
    .country-card {
        padding: 1.2rem;
        border-radius: 14px;
    }
    
    .country-flag {
        font-size: 1.5rem;
    }
    
    .country-name {
        font-size: 1rem;
        letter-spacing: 1px;
    }
    
    .city-counter-wrapper {
        margin: 1rem 0;
    }
    
    .city-counter {
        font-size: 2.5rem;
    }
    
    .city-label {
        font-size: 0.7rem;
    }
    
    .city-highlights {
        gap: 0.5rem;
        margin-top: 0.8rem;
    }
    
    .city-tag {
        padding: 0.35rem 0.7rem;
        font-size: 0.7rem;
        border-radius: 12px;
    }
    
    .city-tag i {
        font-size: 0.6rem;
    }
}

/* Story section sparkle positioning */
#Story {
    position: relative;
}

#Story .story-sparkle {
    z-index: 1;
}
