/**
 * Responsive CSS for DY Eng Theme
 * Fixes mobile scrolling and makes theme fully responsive
 */

/* CSS Custom Properties for consistent spacing */
:root {
    --header-height: 60px;
    --header-height-desktop: 96px;
    --container-padding: 20px;
    --vh: 1vh;
}

/* Reset min-widths and fix viewport */
html {
    min-width: auto !important;
    overflow-x: hidden;
    scroll-behavior: smooth;
}

body {
    min-width: auto !important;
    overflow-x: hidden;
    width: 100%;
    margin: 0;
    padding: 0;
}

/* Prevent horizontal scroll */
* {
    box-sizing: border-box;
}

*:before,
*:after {
    box-sizing: border-box;
}

/* Container responsive fixes */
.in_1150 {
    width: 100% !important;
    max-width: 1150px;
    padding: 0;
    box-sizing: border-box;
    margin: 0 auto;
}

/* Header responsive */
#header {
    min-width: auto !important;
    position: relative;
}

/* Mobile navigation visibility */
.h_gnb {
    display: none; /* Hide top navigation on mobile by default */
}

.mobile-menu-toggle {
    display: block; /* Show mobile toggle on mobile by default */
}

/* Navigation area - hidden by default on mobile */
#main_nav_area {
    display: none;
}

#header {
    width: 100%;
    position: fixed;
    top: 0;
    z-index: 1000;
    transition: background-color 0.3s ease;
}

#header.scrolled {
    background: rgba(0,0,0,0.9);
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

/* Top navigation responsive */
.h_gnb {
    display: none; /* Hide on mobile, show on desktop */
}

.menu {
    height: auto;
    min-height: 60px;
    padding: 10px 0;
}

.logo {
    float: none;
    text-align: center;
}

.logo a {
    display: inline-block;
    padding: 10px 0;
}

.logo img {
    max-height: 40px;
    width: auto;
}

/* Main navigation responsive */
#main_nav_area {
    float: none;
    width: 100%;
    text-align: center;
    display: none; /* Hidden by default on mobile */
}

#main_nav_area .main_menu {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    width: 100%;
    justify-content: flex-end;
    align-items: center;
}

#main_nav_area li {
    float: none;
    display: block;
    /* width: 100%; */
    text-align: center;
    margin: 0;
    /* border-bottom: 1px solid rgba(255,255,255,0.1); */
}

#main_nav_area a {
    display: block;
    line-height: 1.4;
    padding: 20px;
    font-size: 18px;
    color: #fff;
    text-decoration: none;
    transition: background-color 0.3s ease;
}

#main_nav_area a:hover {
    background-color: unset;
}

/* Mobile menu toggle button */
.mobile-menu-toggle {
    display: block;
    position: absolute;
    top: 50%;
    right: 20px;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    padding: 10px;
    z-index: 1001;
    width: 40px;
    height: 40px;
}

.mobile-menu-toggle span {
    display: block;
    width: 25px;
    height: 3px;
    background: #fff;
    margin: 5px auto;
    transition: all 0.3s ease;
    transform-origin: center;
}

/* Hide mobile menu by default */
#main_nav_area {
    display: none;
}

/* Hide desktop submenu on mobile/tablet only */
@media screen and (max-width: 1023px) {
    .main_nav_wrap,
    #main_full_menu {
        display: none !important;
    }
}

/* Menu open state */
.menu-open {
    overflow: hidden; /* Prevent background scrolling */
}

.menu-open #main_nav_area {
    display: block;
    position: fixed;
    top: var(--header-height);
    left: 0;
    width: 100%;
    height: calc(100vh - var(--header-height));
    background: rgba(0,0,0,0.95);
    z-index: 1000;
    overflow-y: auto;
    padding: 20px 0;
}

.menu-open .mobile-menu-toggle span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.menu-open .mobile-menu-toggle span:nth-child(2) {
    opacity: 0;
}

.menu-open .mobile-menu-toggle span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
}

/* CEO Greeting Page Responsive Styles */
.wrap_sub {
    width: 100%;
    min-height: 100vh;
}

/* Sub visual responsive */
.sub_visual {
    position: relative;
    height: 200px;
    overflow: hidden;
    margin-bottom: 20px;
}

.sub_visual .bg_vis {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.sub_visual .bg_vis li {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover !important;
    background-position: center !important;
}

.sub_visual p {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    margin: 0;
    font-size: 18px;
    font-weight: bold;
    color: #fff;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.7);
}

/* Tab menu responsive */
.tab_menu {
    background: #f8f8f8;
    border-bottom: 1px solid #ddd;
    padding: 0;
    overflow-x: auto;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
}

.tab_menu .in_1150 {
    padding: 0;
    min-width: 100%;
}

.tab_menu ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: nowrap;
    min-width: 100%;
}

.tab_menu li {
    flex: 1;
    min-width: 120px;
    border-right: 1px solid #ddd;
}

.tab_menu li:last-child {
    border-right: none;
}

