@import url('https://fonts.googleapis.com/css?family=Lato|Noto+Sans+TC');
:root {
  --dark-gray: #303030;
  --light-gray: #aaaaaa;
  --white: #eeeeee;
}
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  /* outline: 1px red solid; */
}
html {
  font-size: 16px;
}

body {
  font-size: 16px;
  font-family: Lato, 'Noto Sans TC';
}
a {
  text-decoration: none;
  color: black;
}
nav {
  height: 2rem;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  position: fixed;
  mix-blend-mode: difference;
  background: black;
  z-index: 10;
}
nav ul {
  height: 100%;
  display: flex;
  padding-right: 3rem;
}

nav ul li {
  list-style: none;
  padding: 0.5rem;
  display: flex;
  align-items: center;
}
nav ul li:hover {
  border-bottom: 1px var(--white) solid;
}
nav a {
  color: white;
  mix-blend-mode: difference;
}

section {
  height: 100vh;
  /* overflow: hidden; */
  width: 100%;
}
p {
  line-height: 2;
}
.section-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}
.section-title {
  opacity: 0.5;
  letter-spacing: 2px;
  margin: 3rem;
}
.right {
  width: 50%;
  height: 100%;
  float: right;
}
.left {
  width: 50%;
  height: 100%;
  float: left;
}
.img {
  background-position: center;
  background-repeat: no-repeat;
  background-size: auto 100%;
  height: 100%;
  width: 100%;
}
/* ============== Home Section ============== */
.home {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  background: var(--white);
  background-image: url('img/home_bg.png');
  background-size: contain;
  background-repeat: repeat-y;
  background-position: center;
  color: white;
  position: relative;
  z-index: 1;
}
.home:after {
  content: '';
  background: #000;
  opacity: 0.3;
  width: 100%;
  height: 100%;
  position: absolute;
  z-index: 2;
}
.my-name {
  font-size: 3rem;
  z-index: 3;
  margin-left: 3rem;
}
.my-name img {
  width: 100%;
}

/* ============== About Section ============== */
.about {
  display: flex;
}

.about-image {
  background-image: url('img/selfie.jpg');
  height: 100%;
  width: 100%;
  background-size: cover;
}
.about-content {
  color: white;
  background-color: var(--dark-gray);
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
}
.about-content p {
  margin: 3rem;
}

/* ============== UI Work Section ============== */

.ui-works {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--white);
}

.ui-work {
  width: 250px;
  height: 250px;
  margin: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.ui-work1 {
  background-image: url('img/work1.png');
}
.ui-work2 {
  background-image: url('img/work2.png');
}
.ui-work3 {
  background-image: url('img/work3.png');
}

/* ============== DEV Work Section ============== */
.dev-works {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--dark-gray);
}
.dev-works .section-title {
  color: white;
}

.dev-work-wrapper > div {
  position: relative;
}

