:root {
    --md-sys-color-background: #101014;
    --md-sys-color-surface: #1C1B1F;
    --md-sys-color-surface-container: #25232a;
    --md-sys-color-surface-container-high: #2b2930;

    --md-sys-color-primary: #D0BCFF;
    --md-sys-color-on-primary: #381E72;
    --md-sys-color-primary-container: #4F378B;
    --md-sys-color-on-primary-container: #EADDFF;

    --md-sys-color-secondary: #CCC2DC;
    --md-sys-color-secondary-container: #4A4458;

    --md-sys-color-tertiary: #EFB8C8;
    --md-sys-color-tertiary-container: #492532;

    --md-sys-color-on-surface: #E6E1E5;
    --md-sys-color-on-surface-variant: #CAC4D0;
    --md-sys-color-outline: #938F99;

    --md-sys-shape-corner-large: 28px;
    --md-sys-shape-corner-medium: 16px;
    --md-sys-shape-corner-full: 100px;
}

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

@font-face {
    font-family: nunito;
    src: url(./Nunito-SemiBold.woff2);
    font-display: swap;
}

body {
    font-family: 'nunito', sans-serif;
    background-color: var(--md-sys-color-background);
    background-image: linear-gradient(135deg, rgba(139, 79, 95, 0.15) 0%, rgba(74, 107, 138, 0.15) 100%);
    background-attachment: fixed;
    color: var(--md-sys-color-on-surface);
    padding-bottom: 100px;
    overflow-x: hidden;
}

header {
    padding: 60px 20px 30px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

.header-img {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--md-sys-color-surface-container-high);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    transition: transform 0.3s cubic-bezier(0.2, 0.0, 0, 1.0);
}

.header-img:hover {
    transform: scale(1.05);
}

h1 {
    font-size: 3.7rem;
    font-weight: 500;
    letter-spacing: -0.02em;
    color: var(--md-sys-color-primary);
    margin: 0;
}

.subtitle {
    font-size: 1.8rem;
    color: var(--md-sys-color-on-surface-variant);
    opacity: 0.8;
}

main {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 16px;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.card {
    background-color: var(--md-sys-color-surface-container);
    border-radius: var(--md-sys-shape-corner-large);
    padding: 32px;
    box-shadow: 0px 1px 3px 1px rgba(0, 0, 0, 0.15), 0px 1px 2px 0px rgba(0, 0, 0, 0.3);
    transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
    box-shadow: 0px 4px 8px 3px rgba(0, 0, 0, 0.15), 0px 1px 3px 0px rgba(0, 0, 0, 0.3);
}

h2 {
    font-size: 1.9rem;
    text-transform: lowercase;
    letter-spacing: 0.05em;
    font-weight: 600;
    color: var(--md-sys-color-on-surface);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

h2::before {
    content: '';
    width: 4px;
    height: 18px;
    background: var(--md-sys-color-secondary);
    border-radius: 2px;
}

ul {
    list-style: none;
}

li {
    padding: 12px 0;
    font-size: 1.2rem;
    line-height: 1.5;
    color: var(--md-sys-color-on-surface-variant);
    border-bottom: 1px solid rgba(255,255,255,0.05);
    display: flex;
    align-items: flex-start;
}

li:last-child {
    border-bottom: none;
}

li::before {
    content: 'arrow_right';
    font-family: 'Material Icons Round', serif;
    color: var(--md-sys-color-primary);
    margin-right: 12px;
    font-size: 20px;
    margin-top: 2px;
}

.links {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 12px;
    width: 100%;
}

.link-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 48px;
    padding: 0 16px;
    background-color: var(--md-sys-color-surface-container-high);
    border: 1px solid var(--md-sys-color-outline);
    border-radius: var(--md-sys-shape-corner-medium);
    color: var(--md-sys-color-on-surface);
    text-decoration: none;
    font-weight: 600;
    font-size: 1.0rem;
    transition: all 0.3s cubic-bezier(0.2, 0.0, 0, 1.0);
    text-align: center;
}

.link-btn:hover {
    background-color: var(--md-sys-color-primary-container);
    color: var(--md-sys-color-on-primary-container);
    border-color: transparent;
    transform: translateY(-2px);
}

.link-btn:active {
    background-color: rgba(208, 188, 255, 0.12);
}

.link-btn.primary:hover {
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
    background-color: var(--md-sys-color-primary-container);
    color: var(--md-sys-color-on-primary-container);
    border-color: transparent;
}


.friends-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100px, max-content));
    justify-content: center;
    gap: 24px;
    margin: 20px auto 0 auto;
    width: 100%;
}

.friend-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    gap: 8px;
    margin-bottom: 0;
    width: 100px;
}

.friend-img {
    width: 80px;
    height: 80px;
    border-radius: 20px;
    object-fit: cover;
    transition: transform 0.2s;
    background: var(--md-sys-color-surface-container-high);
}

