/* 기본 레이아웃 */
html, body {
    height: 100%;
    margin: 0;
    display: flex;
    flex-direction: column;
}

body {
    background-color: #fdf9f6;
    color: #333;
}

/* 헤더 */
header {
    padding: 0px;
    padding-top: 100px;
    background-color: #fdf9f6;
}
header h2 {
    margin-top: 0;
    color: #1a73e8;
}

/* 고정 메뉴 */
.fixed, .fixed2 {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
}
.fixed {
    background-color: #1a73e8;
    padding: 5px 0;
}
.fixed-menu {
    max-width: 900px;
    margin: auto;
    text-align: right;
}
.fixed-menu ul {
    list-style-type: none;
    margin: 0;
    padding: 0;
}
.fixed-menu li {
    display: inline-block;
    margin: 0 10px;
}
.fixed-menu a {
    text-decoration: none;
    color: #eee;
}
.fixed-menu a:hover {
    color: #fff;
}
.fixed2 {
    background-color: #ffffff;
    margin-top: 0px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}
.fixed2 table {
    width: 100%;
    max-width: 900px;
    margin: auto;
    margin-top: 30px;
}
.fixed2 td {
    vertical-align: top;
}


/* 콘텐츠 */
article {
    flex: 1;
    width: 90%;
    max-width: 840px;
    margin: 20px auto;
    padding: 20px;
    background-color: #fff;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
    border-radius: 8px;
}
section {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}
section:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}
section h3 {
    color: #1a73e8;
    margin-top: 0;
    border-left: 5px solid #1a73e8;
    padding-left: 10px;
}

/* 테이블 */
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
}
table td {
    padding: 10px;
    vertical-align: top;
}

/* 온라인 폼 */
.onlineForm table td {
    padding: 10px 0;
}
.onlineForm label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}
.onlineForm input[type="text"],
.onlineForm input[type="email"],
.onlineForm input[type="file"],
.onlineForm input[type="tel"],
.onlineForm textarea {
    width: calc(100% - 30px);
    padding: 10px;
    padding-right: 10px;
    margin-top: 5px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 1em;
}
.onlineForm textarea {
    min-height: 150px;
    resize: vertical;
}
.onlineForm td[colspan="2"] {
    width: 100%;
}
.onlineForm button[type="submit"],
.onlineForm button[type="button"] {
    padding: 10px;
    background-color: #1a73e8;
    color: #fff;
    border: none;
    border-radius: 5px;
    font-size: 1.1em;
    cursor: pointer;
    transition: background-color 0.3s ease;
}
.onlineForm button[type="submit"]:hover,
.onlineForm button[type="button"]:hover {
    background-color: #135abc;
}

button[type="submit"],
button[type="button"] {
    padding: 7px;
    background-color: #1a73e8;
    color: #fff;
    border: none;
    border-radius: 5px;
    font-size: 1.1em;
    cursor: pointer;
    vertical-align:bottom;
    transition: background-color 0.3s ease;
}
button[type="submit"]:hover,
button[type="button"]:hover {
    background-color: #135abc;
}

input[type="text"] {
    padding: 10px;
    padding-right: 10px;
    margin-top: 5px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 1em;
    vertical-align:bottom;
}
/* 푸터 */
footer {
    background-color: #333;
    color: #fff;
    padding: 20px;
    margin-top: 20px;
}
footer div {
    margin: auto;
    width: 100%;
    height: 100px;
    max-width: 880px;
    font-size:0.8em;
}

footer a {
    color: #fff;
}

footer a:hover {
    color: #fff;
}

/* 팝업 */
.popup {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    z-index: 1000;
}
.popup-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: white;
    padding: 10px;
    border-radius: 5px;
    text-align: center;
}
.popup-content img {
    max-width: 100%;
    max-height: 90%;
}

/* 다운로드 링크 */
.downloads a {
    text-decoration: none;
    color: #666666;
    font-size: 0.9em;
}
.downloads a:hover {
    color: #1b1b1b;
    font-weight: bold;
}

/* 반응형 */
@media (max-width: 768px) {
    footer {
        flex-direction: column;
        align-items: flex-start;
    }
    footer img {
        margin-top: 10px;
    }
    .fixed-menu ul {
        padding: 0 10px;
    }
    .fixed-menu li {
        margin: 0 10px;
    }
    article {
        width: 95%;
        padding: 10px;
    }
    section.contactus table,
    footer table {
        display: block;
    }
    section.contactus table td,
    footer table td {
        display: block;
        width: 100% !important;
        text-align: left !important;
        padding: 5px 0;
    }
    .onlineForm table tr,
    .onlineForm table td {
        display: block;
        width: 100%;
        padding: 5px 0;
    }
    .onlineForm input[type="text"],
    .onlineForm input[type="email"],
    .onlineForm input[type="file"],
    .onlineForm textarea {
        width: calc(100% - 22px);
    }
}