.tab_menu a {
    display: block;
    padding: 15px 10px;
    text-align: center;
    font-size: 14px;
    color: #666;
    text-decoration: none;
    transition: all 0.3s ease;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.tab_menu a:hover,
.tab_menu .active a {
    background: #ff6600;
    color: #fff;
}

/* Sub contents responsive */
.sub_contents {
    padding: 20px 0 40px 0;
}

.page_top {
    margin-bottom: 30px;
    text-align: center;
}

.page_top .page_title {
    font-size: 24px;
    font-weight: bold;
    color: #333;
    margin: 0;
    padding: 20px 0;
}

/* Content area responsive */
.page {
    background: #fff;
    padding: 20px;
    margin: 0;
    border-radius: 8px;
    /* box-shadow: 0 2px 10px rgba(0,0,0,0.1); */
}

#ctt {
    margin: 0;
}

#ctt_con {
    padding: 0;
}

/* CEO Greeting block responsive */
.greeting {
    padding: 20px 0;
}

.gret_txt {
    max-width: 100%;
    margin: 0;
    text-align: left;
}

.grett_tit {
    font-size: 20px;
    font-weight: bold;
    line-height: 1.4;
    margin-bottom: 20px;
    color: #333;
    text-align: center;
}

.grett_tit .col_o {
    color: #ff6600;
}

.grett_txt {
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 30px;
    color: #555;
    text-align: left;
}

.grett_dy {
    font-size: 14px;
    font-weight: bold;
    text-align: center;
    margin-top: 30px;
    color: #333;
}

.grett_dy .col_o {
    color: #ff6600;
    display: block;
    font-size: 16px;
    margin-top: 5px;
}

/* Visual section responsive */
.visual {
    margin-top: var(--header-height);
    position: relative;
    width: 100%;
    overflow: hidden;
}

.visual .bg_vis {
    height: 60vh; /* Use viewport height for better mobile experience */
    min-height: 300px;
}

.visual .bg_vis li {
    background-size: cover !important;
    background-position: center center !important;
    background-repeat: no-repeat !important;
}

.vis_left_arrow,
.vis_right_arrow {
    display: none; /* Hide arrows on mobile */
}

.readmore {
    display: none; /* Hide read more button on mobile */
}

/* Fix any potential overflow from background images */
.visual .bg_vis li {
    width: 100% !important;
    max-width: 100% !important;
}

/* Product section responsive */
/* .prod {
    min-height: auto;
    padding: 40px 0;
    background-size: cover;
    background-position: center bottom;
} */

.prod h2 {
    font-size: 28px;
    padding: 20px 0 10px;
}

.prod p {
    font-size: 14px;
    padding: 0 20px;
    margin-bottom: 30px;
}

.prod_ul {
    width: 100%;
    padding: 20px;
    margin: 0;
}

.prod_ul li {
    float: none;
    width: 100%;
    max-width: 300px;
    margin: 0 auto 30px auto;
    box-shadow: 3px 3px 15px rgba(11,3,4,0.2);
}

.prod_img {
    height: 200px;
}

.prod_img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.prod_txt {
    height: 60px;
    line-height: 60px;
    font-size: 16px;
}

.prod_btn {
    display: none; /* Hide product navigation arrows on mobile */
}

/* Main content responsive */
.mcon_wrap {
    padding: 40px 0;
}

.mcon_wrap .in_1150 {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 0 15px;
}

.mcon_wrap .in_1150 > div {
    float: none;
    width: 100%;
    margin: 0;
}

.customer,
.notice {
    float: none;
    width: 100%;
    height: auto;
    padding: 25px 20px;
    margin: 0;
    text-align: left;
    box-sizing: border-box;
}

.customer {
    background-size: cover;
    background-position: center;
}

.customer h2 {
    font-size: 22px;
    margin-bottom: 15px;
    color: #fff;
}

.customer .num {
    font-size: 24px;
    font-weight: bold;
    color: #f0e41d;
    margin: 10px 0;
}

.c_info {
    margin: 15px 0;
}

.c_info li {
    margin: 5px 0;
    font-size: 14px;
    color: #fff;
}

/* YouTube video responsive */
.mcon_wrap iframe {
    float: none !important;
    width: 100% !important;
    max-width: 100%;
    height: auto;
    min-height: 250px;
    margin: 0 !important;
    display: block;
}

/* Button grid responsive */
.mcon_btn {
    float: none;
    width: 100%;
    height: auto;
    padding: 0;
    background: none;
}

.mcon_btn ul {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin: 0;
    padding: 0;
    background: #f12b42;
}

.mcon_btn li {
    width: 100%;
    float: none;
    height: auto;
    background: none;
    border: none;
    margin: 0px !important;
}

.mcon_btn li:after {
    display: none;
}

.mcon_btn a {
    display: block;
    padding: 0px !;
    background: #f12b42;
    color: #fff;
    text-decoration: none;
    text-align: center;
    border-radius: 5px;
    font-size: 14px;
    font-weight: bold;
    transition: background 0.3s;
    height: 120px !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
}

.mcon_btn a:hover {
    background: #d12030;
}

/* Footer responsive */
#footer {
    padding: 30px 0;
    width: 100%;
}

#footer .in_1150 {
    width: 100%;
    padding: 0 15px;
}

.copyright {
    width: 100%;
    padding: 20px 0;
    background: none;
    text-align: center;
}

.copyright .copy p {
    font-size: 11px;
    color: #666;
    line-height: 1.6;
    margin: 8px 0;
    word-break: keep-all;
}

.copyright p.f_copy {
    margin-top: 12px;
    color: #969696;
    font-size: 11px;
    line-height: 1.5;
}

.copyright p.f_copy a {
    color: #969696;
    text-decoration: none;
}

