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

body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    background-color: #f8f6ff;
    color: #333;
}

header {
    background-color: #dcd3ff;
    padding: 20px 40px;
}

header h1 {
    margin-bottom: 10px;
    color: #4b3f72;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 20px;
}

nav a {
    text-decoration: none;
    color: #4b3f72;
    font-weight: bold;
}

nav a:hover {
    color: #7a68b3;
}

main {
    max-width: 1000px;
    margin: 40px auto;
    padding: 0 20px;
}

section {
    background-color: #ffffff;
    margin-bottom: 30px;
    padding: 30px;
    border-radius: 16px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
}

section h2 {
    margin-bottom: 15px;
    color: #4b3f72;
}

section p,
section li {
    font-size: 16px;
}

section ul {
    padding-left: 20px;
}

footer {
    text-align: center;
    padding: 20px;
    background-color: #dcd3ff;
    color: #4b3f72;
    margin-top: 40px;
}

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

.work-card {
    background-color: #fdfcff;
    border: 1px solid #e3dcf5;
    border-radius: 14px;
    padding: 20px;
    box-shadow: 0 4px 10px rgba(75, 63, 114, 0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.work-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 18px rgba(75, 63, 114, 0.12);
}

.work-card h3 {
    font-size: 20px;
    color: #4b3f72;
    margin-bottom: 10px;
}

.work-card p {
    margin-bottom: 10px;
    font-size: 15px;
    line-height: 1.7;
}

.work-card .tech {
    color: #7a68b3;
    font-weight: bold;
    font-size: 14px;
}

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

.detail-button {
    display: inline-block;
    margin-top: 10px;
    padding: 10px 18px;
    background-color: #7a68b3;
    color: #fff;
    text-decoration: none;
    border-radius: 10px;
    font-weight: bold;
    transition: background-color 0.2s ease;
}

.detail-button:hover {
    background-color: #5f4f96;
}

.detail-card {
    background-color: #ffffff;
    margin-bottom: 30px;
    padding: 30px;
    border-radius: 16px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
}

.detail-card h2 {
    margin-bottom: 15px;
    color: #4b3f72;
}

.detail-card p {
    margin-bottom: 12px;
    line-height: 1.8;
}
.detail-buttons {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 24px;
}

.detail-button {
    display: inline-block;
    padding: 12px 20px;
    background-color: #7a68b3;
    color: #ffffff;
    text-decoration: none;
    border-radius: 10px;
    font-weight: bold;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.detail-button:hover {
    background-color: #5f4f96;
    transform: translateY(-2px);
}

.sub-button {
    background-color: #9b8bcf;
}

.sub-button:hover {
    background-color: #7f6db7;
}

.back-button {
    background-color: #d9d1f0;
    color: #4b3f72;
}

.back-button:hover {
    background-color: #c8bee8;
}

.work-images {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin: 20px 0 24px;
}

.work-images img {
    width: 100%;
    max-width: 700px;
    border-radius: 12px;
    border: 1px solid #ddd;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
}

.site-links {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 20px;
}

.site-header {
    background: linear-gradient(135deg, #d8cef7 0%, #cfc3f2 100%);
    padding: 28px 0 48px;
}

.header-inner {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
}

.header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    margin-bottom: 48px;
}

.site-title {
    font-size: 44px;
    color: #4b3f72;
    margin: 0;
}

.site-nav ul {
    list-style: none;
    display: flex;
    gap: 24px;
    margin: 0;
    padding: 0;
}

.site-nav a {
    text-decoration: none;
    color: #4b3f72;
    font-weight: bold;
    font-size: 16px;
}

.site-nav a:hover {
    color: #7a68b3;
}

.hero {
    background-color: rgba(255, 255, 255, 0.45);
    border-radius: 24px;
    padding: 36px;
    box-shadow: 0 8px 20px rgba(75, 63, 114, 0.08);
}

.hero-subtitle {
    font-size: 14px;
    color: #7a68b3;
    font-weight: bold;
    margin-bottom: 14px;
    letter-spacing: 0.05em;
}

.hero h2 {
    font-size: 38px;
    line-height: 1.4;
    color: #4b3f72;
    margin-bottom: 18px;
}

.hero-description {
    font-size: 17px;
    line-height: 1.9;
    color: #555;
    /* max-width: 700px; */
    margin-bottom: 24px;
}

.hero-buttons {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
}

.hero-button {
    display: inline-block;
    padding: 12px 22px;
    border-radius: 12px;
    text-decoration: none;
    font-weight: bold;
    transition: 0.2s ease;
}

.hero-button.primary {
    background-color: #7a68b3;
    color: #fff;
}

.hero-button.primary:hover {
    background-color: #5f4f96;
}

.hero-button.secondary {
    background-color: #ece5ff;
    color: #4b3f72;
}

.hero-button.secondary:hover {
    background-color: #ddd2fb;
}

.detail-header-text {
    margin-top: 8px;
    color: #6d5aa8;
    font-weight: bold;
    font-size: 14px;
}

#page-top {
    position: fixed;
    right: 20px;
    bottom: 20px;
    width: 50px;
    height: 50px;
    border: none;
    border-radius: 50%;
    background-color: #7a68b3;
    color: #fff;
    font-size: 20px;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    display: none;
    z-index: 999;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

#page-top:hover {
    background-color: #5f4f96;
    transform: translateY(-2px);
}

.site-title a {
    color: inherit;
    text-decoration: none;
}

.site-title a:hover {
    opacity: 0.85;
}

@media (max-width: 768px) {
    header {
        padding: 24px 20px;
    }

    header h1 {
        font-size: 24px;
        line-height: 1.4;
    }

    nav ul {
        /* flex-direction: column; */
        gap: 10px;
        margin-top: 12px;
    }

    main {
        margin: 24px auto;
        padding: 0 16px;
    }

    section {
        padding: 20px;
        border-radius: 14px;
    }

    section h2 {
        font-size: 28px;
    }

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

    .work-card {
        padding: 18px;
    }

    .work-card h3 {
        font-size: 22px;
        line-height: 1.5;
    }

    .work-card p {
        font-size: 14px;
    }

    .detail-card {
        padding: 20px;
    }

    .detail-card h2 {
        font-size: 28px;
        line-height: 1.5;
    }

    .detail-card p {
        font-size: 15px;
        line-height: 1.9;
    }

    .work-images {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .work-images img {
        width: 100%;
        height: auto;
    }

    .detail-buttons {
        flex-direction: column;
        align-items: stretch;
    }

    .detail-button {
        width: 100%;
        text-align: center;
    }

    footer {
        padding: 16px;
        font-size: 14px;
    }

    .site-links {
        flex-direction: column;
        align-items: stretch;
    }
    
    .site-links .detail-button {
        width: 100%;
        text-align: center;
    }

    .site-header {
        padding: 20px 0 32px;
    }

    .header-top {
        flex-direction: column;
        align-items: flex-start;
        margin-bottom: 28px;
    }

    .site-title {
        font-size: 32px;
    }

    .site-nav ul {
        flex-wrap: wrap;
        gap: 14px;
    }

    .hero {
        padding: 24px 20px;
        border-radius: 18px;
    }

    .hero h2 {
        font-size: 28px;
    }

    .hero-description {
        font-size: 15px;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: stretch;
    }

    .hero-button {
        text-align: center;
    }
}