/* 基础样式 */
body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f5f5f5;
}

/* 头部样式 */
.header {
    background: linear-gradient(135deg, #4CAF50, #2E7D32);
    color: white;
    padding: 25px 20px;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    border-bottom: 5px solid #FFC107;
    position: relative;
    overflow: hidden;
}

.header::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.header:hover::before {
    left: 100%;
}

.header-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: all 0.3s ease;
    padding: 10px 20px;
    border-radius: 8px;
}

.header-link:hover {
    background-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-3px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.header-logo {
    width: 48px;
    height: 48px;
    margin-right: 15px;
    transition: all 0.3s ease;
    filter: drop-shadow(2px 2px 3px rgba(0,0,0,0.3));
}

.header-link:hover .header-logo {
    transform: rotate(10deg) scale(1.1);
}

.header-title {
    margin: 0;
    font-size: 3em;
    font-weight: 800;
    text-shadow: 3px 3px 5px rgba(0,0,0,0.3);
    letter-spacing: 1px;
    background: linear-gradient(to right, #fff, #f0f0f0);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    transition: all 0.3s ease;
    line-height: 1;
}

.header-slogan {
    margin: 10px 0 0 0;
    font-size: 1.2em;
    color: #ffffff;
    text-align: center;
    font-weight: bold;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
}

.header-link:hover .header-title {
    letter-spacing: 2px;
}

/* 搜索框样式 */
.search-container {
    background-color: white;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 20px;
    width: 100%;
    box-sizing: border-box;
}

.search-box {
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
    display: flex;
}

.search-box input {
    flex: 1;
    padding: 12px;
    border: 2px solid #4CAF50;
    border-radius: 4px 0 0 4px;
    font-size: 16px;
    min-width: 0;
}

.search-box button {
    background-color: #4CAF50;
    color: white;
    border: none;
    padding: 12px 20px;
    cursor: pointer;
    border-radius: 0 4px 4px 0;
    font-size: 16px;
    white-space: nowrap;
}

.search-box button:hover {
    background-color: #45a049;
}

.search-box a {
    background-color: #2196F3;
    color: white;
    border: none;
    padding: 12px 20px;
    cursor: pointer;
    border-radius: 4px;
    font-size: 16px;
    white-space: nowrap;
    text-decoration: none;
    margin-left: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-box a:hover {
    background-color: #1976D2;
}

/* 主体内容样式 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    width: 100%;
    box-sizing: border-box;
}

.results {
    background-color: white;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    padding: 20px;
}

.resource-item {
    border-bottom: 1px solid #eee;
    padding: 15px 0;
}

.resource-item:last-child {
    border-bottom: none;
}

.resource-title {
    font-size: 18px;
    font-weight: bold;
    color: #333;
    margin-bottom: 5px;
    word-wrap: break-word;
}

.resource-url {
    color: #4CAF50;
    text-decoration: none;
    word-break: break-all;
    font-size: 14px;
}

.resource-url:hover {
    text-decoration: underline;
}

.resource-password {
    background-color: #f1f8e9;
    padding: 5px 10px;
    border-radius: 3px;
    display: inline-block;
    margin-top: 5px;
    font-size: 14px;
}

/* 底部样式 */
.footer {
    background: linear-gradient(135deg, #2c3e50, #1a2530);
    color: #ecf0f1;
    text-align: center;
    padding: 30px 20px;
    margin-top: 40px;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.2);
    border-top: 3px solid #4CAF50;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.footer-links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 25px;
    margin: 10px 0;
}

.footer-links a {
    color: #bdc3c7;
    text-decoration: none;
    padding: 8px 15px;
    border-radius: 4px;
    transition: all 0.3s ease;
    font-weight: 500;
}

.footer-links a:hover {
    color: #4CAF50;
    background-color: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

.footer-copyright {
    margin: 15px 0;
    font-size: 14px;
    color: #95a5a6;
}

.footer-divider {
    width: 50%;
    margin: 10px auto;
    border: 0;
    height: 1px;
    background: linear-gradient(to right, transparent, #4CAF50, transparent);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .header {
        padding: 15px 10px;
    }

    .header-title {
        font-size: 2.6em;
    }

    .header-slogan {
        font-size: 1.1em;
    }

    .header-logo {
        width: 42px;
        height: 42px;
    }

    .search-box {
        flex-direction: column;
    }

    .search-box input,
    .search-box button {
        border-radius: 4px;
    }

    .search-box input {
        margin-bottom: 10px;
    }

    .search-container {
        padding: 15px;
    }

    .container {
        padding: 10px;
    }

    .results {
        padding: 15px;
    }

    .resource-item {
        padding: 10px 0;
    }

    .footer-links {
        gap: 15px;
    }
}

@media (max-width: 480px) {
    .header {
        padding: 15px 10px;
    }

    .header-title {
        font-size: 2.2em;
    }

    .header-slogan {
        font-size: 1em;
    }

    .header-logo {
        width: 36px;
        height: 36px;
        margin-right: 10px;
    }

    .search-container {
        padding: 10px;
    }

    .search-box input,
    .search-box button {
        padding: 10px;
        font-size: 14px;
    }

    .container {
        padding: 5px;
    }

    .results {
        padding: 10px;
    }

    .resource-title {
        font-size: 16px;
    }

    .footer {
        padding: 20px 10px;
    }

    .footer-links {
        flex-direction: column;
        gap: 10px;
    }

    .footer-links a {
        padding: 10px;
        width: 80%;
        margin: 0 auto;
    }

    .footer-divider {
        width: 80%;
    }
}