.copyright p.f_copy a.link_barom {
    display: inline-block;
    padding-left: 18px;
    background: url(../images_en/barom.png) no-repeat left center;
    background-size: 14px;
    margin-left: 2px;
}

/* Form elements responsive */
input, textarea, select {
    max-width: 100%;
    box-sizing: border-box;
}

/* Images responsive */
img {
    max-width: 100%;
    height: auto;
}

/* Tables responsive */
table {
    width: 100%;
    overflow-x: auto;
    display: block;
    white-space: nowrap;
}

table tbody {
    display: table;
    width: 100%;
}

/* Utility classes for mobile */
.mobile-hide {
    display: none;
}

.mobile-show {
    display: block;
}

/* Prevent any wide content from causing horizontal scroll */
.prod_ul,
.mcon_wrap,
.main_contents,
.visual,
#header,
#footer {
    max-width: 100%;
}

/* Fix any absolutely positioned elements that might overflow */
.prod_btn .prod_arrl,
.prod_btn .prod_arrr {
    display: none;
}

/* Ensure all content respects container width */
div, section, article, aside, nav, header, footer, main {
    max-width: 100%;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* Fix for long URLs or text that might cause overflow */
a, p, span, div {
    word-break: break-word;
    hyphens: auto;
}

/* Responsive typography scale */
@media screen and (max-width: 480px) {
    html {
        font-size: 14px;
    }
    
    body {
        font-size: 14px;
        line-height: 1.5;
    }
}

/* Tablet styles */
@media screen and (min-width: 768px) and (max-width: 1023px) {
    .in_1150 {
        padding: 0 30px;
    }
    
    .visual .bg_vis {
        height: 400px;
    }
    
    .prod h2 {
        font-size: 36px;
    }
    
    .prod_ul li {
        width: 45%;
        float: left;
        margin: 0 2.5% 30px 2.5%;
    }
    
    .mcon_wrap .in_1150 {
        flex-direction: column;
        gap: 20px;
    }
    
    .mcon_wrap .in_1150 > div {
        width: 100%;
        margin: 0;
    }
    
    .customer,
    .notice {
        width: 100%;
        margin: 0;
    }
    
    .mcon_btn ul {
        grid-template-columns: repeat(4, 1fr);
        gap: 15px;
    }
    
    /* Footer tablet styles */
    .copyright .copy p {
        font-size: 13px;
    }
    
    .copyright p.f_copy {
        font-size: 12px;
    }
}

/* Tablet styles for CEO Greeting */
@media screen and (min-width: 768px) and (max-width: 1023px) {
    .sub_visual {
        height: 250px;
    }
    
    .sub_visual p {
        font-size: 20px;
        bottom: 30px;
    }
    
    .tab_menu {
        overflow-x: visible;
    }
    
    .tab_menu ul {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .tab_menu li {
        min-width: 150px;
        flex: none;
    }
    
    .tab_menu a {
        padding: 18px 15px;
        font-size: 15px;
    }
    
    .page_top .page_title {
        font-size: 28px;
    }
    
    .page {
        padding: 30px;
        margin: 0 20px;
    }
    
    .greeting {
        padding: 30px 0;
    }
    
    .gret_txt {
        max-width: 700px;
        margin: 0 auto;
    }
    
    .grett_tit {
        font-size: 24px;
        margin-bottom: 25px;
    }
    
    .grett_txt {
        font-size: 15px;
        line-height: 1.7;
        margin-bottom: 35px;
        text-align: justify;
    }
    
    .grett_dy {
        font-size: 16px;
        text-align: right;
        margin-top: 40px;
    }
    
    .grett_dy .col_o {
        font-size: 18px;
        display: inline;
        margin-top: 0;
    }
}

/* ========================================== */
/* Bootstrap Mobile Navbar Styles */
/* ========================================== */

/* Mobile navbar styles for screens under 1024px */
@media screen and (max-width: 1023px) {
    /* Show navbar toggler on mobile */
    .navbar-toggler {
        display: block !important;
        border: none;
        padding: 0.25rem 0.5rem;
        background: transparent;
        border-radius: 0.25rem;
    }
    
    .navbar-toggler:focus {
        box-shadow: none;
        outline: none;
    }
    
    .navbar-toggler-icon {
        background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 1%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
        width: 1.5em;
        height: 1.5em;
    }
    
    /* Hide navbar collapse by default on mobile */
    .navbar-collapse {
        display: none !important;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(0,0,0,0.95);
        padding: 1rem;
        z-index: 1000;
    }
    
    /* Show navbar collapse when toggled */
    .navbar-collapse.show {
        display: block !important;
    }
    
    /* Mobile menu items styling */
    .navbar-nav {
        flex-direction: column !important;
        width: 100%;
    }
    
    .navbar-nav .nav-item {
        width: 100%;
        margin-bottom: 0.5rem;
        border-bottom: 1px solid rgba(255,255,255,0.1);
    }
    
    .navbar-nav .nav-link {
        color: #fff !important;
        padding: 1rem 0 !important;
        font-size: 16px !important;
        line-height: normal !important;
        width: 100% !important;
        text-align: left !important;
        border-bottom: none;
    }
    
    .navbar-nav .nav-link:hover {
        background: rgba(255,255,255,0.1);
        color: #fe830b !important;
    }
    
    /* Mobile submenu dropdown styles */
    .mobile-arrow {
        font-size: 12px;
        margin-left: 5px;
        transition: transform 0.3s ease;
    }
    
    .mobile-submenu {
        display: none;
        background: rgba(0,0,0,0.9);
        padding: 0;
        margin: 0;
        border-top: 1px solid rgba(255,255,255,0.1);
        overflow: hidden;
        max-height: 0;
        transition: max-height 0.3s ease-in-out;
    }
    
    .mobile-submenu.show {
        display: block;
        max-height: 300px;
    }
    
    .mobile-submenu-list {
        list-style: none;
        padding: 0;
        margin: 0;
    }
    
    .mobile-submenu-list li {
        border-bottom: 1px solid rgba(255,255,255,0.05);
    }
    
    .mobile-submenu-list li:last-child {
        border-bottom: none;
    }
    
    .mobile-submenu-link {
        display: block;
        padding: 0.8rem 1.5rem;
        color: rgba(255,255,255,0.8) !important;
        text-decoration: none;
        font-size: 14px;
        transition: all 0.3s ease;
        border-left: 3px solid transparent;
    }
    
    .mobile-submenu-link:hover {
        background: rgba(254, 131, 11, 0.1);
        color: #fe830b !important;
        border-left-color: #fe830b;
        padding-left: 2rem;
    }
    
    /* Hide desktop submenu on mobile */
    .main_nav_wrap {
        display: none !important;
    }
    
    /* Adjust header height for mobile */
    .navbar {
        min-height: 60px;
        padding: 0.5rem 0;
    }
    
    .navbar-brand img {
        max-height: 40px;
    }
}

/* Desktop styles 1024px+ */
@media screen and (min-width: 1024px) {
    :root {
        --header-height: var(--header-height-desktop);
    }
    
    /* Show top navigation on desktop */
    .h_gnb {
        display: block;
    }
    
    /* Hide Bootstrap navbar toggler on desktop */
    .navbar-toggler {
        display: none !important;
    }
    
    /* Show main navigation on desktop */
    .navbar-collapse {
        display: flex !important;
        position: relative !important;
        flex-basis: auto;
        width: auto;
        text-align: left;
        height: auto !important;
        background: transparent !important;
        padding: 0 !important;
    }
    
    /* Show desktop submenu */
    .main_nav_wrap {
        display: block !important;
        position: absolute;
        top: 96px;
        left: 0;
        width: 100%;
        z-index: 999;
        background: transparent;
        height: 270px;
        pointer-events: auto;
    }

    .navbar-nav {
        flex-direction: row !important;
    }

    .navbar-nav .nav-item {
        float: left;
        display: block;
        width: auto;
    }

    .navbar-nav .nav-link {
        line-height: var(--header-height-desktop);
        font-size: 20.5px !important;
        padding: 0 0px !important;
        border-bottom: none;
        color: #fff !important;
        width: 175px;
        text-align: left;
    }

    /* Menu hover states */
    .navbar-nav .nav-item:hover {
        background: rgba(255,255,255,0.1);
    }

    .navbar-nav .nav-link:hover {
        color: #fe830b !important;
    }    /* Hover-based submenu display is disabled.
       Submenu visibility is controlled exclusively via JavaScript
       when hovering the main menu link anchors. */
    .navbar:hover .main_nav_wrap {
        pointer-events: auto;
    }

    .navbar-brand {
        float: left;
        text-align: left;
    }

    .navbar-brand img {
        max-height: none;
    }

    .navbar {
        height: var(--header-height-desktop);
        padding: 0;
        min-height: auto;
    }
    
    /* Desktop submenu hover functionality */
    .main_nav_wrap {
        display: block !important;
        position: absolute;
        top: 96px;
        left: 0;
        width: 100%;
        z-index: 999;
        background: transparent;
        height: 270px; /* Ensure hover area has height */
        pointer-events: auto;
    }
    
    #main_full_menu {
        display: none;
        position: static;
        width: 100%;
        background: rgba(255,255,255,0.98);
        box-shadow: 0 4px 20px rgba(0,0,0,0.1);
        height: 270px;
        overflow: hidden;
    }
    
    /* Visual feedback for menu items */
    .navbar-nav .nav-item:hover,
    .navbar-nav .nav-link:hover {
        background: rgba(255,255,255,0.1);
        color: #fe830b !important;
    }

    /* JavaScript controlled display - Enhanced */
    .menu-item-hover #main_full_menu {
        display: block !important;
        opacity: 1 !important;
        visibility: visible !important;
        height: 270px !important;
    }
    
    /* Override original jQuery animation */
    #main_full_menu {
        transition: none !important;
        animation: none !important;
    }
    
    /* Only allow submenu to be controlled by JavaScript */
    /* Removed CSS hover triggers to prevent unwanted opening */    /* Add hover bridge to prevent menu from closing */
    /* Remove hover bridge so submenu doesn't show when mouse reaches below nav */
    .main_nav_wrap::before { display: none; }
    
    .visual {
        margin-top: 0;
    }
    
    .visual .bg_vis {
        height: 723px;
    }
    
    .vis_left_arrow,
    .vis_right_arrow {
        display: block;
    }
    
    .readmore {
        display: block;
    }
    
    /* .prod {
        min-height: 735px;
        padding: 0;
    } */
    
    .prod h2 {
        font-size: 41px;
        padding: 60px 0 5px;
    }
    
    .prod p {
        font-size: 16px;
        padding: 0;
    }
    
    .prod_ul {
        width: 1200px;
        padding: 65px 0 0;
        margin: 0 auto;
    }
    
    .prod_ul li {
        float: left;
        width: 345px;
        margin-right: 58px;
        margin-bottom: 0;
    }
    
    .prod_ul li:last-child {
        margin-right: 0;
    }
    
    .prod_btn {
        display: block;
    }
    
    .prod_btn .prod_arrl,
    .prod_btn .prod_arrr {
        display: block;
    }
    
    .prod_img {
        height: 339px;
    }
    
    .prod_txt {
        height: 100px;
        line-height: 100px;
        font-size: 23.5px;
    }
    
    .mcon_wrap {
        padding: 74px 0 75px;
    }
    
    .mcon_wrap .in_1150 {
        flex-direction: row;
        /* display: block; */
    }
    
    .customer,
    .notice {
        float: left;
        width: 334px;
        padding: 20px;
        text-align: left;
    }
    
    .mobile-hide {
        display: block;
    }
    
    .mobile-show {
        display: none;
    }
    
    /* Footer desktop styles */
    .copyright {
        padding: 55px 0 60px 268px;
        background: url(../images_en/foot_logo.png) 1px 72px no-repeat;
        text-align: left;
    }
    
    .copyright .copy p {
        font-size: 14px;
        line-height: 20px;
    }
    
    .copyright p.f_copy {
        font-size: 13.5px;
    }
    
    .copyright p.f_copy a.link_barom {
        background-position: left 4px;
        background-size: auto;
    }
}

