/* css/style.css */

/* Variables */
:root {
    /* Colors */
    --bg-color: #f8fafc;
    --bg-darker: #f1f5f9;
    --text-color: #334155;
    --heading-color: #0f172a;
    --accent-color: #3b82f6;
    --accent-gradient: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 100%);
    --card-bg: #ffffff;
    --border-color: rgba(0, 0, 0, 0.05);
    
    /* Typography */
    --font-heading: 'Inter', sans-serif;
    --font-body: 'Noto Sans JP', 'Inter', sans-serif;
    --font-cursive: 'Dancing Script', cursive;
    
    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-slow: 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-fast);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

h1, h2, h3, h4, .logo, .nav-link {
    font-family: var(--font-heading);
    color: var(--heading-color);
}

/* Layout Utilities */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 5%;
}

.section {
    padding: 100px 0;
}

.bg-darker {
    background-color: var(--bg-darker);
}

.section-title {
    text-align: center;
    margin-bottom: 60px;
}

.title-main {
    font-size: 3rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
    margin-bottom: 8px;
}

.title-sub {
    font-size: 1rem;
    color: var(--text-color);
    opacity: 0.7;
    letter-spacing: 0.1em;
}

.highlight {
    color: var(--accent-color);
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 14px 32px;
    border-radius: 30px;
    font-weight: 600;
    font-family: var(--font-heading);
    cursor: pointer;
    border: none;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn-primary {
    background: var(--accent-gradient);
    color: #fff;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(135deg, #8b5cf6 0%, #3b82f6 100%);
    z-index: -1;
    transition: opacity var(--transition-normal);
    opacity: 0;
}

.btn-primary:hover::before {
    opacity: 1;
}

.btn-primary:hover {
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.5);
    transform: translateY(-2px);
}

/* Header & Navigation */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 24px 0;
    z-index: 1000;
    transition: background-color var(--transition-fast), padding var(--transition-fast);
}

.header.scrolled {
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 16px 0;
    border-bottom: 1px solid var(--border-color);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.05em;
}

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

.nav-link {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-color);
    position: relative;
}

.nav-link:hover, .nav-link.active {
    color: var(--heading-color);
}

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

.nav-link:hover::after, .nav-link.active::after {
    width: 100%;
}

.hamburger {
    display: none;
    cursor: pointer;
    z-index: 1001;
}

.hamburger .bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    transition: all 0.3s ease-in-out;
    background-color: var(--heading-color);
    border-radius: 3px;
}

/* Hero Section */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.hero-content {
    position: relative;
    z-index: 10;
    max-width: 800px;
    text-align: center;
    width: 100%;
    padding: 0 5%;
}

.greeting {
    font-size: 1.5rem;
    color: var(--accent-color);
    font-weight: 600;
    margin-bottom: 10px;
}

.name {
    font-size: 5rem;
    font-weight: 700;
    font-family: var(--font-cursive);
    line-height: 1.1;
    margin-bottom: 20px;
    letter-spacing: 0.02em;
}

.title {
    font-size: 1.5rem;
    color: var(--text-color);
    margin-bottom: 40px;
    font-weight: 300;
}

.hero-bg {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    z-index: 1;
    overflow: hidden;
}

.circle {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.5;
}

.circle-1 {
    width: 500px; height: 500px;
    background: rgba(59, 130, 246, 0.15);
    top: -100px; right: -100px;
    animation: float1 15s infinite ease-in-out alternate;
}

.circle-2 {
    width: 600px; height: 600px;
    background: rgba(139, 92, 246, 0.2);
    bottom: -200px; left: -200px;
    animation: float2 20s infinite ease-in-out alternate;
}

@keyframes float1 {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(-100px, 100px) scale(1.2); }
}

@keyframes float2 {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(150px, -150px) scale(1.1); }
}

.scroll-down {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    opacity: 0.7;
    animation: bounce 2s infinite;
}

.scroll-down span {
    font-size: 0.8rem;
    font-family: var(--font-heading);
    letter-spacing: 0.1em;
}

.mouse {
    width: 24px;
    height: 36px;
    border: 2px solid var(--heading-color);
    border-radius: 12px;
    position: relative;
}

.wheel {
    width: 4px;
    height: 8px;
    background: var(--heading-color);
    border-radius: 2px;
    position: absolute;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    animation: scroll 1.5s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-10px); }
    60% { transform: translateY(-5px); }
}

@keyframes scroll {
    0% { top: 6px; opacity: 1; }
    100% { top: 18px; opacity: 0; }
}

/* About Section */
.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.about-image {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0,0,0,0.5);
}

/* Removed dark gradient */
.about-image::after {
    display: none;
}

.about-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    aspect-ratio: 4/5;
}

.about-text h3 {
    font-size: 2rem;
    margin-bottom: 24px;
    line-height: 1.4;
}

.about-text p {
    margin-bottom: 16px;
    font-size: 1.05rem;
    opacity: 0.9;
}

/* Skills Section */
.skills-grid {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.skill-card {
    background: var(--card-bg);
    padding: 30px;
    border-radius: 16px;
    border: 1px solid var(--border-color);
}

.skill-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
}

.skill-name {
    font-size: 1.2rem;
    font-weight: 600;
}

.skill-percentage {
    font-family: var(--font-heading);
    font-weight: 700;
    color: var(--accent-color);
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(0,0,0,0.05);
    border-radius: 4px;
    margin-bottom: 15px;
    overflow: hidden;
}

.progress {
    height: 100%;
    background: var(--accent-gradient);
    border-radius: 4px;
    width: 0; /* Animated via JS */
    transition: width 1.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.skill-desc {
    font-size: 0.95rem;
    opacity: 0.8;
}

/* Works Section */
.works-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
}

