body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f7f8fa;
    margin: 0;
    color: #222;
}
.navbar {
    background: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
    display: flex;
    align-items: center;
    padding: 0 32px;
    height: 64px;
    position: sticky;
    top: 0;
    z-index: 10;
}

.navbar-spacer {
    flex: 1;
}

/* Hamburger menu styles */
.hamburger-menu {
    display: none;
    flex-direction: column;
    cursor: pointer;
    padding: 8px;
    margin-left: 0;
    margin-right: 0;
    z-index: 1000;
}

.hamburger-menu span {
    width: 25px;
    height: 3px;
    background: #222;
    margin: 3px 0;
    transition: 0.3s;
    border-radius: 2px;
}

.hamburger-menu.active span:nth-child(1) {
    transform: rotate(-45deg) translate(-5px, 6px);
}

.hamburger-menu.active span:nth-child(2) {
    opacity: 0;
}

.hamburger-menu.active span:nth-child(3) {
    transform: rotate(45deg) translate(-5px, -6px);
}
.navbar-logo {
    font-family: 'Montserrat', 'Segoe UI', Arial, sans-serif;
    font-weight: 900;
    font-size: 2.2rem;
    letter-spacing: 2px;
    color: #222;
    margin-right: 32px;
    text-transform: uppercase;
    display: flex;
    align-items: center;
    user-select: none;
}
.navbar-logo span {
    color: #222;
    font-size: 1.2rem;
    margin-left: 6px;
    font-weight: 600;
}
.navbar-menu {
    display: flex;
    gap: 24px;
    flex: 1;
    align-items: center;
    justify-content: flex-start;
}
.navbar-menu a, .navbar-menu .dropdown {
    color: #222;
    text-decoration: none;
    font-size: 1rem;
    font-weight: 500;
    padding: 8px 0;
    position: relative;
    cursor: pointer;
}
.navbar-menu a:hover, .navbar-menu .dropdown:hover {
    color: #e74c3c;
}
.dropdown {
    position: relative;
}
.dropdown-content {
    display: none;
    position: absolute;
    left: 0;
    top: 32px;
    background: #fff;
    min-width: 180px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.08);
    border-radius: 8px;
    z-index: 100;
}
.dropdown:hover .dropdown-content {
    display: block;
}
.dropdown-content a {
    display: block;
    padding: 10px 18px;
    color: #222;
    text-decoration: none;
    font-size: 1rem;
}
.dropdown-content a:hover {
    background: #f2f2f2;
    color: #e74c3c;
}
.navbar-actions {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 16px;
}
.lang-switch {
    margin-left: 12px;
}
.lang-switch select {
    font-size: 1rem;
    padding: 4px 10px;
    border-radius: 6px;
    border: 1px solid #ccc;
}
.headline {
    text-align: center;
    margin: 48px 0 18px 0;
}
.headline h1 {
    font-size: 2.4rem;
    font-weight: 700;
    margin-bottom: 10px;
}
.headline p {
    font-size: 1.15rem;
    color: #666;
    margin: 0 auto;
    max-width: 600px;
}
.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
    gap: 28px;
    max-width: 1200px;
    margin: 36px auto 0 auto;
    padding: 0 16px 48px 16px;
}
.tool-card {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
    padding: 28px 22px 22px 22px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    transition: box-shadow 0.2s, transform 0.2s;
    cursor: pointer;
    border: 1.5px solid #f2f2f2;
}
.tool-card:hover {
    box-shadow: 0 8px 24px rgba(231,76,60,0.10);
    border-color: #e74c3c33;
    transform: translateY(-2px) scale(1.01);
}
.tool-icon {
    font-size: 2.1rem;
    border-radius: 8px;
    padding: 8px;
    margin-bottom: 16px;
    display: inline-block;
}
.icon-merge { background: #ffe5e0; color: #e74c3c; }
.icon-split { background: #ffe5e0; color: #e67e22; }
.icon-compress { background: #eafbe7; color: #27ae60; }
.icon-pdf2word, .icon-word2pdf { background: #e7f0fd; color: #2980ef; }
.icon-pdf2ppt, .icon-ppt2pdf { background: #fbeeee; color: #e67e22; }
.icon-pdf2excel, .icon-excel2pdf { background: #f0fbe7; color: #27ae60; }
.icon-pdf2jpg, .icon-jpg2pdf { background: #fffbe7; color: #f1c40f; }
.icon-html2pdf { background: #f7e7fd; color: #9b59b6; }
.icon-rotate { background: #f7e7fd; color: #9b59b6; }
.icon-unlock { background: #e7f0fd; color: #2980ef; }
.icon-protect { background: #ffe5e0; color: #e74c3c; }
.icon-watermark { background: #fbeeee; color: #e67e22; }
.tool-title {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 6px;
}
.tool-desc {
    font-size: 0.98rem;
    color: #666;
    margin-bottom: 0;
}
/* Mobile responsive styles */
@media (max-width: 768px) {
    .navbar {
        padding: 0 16px;
        position: relative;
    }
    
    .navbar-logo {
        font-size: 1.8rem;
        margin-right: 0;
    }
    
    .navbar-spacer {
        display: none;
    }
    
    .hamburger-menu {
        display: flex;
        margin-left: auto;
    }
    
    .navbar-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80vw;
        max-width: 340px;
        height: 100vh;
        background: #fff;
        flex-direction: column;
        align-items: flex-start;
        padding: 80px 24px 24px 24px;
        transition: right 0.3s ease;
        box-shadow: -2px 0 8px rgba(0,0,0,0.1);
        overflow-y: auto;
        gap: 0;
        z-index: 999;
        flex: unset;
        justify-content: unset;
    }
    
    .navbar-menu.active {
        right: 0;
    }
    
    .navbar-menu a, .navbar-menu .dropdown {
        padding: 16px 0;
        border-bottom: 1px solid #f0f0f0;
        font-size: 1.1rem;
        width: 100%;
    }
    
    .navbar-menu a:last-child, .navbar-menu .dropdown:last-child {
        border-bottom: none;
    }
    
    .dropdown-content {
        position: static;
        display: none;
        box-shadow: none;
        border-radius: 0;
        margin-top: 10px;
        padding-left: 20px;
        background: #f8f9fa;
        border-left: 3px solid #e74c3c;
    }
    
    .dropdown.active .dropdown-content {
        display: block;
    }
    
    .dropdown-content a {
        padding: 12px 16px;
        border-bottom: 1px solid #e9ecef;
    }
    
    .dropdown-content a:last-child {
        border-bottom: none;
    }
    
    /* Show language selector only in mobile menu */
    .mobile-lang-switch {
        display: block;
        width: 100%;
        margin-top: 24px;
        margin-bottom: 8px;
    }
    
    .mobile-lang-switch select {
        width: 100%;
        font-size: 1rem;
        padding: 8px 10px;
        border-radius: 6px;
        border: 1px solid #ccc;
    }
    
    .navbar-actions {
        display: none;
    }
    
    .headline h1 { 
        font-size: 1.5rem; 
    }
    
    .tools-grid { 
        grid-template-columns: 1fr; 
        gap: 20px;
        padding: 0 12px 48px 12px;
    }
    
    .tool-card {
        padding: 20px 16px 16px 16px;
    }
    
    .desktop-lang-switch {
        display: none;
    }
}

@media (max-width: 480px) {
    .navbar-logo {
        font-size: 1.6rem;
    }
    
    .navbar-menu {
        padding: 80px 12px 12px 12px;
    }
    
    .navbar-menu a, .navbar-menu .dropdown {
        font-size: 1rem;
        padding: 14px 0;
    }
    
    .dropdown-content a {
        padding: 10px 12px;
        font-size: 0.95rem;
    }
    
    .headline h1 {
        font-size: 1.3rem;
    }
    
    .headline p {
        font-size: 1rem;
    }
    
    .tool-card {
        padding: 16px 12px 12px 12px;
    }
    
    .tool-icon {
        font-size: 1.8rem;
        padding: 6px;
    }
    
    .tool-title {
        font-size: 1.1rem;
    }
    
    .tool-desc {
        font-size: 0.9rem;
    }
}

/* Additional responsive improvements */
@media (max-width: 768px) {
    /* Improve touch targets */
    .navbar-menu a, .navbar-menu .dropdown {
        min-height: 44px;
        display: flex;
        align-items: center;
    }
    
    .dropdown-content a {
        min-height: 40px;
        display: flex;
        align-items: center;
    }
    
    /* Better spacing for mobile */
    .headline {
        margin: 32px 0 16px 0;
        padding: 0 16px;
    }
    
    /* Improve modal responsiveness */
    .modal-content {
        margin: 20px;
        max-width: calc(100vw - 40px);
        max-height: calc(100vh - 40px);
    }
}

/* Countdown Modal Styles */
#toolModalDownloadCountdown {
    margin-top: 24px;
    text-align: center;
    display: none;
}
.countdown-circle {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 8px;
}
.countdown-svg {
    margin-bottom: 4px;
}
.countdown-number {
    font-size: 2rem;
    font-weight: 700;
    fill: #e74c3c;
    font-family: inherit;
}
.countdown-msg {
    font-size: 1rem;
    color: #e74c3c;
    font-weight: 500;
    margin-bottom: 4px;
}
.countdown-fallback {
    color: #e74c3c;
    font-size: 0.97rem;
    font-weight: 500;
    text-decoration: underline;
    display: block;
    margin-top: 2px;
    opacity: 0.85;
}

/* Disabled button style */
button:disabled, .btn-disabled {
    opacity: 0.6 !important;
    cursor: not-allowed !important;
    pointer-events: none !important;
}

.custom-file-input {
  display: flex;
  align-items: center;
  gap: 10px;
}

#customFileBtn {
  background: linear-gradient(90deg, #e74c3c, #f39c12);
  color: #fff;
  border: none;
  padding: 6px 16px;
  border-radius: 8px;
  font-size: 0.98rem;
  cursor: pointer;
  font-weight: 600;
  transition: background 0.2s;
  height: 34px;
  min-width: 120px;
  box-shadow: 0 1px 4px rgba(231,76,60,0.07);
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  justify-content: center;
}

#customFileBtn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

#customFileName {
  font-size: 1rem;
  color: #444;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 180px;
}

/* Modal state visibility control */
#toolModalBody, #toolModalProgressBar, #toolModalDownloadCountdown, #toolModalError, #toolModalDownloadPhrase { display: none; }

#toolModal.modal--idle #toolModalBody { display: block; }
#toolModal.modal--idle #toolModalProgressBar { display: none; }
#toolModal.modal--idle #toolModalDownloadCountdown { display: none; }
#toolModal.modal--idle #toolModalError { display: none; }
#toolModal.modal--idle #toolModalDownloadPhrase { display: none; }

#toolModal.modal--progress #toolModalBody { display: block; }
#toolModal.modal--progress #toolModalProgressBar { display: block; }
#toolModal.modal--progress #toolStartBtn { display: none; }
#toolModal.modal--progress #toolModalDownloadCountdown { display: none; }
#toolModal.modal--progress #toolModalError { display: none; }
#toolModal.modal--progress #toolModalDownloadPhrase { display: none; }

#toolModal.modal--countdown #toolModalDownloadCountdown { display: block; }
#toolModal.modal--countdown #toolModalDownloadPhrase { display: block; }
#toolModal.modal--countdown #toolModalBody { display: none; }
#toolModal.modal--countdown #toolModalProgressBar { display: none; }
#toolModal.modal--countdown #toolModalError { display: none; }

#toolModal.modal--error #toolModalError { display: block; }
#toolModal.modal--error #toolModalBody { display: none; }
#toolModal.modal--error #toolModalProgressBar { display: none; }
#toolModal.modal--error #toolModalDownloadCountdown { display: none; }
#toolModal.modal--error #toolModalDownloadPhrase { display: none; }

#toolModalDownloadCountdown {
  margin-top: 24px;
  text-align: center;
  display: none;
}

/* Desktop language selector visible only on desktop */
.desktop-lang-switch {
    margin-left: 24px;
}

/* Mobile language selector hidden on desktop */
.mobile-lang-switch {
    display: none;
}

@media (max-width: 768px) {
    .desktop-lang-switch {
        display: none;
    }
    .mobile-lang-switch {
        display: block;
        width: 100%;
        margin-top: 24px;
        margin-bottom: 8px;
    }
    .mobile-lang-switch select {
        width: 100%;
        font-size: 1rem;
        padding: 8px 10px;
        border-radius: 6px;
        border: 1px solid #ccc;
    }
} 