.dev-work {
  width: 320px;
  height: 230px;
  margin: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.dev-work1 {
  background-image: url('img/fish_game.png');
}

.dev-work2 {
  background-image: url('img/todo_list.png');
}

.work-title {
  color: #ffffff;
  opacity: 0;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 10;
}

/* ============== hover Section ============== */

.ui-work > .img,
.dev-work > .img {
  transition: all 0.3s 0.1s ease-out;
}

.ui-work:hover > .img,
.dev-work:hover > .img {
  filter: brightness(50%);
  background-size: auto 110%;
  transition: background-size 0.3s 0.1s ease-in-out, filter 1s ease;
}

.dev-work:hover .work-title,
.ui-work:hover .work-title {
  opacity: 1;
}

/* ============== Talks leSection ============== */

.talks {
  background: var(--white);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.talk1 {
  display: block;
  height: 300px;
  width: 60%;
  background-image: url('img/talk_1.jpg');
  background-size: contain;
}

.talk-info {
  margin: 3rem;
}
/* ============== Contact Section ============== */
.contact {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--dark-gray);
  color: var(--white);
}
.contact a {
  color: var(--white);
}

.contact-info > *,
.social-media > * {
  opacity: 0.6;
}
.contact-info > *:hover,
.social-media > *:hover {
  opacity: 1;
}
.contact-info {
  margin: 1rem;
}
.resume {
  padding-top: 1rem;
}
.v-line {
  height: 3rem;
  width: 1px;
  border-right: 1px solid var(--white);
}
.social-media-link {
  display: flex;
  margin: 1rem;
}
.social-media-icon {
  height: 30px;
  width: 30px;
  margin-right: 1rem;
}
.facebook {
  background-image: url('svg/facebook.svg');
}
.twitter {
  background-image: url('svg/twitter.svg');
}
.github {
  background-image: url('svg/github.svg');
}

/* ============== Work Content Page ============== */

header {
  background-image: url('https://source.unsplash.com/random/1000x600');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  height: 75vh;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  color: #ffffff;
  z-index: 1;
  position: relative;
}
header:after {
  content: '';
  background: black;
  opacity: 0.1;
  width: 100%;
  height: 100%;
  position: absolute;
  z-index: -1;
}
.back {
  opacity: 0.8;
  display: block;
  height: 2rem;
  width: 2rem;
  background-image: url('svg/left-arrow.svg');
  background-size: cover;
  position: fixed;
  top: 25px;
  left: 25px;
  z-index: 10;
  background-color: rgba(0, 0, 0, 0.1);
  mix-blend-mode: screen;
}

.back:hover {
  opacity: 1;
}
header h1,
header p {
  letter-spacing: 2px;
}
header p {
  margin: 1rem;
}

.work-content .wrapper {
  display: flex;
  height: 100%;
  width: 80%;
  margin: 0 auto;
  justify-content: center;
}

.work-content article {
  /* border: 1px grey solid; */
  width: 80%;
  padding: 3rem;
}
.work-content article h5 {
  font-size: 1rem;
  letter-spacing: 1px;
  margin-top: 5rem;
  margin-bottom: 2rem;
}
.work-content article p {
  margin: 0.8rem;
  color: var(--dark-grey);
}
.work-content article li {
  margin: 0.5rem;
  text-indent: 30px;
}
.work-content .caption {
  text-align: center;
  margin-top: 0rem;
  margin-bottom: 3rem;
  font-size: 0.8rem;
}

.work-content img {
  width: 100%;
  padding: 1rem;
  margin: 0 auto;
  display: block;
}

footer {
  margin-top: 10rem;
  height: 20vh;
  background: var(--dark-gray);
  display: flex;
  align-items: center;
  justify-content: center;
}
footer ul {
  display: flex;
  width: 60%;
  justify-content: space-around;
}
footer ul li {
  list-style: none;
}
footer ul li:hover {
  opacity: 0.8;
}
footer ul li a {
  color: var(--white);
}
iframe {
  margin: 0 auto;
  display: block;
}

/* ============== Work 1 Page ============== */
.page1 header {
  background-image: url('img/work1header.jpg');
}

/* ============== Work 2 Page ============== */
.page2 header {
  background-image: url('img/work2header.jpg');
}

/* ============== Work 3 Page ============== */
.page3 header {
  background-image: url('img/work3header.png');
}

@media screen and (max-width: 500px) {
  html {
    font-size: 12px;
  }
  nav {
  }
  nav ul {
    width: 100%;
    margin: 1.5rem;
    margin-top: 5rem;
    padding: 0;
    font-size: 1.5rem;
    justify-content: space-evenly;
  }

  .left,
  .right {
    width: 100%;
    height: 50%;
  }
  .section-wrapper {
    flex-direction: column;
  }
  .contact {
    flex-direction: column;
  }
  .v-line {
    height: 1px;
    width: 3rem;
    border: none;
    border-bottom: 1px solid var(--white);
    margin: 5rem;
  }
  .work-content .wrapper {
    width: 100%;
  }
  .work-content article {
    padding: 0;
  }
  footer {
    height: auto;
  }
  footer ul {
    flex-direction: column;
    margin-bottom: 3rem;
    justify-content: center;
  }
  footer ul li {
    margin-top: 2rem;
  }
  #maincontent {
    transform: scale(0.7);
  }
  iframe {
    width: 100%;
  }
}