.friend-name {
    font-size: 1.0rem;
    color: var(--md-sys-color-on-surface-variant);
    font-weight: 500;
}


.friend-link:hover .friend-img {
    transform: scale(1.1);
}

.friend-link:hover .friend-name {
    color: var(--md-sys-color-primary);
}


.image-container {
    margin-top: 16px;
    border-radius: var(--md-sys-shape-corner-large);
    overflow: hidden;
    background: var(--md-sys-color-surface-container);
}

.image-container img {
    width: 100%;
    height: auto;
    display: block;
}

h3 {
    text-align: center;
    font-weight: 400;
    font-size: 1.3rem;
    color: var(--md-sys-color-secondary);
    margin-top: 16px;
}

#player {
    position: fixed;
    top: 24px;
    right: 24px;
    width: 300px;
    background: var(--md-sys-color-surface-container-high);
    border-radius: 24px;
    padding: 16px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.4);
    z-index: 1000;
    border: 1px solid rgba(255,255,255,0.05);
    transition: opacity 0.3s;
}

.player-label {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--md-sys-color-primary);
    margin-bottom: 6px;
    font-weight: 700;
}

#player iframe {
    width: 100%;
    height: 100px;
    border: none;
    border-radius: 12px;
}

#gf-corner {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 2000;
}

.gf-card {
    background: var(--md-sys-color-tertiary-container);
    color: var(--md-sys-color-tertiary);
    padding: 8px;
    border-radius: 20px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
    transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    width: 120px;
}

.gf-card:hover {
    transform: scale(1.05) translateY(-4px);
}

#gf-photo {
    width: 100%;
    aspect-ratio: 1/1;
    object-fit: cover;
    border-radius: 14px;
    margin-bottom: 6px;
}

.gf-label {
    font-size: 0.8rem;
    font-weight: 700;
    color: #ffd8e4;
}

.heart-particle {
    position: fixed;
    pointer-events: none;
    font-size: 28px;
    z-index: 3000;
    animation: heartFloat 1.2s ease-out forwards;
}

.dialog-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 5000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    backdrop-filter: blur(4px);
}



.dialog-overlay.active {
    opacity: 1;
    visibility: visible;
}

.dialog-card {
    background: var(--md-sys-color-surface-container-high);
    width: 90%;
    max-width: 320px;
    padding: 24px;
    border-radius: 28px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    text-align: center;
    transform: scale(0.8);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.dialog-overlay.active .dialog-card {
    transform: scale(1);
}

.dialog-icon {
    color: var(--md-sys-color-tertiary);
    font-size: 40px !important;
    margin-bottom: 16px;
}

.dialog-title {
    font-size: 1.5rem;
    color: var(--md-sys-color-on-surface);
    margin-bottom: 12px;
    justify-content: center;
}

.dialog-title::before {
    display: none;
}

.dialog-text {
    color: var(--md-sys-color-on-surface-variant);
    font-size: 0.95rem;
    line-height: 1.5;
    margin-bottom: 24px;
}

.dialog-actions {
    display: flex;
    gap: 8px;
    justify-content: flex-end;
}

.dialog-actions .link-btn {
    height: 40px;
    padding: 0 16px;
    border: none;
}

.copy-container {
    cursor: pointer;
    padding: 12px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    transition: all 0.2s ease;
    border: 1px dashed var(--md-sys-color-outline);
    margin-bottom: 20px;
    position: relative;
}

.copy-container:hover {
    background: rgba(208, 188, 255, 0.08);
    border-color: var(--md-sys-color-primary);
}

.copy-badge {
    display: block;
    font-size: 0.7rem;
    color: var(--md-sys-color-primary);
    margin-top: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.copy-container.copied {
    border-style: solid;
    background: rgba(120, 255, 120, 0.05);
}

@keyframes heartFloat {
    0% { transform: translate(0, 0) scale(0); opacity: 0; }
    20% { opacity: 1; transform: translate(0, 0) scale(1); }
    100% { transform: translate(var(--x), var(--y)) rotate(var(--r)) scale(1.5); opacity: 0; }
}

footer {
    margin-top: 40px;
    text-align: center;
    color: var(--md-sys-color-outline);
    font-size: 0.85rem;
}

footer a {
    color: var(--md-sys-color-primary);
    text-decoration: none;
}

@media (max-width: 768px) {
    h1 { font-size: 2.6rem; }

    #player {
        position: relative;
        top: auto;
        right: auto;
        width: 100%;
        margin: 0 0 24px 0;
    }

    #gf-corner {
        bottom: 16px;
        right: 16px;
    }

    .card { padding: 24px; }
    .links { justify-content: center; }

    .friends-container {
        grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
        gap: 20px;
    }

    .friend-img {
        width: 90px;
        height: 90px;
    }
}