/* Primary Colors */
:root {
    --primary: #406E4A;          /* สีหลัก - เขียว */
    --primary-dark: #2C4D34;     /* สีหลักเข้ม */
    --primary-light: #588662;    /* สีหลักอ่อน */
    --complement: #6E404A;       /* สี complement - แดงอมม่วง */
    --neutral-dark: #2c3e50;     /* สีเทาเข้ม */
    --neutral-light: #f8f9fa;    /* สีเทาอ่อน */
}

/* Base Styles */
body {
    font-family: 'Prompt', sans-serif;
    font-weight: 300;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Prompt', sans-serif;
    font-weight: 500;
}

/* Navbar Styles */
.navbar {
    background-color: var(--primary-dark) !important;
    box-shadow: 0 2px 4px rgba(0,0,0,.1);
}

.navbar-brand {
    display: flex;
    align-items: center;
}

.navbar-brand img {
    height: 40px;
    margin-right: 10px;
}

.navbar-brand span {
    font-weight: 500;
    color: #fff;
}

.navbar-dark .navbar-nav .nav-link {
    color: rgba(255,255,255,.9);
}

.navbar-dark .navbar-nav .nav-link:hover {
    color: #fff;
}

.faculty-name {
    display: flex;
    flex-direction: column;
    line-height: 1;  /* ปรับ line-height ให้ข้อความชิดกัน */
}

.university-name {
    font-size: 0.6em;  /* ปรับขนาดตัวอักษรให้เล็กลง */
    margin-top: 2px;   /* ระยะห่างระหว่างบรรทัด */
}

/* Dropdown Styles */
.dropdown-menu {
    border: none;
    box-shadow: 0 2px 10px rgba(0,0,0,.1);
}

.dropdown-item {
    display: flex;
    align-items: center;
    padding: 0.5rem 1rem;
}

.dropdown-item:hover,
.dropdown-item:focus {
    background-color: var(--neutral-light);
    color: var(--primary);
}

.dropdown-item.active {
    background-color: var(--neutral-light);
    color: var(--primary);
}

/* Hero Section & Carousel */
.hero-banner {
    background-size: cover;
    height: 500px;
    color: white;
    text-align: center;
    display: flex;
    justify-content: center;
    align-items: center;
}

.carousel-item {
    height: 500px;
}

.carousel-item img {
    object-fit: cover;
    height: 100%;
    width: 100%;
}
/* 
.carousel-caption {
    background-color: var(--complement); 
    border-radius: 10px;
    padding: 20px;
}

.carousel-caption h1 {
    color: white;
    font-weight: 600;
}

.carousel-caption p {
    color: rgba(255, 255, 255, 0.9);
} */

/* ปรับส่วน Carousel Caption */
.carousel-caption {
    background: linear-gradient(to top,
        rgba(64, 110, 74, 0.9) 0%,
        rgba(64, 110, 74, 0.7) 50%,
        rgba(64, 110, 74, 0) 100%
    );
    
    border-radius: 0;  /* ลบ border-radius เดิมออก */
    padding: 40px 20px 20px 20px;  /* เพิ่ม padding ด้านบนให้มากขึ้น */
    left: 0;
    right: 0;
    bottom: 0;
    background-size: 100% 200px;  /* ปรับความสูงของ gradient */
}



.carousel-caption h1 {
    color: white;
    font-weight: 600;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);  /* เพิ่ม text shadow */
}

.carousel-caption p {
    color: rgba(255, 255, 255, 0.95);
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);  /* เพิ่ม text shadow */
}

.carousel-indicators button {
    background-color: var(--primary) !important;
    opacity: 0.5;
}

.carousel-indicators button.active {
    opacity: 1;
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
    /* background-color: var(--primary); */
    border-radius: 50%;
    padding: 1.5rem;
}