/* Desktop styles 1024px+ */
@media screen and (min-width: 1024px) {
    /* CEO Greeting Page Desktop Styles */
    .wrap_sub {
        padding-top: 0px;
    }
    
    .sub_visual {
        height: 300px;
        margin-bottom: 0;
    }
    
    .sub_visual p {
        font-size: 24px;
        bottom: 50px;
    }
    
    .tab_menu {
        background: #f8f8f8;
        overflow: visible;
        white-space: normal;
    }
    
    .tab_menu ul {
        justify-content: center;
        flex-wrap: nowrap;
    }
    
    .tab_menu li {
        min-width: 180px;
        flex: none;
    }
    
    .tab_menu a {
        padding: 20px 25px;
        font-size: 16px;
        white-space: normal;
    }
    
    .sub_contents {
        padding: 50px 0 80px 0;
    }
    
    .page_top .page_title {
        font-size: 32px;
        padding: 30px 0;
    }
    
    .page {
        padding: 0px;
        margin: 0;
    }
    
    .greeting {
        padding: 50px 0;
    }
    
    .gret_txt {
        max-width: 800px;
        margin: 0 auto;
    }
    
    .grett_tit {
        font-size: 28px;
        line-height: 1.4;
        margin-bottom: 30px;
        text-align: left;
    }
    
    .grett_txt {
        font-size: 16px;
        line-height: 1.8;
        margin-bottom: 40px;
        text-align: justify;
    }
    
    .grett_dy {
        font-size: 18px;
        text-align: right;
        margin-top: 50px;
    }
    
    .grett_dy .col_o {
        font-size: 20px;
        display: inline;
    }
}

