/* DentalX Clinic - Custom Styles */
/* Minimal Corporate Design */

:root {
    --primary-color: #1e40af;
    --secondary-color: #3b82f6;
    --text-color: #1f2937;
    --light-bg: #f9fafb;
    --bot-logo-url: none; /* Chatbot logo URL - dinamik olarak ayarlanabilir */
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: var(--text-color);
    line-height: 1.6;
}

/* Smooth Scroll */
html {
    scroll-behavior: smooth;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--secondary-color);
}

/* Buttons */
.btn-primary {
    background-color: var(--primary-color);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 0.375rem;
    transition: all 0.3s ease;
    display: inline-block;
    text-decoration: none;
    border: none;
    cursor: pointer;
}

.btn-primary:hover {
    background-color: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(30, 64, 175, 0.3);
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.6s ease-out;
}

/* Card Hover Effect */
.card-hover {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card-hover:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

/* Gradient Text */
.gradient-text {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Section Padding */
.section-padding {
    padding: 5rem 0;
}

/* Loading Spinner */
.spinner {
    border: 3px solid #f3f3f3;
    border-top: 3px solid var(--primary-color);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive Images */
img {
    max-width: 100%;
    height: auto;
}

/* Focus States */
input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.1);
}

/* Transitions */
a, button {
    transition: all 0.3s ease;
}

/* Print Styles */
@media print {
    .no-print {
        display: none;
    }
}

/* Navigation Links */
.nav-link {
    position: relative;
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: var(--primary-color);
}

.nav-link.active {
    color: var(--primary-color);
}

/* Line clamp utility */
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.line-clamp-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.line-clamp-4 {
    display: -webkit-box;
    -webkit-line-clamp: 4;
    line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Treatment card animations */
.group:hover .group-hover\:scale-105 {
    transform: scale(1.05);
}

.group:hover .group-hover\:translate-x-1 {
    transform: translateX(0.25rem);
}

.group:hover .group-hover\:bg-opacity-20 {
    background-color: rgba(0, 0, 0, 0.2);
}

/* Blog Detail Typography */
#post-content {
    font-size: 1.125rem;
    line-height: 1.75;
    color: #374151;
    max-width: 100%;
}

#post-content p {
    margin: 1.5rem 0;
    font-size: 1.125rem;
    line-height: 1.75;
    color: #374151;
}

#post-content h1,
#post-content h2,
#post-content h3,
#post-content h4,
#post-content h5,
#post-content h6 {
    font-weight: 700;
    color: #111827;
    margin-top: 2rem;
    margin-bottom: 1rem;
    line-height: 1.3;
    scroll-margin-top: 5rem; /* TOC scroll offset */
}

#post-content h1 {
    font-size: 2.5rem;
    margin-top: 3rem;
    margin-bottom: 1.5rem;
}

#post-content h2 {
    font-size: 2rem;
    margin-top: 2.5rem;
    margin-bottom: 1.25rem;
    border-bottom: 2px solid #e5e7eb;
    padding-bottom: 0.5rem;
}

#post-content h3 {
    font-size: 1.5rem;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

#post-content h4 {
    font-size: 1.25rem;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

#post-content h5 {
    font-size: 1.125rem;
    margin-top: 1.25rem;
    margin-bottom: 0.5rem;
}

#post-content h6 {
    font-size: 1rem;
    margin-top: 1rem;
    margin-bottom: 0.5rem;
}

#post-content a {
    color: #2563eb;
    text-decoration: underline;
    transition: color 0.2s ease;
}

#post-content a:hover {
    color: #1d4ed8;
    text-decoration: none;
}

#post-content ul,
#post-content ol {
    margin: 1.5rem 0;
    padding-left: 2rem;
}

#post-content ul {
    list-style-type: disc;
}

#post-content ol {
    list-style-type: decimal;
}

#post-content li {
    margin: 0.5rem 0;
    line-height: 1.75;
}

#post-content li > ul,
#post-content li > ol {
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
}

#post-content blockquote {
    border-left: 4px solid #3b82f6;
    padding: 1rem 1.5rem;
    margin: 2rem 0;
    background: #f0f9ff;
    color: #1e293b;
    font-style: italic;
    border-radius: 0.375rem;
}

#post-content blockquote p {
    margin: 0;
}

#post-content img {
    max-width: 100%;
    height: auto;
    border-radius: 0.5rem;
    margin: 2rem 0;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

#post-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 2rem 0;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
    border-radius: 0.5rem;
    overflow: hidden;
}

#post-content table th {
    background: #f9fafb;
    font-weight: 600;
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 2px solid #e5e7eb;
}

#post-content table td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #e5e7eb;
}

#post-content table tr:last-child td {
    border-bottom: none;
}

#post-content table tr:hover {
    background: #f9fafb;
}

#post-content code {
    background: #f3f4f6;
    padding: 0.125rem 0.375rem;
    border-radius: 0.25rem;
    font-size: 0.9em;
    font-family: 'Courier New', monospace;
    color: #dc2626;
}