/* Content Containers & Sections */
.content-container {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.content-container h2 {
    /* color: var(--primary); */
    margin-bottom: 1.5rem;
    font-weight: 500;
}

.content-area {
    flex: 1;
}

/* News Section Styles */
.news-item {
    background-color: #fff;
    border: 1px solid #e9ecef;
    border-radius: 10px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    margin-bottom: 20px;
    padding: 15px;
}

.news-item:hover {
    box-shadow: 0 5px 15px rgba(64, 110, 74, 0.15);
    border-color: var(--primary-light);
}

.news-item h5 {
    color: var(--primary);
    margin: 1rem 0;
}

.news-item img {
    width: 100%;
    height: auto;
    border-radius: 10px 10px 0 0;
}

/* Events Section Styles */
.event-item {
    background-color: #fff;
    border: 1px solid #e9ecef;
    border-radius: 10px;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    display: flex;
    align-items: start;
    gap: 20px;
    padding: 15px;
}

.event-item:hover {
    box-shadow: 0 5px 15px rgba(64, 110, 74, 0.15);
    border-color: var(--primary-light);
}

.event-date {
    min-width: 80px;
    text-align: center;
    background: var(--primary-light);
    color: white;
    padding: 10px;
    border-radius: 8px;
}

.event-date .month {
    font-size: 1.2rem;
    font-weight: bold;
    text-transform: uppercase;
}

.event-date .day {
    font-size: 1.8rem;
    font-weight: bold;
    line-height: 1;
}

.event-content {
    flex: 1;
}

.event-content h5 {
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.hover-shadow {
    transition: all 0.3s ease;
}
.hover-shadow:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

/* Philosophy Section Styles */
.philosophy-box {
    background: linear-gradient(135deg, var(--neutral-light) 0%, #E8F0EA 100%);
    padding: 3rem;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    margin-bottom: 4rem;
}

.philosophy-content {
    max-width: 800px;
    margin: 0 auto;
}

.philosophy-content .lead {
    font-size: 1.8rem;
    color: var(--primary);
    font-weight: 500;
    margin-bottom: 2rem;
}

.philosophy-divider {
    position: relative;
    height: 50px;
    margin: 2rem 0;
}

.philosophy-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: #dee2e6;
}

.divider-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: var(--primary);
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.philosophy-description {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #495057;
    text-align: center;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .philosophy-box {
        padding: 2rem;
    }

    .philosophy-content .lead {
        font-size: 1.5rem;
    }

    .philosophy-description {
        font-size: 1rem;
    }
}

/* Program Box Styles */
.program-box {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.1);
    height: 100%;
    transition: transform 0.3s ease;
}

.program-box:hover {
    transform: translateY(-5px);
}

.program-icon {
    width: 60px;
    height: 60px;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
}

.program-box h3 {
    color: var(--primary);
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.mission-list {
    padding-left: 1.2rem;
    margin: 0;
}

.mission-list li {
    margin-bottom: 0.5rem;
    color: #666;
}

/* Curriculum Structure Styles */
.curriculum-content {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.1);
}

.course-structure h4 {
    color: var(--primary);
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--primary);
}

.course-category {
    margin-bottom: 2rem;
}

.course-category h5 {
    color: #2c3e50;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.course-category ul {
    list-style: none;
    padding-left: 1.5rem;
}

.course-category li {
    display: flex;
    justify-content: space-between;
    color: #666;
    margin-bottom: 0.5rem;
}

/* Program Info Box */
.program-info-box {
    background: #f8f9fa;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.1);
}

.program-info-box h4 {
    color: var(--primary);
    margin-bottom: 1.5rem;
}

.program-info-box ul {
    list-style: none;
    padding: 0;
}

.program-info-box li {
    margin-bottom: 1rem;
    color: #666;
}

.program-info-box i {
    color: var(--primary);
    margin-right: 10px;
    width: 20px;
}

/* Responsive */
@media (max-width: 991px) {
    .program-info-box {
        margin-top: 2rem;
    }
}

/* Button Styles */
.btn-primary {
    background-color: var(--primary);
    border-color: var(--primary);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    border-color: var(--primary-dark);
}

.btn-outline-primary {
    color: var(--primary);
    border-color: var(--primary);
}

.btn-outline-primary:hover {
    background-color: var(--primary);
    border-color: var(--primary);
    color: white;
}

/* Partner Logo Styles */
.img-fluid {
    transition: transform 0.3s ease;
    filter: grayscale(100%);
    opacity: 0.7;
}

.img-fluid:hover {
    transform: scale(1.05);
    filter: grayscale(0%);
    opacity: 1;
}

/* Footer Styles
footer {
    background-color: var(--primary-dark) !important;
    font-weight: 300;
}

footer h5 {
    font-weight: 500;
    color: #fff;
    opacity: 0.95;
}

footer p {
    color: rgba(255,255,255,.9);
} */

/* Footer Styles */
footer.bg-dark {
    background-color: var(--primary) !important;
}