/* Large desktop styles */
@media screen and (min-width: 1200px) {
    :root {
        --container-padding: 0;
    }
    
    .in_1150 {
        width: 1150px;
        padding: 0;
    }
    
    #header {
        min-width: 1150px;
    }
}

/* Ultra-wide screens */
@media screen and (min-width: 1400px) {
    .in_1150 {
        max-width: 1200px;
    }
}

/* ========================================== */
/* Product Enquiry Form Styles */
/* ========================================== */
#bo_w {
    max-width: 100%;
    margin: 0 auto;
    padding: 20px;
}

.write_div {
    margin-bottom: 20px;
}

.bo_w_info {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.bo_w_info input {
    flex: 1;
    min-width: 200px;
}

.frm_input {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    background: #fff;
    transition: border-color 0.3s ease;
}

.frm_input:focus {
    outline: none;
    border-color: #ff6600;
    box-shadow: 0 0 5px rgba(255, 102, 0, 0.2);
}

.full_input {
    width: 100%;
}

.wr_content textarea {
    width: 100%;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    font-family: inherit;
    resize: vertical;
    min-height: 200px;
}

.wr_content textarea:focus {
    outline: none;
    border-color: #ff6600;
    box-shadow: 0 0 5px rgba(255, 102, 0, 0.2);
}

.file_wr {
    margin-bottom: 15px;
}

.lb_icon {
    display: inline-block;
    margin-bottom: 5px;
    font-weight: 500;
    color: #333;
}

.lb_icon i {
    margin-right: 5px;
    color: #ff6600;
}

.frm_file {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #fff;
}

.btn_confirm {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 30px;
}

.btn {
    padding: 12px 30px;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-block;
    text-align: center;
}

.btn_submit {
    background: #ff6600;
    color: #fff;
    padding: 0px 15px !important;
}

.btn_submit:hover {
    background: #e55a00;
}

.btn_cancel {
    background: #6c757d;
    color: #fff;
}

.btn_cancel:hover {
    background: #5a6268;
    color: #fff;
    text-decoration: none;
}

/* Checkbox styling */
input[type="checkbox"] {
    width: auto;
    margin-right: 8px;
}

label {
    cursor: pointer;
}

/* Sound only - accessibility */
.sound_only {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

/* Mobile responsive for form */
@media screen and (max-width: 768px) {
    #bo_w {
        padding: 15px;
    }
    
    .bo_w_info {
        flex-direction: column;
        gap: 10px;
    }
    
    .bo_w_info input {
        min-width: auto;
    }
    
    .btn_confirm {
        flex-direction: column;
        gap: 10px;
    }
    
    .btn {
        width: 100%;
        padding: 15px 20px;
    }
    
    .wr_content textarea {
        min-height: 150px;
        padding: 12px;
    }
    
    .frm_input {
        padding: 15px 12px;
        font-size: 16px; /* Prevent zoom on iOS */
    }
}

@media screen and (max-width: 480px) {
    #bo_w {
        padding: 10px;
    }
    
    .write_div {
        margin-bottom: 15px;
    }
    
    .frm_input, .wr_content textarea {
        padding: 12px 10px;
    }
}

