/* Tool Page Common Styles */
.tool-page {
    padding-top: 0;
}

/* Breadcrumb */
.breadcrumb {
    padding: 20px 0;
    font-size: 14px;
    color: #666;
}

.breadcrumb a {
    color: #666;
    text-decoration: none;
    transition: color 0.3s;
}

.breadcrumb a:hover {
    color: #f5576c;
}

.breadcrumb .separator {
    margin: 0 10px;
    color: #ddd;
}

.breadcrumb .current {
    color: #333;
    font-weight: 600;
}

/* Tool Header */
.tool-header {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: white;
    padding: 60px 20px;
    text-align: center;
}

.tool-header-content {
    max-width: 800px;
    margin: 0 auto;
}

.tool-icon-large {
    font-size: 72px;
    margin-bottom: 20px;
    animation: bounce 2s ease-in-out infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.tool-header h1 {
    font-size: 48px;
    font-weight: 900;
    margin-bottom: 15px;
    line-height: 1.2;
}

.tool-subtitle {
    font-size: 20px;
    opacity: 0.95;
    margin-bottom: 25px;
    line-height: 1.6;
}

.tool-meta {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
    font-size: 16px;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 5px;
}

.meta-separator {
    opacity: 0.5;
}

/* Tool Content */
.tool-content {
    padding: 60px 20px;
    background: #f8f9fa;
}

/* Meme Generator Specific Styles */
.meme-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0;
    background: #ffffff;
    border-radius: 25px;
    box-shadow: 0 15px 60px rgba(0,0,0,0.12);
    overflow: hidden;
}

.meme-header {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    padding: 40px 30px;
    text-align: center;
    color: white;
}

.meme-header h2 {
    font-size: 36px;
    margin-bottom: 10px;
    font-weight: 700;
}

.meme-header p {
    font-size: 16px;
    opacity: 0.95;
    margin: 0;
}

.meme-controls {
    padding: 40px 30px;
    background: #f8f9fa;
}

.meme-control-group {
    margin-bottom: 25px;
}

.meme-control-group label {
    display: block;
    font-weight: 700;
    color: #333;
    margin-bottom: 10px;
    font-size: 15px;
}

.meme-control-group input[type="text"],
.meme-control-group select {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 16px;
    color: #333;
    transition: all 0.3s ease;
    font-family: inherit;
}

.meme-control-group input[type="file"] {
    width: 100%;
    padding: 12px;
    border: 2px dashed #e0e0e0;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
}

.meme-control-group input[type="file"]:hover {
    border-color: #f5576c;
    background: #fff5f7;
}

.meme-control-group input[type="range"] {
    width: 100%;
    height: 8px;
    border-radius: 5px;
    background: #e0e0e0;
    outline: none;
    cursor: pointer;
}

.meme-control-group input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    cursor: pointer;
}

.meme-control-group input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    cursor: pointer;
    border: none;
}

.meme-control-group input[type="text"]:focus,
.meme-control-group select:focus {
    outline: none;
    border-color: #f5576c;
    box-shadow: 0 0 0 4px rgba(245, 87, 108, 0.1);
}

.meme-hint {
    display: block;
    margin-top: 8px;
    font-size: 13px;
    color: #999;
    font-style: italic;
}

.meme-control-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.meme-canvas-wrapper {
    padding: 40px 30px;
    background: white;
    text-align: center;
}

.meme-canvas-container {
    display: inline-block;
    box-shadow: 0 8px 30px rgba(0,0,0,0.15);
    border-radius: 12px;
    overflow: hidden;
    background: #f8f9fa;
    max-width: 100%;
}

#memeCanvas {
    display: block;
    max-width: 100%;
    height: auto;
}

.meme-preview-hint {
    margin-top: 20px;
    color: #999;
    font-size: 14px;
    font-style: italic;
}

.meme-buttons {
    display: flex;
    gap: 15px;
    padding: 30px;
    background: #f8f9fa;
}

.meme-btn {
    flex: 1;
    padding: 18px 24px;
    border: none;
    border-radius: 12px;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.meme-btn-primary {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: white;
    box-shadow: 0 6px 20px rgba(245, 87, 108, 0.3);
}

.meme-btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(245, 87, 108, 0.4);
}

.meme-btn-secondary {
    background: white;
    color: #f5576c;
    border: 2px solid #f5576c;
}

.meme-btn-secondary:hover {
    background: #fff5f7;
    transform: translateY(-2px);
}

.meme-btn:active {
    transform: translateY(0);
}

/* SEO Content Section */
.seo-content {
    padding: 80px 20px;
    background: white;
}

.content-article {
    max-width: 900px;
    margin: 0 auto;
    line-height: 1.8;
}

.content-article h2 {
    font-size: 32px;
    font-weight: 800;
    margin-top: 50px;
    margin-bottom: 20px;
    color: #333;
}

.content-article h2:first-child {
    margin-top: 0;
}

.content-article h3 {
    font-size: 24px;
    font-weight: 700;
    margin-top: 35px;
    margin-bottom: 15px;
    color: #333;
}

.content-article p {
    margin-bottom: 20px;
    color: #666;
    font-size: 16px;
}

.content-article ul,
.content-article ol {
    margin-bottom: 25px;
    padding-left: 30px;
    color: #666;
}

.content-article li {
    margin-bottom: 12px;
    line-height: 1.8;
}

.content-article strong {
    color: #333;
    font-weight: 700;
}

/* Related Tools */
.related-tools {
    max-width: 900px;
    margin: 60px auto 0;
    padding: 40px;
    background: #f8f9fa;
    border-radius: 15px;
}

.related-tools h3 {
    font-size: 28px;
    font-weight: 800;
    margin-bottom: 30px;
    text-align: center;
    color: #333;
}

.related-tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.related-tool-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 25px;
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    transition: all 0.3s;
    text-align: center;
    text-decoration: none;
}

.related-tool-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    border-color: #f5576c;
}

.related-tool-card .tool-icon {
    font-size: 42px;
}

.related-tool-card .tool-name {
    font-weight: 700;
    color: #333;
    font-size: 16px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .tool-header h1 {
        font-size: 32px;
    }
    
    .tool-subtitle {
        font-size: 16px;
    }
    
    .tool-icon-large {
        font-size: 52px;
    }
    
    .tool-meta {
        font-size: 14px;
    }
    
    .meme-container {
        margin: 20px;
        border-radius: 20px;
    }
    
    .meme-header {
        padding: 30px 20px;
    }
    
    .meme-header h2 {
        font-size: 28px;
    }
    
    .meme-controls,
    .meme-canvas-wrapper,
    .meme-buttons {
        padding: 30px 20px;
    }
    
    .meme-control-row {
        grid-template-columns: 1fr;
    }
    
    .meme-buttons {
        flex-direction: column;
    }
    
    .meme-btn {
        width: 100%;
    }
    
    .content-article h2 {
        font-size: 26px;
    }
    
    .content-article h3 {
        font-size: 20px;
    }
    
    .related-tools-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .meme-header h2 {
        font-size: 24px;
    }
    
    .meme-header p {
        font-size: 14px;
    }
    
    .meme-btn {
        font-size: 16px;
        padding: 16px 20px;
    }
}

/* Print Styles */
@media print {
    .meme-controls,
    .meme-buttons {
        display: none;
    }
    
    .meme-container {
        box-shadow: none;
        border: 1px solid #ddd;
    }
}