footer .social-icons a {
    color: white !important;
    opacity: 0.9;
    transition: opacity 0.3s ease;
}

footer .social-icons a:hover {
    opacity: 1;
    color: white !important;
}

footer .footer-links a {
    color: rgba(255,255,255,.9);
    transition: color 0.3s ease;
}

footer .footer-links a:hover {
    color: #fff;
}

footer hr.bg-light {
    opacity: 0.1;
}

/* Footer headings */
footer h5 {
    color: #fff;
    opacity: 0.95;
}

/* Footer text */
footer p {
    color: rgba(255,255,255,.9);
}

.social-icons {
    display: flex;
    gap: 10px;
}

.social-icon {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    transition: transform 0.3s ease;
}

.social-icon:hover {
    transform: translateY(-2px);
    color: white;
}

.social-icon.facebook {
    background-color: var(--primary);
}

.social-icon.instagram {
    background: linear-gradient(45deg, var(--primary), var(--primary-dark), var(--complement));
}

.footer-links a {
    color: rgba(255,255,255,.9);
    text-decoration: none !important;
    transition: color 0.3s ease;
    display: block;
    padding: 5px 0;
}

.footer-links a:hover {
    color: #fff;
}

footer hr.bg-light {
    opacity: 0.1;
}

/* Responsive Styles */
@media (max-width: 991px) {
    .button-area {
        text-align: center !important;
    }
    
    .mobile-section-gap {
        margin-bottom: 2rem;
    }
    
    .program-info-box {
        margin-top: 2rem;
    }
}

@media (max-width: 767px) {
    .footer-links {
        text-align: center;
    }
    
    .social-icons {
        justify-content: center;
        margin-top: 1rem;
    }

    footer h5 {
        text-align: center;
    }
    
    .philosophy-content .lead {
        font-size: 1.5rem;
    }
    
    .philosophy-description {
        font-size: 1rem;
    }
}

@media (max-width: 576px) {
    .navbar-brand span {
        display: none;
    }
    
    .philosophy-box {
        padding: 2rem;
    }
    
    .program-box {
        padding: 1.5rem;
    }
}

/* Hero Section Styles */
.hero-section {
    margin-bottom: 3rem;
}

.hero-image {
    position: relative;
    height: 400px;
    overflow: hidden;
}

.hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-image .overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(rgba(0,0,0,0.3), rgba(0,0,0,0.6));
}

.hero-content {
    position: absolute;
    bottom: 50px;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    z-index: 2;
}

.hero-content h1 {
    font-size: 2.5rem;
    font-weight: 600;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

/* Breadcrumb Styles */
.breadcrumb {
    background: transparent;
    padding: 0;
    margin: 0;
}

.breadcrumb-item a {
    color: #fff;
    text-decoration: none;
    transition: color 0.3s ease;
}

.breadcrumb-item a:hover {
    color: #ddd;
}

.breadcrumb-item.active {
    color: #ddd;
}

.breadcrumb-item+.breadcrumb-item::before {
    color: #fff;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .hero-image {
        height: 300px;
    }
    
    .hero-content {
        bottom: 30px;
    }
    
    .hero-content h1 {
        font-size: 2rem;
    }
}

@media (max-width: 576px) {
    .hero-image {
        height: 250px;
    }
    
    .hero-content h1 {
        font-size: 1.5rem;
    }
}

/* Timeline Styles */
.timeline {
    position: relative;
    padding: 20px 0;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 50px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--primary);
}

.timeline-item {
    position: relative;
    margin-bottom: 40px;
    padding-left: 120px;
}

.timeline-item .year {
    position: absolute;
    left: 0;
    top: 0;
    width: 100px;
    padding: 8px 15px;
    background: var(--primary);
    color: white;
    font-weight: bold;
    text-align: center;
    border-radius: 4px;
}

.timeline-item .content {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.timeline-item .content h5 {
    color: var(--primary);
    margin-bottom: 10px;
}

.timeline-item .content p {
    margin-bottom: 10px;
}

.timeline-item .content ul {
    padding-left: 20px;
}

/* Responsive Timeline */
@media (max-width: 576px) {
    .timeline::before {
        left: 30px;
    }
    
    .timeline-item {
        padding-left: 70px;
    }
    
    .timeline-item .year {
        width: 60px;
        padding: 5px;
        font-size: 14px;
    }
}

/* Vision & Mission Styles */
.section-title {
    color: var(--primary);
    font-weight: 600;
    margin-bottom: 2rem;
    position: relative;
    padding-bottom: 1rem;
}

.section-title::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 50px;
    height: 3px;
    background: var(--primary);
}