/* ========================================== */
/* Product Gallery Styles */
/* ========================================== */
#bo_gall {
    width: 100%;
    margin: 0 auto;
    padding: 20px 0;
}

#bo_btn_top {
    margin-bottom: 20px;
    text-align: right;
}

#bo_list_total {
    font-size: 14px;
    color: #666;
}

.gall_row {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.gall_li {
    position: relative;
    margin-bottom: 20px;
}

.gall_box {
    border: 1px solid #e5e5e5;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s ease;
    background: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.gall_box:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.gall_chk {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0,0,0,0.7);
    color: #fff;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 12px;
    z-index: 2;
}

.gall_con {
    position: relative;
}

.gall_img {
    position: relative;
    width: 100%;
    height: 250px;
    overflow: hidden;
}

.gall_img a {
    display: block;
    width: 100%;
    height: 100%;
}

.gall_img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.gall_box:hover .gall_img img {
    transform: scale(1.05);
}

.gall_text_href {
    padding: 15px 20px;
    background: #fff;
}

.gall_text_href a.bo_tit {
    display: block;
    font-size: 16px;
    font-weight: 500;
    color: #333;
    text-decoration: none;
    line-height: 1.4;
    transition: color 0.3s ease;
}

.gall_text_href a.bo_tit:hover {
    color: #ff6600;
}

/* Grid system classes */
.col-gn-4 {
    width: 100%;
}

/* Search form styles */
#bo_sch {
    margin: 40px 0;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    border: none;
}

#bo_sch legend {
    font-size: 16px;
    font-weight: 500;
    color: #333;
    margin-bottom: 15px;
}

#bo_sch form {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

#bo_sch select,
#bo_sch input[type="text"] {
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

#bo_sch select {
    min-width: 140px;
}

.sch_input {
    flex: 1;
    min-width: 200px;
}

.sch_btn {
    padding: 10px 20px;
    background: #ff6600;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background 0.3s ease;
}

.sch_btn:hover {
    background: #e55a00;
}

/* Pagination styles */
.pg_wrap {
    margin: 30px 0;
    text-align: center;
}

.pg {
    display: inline-flex;
    gap: 5px;
    align-items: center;
}

.pg_current {
    background: #ff6600;
    color: #fff;
    padding: 8px 12px;
    border-radius: 4px;
    font-weight: bold;
    font-size: 14px;
}

.pg_page {
    padding: 8px 12px;
    color: #666;
    text-decoration: none;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    transition: all 0.3s ease;
}

.pg_page:hover {
    background: #f8f9fa;
    color: #333;
}

.pg_end {
    margin-left: 5px;
    background: #6c757d;
    color: #fff;
}

.pg_end:hover {
    background: #5a6268;
    color: #fff;
}

/* No products message */
.no-products {
    text-align: center;
    padding: 60px 20px;
    color: #666;
}

.no-products p {
    font-size: 16px;
    margin: 0;
}

/* Mobile responsive adjustments for gallery */
@media screen and (max-width: 768px) {
    .gall_row {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .gall_img {
        height: 200px;
    }
    
    .gall_text_href {
        padding: 12px 15px;
    }
    
    .gall_text_href a.bo_tit {
        font-size: 15px;
    }
    
    #bo_sch form {
        flex-direction: column;
        align-items: stretch;
    }
    
    #bo_sch select,
    .sch_input,
    .sch_btn {
        width: 100%;
        margin-bottom: 10px;
    }
    
    .sch_btn {
        margin-bottom: 0;
    }
    
    .pg {
        flex-wrap: wrap;
        justify-content: center;
        gap: 3px;
    }
    
    .pg_current,
    .pg_page {
        padding: 6px 10px;
        font-size: 13px;
    }
}

/* Tablet responsive adjustments */
@media screen and (min-width: 769px) and (max-width: 1023px) {
    .gall_row {
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
    }   
}

/* Desktop responsive adjustments */
@media screen and (min-width: 1024px) {
    .gall_row {
        grid-template-columns: repeat(4, 1fr);
        gap: 25px;
    }
    
    #bo_gall {
        padding: 30px 0;
    }
    
    #bo_sch {
        margin: 50px 0;
        padding: 25px;
    }
    
    #bo_sch form {
        justify-content: center;
    }
    
    .gall_text_href a.bo_tit {
        font-size: 17px;
    }
}

/* ========================================== */
/* Single Product Styles */
/* ========================================== */
.single-product {
    max-width: 100%;
}

