summaryrefslogtreecommitdiff
path: root/app/static/styles/home.css
blob: 161abc80b4313b3602fe451bf6a11d837f6a44d0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
/* Tabs. */
.tab-yes {
    height: 100%;
    width: 6%;
    position: absolute;
    left: 0;
    background: var(--yes);
    animation-name: squeeze-refresh;
    animation-duration: var(--med-speed);
}
.tab-yes:hover ~ .feed-post {
    left: 6%;
    right: 0%;
    transition: var(--fast-speed);
}
.tab-no {
    height: 100%;
    width: 6%;
    position: absolute;
    right: 0;
    background: var(--no);
    animation-name: squeeze-refresh;
    animation-duration: var(--med-speed);
}
.tab-no:hover ~ .feed-post {
    left: 0%;
    right: 6%;
    transition: var(--fast-speed);
}

/* Feed of posts. */
.feed-post {
    height: 100%;
    left: 3%;
    right: 3%;
    background: white;
    background-image: url(../img/home.png);
    background-repeat: repeat-x;
    display: flex;
    position: absolute;
    flex-wrap: wrap;
    overflow: auto;
    justify-content: space-between;
    animation-name: fade-refresh;
    animation-duration: var(--slow-speed);
}

.post-wrapper {
    /* background: blue; */
    position: relative;
    /* height: 20rem; */
    height: 20%;
    max-width: 40%;
    margin: 1rem;
    perspective: 600px;
}

.post {
    position: relative;
    margin: 0 auto;
    height: 100%;
    width: 100%;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    transition-duration: var(--med-speed);
}
.post-wrapper:hover > .post {
    width: 65%;
    overflow-y: auto;
}

.btn-yes {
    height: 100%;
    width: 15%;
    position: absolute;
    left: 0;
    background: var(--yes);
    border-radius: 8px;
    transform: rotateY(-90deg);
    transition-duration: var(--slow-speed);
    transform-origin: right;
}
.post-wrapper:hover > .btn-yes {transform: rotateY(0deg);}

.btn-no {
    height: 100%;
    width: 15%;
    position: absolute;
    right: 0;
    background: var(--no);
    border-radius: 8px;
    transform: rotateY(90deg);
    transition-duration: 1s;
    transform-origin: left;
}
.post-wrapper:hover > .btn-no {transform: rotateY(0deg);}

/* Dynamic content reajustment if browser window is made too narrow */
@media (max-width: 900px) {
    .feed-post {
        display: inline;
    }
    .post-wrapper {
        max-width: 100%;
    }
}
Copyright 2019--2024 Marius PETER