.vision-content {
    padding: 2rem;
    background: #f8f9fa;
    border-radius: 10px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.1);
}

.vision-content .lead {
    font-size: 1.2rem;
    line-height: 1.8;
    color: #444;
}

/* Mission Cards */
.mission-card {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.1);
    text-align: center;
    height: 100%;
    transition: transform 0.3s ease;
}

.mission-card:hover {
    transform: translateY(-5px);
}

.mission-icon {
    width: 80px;
    height: 80px;
    line-height: 80px;
    background: var(--primary);
    color: white;
    font-size: 2rem;
    border-radius: 50%;
    margin: 0 auto 1.5rem;
}

.mission-card h4 {
    color: var(--primary);
    margin-bottom: 1rem;
    font-size: 1.25rem;
}

.mission-card p {
    color: #666;
    margin: 0;
    font-size: 0.95rem;
    line-height: 1.6;
}

/* Responsive Styles */
@media (max-width: 991px) {
    .vision-content {
        margin-bottom: 2rem;
    }
}

@media (max-width: 767px) {
    .section-title {
        text-align: center;
    }
    
    .section-title::after {
        left: 50%;
        transform: translateX(-50%);
    }
    
    .mission-card {
        margin-bottom: 1.5rem;
    }
}

/* Organization Chart Styles */
.org-chart {
    text-align: center;
    padding: 20px;
}

.org-box {
    background: white;
    border: 2px solid var(--primary);
    border-radius: 8px;
    padding: 15px;
    margin: 10px;
    display: inline-block;
    min-width: 250px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.org-box .position {
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 5px;
}

.org-box .name {
    font-size: 0.9rem;
    color: #666;
}

/* Levels */
.level-1 {
    margin-bottom: 40px;
}

.level-1::after {
    content: '';
    display: block;
    width: 2px;
    height: 20px;
    background: #1e4d8c;
    margin: 20px auto;
}

.level-2 {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 40px;
    position: relative;
}

.level-2::before {
    content: '';
    position: absolute;
    top: -20px;
    left: 50%;
    width: 80%;
    height: 2px;
    background: #1e4d8c;
    transform: translateX(-50%);
}

.department-title {
    color: #1e4d8c;
    margin: 30px 0;
    text-align: center;
}

.department-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    padding: 20px;
}

/* Administrative Structure */
.admin-box {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.1);
}

.admin-box h4 {
    color: #1e4d8c;
    text-align: center;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #1e4d8c;
}

.admin-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.admin-list li {
    padding: 10px 0;
    border-bottom: 1px solid #dee2e6;
    text-align: center;
}

.admin-list li:last-child {
    border-bottom: none;
}

/* Responsive */
@media (max-width: 768px) {
    .level-2 {
        flex-direction: column;
        align-items: center;
    }

    .level-2::before {
        width: 2px;
        height: 100%;
        top: 0;
    }

    .org-box {
        min-width: 200px;
    }
}

/* External Links Styles */
.external-links h5,
.social-links h5 {
    color: var(--primary);
    margin-bottom: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #dee2e6;
}

.external-links ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.external-links li {
    margin-bottom: 0.8rem;
}

.external-links a {
    color: #495057;
    text-decoration: none;
    display: flex;
    align-items: center;
    transition: color 0.3s ease;
}

.external-links a:hover {
    color: var(--primary-light);
}

.external-links i {
    width: 20px;
    margin-right: 10px;
    color: var(--primary);
}

/* Social Media Buttons */
.social-buttons {
    display: none;
}

/* Hover Effects for Links */
.program-info-box a:not(.btn) {
    position: relative;
    display: inline-block;
}

.program-info-box a:not(.btn)::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 1px;
    bottom: -2px;
    left: 0;
    background-color: #1e4d8c;
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.3s ease;
}

.program-info-box a:not(.btn):hover::after {
    transform: scaleX(1);
    transform-origin: left;
}

/* Responsive Adjustments */
@media (max-width: 576px) {
    .social-buttons {
        flex-direction: column;
    }
    
    .social-buttons .btn {
        width: 100%;
    }
}