.product-featured-image {
    text-align: center;
    margin-bottom: 30px;
}

.product-featured-image img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.product-info {
    margin-bottom: 40px;
}

.product-meta {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 30px;
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
}

.product-category,
.product-date {
    font-size: 14px;
    color: #666;
}

.product-category strong,
.product-date strong {
    color: #333;
    margin-right: 5px;
}

.product-category a {
    color: #ff6600;
    text-decoration: none;
}

.product-category a:hover {
    text-decoration: underline;
}

.product-excerpt {
    font-size: 18px;
    font-weight: 500;
    color: #555;
    line-height: 1.6;
    margin-bottom: 20px;
    padding: 20px;
    background: #f8f9fa;
    border-left: 4px solid #ff6600;
    border-radius: 0 8px 8px 0;
}

.product-content {
    font-size: 16px;
    line-height: 1.7;
    color: #444;
}

.product-content h2,
.product-content h3,
.product-content h4 {
    color: #333;
    margin-top: 30px;
    margin-bottom: 15px;
}

.product-content h2 {
    font-size: 24px;
    border-bottom: 2px solid #ff6600;
    padding-bottom: 10px;
}

.product-content h3 {
    font-size: 20px;
}

.product-content h4 {
    font-size: 18px;
}

.product-content p {
    margin-bottom: 15px;
}

.product-content ul,
.product-content ol {
    margin-bottom: 20px;
    padding-left: 30px;
}

.product-content li {
    margin-bottom: 8px;
}

/* Product Navigation */
.product-navigation {
    margin-top: 50px;
    border-top: 1px solid #e5e5e5;
    padding-top: 40px;
}

.nav-links {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 30px;
}

.nav-previous,
.nav-next {
    flex: 1;
    max-width: 45%;
}

.nav-next {
    text-align: right;
}

.nav-links .btn {
    display: block;
    padding: 15px 20px;
    background: #f8f9fa;
    color: #333;
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.3s ease;
    border: 1px solid #e5e5e5;
}

.nav-links .btn:hover {
    background: #ff6600;
    color: #fff;
    border-color: #ff6600;
}

.nav-links .btn span {
    display: block;
    font-size: 13px;
    color: #666;
    margin-bottom: 5px;
}

.nav-links .btn:hover span {
    color: #fff;
}

.nav-links .btn strong {
    display: block;
    font-size: 16px;
    font-weight: 500;
}