#post-content pre {
    background: #1f2937;
    color: #f9fafb;
    padding: 1.5rem;
    border-radius: 0.5rem;
    overflow-x: auto;
    margin: 2rem 0;
}

#post-content pre code {
    background: transparent;
    color: inherit;
    padding: 0;
}

#post-content hr {
    border: none;
    border-top: 2px solid #e5e7eb;
    margin: 3rem 0;
}

#post-content strong {
    font-weight: 700;
    color: #111827;
}

#post-content em {
    font-style: italic;
}

#post-content mark {
    background: #fef08a;
    padding: 0.125rem 0.25rem;
    border-radius: 0.125rem;
}

#post-content figure {
    margin: 2rem 0;
    max-width: 100%;
}

#post-content figure img {
    margin: 0;
    width: 100%;
    border-radius: 0.5rem;
}

#post-content figure.rich-editor-figure-align-left {
    float: left;
    margin-right: 1rem;
    max-width: 50%;
}

#post-content figure.rich-editor-figure-align-right {
    float: right;
    margin-left: 1rem;
    max-width: 50%;
}

#post-content figure.rich-editor-figure-align-center {
    margin-left: auto;
    margin-right: auto;
    max-width: 80%;
}

#post-content figcaption,
#post-content .rich-editor-figcaption {
    text-align: center;
    font-size: 0.875rem;
    color: #6b7280;
    margin-top: 0.5rem;
    font-style: italic;
    line-height: 1.5;
}

/* Service Content Typography - Blog ile aynı stil */
.service-content-typography {
    font-size: 1.125rem;
    line-height: 1.75;
    color: #374151;
    max-width: 100%;
}

.service-content-typography p {
    margin: 1.5rem 0;
    font-size: 1.125rem;
    line-height: 1.75;
    color: #374151;
}

.service-content-typography h1,
.service-content-typography h2,
.service-content-typography h3,
.service-content-typography h4,
.service-content-typography h5,
.service-content-typography h6 {
    font-weight: 700;
    color: #111827;
    margin-top: 2rem;
    margin-bottom: 1rem;
    line-height: 1.3;
}

.service-content-typography h1 {
    font-size: 2.5rem;
    margin-top: 3rem;
    margin-bottom: 1.5rem;
}

.service-content-typography h2 {
    font-size: 2rem;
    margin-top: 2.5rem;
    margin-bottom: 1.25rem;
}

.service-content-typography h3 {
    font-size: 1.5rem;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.service-content-typography h4 {
    font-size: 1.25rem;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

.service-content-typography h5 {
    font-size: 1.125rem;
    margin-top: 1.25rem;
    margin-bottom: 0.5rem;
}

.service-content-typography h6 {
    font-size: 1rem;
    margin-top: 1rem;
    margin-bottom: 0.5rem;
}

.service-content-typography a {
    color: #2563eb;
    text-decoration: underline;
    transition: color 0.2s ease;
}

.service-content-typography a:hover {
    color: #1d4ed8;
    text-decoration: none;
}

.service-content-typography ul,
.service-content-typography ol {
    margin: 1.5rem 0;
    padding-left: 2rem;
}

.service-content-typography ul {
    list-style-type: disc;
}

.service-content-typography ol {
    list-style-type: decimal;
}

.service-content-typography li {
    margin: 0.5rem 0;
    line-height: 1.75;
}

.service-content-typography li > ul,
.service-content-typography li > ol {
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
}

.service-content-typography blockquote {
    border-left: 4px solid #3b82f6;
    padding: 1rem 1.5rem;
    margin: 2rem 0;
    background: #f0f9ff;
    color: #1e293b;
    font-style: italic;
    border-radius: 0.375rem;
}

.service-content-typography blockquote p {
    margin: 0;
}

.service-content-typography img {
    max-width: 100%;
    height: auto;
    border-radius: 0.5rem;
    margin: 2rem 0;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.service-content-typography table {
    width: 100%;
    border-collapse: collapse;
    margin: 2rem 0;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
    border-radius: 0.5rem;
    overflow: hidden;
}

.service-content-typography table th {
    background: #f9fafb;
    font-weight: 600;
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 2px solid #e5e7eb;
}

.service-content-typography table td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #e5e7eb;
}

.service-content-typography table tr:last-child td {
    border-bottom: none;
}

.service-content-typography table tr:hover {
    background: #f9fafb;
}

.service-content-typography code {
    background: #f3f4f6;
    padding: 0.125rem 0.375rem;
    border-radius: 0.25rem;
    font-size: 0.9em;
    font-family: 'Courier New', monospace;
    color: #dc2626;
}

.service-content-typography pre {
    background: #1f2937;
    color: #f9fafb;
    padding: 1.5rem;
    border-radius: 0.5rem;
    overflow-x: auto;
    margin: 2rem 0;
}

.service-content-typography pre code {
    background: transparent;
    color: inherit;
    padding: 0;
}

.service-content-typography hr {
    border: none;
    border-top: 2px solid #e5e7eb;
    margin: 3rem 0;
}

.service-content-typography strong,
.service-content-typography b {
    font-weight: 700;
    color: #111827;
}

.service-content-typography em,
.service-content-typography i {
    font-style: italic;
}

.service-content-typography mark {
    background: #fef08a;
    padding: 0.125rem 0.25rem;
    border-radius: 0.125rem;
}

.service-content-typography figure {
    margin: 2rem 0;
    max-width: 100%;
}

.service-content-typography figure img {
    margin: 0;
    width: 100%;
    border-radius: 0.5rem;
}

.service-content-typography figure.rich-editor-figure-align-left {
    float: left;
    margin-right: 1rem;
    max-width: 50%;
}

.service-content-typography figure.rich-editor-figure-align-right {
    float: right;
    margin-left: 1rem;
    max-width: 50%;
}

.service-content-typography figure.rich-editor-figure-align-center {
    margin-left: auto;
    margin-right: auto;
    max-width: 80%;
}

.service-content-typography figcaption,
.service-content-typography .rich-editor-figcaption {
    text-align: center;
    font-size: 0.875rem;
    color: #6b7280;
    margin-top: 0.5rem;
    font-style: italic;
    line-height: 1.5;
}

/* Table of Contents Styling */
#article-toc-list li,
#service-toc-list li {
    padding: 0.125rem 0;
    line-height: 1.5;
}

#article-toc-list li a,
#service-toc-list li a {
    display: block;
    padding: 0.375rem 0.5rem;
    border-radius: 0.375rem;
    transition: background-color 0.2s ease;
    font-size: 0.9375rem;
}