.works-grid .work-card:nth-child(3),
.works-grid .work-card:nth-child(4),
.works-grid .work-card:nth-child(5) {
    /* If we want uneven layout or span, else keep grid. Currently keeping 2 cols. */
}

.work-card {
    border-radius: 16px;
    overflow: hidden;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

.work-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.5);
    border-color: rgba(59, 130, 246, 0.5);
}

.work-image {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16/10;
}

.work-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

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

.work-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(0deg, rgba(13,17,23,0.9) 0%, rgba(13,17,23,0.3) 100%);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 30px;
    opacity: 0;
    transform: translateY(20px);
    transition: all var(--transition-normal);
}

.work-card:hover .work-overlay {
    opacity: 1;
    transform: translateY(0);
}

.work-category {
    font-size: 0.8rem;
    color: var(--accent-color);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 600;
    margin-bottom: 5px;
}

.work-overlay h3 {
    font-size: 1.5rem;
}

.work-info {
    padding: 24px;
}

.work-info p {
    font-size: 0.95rem;
    opacity: 0.8;
}

/* Appeal Section */
.appeal-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.appeal-card {
    background: var(--card-bg);
    padding: 40px 30px;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    text-align: center;
    transition: var(--transition-fast);
}

.appeal-card:hover {
    background: #ffffff;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    transform: translateY(-5px);
}

.appeal-icon {
    width: 60px; height: 60px;
    margin: 0 auto 24px;
    background: rgba(59, 130, 246, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-color);
    transition: var(--transition-fast);
}

.appeal-card:hover .appeal-icon {
    background: var(--accent-gradient);
    color: #fff;
    transform: scale(1.1);
}

.appeal-icon svg {
    width: 28px; height: 28px;
}

.appeal-title {
    font-size: 1.25rem;
    margin-bottom: 16px;
}

.appeal-desc {
    font-size: 0.95rem;
    opacity: 0.8;
}

/* Contact Section */
.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 60px;
    background: var(--card-bg);
    border-radius: 20px;
    border: 1px solid var(--border-color);
    padding: 50px;
}

.contact-info h3 {
    font-size: 2rem;
    margin-bottom: 16px;
}

.contact-info p {
    margin-bottom: 40px;
    opacity: 0.8;
}

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.contact-details li {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 1.1rem;
}

.contact-details svg {
    width: 24px; height: 24px;
    color: var(--accent-color);
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-size: 0.9rem;
    font-weight: 500;
    opacity: 0.9;
}

.form-group input,
.form-group textarea {
    background: #ffffff;
    border: 1px solid var(--border-color);
    color: var(--heading-color);
    padding: 16px;
    border-radius: 8px;
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition-fast);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

/* Footer */
.footer {
    padding: 40px 0;
    text-align: center;
    border-top: 1px solid var(--border-color);
    background-color: var(--bg-darker);
}

.footer p {
    opacity: 0.6;
    font-size: 0.9rem;
}

/* Animations (Scroll reveal) */
.fade-up {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Form success message */
.form-success-msg {
    margin-top: 20px;
    padding: 15px;
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid #10b981;
    color: #10b981;
    border-radius: 8px;
    text-align: center;
    display: none;
    animation: fadeIn 0.5s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}


/* Media Queries */
@media (max-width: 992px) {
    .name { font-size: 4rem; }
    .about-content { grid-template-columns: 1fr; }
    .about-image { max-width: 500px; margin: 0 auto; }
    .works-grid { grid-template-columns: 1fr; }
    .contact-wrapper { grid-template-columns: 1fr; padding: 40px 30px; }
}

@media (max-width: 768px) {
    .hamburger { display: block; }
    
    .navbar {
        position: fixed;
        top: 0; left: -100%;
        width: 100%; height: 100vh;
        background-color: rgba(255, 255, 255, 0.98);
        display: flex;
        align-items: center;
        justify-content: center;
        transition: left 0.4s ease-in-out;
    }
    
    .navbar.active { left: 0; }
    
    .nav-list {
        flex-direction: column;
        align-items: center;
        gap: 40px;
    }
    
    .nav-link { font-size: 1.5rem; }
    
    .hamburger.active .bar:nth-child(2) { opacity: 0; }
    .hamburger.active .bar:nth-child(1) { transform: translateY(8px) rotate(45deg); }
    .hamburger.active .bar:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
    
    .name { font-size: 3rem; }
    .appeal-grid { grid-template-columns: 1fr; }
    .section { padding: 80px 0; }
}

@media (max-width: 480px) {
    .name { font-size: 2.5rem; }
    .title-main { font-size: 2.2rem; }
    .contact-wrapper { padding: 30px 20px; }
}

/* Shooting Stars Effect */
.shooting-star {
    position: absolute;
    width: 150px;
    height: 2px;
    background: linear-gradient(90deg, rgba(59,130,246,0) 0%, rgba(59,130,246,0.8) 100%);
    border-radius: 50%;
    filter: drop-shadow(0 0 6px rgba(59,130,246,0.5));
    animation: shooting linear infinite;
    opacity: 0;
}

.shooting-star::after {
    content: '';
    position: absolute;
    top: 50%;
    right: 0;
    transform: translateY(-50%);
    width: 4px; 
    height: 4px;
    background: #fff;
    border-radius: 50%;
    box-shadow: 0 0 8px #3b82f6, 0 0 15px #3b82f6;
}

@keyframes shooting {
    0% {
        transform: translateX(0);
        opacity: 1;
    }
    70% {
        opacity: 1;
    }
    100% {
        transform: translateX(1200px);
        opacity: 0;
    }
}