.back-to-archive {
    text-align: center;
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn-primary {
    background: #ff6600;
    color: #fff;
}

.btn-primary:hover {
    background: #e55a00;
    color: #fff;
}

.btn-outline {
    background: transparent;
    color: #ff6600;
    border: 2px solid #ff6600;
}

.btn-outline:hover {
    background: #ff6600;
    color: #fff;
}

/* Related Products */
.related-products {
    margin-top: 60px;
    border-top: 1px solid #e5e5e5;
    padding-top: 40px;
}

.related-products h3 {
    font-size: 24px;
    color: #333;
    text-align: center;
    margin-bottom: 30px;
    position: relative;
}

.related-products h3:after {
    content: '';
    width: 50px;
    height: 3px;
    background: #ff6600;
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
}

/* Mobile responsive for single product */
@media screen and (max-width: 768px) {
    .product-featured-image {
        margin-bottom: 20px;
    }
    
    .product-meta {
        flex-direction: column;
        gap: 15px;
        padding: 15px;
    }
    
    .product-excerpt {
        font-size: 16px;
        padding: 15px;
        margin-bottom: 15px;
    }
    
    .product-content {
        font-size: 14px;
        line-height: 1.6;
    }
    
    .product-content h2 {
        font-size: 20px;
        margin-top: 25px;
    }
    
    .product-content h3 {
        font-size: 18px;
    }
    
    .product-content h4 {
        font-size: 16px;
    }
    
    .product-navigation {
        margin-top: 40px;
        padding-top: 30px;
    }
    
    .nav-links {
        flex-direction: column;
        gap: 15px;
    }
    
    .nav-previous,
    .nav-next {
        max-width: 100%;
        text-align: left;
    }
    
    .nav-links .btn {
        padding: 12px 15px;
    }
    
    .nav-links .btn strong {
        font-size: 14px;
    }
    
    .back-to-archive {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }
    
    .related-products {
        margin-top: 40px;
        padding-top: 30px;
    }
    
    .related-products h3 {
        font-size: 20px;
        margin-bottom: 20px;
    }
}

/* Tablet responsive for single product */
@media screen and (min-width: 769px) and (max-width: 1023px) {
    .product-featured-image img {
        max-width: 600px;
    }
    
    .product-meta {
        justify-content: space-around;
    }
    
    .nav-links {
        gap: 30px;
    }
    
    .related-products .gall_row {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Desktop responsive for single product */
@media screen and (min-width: 1024px) {
    .product-featured-image img {
        max-width: 700px;
    }
    
    .product-content {
        max-width: 800px;
        margin: 0 auto;
    }
    
    .product-meta {
        max-width: 800px;
        margin: 0 auto 30px auto;
    }
    
    .related-products .gall_row {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* ========================================== */
/* Product Overview & Category Pages */
/* ========================================== */
.featured-products {
    margin-top: 40px;
}

.featured-products h3 {
    font-size: 24px;
    color: #333;
    text-align: center;
    margin-bottom: 40px;
    position: relative;
}

.featured-products h3:after {
    content: '';
    width: 60px;
    height: 3px;
    background: #ff6600;
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
}

.products-overview {
    margin-bottom: 40px;
}

.category-preview {
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
}

.category-preview:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(0,0,0,0.12);
}

.category-preview h4 {
    font-size: 22px;
    margin-bottom: 15px;
}

.category-preview h4 a {
    color: #333;
    text-decoration: none;
    transition: color 0.3s ease;
}

.category-preview h4 a:hover {
    color: #ff6600;
}

.category-description {
    font-size: 16px;
    color: #666;
    line-height: 1.6;
    margin-bottom: 25px;
}

.category-featured-product {
    margin-bottom: 25px;
    border-top: 1px solid #f0f0f0;
    padding-top: 25px;
}

.product-preview {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

.product-image {
    flex-shrink: 0;
    width: 200px;
}

.product-image img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 8px;
}

.product-info {
    flex: 1;
}

.product-info h5 {
    font-size: 18px;
    margin-bottom: 10px;
}

.product-info h5 a {
    color: #333;
    text-decoration: none;
}

.product-info h5 a:hover {
    color: #ff6600;
}

.product-info p {
    font-size: 14px;
    color: #666;
    line-height: 1.5;
    margin-bottom: 15px;
}

.read-more {
    color: #ff6600;
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    transition: color 0.3s ease;
}

.read-more:hover {
    color: #e55a00;
}

.category-actions {
    text-align: center;
}

.category-actions .btn {
    display: inline-block;
    padding: 12px 25px;
    background: #ff6600;
    color: #fff;
    text-decoration: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.category-actions .btn:hover {
    background: #e55a00;
    transform: translateY(-2px);
}

.category-actions .count {
    font-weight: normal;
    opacity: 0.9;
}

.all-products-link {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid #e5e5e5;
}

.btn-large {
    padding: 15px 40px;
    font-size: 16px;
    font-weight: 600;
}

/* Category Products Display */
.category-products-display {
    margin-top: 40px;
}

.products-grid {
    margin-bottom: 40px;
}

.view-more-products {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid #e5e5e5;
}

/* Mobile responsive for product pages */
@media screen and (max-width: 768px) {
    .featured-products h3 {
        font-size: 20px;
        margin-bottom: 30px;
    }
    
    .category-preview {
        padding: 20px;
        margin-bottom: 20px;
    }
    
    .category-preview h4 {
        font-size: 20px;
        margin-bottom: 12px;
    }
    
    .category-description {
        font-size: 14px;
        margin-bottom: 20px;
    }
    
    .category-featured-product {
        margin-bottom: 20px;
        padding-top: 20px;
    }
    
    .product-preview {
        flex-direction: column;
        gap: 15px;
    }
    
    .product-image {
        width: 100%;
        text-align: center;
    }
    
    .product-image img {
        max-width: 250px;
        width: 100%;
    }
    
    .product-info h5 {
        font-size: 16px;
        text-align: center;
    }
    
    .product-info p {
        text-align: center;
    }
    
    .read-more {
        display: block;
        text-align: center;
    }
    
    .category-actions .btn {
        display: block;
        width: 100%;
        max-width: 300px;
        margin: 0 auto;
    }
    
    .all-products-link .btn-large {
        display: block;
        width: 100%;
        max-width: 300px;
        margin: 0 auto;
    }

    .navigation-buttons .wp-block-columns{
        flex-wrap: nowrap !important;
    }

    .prod{
        margin-top: 50px;
        min-height: 620px !important;
    }
}

/* Tablet responsive for product pages */
@media screen and (min-width: 769px) and (max-width: 1023px) {
    .product-image {
        width: 180px;
    }
    
    .product-image img {
        height: 135px;
    }
    
    .category-preview {
        padding: 25px;
    }
}

/* Desktop responsive for product pages */
@media screen and (min-width: 1024px) {
    .featured-products {
        margin-top: 60px;
    }
    
    .featured-products h3 {
        font-size: 28px;
        margin-bottom: 50px;
    }
    
    .products-overview {
        margin-bottom: 50px;
    }
    
    .category-preview {
        padding: 40px;
        margin-bottom: 40px;
    }
    
    .category-preview h4 {
        font-size: 24px;
    }
    
    .category-description {
        font-size: 16px;
    }
    
    .product-preview {
        gap: 30px;
    }
    
    .product-image {
        width: 220px;
    }
    
    .product-image img {
        height: 165px;
    }
    
    .product-info h5 {
        font-size: 19px;
    }
    
    .product-info p {
        font-size: 15px;
    }
}

@media screen and (max-width: 768px) {
    .mobile-submenu-list li{
        display: block !important;
        text-align: left !important;
    }
    .mobile-submenu-link {
        display: block !important;
        padding: 0.8rem 1.5rem !important;
        color: rgba(255, 255, 255, 0.8) !important;
        text-decoration: none !important;
        font-size: 14px !important;
        transition: all 0.3s ease !important;
        border-left: 3px solid transparent !important;
        padding-left: 5px !important;
    }
    .dropdown-toggle::after{
        display: none !important;
    }

    #footer .wp-block-columns{
        flex-wrap: wrap !important;        
        justify-content: center;
    }

    #footer .wp-block-columns .wp-block-column {
        flex-basis: 100% !important;
    }
}