
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    background: #f5f7ff;
    color: #172033;
}

.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 22px 8%;
    background: white;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.04);
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #172033;
    text-decoration: none;
    font-size: 23px;
    font-weight: bold;
}

.logo-icon {
    background: #5546e8;
    color: white;
    padding: 9px 13px;
    border-radius: 10px;
}

nav {
    display: flex;
    gap: 28px;
}

nav a {
    color: #596174;
    text-decoration: none;
    font-weight: 600;
}

nav a:hover {
    color: #5546e8;
}

.hero {
    text-align: center;
    padding: 85px 20px 55px;
}

.tag {
    display: inline-block;
    color: #5546e8;
    background: #e9e7ff;
    padding: 9px 17px;
    border-radius: 30px;
    font-size: 12px;
    font-weight: bold;
    letter-spacing: 1px;
}

.hero h1 {
    font-size: 52px;
    margin: 25px 0 15px;
}

.hero h1 span {
    color: #5546e8;
}

.hero p {
    color: #687084;
    font-size: 18px;
    line-height: 1.7;
}

.converter-section {
    display: flex;
    justify-content: center;
    padding: 10px 20px 75px;
}

.converter-box {
    width: 100%;
    max-width: 600px;
    background: white;
    padding: 35px;
    border-radius: 20px;
    box-shadow: 0 12px 45px rgba(30, 40, 90, 0.08);
    text-align: center;
}

.converter-box h2 {
    font-size: 27px;
    margin-bottom: 10px;
}

.subtitle {
    color: #81899a;
    margin-bottom: 25px;
}

.upload-area {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 35px 15px;
    border: 2px dashed #b8b2f7;
    border-radius: 15px;
    background: #fafaff;
    cursor: pointer;
    transition: 0.3s;
}

.upload-area:hover {
    background: #f0efff;
    border-color: #5546e8;
}

.upload-icon {
    font-size: 40px;
    color: #5546e8;
}

.upload-area strong {
    font-size: 18px;
}

.upload-area span,
.upload-area small {
    color: #7b8293;
}

.preview-area {
    margin-top: 25px;
}

.preview-area img {
    max-width: 100%;
    max-height: 250px;
    border-radius: 12px;
    object-fit: contain;
}

.preview-area p {
    margin-top: 10px;
    color: #687084;
}

.settings {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 25px 0;
}

.settings label {
    font-weight: bold;
}

.settings select {
    padding: 12px 18px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 15px;
}

#convertButton {
    width: 100%;
    padding: 16px;
    background: #5546e8;
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 17px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
}

#convertButton:hover:not(:disabled) {
    background: #4032c9;
}

#convertButton:disabled {
    background: #aaa5d9;
    cursor: not-allowed;
}

#statusMessage {
    margin-top: 15px;
    color: #5546e8;
}

.download-button {
    display: block;
    margin-top: 15px;
    padding: 15px;
    background: #e7f8ee;
    color: #16834b;
    text-decoration: none;
    border-radius: 10px;
    font-weight: bold;
}

.about {
    text-align: center;
    padding: 50px 20px;
    background: white;
}

.about h2 {
    margin-bottom: 15px;
    font-size: 28px;
}

.about p {
    color: #687084;
    line-height: 1.7;
}

footer {
    text-align: center;
    padding: 25px;
    color: #81899a;
}

@media (max-width: 600px) {
    .header {
        padding: 18px 5%;
        flex-direction: column;
        gap: 18px;
    }

    nav {
        gap: 20px;
    }

    .hero {
        padding-top: 60px;
    }

    .hero h1 {
        font-size: 36px;
    }

    .converter-box {
        padding: 22px;
    }
}

#conversionProgress {
    width: 100%;
    height: 9px;
    margin-top: 18px;
    accent-color: #5546e8;
}

#statusMessage {
    min-height: 24px;
    font-weight: 600;
}

.download-button {
    cursor: pointer;
    transition: 0.3s;
}

.download-button:hover {
    background: #d2f3df;
    transform: translateY(-2px);
}

.preview-area p {
    margin-top: 10px;
    color: #687084;
    font-size: 14px;
}

#qualityRange {
    accent-color: #5546e8;
    cursor: pointer;
    margin: 15px 0 25px;
}

#compressButton {
    width: 100%;
    padding: 16px;
    background: #5546e8;
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 17px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
}

#compressButton:hover:not(:disabled) {
    background: #4032c9;
}

#compressButton:disabled {
    background: #aaa5d9;
    cursor: not-allowed;
}

#compressStatus,
#compressResultSize {
    margin-top: 15px;
    color: #5546e8;
    font-weight: 600;
}

#batchFileCount {
    margin: 18px 0;
    color: #5546e8;
    font-weight: bold;
}

#batchResults {
    margin-top: 20px;
    text-align: left;
}

.batch-result {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 14px 0;
    border-bottom: 1px solid #eee;
    flex-wrap: wrap;
}

.batch-result a {
    color: #5546e8;
    text-decoration: none;
    font-weight: bold;
}

#batchDownloadAll {
    width: 100%;
    padding: 16px;
    margin-top: 18px;
    background: #16834b;
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
}

#batchDownloadAll:hover {
    background: #11683b;
}

#batchConvertButton {
    width: 100%;
    padding: 16px;
    background: #5546e8;
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 17px;
    font-weight: bold;
    cursor: pointer;
}

#batchConvertButton:disabled {
    background: #aaa5d9;
    cursor: not-allowed;
}

.main-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
    flex-wrap: wrap;
}

.tools-overview {
    padding: 55px 8%;
    text-align: center;
}

.tools-overview h2 {
    font-size: 30px;
    margin-bottom: 12px;
}

.tools-overview > p {
    color: #687084;
    margin-bottom: 35px;
}

.tools-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
    max-width: 1100px;
    margin: auto;
}

.tool-card {
    display: block;
    padding: 28px;
    background: white;
    border: 1px solid #eee;
    border-radius: 16px;
    text-align: left;
    text-decoration: none;
    color: #172033;
    box-shadow: 0 8px 25px rgba(30, 40, 90, 0.04);
    transition: 0.3s;
}

.tool-card:hover {
    transform: translateY(-5px);
    border-color: #5546e8;
    box-shadow: 0 12px 30px rgba(85, 70, 232, 0.12);
}

.tool-icon {
    font-size: 32px;
}

.tool-card h3 {
    margin: 18px 0 10px;
    font-size: 20px;
}

.tool-card p {
    color: #687084;
    line-height: 1.6;
    min-height: 50px;
    margin-bottom: 18px;
}

.tool-card strong {
    color: #5546e8;
}

@media (max-width: 750px) {
    .tools-grid {
        grid-template-columns: 1fr;
    }

    .tools-overview {
        padding: 40px 5%;
    }

    .main-nav {
        gap: 14px;
    }
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 12px;
    flex-wrap: wrap;
}

.footer-links a {
    text-decoration: none;
    color: inherit;
}

.footer-links a:hover {
    text-decoration: underline;
}