#article-toc-list li a:hover,
#service-toc-list li a:hover {
    background-color: #e5e7eb;
}

/* Responsive */
@media (max-width: 768px) {
    .section-padding {
        padding: 3rem 0;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.75rem;
    }
}

/* ============================================
   Chatbot Widget Styles
   ============================================ */

#chatbotWidget {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

#chatbotMessages {
    font-size: 0.875rem; /* 14px */
}

#chatbotMessages::-webkit-scrollbar {
    width: 6px;
}

#chatbotMessages::-webkit-scrollbar-track {
    background: #f1f1f1;
}

#chatbotMessages::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 3px;
}

#chatbotMessages::-webkit-scrollbar-thumb:hover {
    background: #555;
}

.chatbot-message {
    margin-bottom: 1rem;
    display: flex;
    align-items: flex-start;
    min-height: auto;
    clear: both;
}

.chatbot-message.user {
    justify-content: flex-end;
}

.chatbot-message .message-bubble {
    max-width: 80%;
    padding: 0.75rem 1rem;
    border-radius: 0.875rem;
    word-wrap: break-word;
    word-break: break-word;
    overflow-wrap: break-word;
    line-height: 1.6;
    font-size: 0.875rem; /* 14px */
    display: inline-block;
    position: relative;
}

.chatbot-message .message-bubble p {
    margin-bottom: 0.375rem !important;
    font-size: 0.875rem !important;
    line-height: 1.6 !important;
    word-wrap: break-word !important;
    word-break: break-word !important;
    color: #374151 !important;
}

.chatbot-message .message-bubble p:last-child {
    margin-bottom: 0 !important;
}

.chatbot-message .message-bubble strong {
    font-weight: 600 !important;
    color: #111827 !important;
}

.chatbot-message .message-bubble br {
    margin-bottom: 0.25rem !important;
    display: block !important;
    content: "" !important;
}

.chatbot-message .message-bubble a {
    word-break: break-all;
    font-size: 0.875rem;
}

.chatbot-message .message-bubble ul {
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
    padding-left: 1.25rem;
    font-size: 0.875rem;
}

.chatbot-message .message-bubble li {
    margin-bottom: 0.25rem;
    font-size: 0.875rem;
    line-height: 1.6;
}

.chatbot-message.user .message-bubble {
    background: #3b82f6;
    color: white;
    border-bottom-right-radius: 0.25rem;
    font-size: 0.875rem;
}

.chatbot-message.bot .message-bubble {
    background: #e5e7eb;
    color: #1f2937;
    border-bottom-left-radius: 0.25rem;
    font-size: 0.875rem;
    position: relative;
}

.chatbot-typing {
    background: #e5e7eb !important;
    padding: 0.75rem 1rem !important;
}

.typing-dots {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 4px 0;
}

.typing-dots span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: #6b7280;
    display: inline-block;
    animation: typing-animation 1.4s infinite ease-in-out;
}

.typing-dots span:nth-child(1) {
    animation-delay: -0.32s;
}

.typing-dots span:nth-child(2) {
    animation-delay: -0.16s;
}

.typing-dots span:nth-child(3) {
    animation-delay: 0;
}

@keyframes typing-animation {
    0%, 80%, 100% {
        transform: scale(0.8);
        opacity: 0.5;
    }
    40% {
        transform: scale(1);
        opacity: 1;
    }
}

.chatbot-message.bot .bot-logo {
    position: absolute;
    top: -20px;
    left: 10px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #e5e7eb;
    background-color: white;
    z-index: 1;
}

